From 2341abf35820e8a575578a79d09af418b89d2727 Mon Sep 17 00:00:00 2001 From: Sebastian Kemper Date: Sat, 24 Feb 2018 09:42:50 +0100 Subject: [PATCH 1/3] bcg729: add OpenWrt CPPFLAGS Add TARGET_CPPFLAGS to TARGET_CFLAGS, otherwise OpenWrt's CPPFLAGS are ignored (i.e. fortify-source headers are not picked up). Signed-off-by: Sebastian Kemper --- libs/bcg729/Makefile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/libs/bcg729/Makefile b/libs/bcg729/Makefile index f81e928..c3a7e54 100644 --- a/libs/bcg729/Makefile +++ b/libs/bcg729/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2017 OpenWrt.org +# Copyright (C) 2006-2018 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -40,9 +40,11 @@ define Package/bcg729/description source code in any kind. endef -TARGET_CFLAGS += $(FPIC) +# Otherwise spandsp ignores OpenWrt's CPPFLAGS +TARGET_CFLAGS += $(FPIC) $(TARGET_CPPFLAGS) CMAKE_OPTIONS += \ + -DCMAKE_VERBOSE_MAKEFILE=TRUE \ -DENABLE_SHARED=YES \ -DENABLE_STATIC=NO \ -DENABLE_TESTS=NO From 1d1651c7a1bfca6043545396c20a8a7c24477454 Mon Sep 17 00:00:00 2001 From: Sebastian Kemper Date: Sat, 24 Feb 2018 09:45:23 +0100 Subject: [PATCH 2/3] bcg729: remove $(FPIC) from TARGET_CFLAGS bgg729 already makes sure that the compiler emits position-independent code. Adding $(FPIC) makes no difference. In addition the bcg729 build system puts its own flag behind the CFLAGS, overriding whatever was set before. Signed-off-by: Sebastian Kemper --- libs/bcg729/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libs/bcg729/Makefile b/libs/bcg729/Makefile index c3a7e54..116b7b4 100644 --- a/libs/bcg729/Makefile +++ b/libs/bcg729/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=bcg729 PKG_VERSION:=1.0.4 -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://www.linphone.org/releases/sources/bcg729 @@ -41,7 +41,7 @@ define Package/bcg729/description endef # Otherwise spandsp ignores OpenWrt's CPPFLAGS -TARGET_CFLAGS += $(FPIC) $(TARGET_CPPFLAGS) +TARGET_CFLAGS += $(TARGET_CPPFLAGS) CMAKE_OPTIONS += \ -DCMAKE_VERBOSE_MAKEFILE=TRUE \ From e124b74296d5856fc39d6227484108177aa6495e Mon Sep 17 00:00:00 2001 From: Sebastian Kemper Date: Sat, 24 Feb 2018 10:23:27 +0100 Subject: [PATCH 3/3] bcg729: fix a typo Signed-off-by: Sebastian Kemper --- libs/bcg729/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/bcg729/Makefile b/libs/bcg729/Makefile index 116b7b4..ce189cb 100644 --- a/libs/bcg729/Makefile +++ b/libs/bcg729/Makefile @@ -40,7 +40,7 @@ define Package/bcg729/description source code in any kind. endef -# Otherwise spandsp ignores OpenWrt's CPPFLAGS +# Otherwise OpenWrt's CPPFLAGS are ignored TARGET_CFLAGS += $(TARGET_CPPFLAGS) CMAKE_OPTIONS += \