how can I compile gtk (itself) with Windows SDK ?
Applications built using Gtk# will run on many platforms including Linux, Windows and macOS. The Mono packages for Windows include GTK, Gtk# and a native theme to make applications look like native Windows applications.
Language BindingsGTK is written in C but has been designed to support a wide range of languages such as Python, JavaScript, C++, Rust and many more.
To compile a GTK application, you need to tell the compiler where to find the GTK header files and libraries. This is done with the pkg-config utility. Deprecated GTK functions are annotated to make the compiler emit warnings when they are used (e.g. with gcc, you need to use the -Wdeprecated-declarations option).
Building in Visual Studio is still quite a lot of work. I've done it, but I don't have reproducible steps for you right now. However, if you have a Linux machine around and are willing to cross-compile I have written up directions on how to build GTK+ for Win32 by cross-compiling.
http://live.gnome.org/Cross%20compiling%20GTK%2B%20for%20Win32
It's also possible to build using MSYS in the command-line on Windows, but that's also a major pain in the ass to get setup. It's also really, really slow. Cross-compiling from Linux is, at a minimum, ten times faster. I'm not 100% sure but it seems to be because if you build using the standard build system then there is a lot of process spawning, which is quite expensive in Win32 compared to Linux.
However, if you want to go this way then install MSYS and pull down the source for glib, atk, cairo, pango, and gtk+.. then try to build using the standard Linux way: 1/ untar the source tarball 2/ in the source's root directory do: ./configure 3/ make
There will undoubtedly be other dependencies that you need to install, such as libpng and libjpeg.
Try the HexChat builds. They use Visual Studio 2010 and come with some prepared scripts and solutions to make your life much easier. Oh and you get binary downloads as well.
http://gtk.hexchat.org/
GTK can be compiled under Cygwin or Microsoft Visual C++.
Did you try this installation method? Look the Microsoft Windows section...
Hope it helps!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With