Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Mail Systems
Eclipse Documentation

How To Guides
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Problem Solutions
Privacy Policy




Gtk+/Gnome Application Development
Prev Home Next

Source Tree Checklist

As an initial overview, here are the important steps in creating a skeletal Gnome source tree. If you are starting a new program, you can simply follow this list and you won't forget anything. The rest of this chapter explains the checklist in more detail. It might also be helpful to download a Gnome package or two to look at as you follow the discussion (in particular, the "GnomeHello" source tree is intended to illustrate a proper build setup).

  1. Create a toplevel directory to hold all the components of your application, including build files, documentation, and translations.

  2. It's often nice to create a src subdirectory of this toplevel directory to keep source code separate from everything else.

  3. In the toplevel directory, create AUTHORS, NEWS, COPYING, and README files. If desired, also create an empty ChangeLog.

  4. Write a; the main purpose of is to determine which compiler, compiler flags, and linker flags to use. can also #define symbols to reflect features of the current platform, placing these definitions in the automatically-generated file config.h.

  5. Write acconfig.h, which is a template for This file should #undef each symbol you will potentially #define in config.h. The autoheader program creates based on acconfig.h, and autoconf creates config.h. autoheader comes with autoconf.

  6. Create an empty file,; this is used by the AM_CONFIG_HEADER macro in

  7. Write a in the toplevel directory listing each subdirectory which contains source code; in each subdirectory, also write a

  8. Run the gettextize program that comes with the gettext package. This creates the intl and po directories, needed for internationalization (gettextize is documented in the gettext manual). The intl contains the GNU gettext source code; if users compiling the program do not have gettext, they can pass the --with-included-gettext option to configure to automatically compile a static version in the intl directory. The po directory holds the translation files; gettextize will also create a file called po/, used to build the translations.

  9. Create a file called po/ listing source files which should be scanned for strings to translate. can be empty at first.

  10. Copy and the macros directory from another Gnome module. You must modify to reflect the name of your package. Running will invoke libtoolize, aclocal, autoheader, automake, and autoconf.

  11. invokes automake with the --add-missing argument. This will add some files, such as INSTALL with generic installation instructions. You can (and should) edit INSTALL to include any specific instructions for your application. will also create a Makefile in each directory.

Gtk+/Gnome Application Development
Prev Home Next

  Published under free license. Design by Interspire