]> git.ipfire.org Git - thirdparty/util-linux.git/blob - Makefile.am
build-sys: remove --enable-gtk-doc from make check
[thirdparty/util-linux.git] / Makefile.am
1 AM_CPPFLAGS = \
2 -include config.h \
3 -I$(top_srcdir)/include \
4 -DLOCALEDIR=\"$(localedir)\" \
5 -D_PATH_LOCALSTATEDIR=\"${localstatedir}\"
6 AM_CFLAGS = -fsigned-char $(WARN_CFLAGS)
7 AM_LDFLAGS =
8
9 # Add gettext stuff to the global LDADD for systems with separate libintl
10 # library. The LTLIBINTL is generated by AM_GNU_GETTEXT macro.
11 #
12 LDADD = $(LTLIBINTL)
13
14 # Automake (at least up to 1.10) mishandles dist_man_MANS inside conditionals.
15 # Unlike with other dist primaries, the files are not distributed if the
16 # conditional is false.
17 # Work the bug around until it is fixed:
18 dist_noinst_DATA = $(dist_man_MANS)
19
20 # Paths to in-tree libraries (use ul_ prefix to avoid possible collisions)
21 # Note that blkid.h and libmount.h are generated and stored in build dirs.
22 #
23 ul_libblkid_incdir = $(top_builddir)/libblkid/src
24 ul_libmount_incdir = $(top_builddir)/libmount/src
25 ul_libuuid_incdir = $(top_srcdir)/libuuid/src
26
27 pkgconfigdir = $(usrlib_execdir)/pkgconfig
28
29 dist_noinst_HEADERS =
30 noinst_PROGRAMS =
31 noinst_LTLIBRARIES =
32 usrbin_exec_PROGRAMS =
33 usrsbin_exec_PROGRAMS =
34 dist_man_MANS =
35 man_MANS =
36 pkgconfig_DATA =
37 usrlib_exec_LTLIBRARIES =
38 bin_PROGRAMS =
39 sbin_PROGRAMS =
40 dist_usrbin_exec_SCRIPTS =
41 systemdsystemunit_DATA =
42 ruman1_DATA =
43 check_PROGRAMS =
44 TESTS =
45
46 PATHFILES =
47
48 INSTALL_EXEC_HOOKS =
49 UNINSTALL_HOOKS =
50 INSTALL_DATA_HOOKS =
51 CLEAN_LOCALS =
52 CHECK_LOCALS =
53
54 EXTRA_DIST = man/ru/ddate.1
55 CLEANFILES =
56
57 SUBDIRS = po
58
59 RCS_FIND_IGNORE = \( -name SCCS -o -name BitKeeper -o -name .svn -o \
60 -name CVS -o -name .pc -o -name .hg -o -name .git \) -prune -o
61
62 ACLOCAL_AMFLAGS = -I m4
63
64 EXTRA_DIST += \
65 .version \
66 autogen.sh \
67 Documentation \
68 po/update-potfiles \
69 README.licensing \
70 tools/git-version-gen
71
72
73 include include/Makemodule.am
74 include lib/Makemodule.am
75 include libuuid/Makemodule.am
76 include libblkid/Makemodule.am
77 include libmount/Makemodule.am
78
79 include schedutils/Makemodule.am
80 include text-utils/Makemodule.am
81 include term-utils/Makemodule.am
82 include login-utils/Makemodule.am
83 include mount-deprecated/Makemodule.am
84 include sys-utils/Makemodule.am
85 include misc-utils/Makemodule.am
86 include disk-utils/Makemodule.am
87 include fdisks/Makemodule.am
88
89 include tests/Makemodule.am
90
91 #
92 # Don't rely on configure.ac AC_CONFIG_FILES for install paths.
93 #
94 # The paths should be expanded at make time rather than configure:
95 # - to support 'make install prefix=/foo DESTDIR=/foo'
96 # - to recursively expands the paths (e.g. AC_CONFIG_FILES expands
97 # '@usrsbin_execdir@' to ${exec_prefix}/sbin')
98 #
99 edit_cmd = sed \
100 -e 's|@prefix[@]|$(prefix)|g' \
101 -e 's|@exec_prefix[@]|$(exec_prefix)|g' \
102 -e 's|@sysconfdir[@]|$(sysconfdir)|g' \
103 -e 's|@datadir[@]|$(datadir)|g' \
104 -e 's|@sbindir[@]|$(sbindir)|g' \
105 -e 's|@bindir[@]|$(bindir)|g' \
106 -e 's|@includedir[@]|$(includedir)|g' \
107 -e 's|@localstatedir[@]|$(localstatedir)|g' \
108 -e 's|@usrlib_execdir[@]|$(usrlib_execdir)|g' \
109 -e 's|@usrbin_execdir[@]|$(usrbin_execdir)|g' \
110 -e 's|@usrsbin_execdir[@]|$(usrsbin_execdir)|g' \
111 -e 's|@VERSION[@]|$(VERSION)|g' \
112 -e 's|@LIBUUID_VERSION[@]|$(LIBUUID_VERSION)|g' \
113 -e 's|@LIBMOUNT_VERSION[@]|$(LIBMOUNT_VERSION)|g' \
114 -e 's|@LIBBLKID_VERSION[@]|$(LIBBLKID_VERSION)|g'
115
116 CLEANFILES += $(PATHFILES)
117 EXTRA_DIST += $(PATHFILES:=.in)
118
119 $(PATHFILES): Makefile
120 @ rm -f $@ $@.tmp
121 $(AM_V_GEN) srcdir=''; \
122 test -f ./$@.in || srcdir=$(srcdir)/; \
123 $(edit_cmd) $${srcdir}$@.in >$@.tmp
124 @ mv $@.tmp $@
125
126 # Arrange so that .tarball-version appears only in the distribution
127 # tarball, and never in a checked-out repository.
128 dist-hook:
129 echo $(VERSION) > $(distdir)/.tarball-version
130 # Set ChangeLog tag reference.
131 sed -i "s/log/log;h=$(VERSION)/" $(distdir)/ChangeLog
132
133 distclean-local:
134 -find . -name \*~ -o -name \*.orig -o -name \*.rej | xargs rm -f
135 rm -rf autom4te.cache
136
137
138 checkincludes:
139 @find * $(RCS_FIND_IGNORE) \
140 -name '*.[hcS]' -type f -print | sort -u \
141 | xargs $(top_srcdir)/tools/checkincludes.pl
142
143 checkconfig:
144 @find * $(RCS_FIND_IGNORE) \
145 -name '*.[hcS]' -type f -print | sort -u \
146 | xargs $(top_srcdir)/tools/checkconfig.sh $(top_srcdir)
147
148 checkmans:
149 @$(top_srcdir)/tools/checkmans.sh
150
151 checkxalloc:
152 @ $(top_srcdir)/tools/checkxalloc.sh
153
154 checkdecl:
155 @ $(top_srcdir)/tools/checkdecl.sh
156
157 ENABLE_ALL = --enable-static-programs --enable-most-builds
158 DISTCHECK_CONFIGURE_FLAGS = --disable-use-tty-group \
159 --disable-silent-rules $(ENABLE_ALL) \
160 --with-systemdsystemunitdir=$$dc_install_base/$(systemdsystemunitdir)
161
162
163 BUILT_SOURCES = .version
164 .version:
165 echo $(VERSION) > $@-t && mv $@-t $@
166
167 CHANGELOG_FILE = v$(VERSION)-ChangeLog
168
169 $(CHANGELOG_FILE):
170 @ if test "x$$PREVIOUS_VERSION" == "x"; then \
171 echo "Usage make changelog PREVIOUS_VERSION=<version>"; \
172 exit 1; \
173 fi
174 @ echo "Changes between v$(PREVIOUS_VERSION) and v$(VERSION)" > $(CHANGELOG_FILE)
175 @ echo "--------------------------------------------" >> $(CHANGELOG_FILE)
176 @ echo >> $(CHANGELOG_FILE)
177 $(AM_V_GEN) git log --stat v$(PREVIOUS_VERSION)..HEAD >> $(CHANGELOG_FILE)
178 #
179 #
180 # smatch scan -- smatch and cgcc are expected in $PATH
181 #
182 checksmatch:
183 $(MAKE) CHECK="smatch --data=$(abs_top_srcdir)/tools/smatch-data" CC=cgcc
184
185 changelog: $(CHANGELOG_FILE)
186
187 install-exec-hook: $(INSTALL_EXEC_HOOKS)
188
189 uninstall-hook: $(UNINSTALL_HOOKS)
190
191 install-data-hook: $(INSTALL_DATA_HOOKS)
192
193 clean-local: $(CLEAN_LOCALS)
194
195 check-local: $(CHECK_LOCALS)