All of lore.kernel.org
 help / color / mirror / Atom feed
* [meta-python][PATCH] python3-grpcio: fix do_compile error for native
@ 2020-02-20 10:49 Chen Qi
  0 siblings, 0 replies; 2+ messages in thread
From: Chen Qi @ 2020-02-20 10:49 UTC (permalink / raw)
  To: openembedded-devel

When building python3-grpcio-native, we will meet do_compile error
because of no 'cc'.

In fact, 'cc' is not in our hosttools. So fix to use gcc and make
the patch also apply to native.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 .../0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch | 6 +++---
 .../recipes-devtools/python/python3-grpcio_1.27.1.bb        | 4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/meta-python/recipes-devtools/python/python3-grpcio/0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch b/meta-python/recipes-devtools/python/python3-grpcio/0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch
index 131daace0..f39a82a33 100644
--- a/meta-python/recipes-devtools/python/python3-grpcio/0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch
+++ b/meta-python/recipes-devtools/python/python3-grpcio/0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch
@@ -1,4 +1,4 @@
-From b02be74a2eff8abc612ef84f30e0fbce6a7f65f5 Mon Sep 17 00:00:00 2001
+1From b02be74a2eff8abc612ef84f30e0fbce6a7f65f5 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 4 Aug 2017 09:04:07 -0700
 Subject: [PATCH] setup.py: Do not mix C and C++ compiler options
@@ -24,7 +24,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  
  def check_linker_need_libatomic():
    """Test if linker on system needs libatomic."""
-+  compiler, cc_args = os.environ.get('CC').split(' ', 1) or 'cc'
++  compiler, cc_args = os.environ.get('CC').split(' ', 1) or 'gcc'
    code_test = (b'#include <atomic>\n' +
                 b'int main() { return std::atomic<int64_t>{}; }')
 -  cc_test = subprocess.Popen(['cc', '-x', 'c++', '-std=c++11', '-'],
@@ -57,7 +57,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
              """
              # TODO(lidiz) Remove the generated a.out for success tests.
 -            cc_test = subprocess.Popen(['cc', '-x', 'c', '-std=c++11', '-'],
-+            compiler, cc_args = os.environ.get('CC').split(' ', 1) or 'cc'
++            compiler, cc_args = os.environ.get('CC').split(' ', 1) or 'gcc'
 +            cc_test = subprocess.Popen([compiler, cc_args, '-x', 'c', '-std=c++11', '-'],
                                         stdin=subprocess.PIPE,
                                         stdout=subprocess.PIPE,
diff --git a/meta-python/recipes-devtools/python/python3-grpcio_1.27.1.bb b/meta-python/recipes-devtools/python/python3-grpcio_1.27.1.bb
index bc2b70cf8..42260cb27 100644
--- a/meta-python/recipes-devtools/python/python3-grpcio_1.27.1.bb
+++ b/meta-python/recipes-devtools/python/python3-grpcio_1.27.1.bb
@@ -6,8 +6,8 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
 
 DEPENDS += "${PYTHON_PN}-protobuf"
 
-SRC_URI_append_class-target = " file://0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch \
-                                file://ppc-boringssl-support.patch \
+SRC_URI += "file://0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch"
+SRC_URI_append_class-target = " file://ppc-boringssl-support.patch \
                                 file://riscv64_support.patch \
 "
 SRC_URI[md5sum] = "ccaf4e7eb4f031d926fb80035d193b98"
-- 
2.17.1



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [meta-python][PATCH] python3-grpcio: fix do_compile error for native
@ 2020-02-20 10:48 Chen Qi
  0 siblings, 0 replies; 2+ messages in thread
From: Chen Qi @ 2020-02-20 10:48 UTC (permalink / raw)
  To: openembedded-devel

When building python3-grpcio-native, we will meet do_compile error
because of no 'cc'.

In fact, 'cc' is not in our hosttools. So fix to use gcc and make
the patch also apply to native.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 .../0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch | 6 +++---
 .../recipes-devtools/python/python3-grpcio_1.27.1.bb        | 4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/meta-python/recipes-devtools/python/python3-grpcio/0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch b/meta-python/recipes-devtools/python/python3-grpcio/0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch
index 131daace0..f39a82a33 100644
--- a/meta-python/recipes-devtools/python/python3-grpcio/0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch
+++ b/meta-python/recipes-devtools/python/python3-grpcio/0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch
@@ -1,4 +1,4 @@
-From b02be74a2eff8abc612ef84f30e0fbce6a7f65f5 Mon Sep 17 00:00:00 2001
+1From b02be74a2eff8abc612ef84f30e0fbce6a7f65f5 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 4 Aug 2017 09:04:07 -0700
 Subject: [PATCH] setup.py: Do not mix C and C++ compiler options
@@ -24,7 +24,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  
  def check_linker_need_libatomic():
    """Test if linker on system needs libatomic."""
-+  compiler, cc_args = os.environ.get('CC').split(' ', 1) or 'cc'
++  compiler, cc_args = os.environ.get('CC').split(' ', 1) or 'gcc'
    code_test = (b'#include <atomic>\n' +
                 b'int main() { return std::atomic<int64_t>{}; }')
 -  cc_test = subprocess.Popen(['cc', '-x', 'c++', '-std=c++11', '-'],
@@ -57,7 +57,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
              """
              # TODO(lidiz) Remove the generated a.out for success tests.
 -            cc_test = subprocess.Popen(['cc', '-x', 'c', '-std=c++11', '-'],
-+            compiler, cc_args = os.environ.get('CC').split(' ', 1) or 'cc'
++            compiler, cc_args = os.environ.get('CC').split(' ', 1) or 'gcc'
 +            cc_test = subprocess.Popen([compiler, cc_args, '-x', 'c', '-std=c++11', '-'],
                                         stdin=subprocess.PIPE,
                                         stdout=subprocess.PIPE,
diff --git a/meta-python/recipes-devtools/python/python3-grpcio_1.27.1.bb b/meta-python/recipes-devtools/python/python3-grpcio_1.27.1.bb
index bc2b70cf8..42260cb27 100644
--- a/meta-python/recipes-devtools/python/python3-grpcio_1.27.1.bb
+++ b/meta-python/recipes-devtools/python/python3-grpcio_1.27.1.bb
@@ -6,8 +6,8 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
 
 DEPENDS += "${PYTHON_PN}-protobuf"
 
-SRC_URI_append_class-target = " file://0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch \
-                                file://ppc-boringssl-support.patch \
+SRC_URI += "file://0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch"
+SRC_URI_append_class-target = " file://ppc-boringssl-support.patch \
                                 file://riscv64_support.patch \
 "
 SRC_URI[md5sum] = "ccaf4e7eb4f031d926fb80035d193b98"
-- 
2.17.1



^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-02-20 10:49 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-20 10:49 [meta-python][PATCH] python3-grpcio: fix do_compile error for native Chen Qi
  -- strict thread matches above, loose matches on Subject: below --
2020-02-20 10:48 Chen Qi

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.