1 |
commit: 8aeeba04d1e08aa74cf50e402eb37477e402ec33 |
2 |
Author: Jeremi Piotrowski <jpiotrowski <AT> microsoft <DOT> com> |
3 |
AuthorDate: Thu Mar 24 11:17:22 2022 +0000 |
4 |
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Mar 28 19:31:34 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8aeeba04 |
7 |
|
8 |
sys-libs/liburing: pass --cxx paramter to configure |
9 |
|
10 |
Provide the correct value to --cxx to fix cross-compilation. liburing uses the |
11 |
value of the cxx variable for linking. This happens to work for native builds |
12 |
but breaks when cross-compiling, as evidenced by the below output (from |
13 |
Flatcar): |
14 |
|
15 |
>>> Configuring source in /build/arm64-usr/var/tmp/portage/sys-libs/liburing-2.1-r1/work/liburing-2.1 ... |
16 |
* .arm64: running multilib-minimal_abi_src_configure |
17 |
prefix /usr |
18 |
includedir /usr/include |
19 |
libdir /usr/lib64 |
20 |
libdevdir /usr/lib64 |
21 |
relativelibdir |
22 |
mandir /usr/share/man |
23 |
datadir /usr/share |
24 |
stringop_overflow yes |
25 |
array_bounds yes |
26 |
__kernel_rwf_t yes |
27 |
__kernel_timespec yes |
28 |
open_how no |
29 |
statx yes |
30 |
C++ yes |
31 |
has_ucontext yes |
32 |
CC aarch64-cros-linux-gnu-gcc |
33 |
CXX g++ |
34 |
|
35 |
... |
36 |
|
37 |
aarch64-cros-linux-gnu-gcc -D_GNU_SOURCE -D__SANE_USERSPACE_TYPES__ -I../src/include/ -include ../config-host.h -O2 -pipe -mtune=generic -g -D_GNU_SOURCE -Wall -Wextra -Wno-unused-parameter -Wno-sign-compare -L../src/ -o statx statx.c helpers.o -luring -Wstringop-overflow=0 -Warray-bounds=0 |
38 |
g++ -D_GNU_SOURCE -D__SANE_USERSPACE_TYPES__ -I../src/include/ -include ../config-host.h -O2 -pipe -mtune=generic -g -O2 -pipe -mtune=generic -g -D_GNU_SOURCE -Wall -Wextra -Wno-unused-parameter -Wno-sign-compare -L../src/ -std=c++11 -o sq-full-cpp sq-full-cpp.cc helpers.o -luring -Wstringop-overflow=0 -Warray-bounds=0 |
39 |
/usr/lib/gcc/x86_64-pc-linux-gnu/10.3.0/../../../../x86_64-pc-linux-gnu/bin/ld: helpers.o: Relocations in generic ELF (EM: 183) |
40 |
/usr/lib/gcc/x86_64-pc-linux-gnu/10.3.0/../../../../x86_64-pc-linux-gnu/bin/ld: helpers.o: Relocations in generic ELF (EM: 183) |
41 |
/usr/lib/gcc/x86_64-pc-linux-gnu/10.3.0/../../../../x86_64-pc-linux-gnu/bin/ld: helpers.o: Relocations in generic ELF (EM: 183) |
42 |
/usr/lib/gcc/x86_64-pc-linux-gnu/10.3.0/../../../../x86_64-pc-linux-gnu/bin/ld: helpers.o: Relocations in generic ELF (EM: 183) |
43 |
/usr/lib/gcc/x86_64-pc-linux-gnu/10.3.0/../../../../x86_64-pc-linux-gnu/bin/ld: helpers.o: Relocations in generic ELF (EM: 183) |
44 |
/usr/lib/gcc/x86_64-pc-linux-gnu/10.3.0/../../../../x86_64-pc-linux-gnu/bin/ld: helpers.o: Relocations in generic ELF (EM: 183) |
45 |
/usr/lib/gcc/x86_64-pc-linux-gnu/10.3.0/../../../../x86_64-pc-linux-gnu/bin/ld: helpers.o: error adding symbols: file in wrong format |
46 |
collect2: error: ld returned 1 exit status |
47 |
make[1]: *** [Makefile:165: sq-full-cpp] Error 1 |
48 |
make[1]: *** Waiting for unfinished jobs.... |
49 |
|
50 |
Bug: https://bugs.gentoo.org/836316 |
51 |
Signed-off-by: Jeremi Piotrowski <jpiotrowski <AT> microsoft.com> |
52 |
Closes: https://github.com/gentoo/gentoo/pull/24733 |
53 |
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org> |
54 |
|
55 |
sys-libs/liburing/liburing-2.1-r1.ebuild | 1 + |
56 |
sys-libs/liburing/liburing-2.1-r2.ebuild | 1 + |
57 |
sys-libs/liburing/liburing-9999.ebuild | 1 + |
58 |
3 files changed, 3 insertions(+) |
59 |
|
60 |
diff --git a/sys-libs/liburing/liburing-2.1-r1.ebuild b/sys-libs/liburing/liburing-2.1-r1.ebuild |
61 |
index ae14b067cbb3..ddf39035944f 100644 |
62 |
--- a/sys-libs/liburing/liburing-2.1-r1.ebuild |
63 |
+++ b/sys-libs/liburing/liburing-2.1-r1.ebuild |
64 |
@@ -45,6 +45,7 @@ multilib_src_configure() { |
65 |
--libdevdir="${EPREFIX}/usr/$(get_libdir)" |
66 |
--mandir="${EPREFIX}/usr/share/man" |
67 |
--cc="$(tc-getCC)" |
68 |
+ --cxx="$(tc-getCXX)" |
69 |
) |
70 |
# No autotools configure! "econf" will fail. |
71 |
TMPDIR="${T}" ./configure "${myconf[@]}" |
72 |
|
73 |
diff --git a/sys-libs/liburing/liburing-2.1-r2.ebuild b/sys-libs/liburing/liburing-2.1-r2.ebuild |
74 |
index c65e7baf841c..cb5271810e69 100644 |
75 |
--- a/sys-libs/liburing/liburing-2.1-r2.ebuild |
76 |
+++ b/sys-libs/liburing/liburing-2.1-r2.ebuild |
77 |
@@ -51,6 +51,7 @@ multilib_src_configure() { |
78 |
--libdevdir="${EPREFIX}/usr/$(get_libdir)" |
79 |
--mandir="${EPREFIX}/usr/share/man" |
80 |
--cc="$(tc-getCC)" |
81 |
+ --cxx="$(tc-getCXX)" |
82 |
) |
83 |
# No autotools configure! "econf" will fail. |
84 |
TMPDIR="${T}" ./configure "${myconf[@]}" |
85 |
|
86 |
diff --git a/sys-libs/liburing/liburing-9999.ebuild b/sys-libs/liburing/liburing-9999.ebuild |
87 |
index c7427bfe9a0d..87e93eac4554 100644 |
88 |
--- a/sys-libs/liburing/liburing-9999.ebuild |
89 |
+++ b/sys-libs/liburing/liburing-9999.ebuild |
90 |
@@ -40,6 +40,7 @@ multilib_src_configure() { |
91 |
--libdevdir="${EPREFIX}/usr/$(get_libdir)" |
92 |
--mandir="${EPREFIX}/usr/share/man" |
93 |
--cc="$(tc-getCC)" |
94 |
+ --cxx="$(tc-getCXX)" |
95 |
) |
96 |
# No autotools configure! "econf" will fail. |
97 |
TMPDIR="${T}" ./configure "${myconf[@]}" |