From 47645e9eee02a5a1024bec603df098d2ee969ae9 Mon Sep 17 00:00:00 2001 From: =?utf8?q?R=C3=A9mi=20Denis-Courmont?= Date: Wed, 3 Aug 2011 13:41:26 +0300 Subject: [PATCH] contrib: always build ebml as PIC on Linux --- contrib/src/ebml/ebml-pic.patch | 22 ++++++++++++++++++++++ contrib/src/ebml/rules.mak | 1 + 2 files changed, 23 insertions(+) create mode 100644 contrib/src/ebml/ebml-pic.patch diff --git a/contrib/src/ebml/ebml-pic.patch b/contrib/src/ebml/ebml-pic.patch new file mode 100644 index 0000000000..c9511b1961 --- /dev/null +++ b/contrib/src/ebml/ebml-pic.patch @@ -0,0 +1,22 @@ +diff -ru libebml.orig/make/linux/Makefile libebml/make/linux/Makefile +--- libebml.orig/make/linux/Makefile 2011-08-03 13:39:21.000000000 +0300 ++++ libebml/make/linux/Makefile 2011-08-03 13:39:57.000000000 +0300 +@@ -59,7 +59,7 @@ + + # object files; replace .cxx extension with .o + objects:=$(patsubst %$(EXTENSION),%.o,$(sources)) +-objects_so:=$(patsubst %$(EXTENSION),%.lo,$(sources)) ++objects_so:=$(objects) + + WARNINGFLAGS=-Wall -Wno-unknown-pragmas -ansi -fno-gnu-keywords -Wshadow + COMPILEFLAGS=$(WARNINGFLAGS) $(CXXFLAGS) $(CPPFLAGS) $(DEBUGFLAGS) $(INCLUDE) +@@ -81,9 +81,6 @@ + + # Build rules + %.o: %$(EXTENSION) +- $(CXX) -c $(COMPILEFLAGS) -o $@ $< +- +-%.lo: %$(EXTENSION) + $(CXX) -c $(COMPILEFLAGS) -fPIC -o $@ $< + + $(LIBRARY): $(objects) diff --git a/contrib/src/ebml/rules.mak b/contrib/src/ebml/rules.mak index b7f7c6f083..f8cc61b2cf 100644 --- a/contrib/src/ebml/rules.mak +++ b/contrib/src/ebml/rules.mak @@ -11,6 +11,7 @@ $(TARBALLS)/libebml-$(EBML_VERSION).tar.bz2: libebml: libebml-$(EBML_VERSION).tar.bz2 .sum-ebml $(UNPACK) + $(APPLY) $(SRC)/ebml/ebml-pic.patch $(MOVE) .ebml: libebml -- 2.39.5