Makefile.am 3.19 KB
Newer Older
Owen Taylor's avatar
Owen Taylor committed
1
## Process this file with automake to produce Makefile.in
2
include $(top_srcdir)/glib.mk
Owen Taylor's avatar
Owen Taylor committed
3

4 5 6
# http://people.gnome.org/~walters/docs/build-api.txt
.buildapi-allow-builddir:

7
ACLOCAL_AMFLAGS = -I m4macros ${ACLOCAL_FLAGS}
8

9
SUBDIRS = . m4macros glib gmodule gthread gobject gio po docs tests
10
DIST_SUBDIRS = $(SUBDIRS) build
Tim Janik's avatar
Tim Janik committed
11

12 13
bin_SCRIPTS = glib-gettextize

14
if OS_LINUX
15
TESTS += check-abis.sh
16 17
endif

18 19 20 21 22
AM_CPPFLAGS = 					\
	-DG_LOG_DOMAIN=g_log_domain_glib 	\
	@GLIB_DEBUG_FLAGS@ 			\
	-DG_DISABLE_DEPRECATED 			\
	-DGLIB_COMPILATION
23

24
EXTRA_DIST += 			\
25 26 27
	ChangeLog.pre-2-20	\
	ChangeLog.pre-2-18	\
	ChangeLog.pre-2-16	\
Matthias Clasen's avatar
Matthias Clasen committed
28
	ChangeLog.pre-2-14	\
29 30
	ChangeLog.pre-2-12	\
	ChangeLog.pre-2-10	\
Matthias Clasen's avatar
Matthias Clasen committed
31
	ChangeLog.pre-2-8	\
Owen Taylor's avatar
Owen Taylor committed
32 33
	ChangeLog.pre-2-6	\
	ChangeLog.pre-2-4	\
34
	ChangeLog.pre-2-2	\
Owen Taylor's avatar
Owen Taylor committed
35
	ChangeLog.pre-2-0	\
Owen Taylor's avatar
Owen Taylor committed
36
	ChangeLog.pre-1-2	\
37
	glib-zip.in		\
Tim Janik's avatar
Tim Janik committed
38
	NEWS.pre-1-3		\
39 40
	acglib.m4		\
	sanity_check		\
41
	README.commits		\
42 43
	README.in		\
	INSTALL.in		\
44
	README.win32		\
45 46
	HACKING			\
	autogen.sh		\
Matthias Clasen's avatar
Matthias Clasen committed
47 48
	glib.mk			\
	glib-tap.mk		\
Matthias Clasen's avatar
Matthias Clasen committed
49
	tap-test		\
50
	makefile.msc		\
51
	msvc_recommended_pragmas.h \
52
	config.h.win32.in	\
Owen Taylor's avatar
Owen Taylor committed
53
        po/po2tbl.sed.in        \
54 55 56
	glib-2.0.pc.in 		\
	gobject-2.0.pc.in 	\
	gmodule-2.0.pc.in	\
57
	gmodule-export-2.0.pc.in	\
58
	gmodule-no-export-2.0.pc.in	\
59
	gthread-2.0.pc.in	\
60 61
	gio-2.0.pc.in		\
	gio-unix-2.0.pc.in	\
62
	gio-windows-2.0.pc.in	\
63 64 65
	check-abis.sh		\
	gtk-doc.make		\
	$(NULL)
66

67

68
# These may be in the builddir too
69
BUILT_EXTRA_DIST += 		\
70 71
	README			\
	INSTALL			\
72
	ChangeLog		\
Soeren Sandmann's avatar
Soeren Sandmann committed
73
	config.h.win32		\
74
	$(NULL)
75

76
CONFIGURE_DEPENDENCIES = acglib.m4
77

78
ChangeLog:
79
	$(AM_V_GEN) if test -d "$(srcdir)/.git"; then \
80 81 82 83 84 85 86 87 88 89 90
	  (GIT_DIR=$(top_srcdir)/.git ./missing --run git log GLIB_2_20_0^^.. --stat) | fmt --split-only > $@.tmp \
	  && mv -f $@.tmp $@ \
	  || ($(RM) $@.tmp; \
	      echo Failed to generate ChangeLog, your ChangeLog may be outdated >&2; \
	      (test -f $@ || echo git-log is required to generate this file >> $@)); \
	else \
	  test -f $@ || \
	  (echo A git checkout and git-log is required to generate ChangeLog >&2 && \
	  echo A git checkout and git-log is required to generate this file >> $@); \
	fi

91
pkgconfigdir = $(libdir)/pkgconfig
92 93 94 95 96
pkgconfig_DATA = glib-2.0.pc gobject-2.0.pc gmodule-2.0.pc gmodule-export-2.0.pc gmodule-no-export-2.0.pc gthread-2.0.pc gio-2.0.pc

if OS_UNIX
pkgconfig_DATA += gio-unix-2.0.pc
endif
Havoc Pennington's avatar
Havoc Pennington committed
97

98 99 100 101
if OS_WIN32
pkgconfig_DATA += gio-windows-2.0.pc
endif

102 103
$(pkgconfig_DATA): config.status

104
# build documentation when doing distcheck
105
DISTCHECK_CONFIGURE_FLAGS = --enable-debug --enable-gtk-doc --enable-man --disable-maintainer-mode
106

107
DISTCLEANFILES += config.lt
108

109
distclean-local: lcov-clean
110 111 112 113
	if test $(srcdir) = .; then :; else \
	    rm -f $(BUILT_EXTRA_DIST); \
	fi

114
.PHONY: files release sanity snapshot ChangeLog
Owen Taylor's avatar
Owen Taylor committed
115 116 117 118 119 120 121

files:
	@files=`ls $(DISTFILES) 2> /dev/null `; for p in $$files; do \
	  echo $$p; \
	done

release:
122 123 124 125 126 127 128 129
	rm -rf .deps */.deps
	cd docs && make glib.html
	$(MAKE) distcheck

sanity:
	./sanity_check $(VERSION)

snapshot:
Owen Taylor's avatar
Owen Taylor committed
130 131 132 133
	$(MAKE) dist distdir=$(PACKAGE)-snap`date +"%Y%m%d"`

snapcheck:
	$(MAKE) distcheck distdir=$(PACKAGE)-snap`date +"%Y%m%d"`
134

135
dist-hook: $(BUILT_EXTRA_DIST)
136
	files='$(BUILT_EXTRA_DIST)'; \
137 138
	for f in $$files; do \
	  if test -f $$f; then d=.; else d=$(srcdir); fi; \
139
	  rm -f $(distdir)/$$f && cp $$d/$$f $(distdir) || exit 1; done