aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--recipes-devtools/qmic/qmic/0001-Makefile-Allow-compiler-linker-flags-to-be-overridde.patch32
-rw-r--r--recipes-devtools/qmic/qmic_git.bb4
2 files changed, 35 insertions, 1 deletions
diff --git a/recipes-devtools/qmic/qmic/0001-Makefile-Allow-compiler-linker-flags-to-be-overridde.patch b/recipes-devtools/qmic/qmic/0001-Makefile-Allow-compiler-linker-flags-to-be-overridde.patch
new file mode 100644
index 0000000..7752de6
--- /dev/null
+++ b/recipes-devtools/qmic/qmic/0001-Makefile-Allow-compiler-linker-flags-to-be-overridde.patch
@@ -0,0 +1,32 @@
+From 60c295e1a7852ab5311b0f3be6945a37c8256a2a Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 6 Apr 2017 22:02:30 +0000
+Subject: [PATCH] Makefile: Allow compiler/linker flags to be overridden
+
+This helps with cross compilation where toolchains specify
+certain flags via environment e.g. CFLAGS/LDFLAGS
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ Makefile | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index 0783e49..2efba54 100644
+--- a/Makefile
++++ b/Makefile
+@@ -1,8 +1,8 @@
+ OUT := qmic
+
+-CFLAGS := -Wall -g -O2
+-LDFLAGS :=
+-prefix := /usr/local
++CFLAGS ?= -Wall -g -O2
++LDFLAGS ?=
++prefix ?= /usr/local
+
+ SRCS := qmic.c qmi_message.c qmi_struct.c
+ OBJS := $(SRCS:.c=.o)
+--
+1.9.1
+
diff --git a/recipes-devtools/qmic/qmic_git.bb b/recipes-devtools/qmic/qmic_git.bb
index 457919d..0c3b126 100644
--- a/recipes-devtools/qmic/qmic_git.bb
+++ b/recipes-devtools/qmic/qmic_git.bb
@@ -6,7 +6,9 @@ LICENSE = "BSD-3-Clause"
LIC_FILES_CHKSUM = "file://LICENSE;md5=ca25dbf5ebfc1a058bfc657c895aac2f"
SRCREV = "1c036374ea1dd7a831821efbe3ee686e2a1842fe"
-SRC_URI = "git://github.com/andersson/${BPN}.git;branch=master;protocol=https"
+SRC_URI = "git://github.com/andersson/${BPN}.git;branch=master;protocol=https \
+ file://0001-Makefile-Allow-compiler-linker-flags-to-be-overridde.patch \
+ "
PV = "0.0+${SRCPV}"