GithubHelp home page GithubHelp logo

aliencoweatcake / wintoastlibc Goto Github PK

View Code? Open in Web Editor NEW
3.0 2.0 0.0 43 KB

WinToastLibC is a C bindings for WinToast library. With this bindings you can use the modern toast notifications of Windows 8 & Windows 10 in projects written in C or compiled with non-MSVC compilers

License: MIT License

CMake 2.14% Batchfile 0.57% C 22.34% C++ 74.95%
c notifications toast-notifications toast-templates windows-10

wintoastlibc's Introduction

WinToastLibC

WinToastLibC is a C bindings for WinToast library. With this bindings you can use the modern toast notifications of Windows 8 & Windows 10 in projects written in C or compiled with non-MSVC compilers.

Documentation

Since this project is just bindings, documentation can be found in WinToast project.

Examples

  • example1.c: minimal C code to show the toast notification
  • example2.c: more complex example with image and basic AUMID registration

MinGW integration

Build as is

gcc example1.c wintoastlibc.lib -lole32 -mwindows

Build with fake implib

mv wintoastlibc.lib libwintoastlibc.dll.a
gcc example1.c -L. -lwintoastlibc -lole32 -mwindows

Build with true implib

gendef wintoastlibc.dll
dlltool.exe -d wintoastlibc.def -D wintoastlibc.dll -l libwintoastlibc.dll.a
gcc example1.c -L. -lwintoastlibc -lole32 -mwindows

Build with delayed loader (dll)

Loader source: wintoastlibc_lazy.c

gcc -shared -o wintoastlibc_lazy.dll \
    -Wl,--out-implib=libwintoastlibc.dll.a \
    -Wl,--export-all-symbols -Wl,--enable-auto-import \
    -Wl,--whole-archive wintoastlibc_lazy.c -Wl,--no-whole-archive
gcc example1.c -L. -lwintoastlibc -lole32 -mwindows

Build with delayed loader (static)

Loader source: wintoastlibc_lazy.c

gcc -DWTLC_BUILD_STATIC -o wintoastlibc_lazy.o -c wintoastlibc_lazy.c
ar rcs libwintoastlibc.dll.a wintoastlibc_lazy.o
gcc example1.c -DWTLC_BUILD_STATIC -L. -lwintoastlibc -lole32 -mwindows

Links

wintoastlibc's People

Contributors

aliencoweatcake avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.