1 # Example for use of GNU gettext.
2 # This file is in the public domain.
4 # Makefile configuration - processed by automake.
6 # General automake options.
7 AUTOMAKE_OPTIONS = foreign no-dependencies
8 ACLOCAL_AMFLAGS = -I m4
10 # The list of subdirectories containing Makefiles.
13 # The list of programs that are built.
16 # The source files of the 'hello' program.
17 hello_SOURCES = hello.c resources.c
19 # Define a C macro LOCALEDIR indicating where catalogs will be installed.
20 DEFS = -DLOCALEDIR=\"$(localedir)\" @DEFS@
22 # Make sure the gnome.h include file is found.
23 AM_CPPFLAGS = $(GTK_CFLAGS)
25 # Link time dependencies.
26 LDADD = $(GTK_LIBS) @LIBINTL@
28 BUILT_SOURCES = gschemas.compiled resources.c
30 # Compile GSettings schema.
31 gschemas.compiled: hello.gschema.xml
32 $(AM_V_GEN) $(GLIB_COMPILE_SCHEMAS) .
34 # Compile assets into a C source and link it with the application.
35 resources.c: hello.gresource.xml hello.ui
36 $(AM_V_GEN) $(GLIB_COMPILE_RESOURCES) $< --target=$@ \
37 --sourcedir=$(srcdir) --generate-source
39 desktopdir = $(datadir)/applications
40 desktop_DATA = hello.desktop
42 # Merge translations back into a Desktop Entry file.
44 # Note that the resulting file should be included in EXTRA_DIST and
45 # processed earlier than the variable substitution below. Otherwise,
46 # the 'msgfmt' command will be required at compile-time.
47 hello.desktop.in: hello.desktop.in.in
48 $(AM_V_GEN) $(MSGFMT) --desktop --template $< -d $(top_srcdir)/po -o $@
50 # Substitute variables in a Desktop Entry file.
51 hello.desktop: hello.desktop.in
52 $(AM_V_GEN) sed -e 's|@bindir[@]|$(bindir)|g' $< > $@
54 CLEANFILES = $(BUILT_SOURCES) hello.desktop $(desktop_DATA)
56 # Additional files to be distributed.
57 EXTRA_DIST = autogen.sh autoclean.sh hello.ui \
58 hello.desktop.in.in hello.desktop.in \
62 MAINTAINERCLEANFILES = hello.desktop.in