Makefile.am 2.78 KB
Newer Older
Owen Taylor's avatar
Owen Taylor committed
1 2
## Process this file with automake to produce Makefile.in

3 4
AUTOMAKE_OPTIONS = 1.4

5
SUBDIRS = . m4macros glib gobject gmodule gthread tests build po docs
Tim Janik's avatar
Tim Janik committed
6

7 8
bin_SCRIPTS = glib-gettextize

9
INCLUDES = -DG_LOG_DOMAIN=g_log_domain_glib @GLIB_DEBUG_FLAGS@ \
Owen Taylor's avatar
Owen Taylor committed
10
	-DG_DISABLE_DEPRECATED -DGLIB_COMPILATION
11

Owen Taylor's avatar
Owen Taylor committed
12 13
EXTRA_DIST = 			\
	ChangeLog.pre-1-2	\
14
	glib.spec.in		\
15
	glib-zip.in		\
Tim Janik's avatar
Tim Janik committed
16
	NEWS.pre-1-3		\
17 18
	acglib.m4		\
	sanity_check		\
19 20
	README.in		\
	INSTALL.in		\
21
	README.win32		\
Owen Taylor's avatar
Owen Taylor committed
22
	TODO.xml		\
23 24
	makefile.msc		\
	makefile.mingw		\
25
	glibconfig.h.win32.in	\
26
	msvc_recommended_pragmas.h \
27
	config.h.win32.in	\
Owen Taylor's avatar
Owen Taylor committed
28
        po/po2tbl.sed.in        \
29 30 31
	glib-2.0.pc.in 		\
	gobject-2.0.pc.in 	\
	gmodule-2.0.pc.in	\
32
	gthread-2.0.pc.in	\
33 34 35
	glib-2.0-uninstalled.pc.in 	\
	gobject-2.0-uninstalled.pc.in 	\
	gmodule-2.0-uninstalled.pc.in	\
36
	gthread-2.0-uninstalled.pc.in
37

38
# These may be in the builddir too
39
BUILT_EXTRA_DIST = 		\
40 41
	glibconfig.h.win32	\
	config.h.win32		\
42 43
	glib.spec		\
	glib-zip
44

45
configexecincludedir = $(libdir)/glib-2.0/include
46 47 48 49 50 51 52
#configexecinclude_DATA = glibconfig.h

install-exec-local: glibconfig.h
	$(mkinstalldirs) $(DESTDIR)$(configexecincludedir)
	file=$(DESTDIR)$(configexecincludedir)/glibconfig.h; \
	if test -r $$file && cmp -s glibconfig.h $$file; then :; \
	else $(INSTALL_DATA) glibconfig.h $$file; fi
Owen Taylor's avatar
Owen Taylor committed
53

54
CONFIGURE_DEPENDENCIES = acglib.m4
55

56 57
BUILT_SOURCES = stamp-gc-h #note: not glibconfig.h
glibconfig.h: stamp-gc-h
58 59
	@if test -f glibconfig.h; then :; \
	else rm -f stamp-gc-h; $(MAKE) stamp-gc-h; fi
60 61 62 63
stamp-gc-h: config.status
	CONFIG_FILES= CONFIG_HEADERS= CONFIG_OTHER=glibconfig.h ./config.status
	echo timestamp > stamp-gc-h

Owen Taylor's avatar
Owen Taylor committed
64

65
pkgconfigdir = $(libdir)/pkgconfig
Havoc Pennington's avatar
Havoc Pennington committed
66 67
pkgconfig_DATA = glib-2.0.pc gobject-2.0.pc gmodule-2.0.pc gthread-2.0.pc

68 69
$(pkgconfig_DATA): config.status

70
glibconfig.h.win32: $(top_builddir)/config.status $(top_srcdir)/glibconfig.h.win32.in
71 72
	cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status

73
config.h.win32: $(top_builddir)/config.status $(top_srcdir)/config.h.win32.in
74 75
	cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status

76 77
DISTCLEANFILES = glibconfig-sysdefs.h glibconfig.h stamp-gc-h

78
.PHONY: files release sanity snapshot
Owen Taylor's avatar
Owen Taylor committed
79 80 81 82 83 84 85

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

release:
86 87 88 89 90 91 92 93
	rm -rf .deps */.deps
	cd docs && make glib.html
	$(MAKE) distcheck

sanity:
	./sanity_check $(VERSION)

snapshot:
Owen Taylor's avatar
Owen Taylor committed
94 95 96 97
	$(MAKE) dist distdir=$(PACKAGE)-snap`date +"%Y%m%d"`

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

99
dist-hook: $(BUILT_EXTRA_DIST)
100
	cd $(top_builddir) && CONFIG_FILES="INSTALL README" CONFIG_HEADERS= $(SHELL) ./config.status
101
	files='$(BUILT_EXTRA_DIST) INSTALL README'; \
102 103
	for f in $$files; do \
	  if test -f $$f; then d=.; else d=$(srcdir); fi; \
104
	  rm -f $(distdir)/$$f && cp $$d/$$f $(distdir) || exit 1; done