Hi, Link, On Tue, Aug 22, 2017 at 4:07 PM, Link Dupont <l...@sub-pop.net> wrote: > Hi Igor, > > On Tue, 2017-08-22 at 15:48 -0400, Igor Korot wrote: >> Hi, ALL, >> I have setup to do my development for GTK+2 and GTK+3 on 2 different >> machines. >> My project is on GitHub and there is one codebase. >> >> What's the best way to set up Makefiles? > > You're going to find this is a matter of opinion. Traditionally, GTK+ > and GNOME projects have used GNU autotools for their build system. Many > are now moving to meson. Either way, I suggest you take some time and > learn one or both in order to make an informed decision about which > build system is best for you. > > Meson is relatively new, and has most of its documentation on its > website[1]. GNU autotools has a vast online manual available[2], > however I recommend reading "Autotools: A Practition's Guide to to GNU > Autoconf, Automake, and Libtool"[3] to get a hands-on understanding of > the autotools suite. > > 1: http://mesonbuild.com/ > 2: http://www.gnu.org/software/autoconf/manual/, etc. > 3: https://www.nostarch.com/autotools.htm > > You could, of course, eschew all of those and use your own hand- > maintained Makefile. You'll find varying levels of opinion there too, > although you'll encounter some pretty compelling arguments against > maintaining your own hand-crafted Makefiles anywhere you look. In this > case, you could consider at least using pkg-config to find out whether > your required libraries are installed and where they are located on > your build host.
I'm actually working with Anjuta. Anjuta is Makefile-based. The problem is that if I change something I need to do a 'git pull', which overwrites the "pkg-config --includedir gtk+2" to be "pkg-config --includedir gtk+3". So I'm thinking to just create an environment variable - something like "USE_GTK3", export it on the machine set for GTK3, then fix the Makefile.in for my project. Then this will be kept independently of which version I have installed on the system. Or is there a better and simpler alternative? Maybe pkg-config has something like "set the current GTK+ version to be GTK+3"? Thank you. > >> Is it feasible to define some environment variable and select GTK >> version if it defined? >> >> Or there is a better alternative? >> >> Thank you. >> _______________________________________________ >> gtk-list mailing list >> gtk-list@gnome.org >> https://mail.gnome.org/mailman/listinfo/gtk-list _______________________________________________ gtk-list mailing list gtk-list@gnome.org https://mail.gnome.org/mailman/listinfo/gtk-list