[Buildroot] [git commit] wvstreams: Pass -fPIC to CFLAGS when building PIC objects

Peter Korsgaard jacmet at sunsite.dk
Thu Jun 20 15:08:18 UTC 2013

commit: http://git.buildroot.net/buildroot/commit/?id=31d72937cf17e9e476e956986030e93f8fd2ce56
branch: http://git.buildroot.net/buildroot/commit/?id=refs/heads/master

The argp bundled dependency which is linked to the libwvutils.so
shared library, wasn't built with -fPIC.
MIPS will refuce to link a non-PIC library with a shared one.

We fix this problem by appending -fPIC to CFLAGS and build all the
shared objects with -fPIC.

[Peter: use +=]
Signed-off-by: Markos Chandras <markos.chandras at imgtec.com>
Signed-off-by: Peter Korsgaard <jacmet at sunsite.dk>
 package/wvstreams/wvstreams.mk |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/package/wvstreams/wvstreams.mk b/package/wvstreams/wvstreams.mk
index 65f48d4..b4f7d89 100644
--- a/package/wvstreams/wvstreams.mk
+++ b/package/wvstreams/wvstreams.mk
@@ -27,6 +27,10 @@ WVSTREAMS_CONF_OPT += \
 # needed for openssl detection when statically linking (as ssl needs lz)
+ifneq ($(BR2_PREFER_STATIC_LIB),y)
 ifeq ($(BR2_PACKAGE_DBUS),y)
 	WVSTREAMS_CONF_OPT += --with-dbus

More information about the buildroot mailing list