![gtk linux gtk linux](https://www.omgubuntu.co.uk/wp-content/uploads/2015/06/arc-gtk-theme.jpg)
![gtk linux gtk linux](https://raw.githubusercontent.com/alexheretic/apart-gtk/readme-images/apart-gtk-usage.gif)
PS: Please feel free to add anything to improve this topic.
![gtk linux gtk linux](https://www.omgubuntu.co.uk/wp-content/uploads/2017/09/ant-gtk-theme.jpg)
Gtk linux update#
Gtk linux install#
You can install in a specific directory with: apt-get install libgstreamer-plugins-base0.10-dev.If you want wxMediaCtrl (mediaplayer), you'll probably change the script to: Using the command line prompt in root mode, do: Using the -disable-shared option of configure with wxGTK links wxGTK into your program statically, but not GTK+ itself, which will usually still be linked dynamically. You should note that in most cases (if not all cases), GTK is linked dynamically.Remember that GTK is licensed under LGPL, which essentially means that in order to link it to your application _statically_, your application will have to be (L)GPL-licensed.Please consider that I compiled wxwidgets with gtk2 statically monolithic (-disable-shared -enable-monolithic) I did not solve all problems, but this is a start.
Gtk linux how to#
Ii libpthread-workqueue0 0.8.I spent time understanding how to compile a wx application for binary delivery on any linux distrib. Ii libpthread-workqueue-dev 0.8.2-1 thread pool library (development files) Ii libpthread-stubs0-dev 0.3-3 pthread stubs not provided by native libc, development files Ii libpthread-stubs0 0.3-3 pthread stubs not provided by native libc Ii libevent-pthreads-2.0-5 2.0.16-stable-1 Asynchronous event notification library (pthreads) Gtk_window_set_title (GTK_WINDOW (window), "Hello World") Window = gtk_window_new (GTK_WINDOW_TOPLEVEL) In file included from /usr/include/glib-2.0/gio/gio.h:47,įrom /usr/include/gtk-3.0/gdk/gdkapplaunchcontext.h:28, usr/include/glib-2.0/glib/deprecated/gthread.h:162: error: expected specifier-qualifier-list before ‘pthread_t’ usr/include/glib-2.0/glib/deprecated/gthread.h:133: error: expected specifier-qualifier-list before ‘pthread_mutex_t’ usr/include/glib-2.0/glib/deprecated/gthread.h:123:21: error: pthread.h: No such file or directory In file included from /usr/include/glib-2.0/glib.h:108,įrom /usr/include/gtk-3.0/gdk/gdkconfig.h:13, I586-mingw32msvc-gcc: unrecognized option '-pthread' #$ i586-mingw32msvc-gcc /home/spivvi/Desktop/test.c -o test.exe `pkg-config -cflags -libs gtk+-3.0` Everthing seems to be so smooth but in during comilation i got this compiler error: Here we go ! Transfer this folder to a Windows box. If you extracted to " /opt/gtk3-win32" e.g. Create a folder containing the binary and the Windows. It won't run on our Linux system, because it's targeting Windows ! I586-mingw32msvc-gcc source.c -o executable.exe `pkg-config -cflags -libs gtk+-3.0`Ī new executable should have been created if everything went well. We are ready to compile an sample C source ! Let's use a command in this style : :Įxport PKG_CONFIG_PATH=/opt/gtk3-win32/lib/pkgconfig
![gtk linux gtk linux](http://static.softoware.org/data/programs/images/greyness-blue-gtk-theme_86782.jpg)
We will tell "pkg-config" to locate GTK+ libraries in our custom path. :įind -name '*.pc' | while read pc do sed -e -i "$pc" done If you extracted it to " /opt/gtk3-win32" e.g. In a terminal, move to the " gtk3-win32" folder you just created.
Gtk linux archive#
(ps : Create a folder named " gtk3-win32" where you want, put the ZIP archive therein and extract it with : Download the latest all-in-one bundle ZIP archive directly from the official website (here's a direct link for impatients.). Install the GCC compiler for Windows (namely MinGW) :
Gtk linux code#
We have a C application using GTK+ 3 as its graphical toolkit :Īs the GTK+ 3 Windows binaries now have an official distribution, we will be able to use to create a Windows version of our application, without modifiying the source code nor having a Windows box available. Objectives : compile a C/GTK+3 application under Linux, and produce a valid Windows © binary.