1 |
commit: 9a5aad2bf2e54dab53a598fa151baaa8dd1b1f0c |
2 |
Author: Louis Sautier <sbraz <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sat Nov 5 17:15:58 2022 +0000 |
4 |
Commit: Louis Sautier <sbraz <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Nov 5 18:35:20 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9a5aad2b |
7 |
|
8 |
net-irc/znc: fix build with SWIG 4.1.0 and USE=perl/python |
9 |
|
10 |
Also always enable IPv6 as it doesn't require additional dependencies |
11 |
(pkgcheck warned of "UseFlagWithoutDeps"). |
12 |
|
13 |
Closes: https://bugs.gentoo.org/878587 |
14 |
Signed-off-by: Louis Sautier <sbraz <AT> gentoo.org> |
15 |
|
16 |
net-irc/znc/files/znc-1.8.2-fix-swig.patch | 43 ++++++++++++++++++++++++++++++ |
17 |
net-irc/znc/znc-1.8.2-r2.ebuild | 9 ++++--- |
18 |
2 files changed, 48 insertions(+), 4 deletions(-) |
19 |
|
20 |
diff --git a/net-irc/znc/files/znc-1.8.2-fix-swig.patch b/net-irc/znc/files/znc-1.8.2-fix-swig.patch |
21 |
new file mode 100644 |
22 |
index 000000000000..d07d136c5940 |
23 |
--- /dev/null |
24 |
+++ b/net-irc/znc/files/znc-1.8.2-fix-swig.patch |
25 |
@@ -0,0 +1,43 @@ |
26 |
+From fecdd9895894b3afe903021b0843a422eb4d3308 Mon Sep 17 00:00:00 2001 |
27 |
+From: Alexey Sokolov <alexey+znc@××××××××.org> |
28 |
+Date: Sat, 5 Nov 2022 12:54:40 +0000 |
29 |
+Subject: [PATCH] Add support SWIG 4.1.0, drop support for < 4.0.1 |
30 |
+ |
31 |
+https://bugs.gentoo.org/878587 |
32 |
+--- |
33 |
+ CMakeLists.txt | 2 +- |
34 |
+ modules/modperl/CMakeLists.txt | 1 - |
35 |
+ modules/modpython/CMakeLists.txt | 1 - |
36 |
+ 3 files changed, 1 insertion(+), 3 deletions(-) |
37 |
+ |
38 |
+--- a/CMakeLists.txt |
39 |
++++ b/CMakeLists.txt |
40 |
+@@ -173,7 +173,7 @@ if(WANT_PYTHON AND NOT EXISTS |
41 |
+ endif() |
42 |
+ endif() |
43 |
+ if(search_swig) |
44 |
+- find_package(SWIG 3.0.0) |
45 |
++ find_package(SWIG 4.0.1) |
46 |
+ if(NOT SWIG_FOUND) |
47 |
+ message(FATAL_ERROR |
48 |
+ "Can't find SWIG, therefore Perl and Python aren't supported. " |
49 |
+--- a/modules/modperl/CMakeLists.txt |
50 |
++++ b/modules/modperl/CMakeLists.txt |
51 |
+@@ -53,7 +53,6 @@ if(SWIG_FOUND) |
52 |
+ "-I${PROJECT_SOURCE_DIR}/include" |
53 |
+ "-I${CMAKE_CURRENT_SOURCE_DIR}/.." |
54 |
+ "-I${CMAKE_CURRENT_SOURCE_DIR}/include" |
55 |
+- -DZNC_EXPORT_LIB_EXPORT |
56 |
+ -outdir "${CMAKE_CURRENT_BINARY_DIR}" |
57 |
+ -o "${CMAKE_CURRENT_BINARY_DIR}/modperl_biglib.cpp" |
58 |
+ "${CMAKE_CURRENT_SOURCE_DIR}/modperl.i" |
59 |
+--- a/modules/modpython/CMakeLists.txt |
60 |
++++ b/modules/modpython/CMakeLists.txt |
61 |
+@@ -50,7 +50,6 @@ if(SWIG_FOUND) |
62 |
+ "-I${PROJECT_BINARY_DIR}/include" |
63 |
+ "-I${PROJECT_SOURCE_DIR}/include" |
64 |
+ "-I${CMAKE_CURRENT_SOURCE_DIR}/.." |
65 |
+- -DZNC_EXPORT_LIB_EXPORT |
66 |
+ -outdir "${CMAKE_CURRENT_BINARY_DIR}" |
67 |
+ -o "${CMAKE_CURRENT_BINARY_DIR}/modpython_biglib.cpp" |
68 |
+ "${CMAKE_CURRENT_SOURCE_DIR}/modpython.i" |
69 |
|
70 |
diff --git a/net-irc/znc/znc-1.8.2-r2.ebuild b/net-irc/znc/znc-1.8.2-r2.ebuild |
71 |
index b9d4a004fac3..885291374ae4 100644 |
72 |
--- a/net-irc/znc/znc-1.8.2-r2.ebuild |
73 |
+++ b/net-irc/znc/znc-1.8.2-r2.ebuild |
74 |
@@ -30,7 +30,7 @@ LICENSE="Apache-2.0" |
75 |
# "If you upgrade your ZNC version, you must recompile all your modules." |
76 |
# - https://wiki.znc.in/Compiling_modules |
77 |
SLOT="0/${PV}" |
78 |
-IUSE="+ipv6 +icu nls perl python +ssl sasl tcl test +zlib" |
79 |
+IUSE="+icu nls perl python +ssl sasl tcl test +zlib" |
80 |
RESTRICT="!test? ( test )" |
81 |
|
82 |
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} icu )" |
83 |
@@ -40,11 +40,11 @@ BDEPEND=" |
84 |
virtual/pkgconfig |
85 |
nls? ( sys-devel/gettext ) |
86 |
perl? ( |
87 |
- >=dev-lang/swig-3.0.0 |
88 |
+ >=dev-lang/swig-4.0.1 |
89 |
>=dev-lang/perl-5.10 |
90 |
) |
91 |
python? ( |
92 |
- >=dev-lang/swig-3.0.0 |
93 |
+ >=dev-lang/swig-4.0.1 |
94 |
>=dev-lang/perl-5.10 |
95 |
) |
96 |
test? ( |
97 |
@@ -75,6 +75,7 @@ PATCHES=( |
98 |
"${FILESDIR}"/${P}-add-libera.patch |
99 |
"${FILESDIR}"/${P}-fix-python-3.10.patch |
100 |
"${FILESDIR}"/${P}-fix-odr-violation.patch |
101 |
+ "${FILESDIR}"/${P}-fix-swig.patch |
102 |
) |
103 |
|
104 |
pkg_setup() { |
105 |
@@ -103,7 +104,7 @@ src_configure() { |
106 |
-DWANT_SYSTEMD=yes # Causes -DSYSTEMD_DIR to be used. |
107 |
-DSYSTEMD_DIR="$(systemd_get_systemunitdir)" |
108 |
-DWANT_ICU="$(usex icu)" |
109 |
- -DWANT_IPV6="$(usex ipv6)" |
110 |
+ -DWANT_IPV6=yes |
111 |
-DWANT_I18N="$(usex nls)" |
112 |
-DWANT_PERL="$(usex perl)" |
113 |
-DWANT_PYTHON="$(usex python)" |