diff options
30 files changed, 32 insertions, 16 deletions
diff --git a/build-aux/Makefile.each.tail/20-systemd.mk b/build-aux/Makefile.each.tail/20-systemd.mk index a774fa5424..3b533309a8 100644 --- a/build-aux/Makefile.each.tail/20-systemd.mk +++ b/build-aux/Makefile.each.tail/20-systemd.mk @@ -24,6 +24,10 @@ -include $(outdir)/$(DEPDIR)/*.P* std.clean_files += *.o *.lo .deps/ .libs/ +std.clean_files += *-list.txt +std.clean_files += *-from-name.gperf +std.clean_files += *-from-name.h +std.clean_files += *-to-name.h $(outdir)/%.o: $(srcdir)/%.c $(topoutdir)/config.h | $(outdir)/.deps $(AM_V_CC)$(COMPILE) -c -o $@ $< diff --git a/build-aux/Makefile.once.head/20-systemd.mk b/build-aux/Makefile.once.head/20-systemd.mk index eefed97d1e..6f528c5b2b 100644 --- a/build-aux/Makefile.once.head/20-systemd.mk +++ b/build-aux/Makefile.once.head/20-systemd.mk @@ -21,6 +21,8 @@ # You should have received a copy of the GNU Lesser General Public License # along with systemd; If not, see <http://www.gnu.org/licenses/>. +SHELL = bash -o pipefail + OUR_CPPFLAGS += -MT $@ -MD -MP -MF $(@D)/$(DEPDIR)/$(basename $(@F)).P$(patsubst .%,%,$(suffix $(@F))) OUR_CPPFLAGS += -include $(topoutdir)/config.h OUR_CPPFLAGS += $(if $(<D),-I$(<D)) -I$(@D) diff --git a/config.mk.in b/config.mk.in index b95c1ee8a5..eeb4d4412d 100644 --- a/config.mk.in +++ b/config.mk.in @@ -99,7 +99,7 @@ libshared.CPPFLAGS = -I$(topsrcdir)/src/libshared -I$(topoutdir)/src/libshar libshared.DEPENDS = $(topoutdir)/src/libshared/libshared.la libfirewall.CPPFLAGS = -I$(topsrcdir)/src/libfirewall -I$(topoutdir)/src/libfirewall libfirewall.DEPENDS = $(topoutdir)/src/libfirewall/libfirewall.la -libsystemd.CPPFLAGS = -I$(topsrcdir)/src/libsystemd/include -I$(topoutdir)/src/libsystemd/include +libsystemd.CPPFLAGS = -I$(topsrcdir)/src/libsystemd/include libsystemd.DEPENDS = $(topoutdir)/src/libsystemd/libsystemd/libsystemd.la libsystemd-internal.CPPFLAGS = -I$(topsrcdir)/src/libsystemd/libsystemd-internal/include libsystemd-internal.DEPENDS = $(topoutdir)/src/libsystemd/libsystemd-internal/libsystemd-internal.la @@ -222,6 +222,13 @@ HAVE_ZLIB = @HAVE_ZLIB_TRUE@1 LIBTOOLFLAGS = +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +pkgpyexecdir = @pkgpyexecdir@ +pkgpythondir = @pkgpythondir@ + INTLTOOL_EXTRACT = @INTLTOOL_EXTRACT@ INTLTOOL_MERGE = @INTLTOOL_MERGE@ INTLTOOL_PERL = @INTLTOOL_PERL@ diff --git a/src/journal/Makefile b/src/journal/Makefile index c67840c42f..e5223d72bc 100644 --- a/src/journal/Makefile +++ b/src/journal/Makefile @@ -23,20 +23,6 @@ include $(dir $(lastword $(MAKEFILE_LIST)))/../../config.mk include $(topsrcdir)/build-aux/Makefile.head.mk -audit_list_includes = -include linux/audit.h -include missing.h -ifneq ($(HAVE_AUDIT),) -audit_list_includes += -include libaudit.h -endif - -$(outdir)/audit_type-list.txt: - $(AM_V_at)$(MKDIR_P) $(dir $@) - $(AM_V_GEN)$(CPP) $(CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) -dM $(audit_list_includes) - </dev/null | grep -vE 'AUDIT_.*(FIRST|LAST)_' | $(SED) -r -n 's/^#define\s+AUDIT_(\w+)\s+([0-9]{4})\s*$$/\1\t\2/p' | sort -k2 >$@ - -$(outdir)/audit_type-to-name.h: src/journal/audit_type-list.txt - $(AM_V_at)$(MKDIR_P) $(dir $@) - $(AM_V_GEN)$(AWK) 'BEGIN{ print "const char *audit_type_to_string(int type) {\n\tswitch(type) {" } {printf " case AUDIT_%s: return \"%s\";\n", $$1, $$1 } END{ print " default: return NULL;\n\t}\n}\n" }' <$< >$@ - - $(outdir)/dns_type-list.txt: src/resolve/dns-type.h $(AM_V_at)$(MKDIR_P) $(dir $@) $(AM_V_GEN)$(SED) -n -r 's/.* DNS_TYPE_(\w+).*/\1/p' <$< >$@ diff --git a/src/libsystemd/Makefile b/src/libsystemd/Makefile index a7d690515f..0efd098fb2 100644 --- a/src/libsystemd/Makefile +++ b/src/libsystemd/Makefile @@ -274,4 +274,5 @@ test_libsystemd_sym_LDADD = \ libsystemd.la $(eval $(value automake2autothing)) +at.subdirs += compat-libs libsystemd-internal libsystem-journal-internal include $(topsrcdir)/build-aux/Makefile.tail.mk diff --git a/src/libsystemd/libsystemd-journal-internal/Makefile b/src/libsystemd/libsystemd-journal-internal/Makefile index 09677d6e5e..784e38732b 100644 --- a/src/libsystemd/libsystemd-journal-internal/Makefile +++ b/src/libsystemd/libsystemd-journal-internal/Makefile @@ -20,7 +20,7 @@ # # You should have received a copy of the GNU Lesser General Public License # along with systemd; If not, see <http://www.gnu.org/licenses/>. -include $(dir $(lastword $(MAKEFILE_LIST)))/../../config.mk +include $(dir $(lastword $(MAKEFILE_LIST)))/../../../config.mk include $(topsrcdir)/build-aux/Makefile.head.mk pkginclude_HEADERS += \ @@ -94,5 +94,21 @@ endif noinst_LTLIBRARIES += \ libsystemd-journal-internal.la + +audit_list_includes = -include linux/audit.h -include $(call at.path,$(topsrcdir)/src/libbasic/missing.h) +ifneq ($(HAVE_AUDIT),) +audit_list_includes += -include libaudit.h +endif + +$(outdir)/audit_type-list.txt: $(call at.path,$(topsrcdir)/src/libbasic/missing.h) + $(AM_V_GEN)$(CPP) $(ALL_CPPFLAGS) -dM $(audit_list_includes) - </dev/null | grep -vE 'AUDIT_.*(FIRST|LAST)_' | $(SED) -r -n 's/^#define\s+AUDIT_(\w+)\s+([0-9]{4})\s*$$/\1\t\2/p' | sort -k2 >$@ + +$(outdir)/audit_type-to-name.h: $(outdir)/audit_type-list.txt + $(AM_V_GEN)$(AWK) 'BEGIN{ print "const char *audit_type_to_string(int type) {\n\tswitch(type) {" } {printf " case AUDIT_%s: return \"%s\";\n", $$1, $$1 } END{ print " default: return NULL;\n\t}\n}\n" }' <$< >$@ + $(eval $(value automake2autothing)) +AM_CPPFLAGS += $(libbasic.CPPFLAGS) +AM_CPPFLAGS += -DCATALOG_DATABASE=\"$(catalogstatedir)/database\" +$(outdir)/audit-type.lo: $(outdir)/audit_type-to-name.h + include $(topsrcdir)/build-aux/Makefile.tail.mk diff --git a/src/journal/audit-type.c b/src/libsystemd/libsystemd-journal-internal/audit-type.c index 71e8790ca8..71e8790ca8 100644 --- a/src/journal/audit-type.c +++ b/src/libsystemd/libsystemd-journal-internal/audit-type.c diff --git a/src/journal/audit-type.h b/src/libsystemd/libsystemd-journal-internal/audit-type.h index 1dd2163707..1dd2163707 100644 --- a/src/journal/audit-type.h +++ b/src/libsystemd/libsystemd-journal-internal/audit-type.h diff --git a/src/journal/catalog.c b/src/libsystemd/libsystemd-journal-internal/catalog.c index 962ca238b9..962ca238b9 100644 --- a/src/journal/catalog.c +++ b/src/libsystemd/libsystemd-journal-internal/catalog.c diff --git a/src/journal/catalog.h b/src/libsystemd/libsystemd-journal-internal/catalog.h index b621de3068..b621de3068 100644 --- a/src/journal/catalog.h +++ b/src/libsystemd/libsystemd-journal-internal/catalog.h diff --git a/src/journal/compress.c b/src/libsystemd/libsystemd-journal-internal/compress.c index 1933b87b00..1933b87b00 100644 --- a/src/journal/compress.c +++ b/src/libsystemd/libsystemd-journal-internal/compress.c diff --git a/src/journal/compress.h b/src/libsystemd/libsystemd-journal-internal/compress.h index c138099d9a..c138099d9a 100644 --- a/src/journal/compress.h +++ b/src/libsystemd/libsystemd-journal-internal/compress.h diff --git a/src/journal/fsprg.c b/src/libsystemd/libsystemd-journal-internal/fsprg.c index 8f7e137e74..8f7e137e74 100644 --- a/src/journal/fsprg.c +++ b/src/libsystemd/libsystemd-journal-internal/fsprg.c diff --git a/src/journal/fsprg.h b/src/libsystemd/libsystemd-journal-internal/fsprg.h index 829b56e240..829b56e240 100644 --- a/src/journal/fsprg.h +++ b/src/libsystemd/libsystemd-journal-internal/fsprg.h diff --git a/src/journal/journal-authenticate.c b/src/libsystemd/libsystemd-journal-internal/journal-authenticate.c index 49f3c8f0f4..49f3c8f0f4 100644 --- a/src/journal/journal-authenticate.c +++ b/src/libsystemd/libsystemd-journal-internal/journal-authenticate.c diff --git a/src/journal/journal-authenticate.h b/src/libsystemd/libsystemd-journal-internal/journal-authenticate.h index 6c87319ede..6c87319ede 100644 --- a/src/journal/journal-authenticate.h +++ b/src/libsystemd/libsystemd-journal-internal/journal-authenticate.h diff --git a/src/journal/journal-def.h b/src/libsystemd/libsystemd-journal-internal/journal-def.h index a0a052ce4f..a0a052ce4f 100644 --- a/src/journal/journal-def.h +++ b/src/libsystemd/libsystemd-journal-internal/journal-def.h diff --git a/src/journal/journal-file.c b/src/libsystemd/libsystemd-journal-internal/journal-file.c index 4ea7013a53..4ea7013a53 100644 --- a/src/journal/journal-file.c +++ b/src/libsystemd/libsystemd-journal-internal/journal-file.c diff --git a/src/journal/journal-file.h b/src/libsystemd/libsystemd-journal-internal/journal-file.h index 0414117d98..0414117d98 100644 --- a/src/journal/journal-file.h +++ b/src/libsystemd/libsystemd-journal-internal/journal-file.h diff --git a/src/journal/journal-internal.h b/src/libsystemd/libsystemd-journal-internal/journal-internal.h index 8f21544ae1..8f21544ae1 100644 --- a/src/journal/journal-internal.h +++ b/src/libsystemd/libsystemd-journal-internal/journal-internal.h diff --git a/src/journal/journal-send.c b/src/libsystemd/libsystemd-journal-internal/journal-send.c index b85d9d3c61..b85d9d3c61 100644 --- a/src/journal/journal-send.c +++ b/src/libsystemd/libsystemd-journal-internal/journal-send.c diff --git a/src/journal/journal-vacuum.c b/src/libsystemd/libsystemd-journal-internal/journal-vacuum.c index 3650ab3865..3650ab3865 100644 --- a/src/journal/journal-vacuum.c +++ b/src/libsystemd/libsystemd-journal-internal/journal-vacuum.c diff --git a/src/journal/journal-vacuum.h b/src/libsystemd/libsystemd-journal-internal/journal-vacuum.h index 1e750a2170..1e750a2170 100644 --- a/src/journal/journal-vacuum.h +++ b/src/libsystemd/libsystemd-journal-internal/journal-vacuum.h diff --git a/src/journal/journal-verify.c b/src/libsystemd/libsystemd-journal-internal/journal-verify.c index b968e89bb8..b968e89bb8 100644 --- a/src/journal/journal-verify.c +++ b/src/libsystemd/libsystemd-journal-internal/journal-verify.c diff --git a/src/journal/journal-verify.h b/src/libsystemd/libsystemd-journal-internal/journal-verify.h index 8f0eaf6daa..8f0eaf6daa 100644 --- a/src/journal/journal-verify.h +++ b/src/libsystemd/libsystemd-journal-internal/journal-verify.h diff --git a/src/journal/lookup3.c b/src/libsystemd/libsystemd-journal-internal/lookup3.c index 3d791234f4..3d791234f4 100644 --- a/src/journal/lookup3.c +++ b/src/libsystemd/libsystemd-journal-internal/lookup3.c diff --git a/src/journal/lookup3.h b/src/libsystemd/libsystemd-journal-internal/lookup3.h index 787921ffbf..787921ffbf 100644 --- a/src/journal/lookup3.h +++ b/src/libsystemd/libsystemd-journal-internal/lookup3.h diff --git a/src/journal/mmap-cache.c b/src/libsystemd/libsystemd-journal-internal/mmap-cache.c index 9c0ce8ccbf..9c0ce8ccbf 100644 --- a/src/journal/mmap-cache.c +++ b/src/libsystemd/libsystemd-journal-internal/mmap-cache.c diff --git a/src/journal/mmap-cache.h b/src/libsystemd/libsystemd-journal-internal/mmap-cache.h index 199d944647..199d944647 100644 --- a/src/journal/mmap-cache.h +++ b/src/libsystemd/libsystemd-journal-internal/mmap-cache.h diff --git a/src/journal/sd-journal.c b/src/libsystemd/libsystemd-journal-internal/sd-journal.c index 1493f0348d..1493f0348d 100644 --- a/src/journal/sd-journal.c +++ b/src/libsystemd/libsystemd-journal-internal/sd-journal.c |