diff options
-rw-r--r-- | meta-python/recipes-devtools/python/python3-grpcio/0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch | 6 | ||||
-rw-r--r-- | meta-python/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 131daace06..f39a82a33d 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 @@ | |||
1 | From b02be74a2eff8abc612ef84f30e0fbce6a7f65f5 Mon Sep 17 00:00:00 2001 | 1 | 1From b02be74a2eff8abc612ef84f30e0fbce6a7f65f5 Mon Sep 17 00:00:00 2001 |
2 | From: Khem Raj <raj.khem@gmail.com> | 2 | From: Khem Raj <raj.khem@gmail.com> |
3 | Date: Fri, 4 Aug 2017 09:04:07 -0700 | 3 | Date: Fri, 4 Aug 2017 09:04:07 -0700 |
4 | Subject: [PATCH] setup.py: Do not mix C and C++ compiler options | 4 | 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> | |||
24 | 24 | ||
25 | def check_linker_need_libatomic(): | 25 | def check_linker_need_libatomic(): |
26 | """Test if linker on system needs libatomic.""" | 26 | """Test if linker on system needs libatomic.""" |
27 | + compiler, cc_args = os.environ.get('CC').split(' ', 1) or 'cc' | 27 | + compiler, cc_args = os.environ.get('CC').split(' ', 1) or 'gcc' |
28 | code_test = (b'#include <atomic>\n' + | 28 | code_test = (b'#include <atomic>\n' + |
29 | b'int main() { return std::atomic<int64_t>{}; }') | 29 | b'int main() { return std::atomic<int64_t>{}; }') |
30 | - cc_test = subprocess.Popen(['cc', '-x', 'c++', '-std=c++11', '-'], | 30 | - cc_test = subprocess.Popen(['cc', '-x', 'c++', '-std=c++11', '-'], |
@@ -57,7 +57,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com> | |||
57 | """ | 57 | """ |
58 | # TODO(lidiz) Remove the generated a.out for success tests. | 58 | # TODO(lidiz) Remove the generated a.out for success tests. |
59 | - cc_test = subprocess.Popen(['cc', '-x', 'c', '-std=c++11', '-'], | 59 | - cc_test = subprocess.Popen(['cc', '-x', 'c', '-std=c++11', '-'], |
60 | + compiler, cc_args = os.environ.get('CC').split(' ', 1) or 'cc' | 60 | + compiler, cc_args = os.environ.get('CC').split(' ', 1) or 'gcc' |
61 | + cc_test = subprocess.Popen([compiler, cc_args, '-x', 'c', '-std=c++11', '-'], | 61 | + cc_test = subprocess.Popen([compiler, cc_args, '-x', 'c', '-std=c++11', '-'], |
62 | stdin=subprocess.PIPE, | 62 | stdin=subprocess.PIPE, |
63 | stdout=subprocess.PIPE, | 63 | 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 bc2b70cf87..42260cb27c 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" | |||
6 | 6 | ||
7 | DEPENDS += "${PYTHON_PN}-protobuf" | 7 | DEPENDS += "${PYTHON_PN}-protobuf" |
8 | 8 | ||
9 | SRC_URI_append_class-target = " file://0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch \ | 9 | SRC_URI += "file://0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch" |
10 | file://ppc-boringssl-support.patch \ | 10 | SRC_URI_append_class-target = " file://ppc-boringssl-support.patch \ |
11 | file://riscv64_support.patch \ | 11 | file://riscv64_support.patch \ |
12 | " | 12 | " |
13 | SRC_URI[md5sum] = "ccaf4e7eb4f031d926fb80035d193b98" | 13 | SRC_URI[md5sum] = "ccaf4e7eb4f031d926fb80035d193b98" |