From ba54bb9ac437667b92fb1e6d58a53b1a5b836b9f Mon Sep 17 00:00:00 2001 From: Werner Fink Date: Tue, 4 May 2010 07:50:12 +0000 Subject: [PATCH] Fix sysvinit bug #29758 --- Makefile | 2 ++ doc/Changelog | 2 ++ src/Makefile | 20 ++++++++++++++------ 3 files changed, 18 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index 5e27766..2d8ed5d 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,7 @@ all install clean distclean: $(MAKE) -C src $@ +ifeq ($(MAKECMDGOALS),upload) PACKAGE=sysvinit VERSION=$(shell sed -rn '1s/.*[[:blank:]]\((.*)\)[[:blank:]].*/\1/p' doc/Changelog) SVLOGIN=$(shell svn info | sed -rn '/Repository Root:/{ s|.*//(.*)\@.*|\1|p }') @@ -35,3 +36,4 @@ $(TMP)/$(PACKAGE)-$(VERSION): .svn svn export . $@ @chmod -R a+r,u+w,og-w $@ @find $@ -type d | xargs -r chmod a+rx,u+w,og-w +endif diff --git a/doc/Changelog b/doc/Changelog index a20be0d..9b1ed59 100644 --- a/doc/Changelog +++ b/doc/Changelog @@ -5,6 +5,8 @@ sysvinit (2.89dsf) UNRELEASED; urgency=low and if already set to make sure the utf-8 flag is not cleared from the tty. Patch from Samuel Thibault. * Include limits.h in killall.c to enforce definition of PATH_MAX + * Fix sysvinit bug #29758 Linker invocation should not contain + headers. Change based on patch from Elias Pipping. [ Petter Reinholdtsen ] * Next release will be 2.89dsf. diff --git a/src/Makefile b/src/Makefile index e2b8028..19675c5 100644 --- a/src/Makefile +++ b/src/Makefile @@ -92,9 +92,9 @@ all: $(BIN) $(SBIN) $(USRBIN) init: LDLIBS += $(INITLIBS) $(STATIC) init: init.o init_utmp.o -halt: halt.o ifdown.o hddown.o utmp.o reboot.h +halt: halt.o ifdown.o hddown.o utmp.o -last: last.o oldutmp.h +last: last.o mesg: mesg.o @@ -109,7 +109,7 @@ sulogin: sulogin.o wall: dowall.o wall.o -shutdown: dowall.o shutdown.o utmp.o reboot.h +shutdown: dowall.o shutdown.o utmp.o bootlogd: LDLIBS += -lutil bootlogd: bootlogd.o @@ -118,14 +118,22 @@ sulogin.o: CPPFLAGS += $(SELINUX_DEF) sulogin.o: sulogin.c init.o: CPPFLAGS += $(SELINUX_DEF) -init.o: init.c init.h set.h reboot.h initreq.h +init.o: init.c init.h initreq.h paths.h reboot.h set.h -utmp.o: utmp.c init.h +utmp.o: init_utmp.o: CPPFLAGS += -DINIT_MAIN -init_utmp.o: utmp.c init.h +init_utmp.o: utmp.c init.h initreq.h paths.h $(CC) $(CFLAGS) $(CPPFLAGS) -c -o $@ $< +utmpdump.o: utmpdump.c oldutmp.h + +shutdown.o: shutdown.c paths.h reboot.h initreq.h init.h + +halt.o: halt.c reboot.h + +last.o: last.c oldutmp.h + cleanobjs: rm -f *.o *.bak