From 7b1557f421b955968e1dc90ffa11e7a836b47af6 Mon Sep 17 00:00:00 2001 From: Dieter Hametner Date: Wed, 3 Jan 2007 22:08:10 +0000 Subject: using -Wl,--whole-archive to link sublibraries --- Makefile | 11 ++++++----- css/Makefile | 6 +++--- pages/Makefile | 6 +++--- 3 files changed, 12 insertions(+), 11 deletions(-) diff --git a/Makefile b/Makefile index 5615c59..24c7c82 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ # # Makefile for a Video Disk Recorder plugin # -# $Id: Makefile,v 1.18 2007/01/03 21:43:21 lordjaxom Exp $ +# $Id: Makefile,v 1.19 2007/01/03 22:08:10 tadi Exp $ # The official name of this plugin. # This name will be used in the '-P...' option of VDR to load the plugin. @@ -54,15 +54,16 @@ export DEFINES LIBS += httpd/libhttpd.a -SUBDIRS = httpd pages css +SUBDIRS = httpd pages css images ### The object files (add further files here): PLUGINOBJS = $(PLUGIN).o thread.o tntconfig.o setup.o i18n.o WEBOBJS = tools.o -WEBLIBS = pages/libpages.o \ - css/libcss.o +WEBLIBS = pages/libpages.a \ + css/libcss.a \ + images/libimages.a ### Default rules: @@ -96,7 +97,7 @@ libvdr-$(PLUGIN).so: $(PLUGINOBJS) $(LIBS) @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) libtnt-$(PLUGIN).so: $(WEBOBJS) $(WEBLIBS) - $(CXX) $(LDFLAGS) -shared -o $@ $^ + $(CXX) $(LDFLAGS) -Wl,--whole-archive -shared -o $@ $^ @cp --remove-destination $@ $(LIBDIR)/$@ dist: clean diff --git a/css/Makefile b/css/Makefile index 8fb86a2..006548e 100644 --- a/css/Makefile +++ b/css/Makefile @@ -30,10 +30,10 @@ OBJS = styles.o ### Targets: -all: libcss.o +all: libcss.a -libcss.o: $(OBJS) - $(LD) -i -o $@ $^ +libcss.a: $(OBJS) + $(AR) r $@ $^ clean: @rm -f *~ *.o core* libcss.a $(OBJS:%.o=%.cpp) diff --git a/pages/Makefile b/pages/Makefile index 3a08054..70b6647 100644 --- a/pages/Makefile +++ b/pages/Makefile @@ -42,10 +42,10 @@ OBJS = menu.o event_widget.o channels.o schedule.o whats_on_now.o whats_on_next ### Targets: -all: libpages.o +all: libpages.a -libpages.o: $(OBJS) - $(LD) -i -o $@ $^ +libpages.a: $(OBJS) + $(AR) r $@ $^ clean: @rm -f *~ *.o core* libpages.a $(OBJS:%.o=%.cpp) -- cgit v1.2.3