From aa1129a71d44e55f6cf533dfd9256ade6fe53132 Mon Sep 17 00:00:00 2001 From: Roy Marples Date: Fri, 4 Jan 2008 14:46:45 +0000 Subject: [PATCH] More static building fixes. --- src/Makefile | 8 +++----- src/Makefile.ncurses | 1 + 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/Makefile b/src/Makefile index a0d3d67c..1bbb7c78 100644 --- a/src/Makefile +++ b/src/Makefile @@ -80,8 +80,6 @@ BINLINKS = rc-status SBINLINKS = rc-update runscript start-stop-daemon ALL_LINKS = $(BINLINKS) $(SBINLINKS) $(RC_BINLINKS) $(RC_SBINLINKS) -# We also define _BSD_SOURCE so both Linux and the BSDs get a few -# handy functions which makes our lives a lot easier CPPFLAGS += -DLIB=\"$(LIB)\" # IMPORTANT!!! @@ -89,12 +87,12 @@ CPPFLAGS += -DLIB=\"$(LIB)\" # issues. However, this does ease development a little LDFLAGS += -Wl,-rpath . -# Load an optional OS Makefile +# Load an optional Makefiles - the order is important TOPDIR = .. include $(TOPDIR)/default.mk -include Makefile.$(OS) include Makefile.$(TERMCAP) include Makefile.$(PAM) +include Makefile.$(OS) all: .depend $(TARGET) @@ -130,7 +128,7 @@ $(RCOBJS): $(CC) $(CPPFLAGS) $(CPPFLAGS_SSD) $(CFLAGS) -c $< rc: version.h $(LIBEINFOSO) $(LIBRCSO) $(RCOBJS) $(CC) $(LDFLAGS) $(BIN_LDFLAGS) -o rc \ - $(RCOBJS) $(LDLIBS_LIBEINFO) $(LDLIBS_LIBRC) $(LDLIBS_RC) + $(RCOBJS) $(LDLIBS_LIBRC) $(LDLIBS_RC) $(ALL_LINKS): rc ln -sf rc $@ diff --git a/src/Makefile.ncurses b/src/Makefile.ncurses index 563b71bd..77cad660 100644 --- a/src/Makefile.ncurses +++ b/src/Makefile.ncurses @@ -1,3 +1,4 @@ LIBTERMCAP ?= -lncurses CPPFLAGS_LIBEINFO = -DHAVE_TERMCAP LDLIBS_LIBEINFO += $(LIBTERMCAP) +LDLIBS_RC += $(LIBTERMCAP)