commit:     df1b45dc0a41a65bd351b984bbd1496436baa76b
Author:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
AuthorDate: Tue Jan  7 02:16:21 2025 +0000
Commit:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
CommitDate: Tue Jan  7 05:18:51 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=df1b45dc

net-misc/ubridge: update for unslotted iniparser

Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org>

 ...0.9.16_add_slotted_iniparser-4.1+_support.patch | 36 ----------------------
 ...idge-0.9.19.ebuild => ubridge-0.9.19-r1.ebuild} | 14 ++++-----
 2 files changed, 7 insertions(+), 43 deletions(-)

diff --git 
a/net-misc/ubridge/files/ubridge-0.9.16_add_slotted_iniparser-4.1+_support.patch
 
b/net-misc/ubridge/files/ubridge-0.9.16_add_slotted_iniparser-4.1+_support.patch
deleted file mode 100644
index 4d4825f477aa..000000000000
--- 
a/net-misc/ubridge/files/ubridge-0.9.16_add_slotted_iniparser-4.1+_support.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-diff -ur a/Makefile b/Makefile
---- a/Makefile 2019-05-20 10:02:14.000000000 +0300
-+++ b/Makefile 2019-05-20 10:32:04.972039000 +0300
-@@ -67,7 +67,7 @@
- 
- ifeq ($(SYSTEM_INIPARSER),1)
-     CFLAGS += -DUSE_SYSTEM_INIPARSER
--    LIBS += -liniparser
-+    LIBS += -liniparser4
- else
-     SRC += src/iniparser/iniparser.c   \
-          src/iniparser/dictionary.c
-diff -ur a/src/parse.h b/src/parse.h
---- a/src/parse.h      2019-05-20 10:02:14.000000000 +0300
-+++ b/src/parse.h      2019-05-20 10:32:04.968039000 +0300
-@@ -24,7 +24,7 @@
- #include "ubridge.h"
- 
- #ifdef USE_SYSTEM_INIPARSER
--#include <iniparser.h>
-+#include <iniparser4/iniparser.h>
- #else
- #include "iniparser/iniparser.h"
- #endif
-diff -ur a/src/ubridge.c b/src/ubridge.c
---- a/src/ubridge.c    2019-05-20 10:02:14.000000000 +0300
-+++ b/src/ubridge.c    2019-05-20 10:32:04.968039000 +0300
-@@ -26,7 +26,7 @@
- #include <pthread.h>
- 
- #ifdef USE_SYSTEM_INIPARSER
--#include <iniparser.h>
-+#include <iniparser4/iniparser.h>
- #else
- #include "iniparser/iniparser.h"
- #endif

diff --git a/net-misc/ubridge/ubridge-0.9.19.ebuild 
b/net-misc/ubridge/ubridge-0.9.19-r1.ebuild
similarity index 74%
rename from net-misc/ubridge/ubridge-0.9.19.ebuild
rename to net-misc/ubridge/ubridge-0.9.19-r1.ebuild
index 5c359bef8f37..f2b58fb26ca2 100644
--- a/net-misc/ubridge/ubridge-0.9.19.ebuild
+++ b/net-misc/ubridge/ubridge-0.9.19-r1.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2024 Gentoo Authors
+# Copyright 1999-2025 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
 
-inherit fcaps toolchain-funcs
+inherit fcaps flag-o-matic toolchain-funcs
 
 DESCRIPTION="Bridge for UDP tunnels, Ethernet, TAP and VMnet interfaces"
 HOMEPAGE="https://github.com/GNS3/ubridge";
@@ -15,16 +15,16 @@ KEYWORDS="~amd64 ~x86"
 
 RDEPEND="
        acct-group/ubridge
-       dev-libs/iniparser:4=
+       >=dev-libs/iniparser-4.1-r2:=
        net-libs/libpcap"
 
 DEPEND="${RDEPEND}"
 
-# Bugs: https://bugs.gentoo.org/647588
-#       https://github.com/GNS3/ubridge/issues/60
-PATCHES=( "${FILESDIR}/${PN}-0.9.16_add_slotted_iniparser-4.1+_support.patch" )
-
 src_compile() {
+       # iniparser.pc only exists in >=4.2 and it changes headers location
+       has_version '>=dev-libs/iniparser-4.2' &&
+               append-cflags $($(tc-getPKG_CONFIG) --cflags iniparser || die)
+
        emake \
                CC="$(tc-getCC)" \
                SYSTEM_INIPARSER=1

Reply via email to