From cf3ec1f6834a33cfef0882c85a6b1427fb52dff1 Mon Sep 17 00:00:00 2001 From: Matthias Ringwald Date: Thu, 7 May 2015 19:52:22 +0200 Subject: [PATCH] use -fpic for libBTstack --- platforms/daemon/configure.ac | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/platforms/daemon/configure.ac b/platforms/daemon/configure.ac index ea31ea80d..6fe54c73e 100644 --- a/platforms/daemon/configure.ac +++ b/platforms/daemon/configure.ac @@ -91,11 +91,13 @@ case "$host_os" in REMOTE_DEVICE_DB="remote_device_db_memory" ;; esac - # treat warnings seriously CFLAGS="$CFLAGS -Werror -Wall -Wpointer-arith" +# 64-bit compilation requires position independent code (PIC) for libraries +BTSTACK_LIB_LDFLAGS+=" -fpic" + AM_CONDITIONAL(USE_POWERMANAGEMENT, [test "x$USE_POWERMANAGEMENT" == "xyes"]) # summary @@ -103,6 +105,7 @@ AM_CONDITIONAL(USE_POWERMANAGEMENT, [test "x$USE_POWERMANAGEMENT" == "xyes"]) echo "CC: $CC" echo "CFLAGS: $CFLAGS" echo "LDFLAGS: $LDFLAGS" +echo "BTSTACK_LIB_LDFLAGS: $BTSTACK_LIB_LDFLAGS" if test "x$HCI_TRANSPORT" = xUSB; then echo "USB_PRODUCT_ID: $USB_PRODUCT_ID"