aboutsummaryrefslogtreecommitdiffstats
path: root/package/libs/uclibc++/patches/010-honor-ldflags.patch
blob: b1050cb1bd7642d40e2a4a0cfb3eb4310b26d824 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
--- a/src/Makefile
+++ b/src/Makefile
@@ -3,9 +3,9 @@ include $(TOPDIR)Rules.mak
 
 WR_CXX := WRAPPER_INCLUDEDIR=-I$(TOPDIR)include $(TOPDIR)bin/g++-uc
 
-LDFLAGS += -nodefaultlibs -shared -Wl,-soname,$(SHARED_MAJORNAME) $(BUILD_EXTRA_LIBRARIES)
+EXTRA_LDFLAGS += -nodefaultlibs -shared -Wl,-soname,$(SHARED_MAJORNAME) $(BUILD_EXTRA_LIBRARIES)
 ifneq ($(DODEBUG),y)
-LDFLAGS += -Wl,-s
+EXTRA_LDFLAGS += -Wl,-s
 endif
 
 SRCS =	$(wildcard *.cpp)
@@ -60,7 +60,7 @@ $(LIBNAME).a: libgcc_eh libsupc $(EXOBJS
 	$(RANLIB) $@
 
 $(SHARED_FULLNAME): libgcc_eh libsupc $(EXOBJS)
-	$(CC) $(LDFLAGS) -o $@ $(EXOBJS) $(SUPOBJS) $(GCCOBJS) $(LIBS)
+	$(CC) $(LDFLAGS) $(EXTRA_LDFLAGS) -o $@ $(EXOBJS) $(SUPOBJS) $(GCCOBJS) $(LIBS)
 	$(LN) $@ $(SHARED_MAJORNAME)
 	$(LN) $(SHARED_MAJORNAME) $(LIBNAME).so