Makefile.am 3.07 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 docs tests build
Tim Janik's avatar
Tim Janik committed
6

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

Owen Taylor's avatar
Owen Taylor committed
10 11
EXTRA_DIST = 			\
	ChangeLog.pre-1-2	\
12
	glib.spec.in		\
Tim Janik's avatar
Tim Janik committed
13
	NEWS.pre-1-3		\
14 15 16
	acglib.m4		\
	sanity_check		\
	README.win32		\
Owen Taylor's avatar
Owen Taylor committed
17
	TODO.xml		\
18
	makefile.msc.in		\
19
	makefile.mingw.in	\
20 21
	glibconfig.h.win32.in	\
	config.h.win32.in	\
22
	build-dll		\
23 24 25 26
	glib.rc.in		\
	glib-2.0.pc.in 		\
	gobject-2.0.pc.in 	\
	gmodule-2.0.pc.in	\
27
	gthread-2.0.pc.in	\
28 29 30
	glib-2.0-uninstalled.pc.in 	\
	gobject-2.0-uninstalled.pc.in 	\
	gmodule-2.0-uninstalled.pc.in	\
31
	gthread-2.0-uninstalled.pc.in
32

33
# These may be in the builddir too
34
BUILT_EXTRA_DIST = 		\
35 36 37 38 39 40 41
	makefile.msc		\
	makefile.mingw		\
	glibconfig.h.win32	\
	config.h.win32		\
	glib.rc			\
	glib.spec

42
configexecincludedir = $(libdir)/glib-2.0/include
43 44 45 46 47 48 49
#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
50

51
CONFIGURE_DEPENDENCIES = acglib.m4
52

53 54
BUILT_SOURCES = stamp-gc-h #note: not glibconfig.h
glibconfig.h: stamp-gc-h
55 56
	@if test -f glibconfig.h; then :; \
	else rm -f stamp-gc-h; $(MAKE) stamp-gc-h; fi
57 58 59 60
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
61

62
pkgconfigdir = $(libdir)/pkgconfig
Havoc Pennington's avatar
Havoc Pennington committed
63 64
pkgconfig_DATA = glib-2.0.pc gobject-2.0.pc gmodule-2.0.pc gthread-2.0.pc

65
glibconfig.h.win32: $(top_builddir)/config.status $(top_srcdir)/glibconfig.h.win32.in
66 67
	cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status

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

71
makefile.msc: $(top_builddir)/config.status $(top_srcdir)/makefile.msc.in
72 73
	cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status

74
makefile.mingw: $(top_builddir)/config.status $(top_srcdir)/makefile.mingw.in
75 76
	cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status

77 78 79
glib.rc: $(top_builddir)/config.status $(top_srcdir)/glib.rc.in
	cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status

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

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

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

sanity:
	./sanity_check $(VERSION)

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

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

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