[oe-commits] Roy.Li : wireshark: not put the CC options into CFLAGS_FOR_BUILD

git at git.openembedded.org git at git.openembedded.org
Wed Sep 24 15:23:40 UTC 2014


Module: meta-openembedded.git
Branch: master-next
Commit: bb62e5fd88b0721d61cc7da491a6a6dea21d3dd7
URL:    http://git.openembedded.org/?p=meta-openembedded.git&a=commit;h=bb62e5fd88b0721d61cc7da491a6a6dea21d3dd7

Author: Roy.Li <rongqing.li at windriver.com>
Date:   Wed Sep 24 08:18:57 2014 +0800

wireshark: not put the CC options into CFLAGS_FOR_BUILD

Signed-off-by: Roy Li <rongqing.li at windriver.com>
Signed-off-by: Joe MacDonald <joe_macdonald at mentor.com>

---

 .../files/Do-not-set-CC_FOR_BUILD-flags.patch      | 46 ++++++++++++++++++++++
 .../recipes-support/wireshark/wireshark_1.12.1.bb  |  1 +
 2 files changed, 47 insertions(+)

diff --git a/meta-networking/recipes-support/wireshark/files/Do-not-set-CC_FOR_BUILD-flags.patch b/meta-networking/recipes-support/wireshark/files/Do-not-set-CC_FOR_BUILD-flags.patch
new file mode 100644
index 0000000..64a08ad
--- /dev/null
+++ b/meta-networking/recipes-support/wireshark/files/Do-not-set-CC_FOR_BUILD-flags.patch
@@ -0,0 +1,46 @@
+[PATCH] Do not set CC_FOR_BUILD flags
+
+Upstream-status: Pending
+
+AC_WIRESHARK_COMPILER_FLAGS_CHECK() is checking which options CC is supported,
+and put the supported options into CFLAGS, but it should not put them into 
+CFLAGS_FOR_BUILD. since CC and BUILD_CC can be different, CFLAGS_FOR_BUILD is
+used by BUILD_CC 
+
+BUILD_CC is used to generated host tools, do not use the gcc's optimised options,
+do not effect the running of host tools. so do not set CC_FOR_BUILD flags.
+
+Signed-off-by: Roy.Li <rongqing.li at windriver.com>
+---
+ acinclude.m4 | 8 --------
+ 1 file changed, 8 deletions(-)
+
+diff --git a/acinclude.m4 b/acinclude.m4
+index 136fc27..8d3d360 100644
+--- a/acinclude.m4
++++ b/acinclude.m4
+@@ -1755,10 +1755,6 @@ if test "x$ac_supports_gcc_flags" = "xyes" ; then
+               # just the new option.
+               #
+               CFLAGS="$CFLAGS_saved $GCC_OPTION"
+-              #
+-              # Add it to the flags we use when building build tools.
+-              #
+-              CFLAGS_FOR_BUILD="$CFLAGS_FOR_BUILD $GCC_OPTION"
+             ],
+             [
+               AC_MSG_RESULT(yes)
+@@ -1771,10 +1767,6 @@ if test "x$ac_supports_gcc_flags" = "xyes" ; then
+           # just the new option.
+           #
+           CFLAGS="$CFLAGS_saved $GCC_OPTION"
+-          #
+-          # Add it to the flags we use when building build tools.
+-          #
+-          CFLAGS_FOR_BUILD="$CFLAGS_FOR_BUILD $GCC_OPTION"
+         fi
+       ],
+       [
+-- 
+1.9.1
+
diff --git a/meta-networking/recipes-support/wireshark/wireshark_1.12.1.bb b/meta-networking/recipes-support/wireshark/wireshark_1.12.1.bb
index 71cc082..147c513 100644
--- a/meta-networking/recipes-support/wireshark/wireshark_1.12.1.bb
+++ b/meta-networking/recipes-support/wireshark/wireshark_1.12.1.bb
@@ -8,6 +8,7 @@ DEPENDS = "perl-native libcap libpcap pcre expat glib-2.0 libnl sbc"
 
 SRC_URI = " \
     http://wiresharkdownloads.riverbed.com/wireshark/src/wireshark-${PV}.tar.bz2 \
+    file://Do-not-set-CC_FOR_BUILD-flags.patch \
 "
 
 PE = "1"



More information about the Openembedded-commits mailing list