1 |
commit: 9963929bb82eee544a2d2029a66288b2b9ae507e |
2 |
Author: Sam James <sam <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Nov 6 05:06:12 2022 +0000 |
4 |
Commit: Sam James <sam <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Nov 6 05:41:13 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9963929b |
7 |
|
8 |
app-text/opensp: fix build with clang (16) |
9 |
|
10 |
Fix generic build with Clang but also with Clang 16. |
11 |
|
12 |
Closes: https://bugs.gentoo.org/767865 |
13 |
Signed-off-by: Sam James <sam <AT> gentoo.org> |
14 |
|
15 |
app-text/opensp/files/opensp-1.5.2-configure-clang16.patch | 13 +++++++++++++ |
16 |
.../{opensp-1.5.2-r7.ebuild => opensp-1.5.2-r8.ebuild} | 7 ++++++- |
17 |
2 files changed, 19 insertions(+), 1 deletion(-) |
18 |
|
19 |
diff --git a/app-text/opensp/files/opensp-1.5.2-configure-clang16.patch b/app-text/opensp/files/opensp-1.5.2-configure-clang16.patch |
20 |
new file mode 100644 |
21 |
index 000000000000..468d0f1d306d |
22 |
--- /dev/null |
23 |
+++ b/app-text/opensp/files/opensp-1.5.2-configure-clang16.patch |
24 |
@@ -0,0 +1,13 @@ |
25 |
+--- a/acinclude.m4 |
26 |
++++ b/acinclude.m4 |
27 |
+@@ -9,8 +9,9 @@ changequote([, ])dnl |
28 |
+ AC_MSG_CHECKING(size of $1) |
29 |
+ AC_CACHE_VAL(AC_CV_NAME, |
30 |
+ [AC_TRY_RUN([#include <stdio.h> |
31 |
++#include <stdlib.h> |
32 |
+ #include <$2> |
33 |
+-main() |
34 |
++int main(void) |
35 |
+ { |
36 |
+ FILE *f=fopen("conftestval", "w"); |
37 |
+ if (!f) exit(1); |
38 |
|
39 |
diff --git a/app-text/opensp/opensp-1.5.2-r7.ebuild b/app-text/opensp/opensp-1.5.2-r8.ebuild |
40 |
similarity index 94% |
41 |
rename from app-text/opensp/opensp-1.5.2-r7.ebuild |
42 |
rename to app-text/opensp/opensp-1.5.2-r8.ebuild |
43 |
index 9f6b4f539bb4..743116acc69e 100644 |
44 |
--- a/app-text/opensp/opensp-1.5.2-r7.ebuild |
45 |
+++ b/app-text/opensp/opensp-1.5.2-r8.ebuild |
46 |
@@ -34,11 +34,14 @@ BDEPEND="nls? ( sys-devel/gettext ) |
47 |
PATCHES=( |
48 |
"${FILESDIR}"/${P}-fix-segfault.patch |
49 |
"${FILESDIR}"/${P}-c11-using.patch |
50 |
+ "${FILESDIR}"/${P}-configure-clang16.patch |
51 |
) |
52 |
|
53 |
src_prepare() { |
54 |
default |
55 |
- use prefix && eautoreconf |
56 |
+ |
57 |
+ # Needed for Clang 16 |
58 |
+ eautoreconf |
59 |
} |
60 |
|
61 |
src_configure() { |
62 |
@@ -51,6 +54,8 @@ src_configure() { |
63 |
#ALLOWED_FLAGS="-O -O1 -O2 -pipe -g -march" |
64 |
strip-flags |
65 |
|
66 |
+ append-cxxflags -std=gnu++11 |
67 |
+ |
68 |
econf \ |
69 |
--enable-http \ |
70 |
--enable-default-catalog="${EPREFIX}"/etc/sgml/catalog \ |