Added openGL to automake build. Fixed perspective display.
[familia.git] / Makefile.am
1 AUTOMAKE_OPTIONS = gnu subdir-objects
2 ACLOCAL_AMFLAGS = ${ACLOCAL_FLAGS} -I m4
3 SUBDIRS = po
4
5 EXTRA_DIST = \
6         config.rpath \
7         data/gui.glade \
8         src/gettext.h \
9         doc/CodingStyle
10
11 MAINTAINERCLEANFILES = \
12         aclocal.m4 \
13         config.h.in \
14         config.log \
15         config.status \
16         configure \
17         configure.files \
18         stamp-h.in \
19         depcomp \
20         install-sh \
21         missing
22
23
24 CLEANFILES = \
25         %.o \
26         %.bak \
27         %~ \
28         doxyfile.stamp
29
30 bin_PROGRAMS = bin/familia
31 noinst_HEADERS = src/i18n.h
32 dist_noinst_SCRIPTS = autogen.sh
33
34 bin_familia_SOURCES = \
35         src/dialogs/about_dialog.c \
36         src/dialogs/openfile_dialog.c \
37         src/viewport/drawing_area.c \
38         src/storage/storage.c \
39         src/storage/individual.c \
40         src/storage/family.c \
41         src/storage/positions.c \
42         src/math/positions.c \
43         src/gedcom/familia_gedcom.c \
44         src/memory_stack.c \
45         src/gui.c \
46         src/main.c \
47         src/debug.c \
48         src/commandline.c
49
50 bin_familia_CPPFLAGS = \
51         $(bin_familia_CFLAGS) \
52         -Wall -pedantic -Wextra \
53         @GEDCOM_CFLAGS@ \
54         -I$(top_srcdir)/src \
55         -Wl,--export-dynamic
56
57 bin_familia_LDADD = \
58         $(bin_familia_LIBS) \
59         $(GLU_LIBS) \
60         @GEDCOM_LIBS@ \
61         -L/usr/lib \
62         -lzip
63
64 bin_familia_LDFLAGS = $(LTLIBINTL)
65
66 localedir = $(datadir)/locale
67
68 DEFS = -DLOCALEDIR=\"$(localedir)\" \
69          -DDATADIR=\"$(pkgdatadir)\" \
70         @DEFS@
71
72 all-local: doxyfile.stamp
73         test -d bin/data || mkdir bin/data
74         cp data/gui.glade bin/data/
75         cp -r data/pixmaps bin/data/
76
77 # Documentation
78
79 if HAVE_DOXYGEN
80
81 directory = $(top_srcdir)/doc/man/man3
82
83 doxyfile.stamp:
84         $(DOXYGEN) Doxyfile
85         echo Timestamp > doxyfile.stamp
86
87 #all-local: doxyfile.stamp
88
89 clean-local:
90         rm -rf $(top_srcdir)/doc/man
91
92 endif
93
94 # Localization
95
96 check-gettext:
97         @if test x$(USE_NLS) != "xyes" ; then echo "Missing gettext. Rerun configure and check for" \
98         "'checking whether to use NLS... yes'!" ; exit 1 ; fi
99
100 update-po: check-gettext
101         @find $(srcdir)/src $(srcdir)/data -name '*[glade|c|h]' -type f -print | sort > $(srcdir)/po/POTFILES.in.2 ; \
102         if diff $(srcdir)/po/POTFILES.in $(srcdir)/po/POTFILES.in.2 >/dev/null 2>&1 ; then \
103                 rm -f $(srcdir)/po/POTFILES.in.2 ; \
104         else \
105                 mv $(srcdir)/po/POTFILES.in.2 $(srcdir)/po/POTFILES.in ; \
106         fi
107         cd po && $(MAKE) $(AM_MAKEFLAGS) update-po
108
109 update-gmo: check-gettext
110         cd po && $(MAKE) $(AM_MAKEFLAGS) update-gmo
111
112 force-update-gmo: check-gettext
113         touch po/*.po
114         cd po && $(MAKE) $(AM_MAKEFLAGS) update-gmo
115
116 force-update-gmo-%: check-gettext
117         @language=`echo $@ | sed s/force-update-gmo-//` ; \
118         if test ! -f po/$$language.po ; then echo "file po/$$language.po does not exist" ; exit 1 ; fi ; \
119         touch po/$$language.po ; \
120         cd po && $(MAKE) $(AM_MAKEFLAGS) update-gmo
121
122 .PHONY: check-gettext update-po update-gmo force-update-gmo