commit:     96287bc84761a85c048e6b470b05a5a31cc389df
Author:     Emanuele Torre <torreemanuele6 <AT> gmail <DOT> com>
AuthorDate: Thu Aug 15 23:50:02 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Aug 16 02:18:34 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=96287bc8

net-misc/trurl: add latest 0.14, fix 9999 build

The old Makefile patch can no longer be applied; so I wrote a new patch
that applies to 0.14 that is also applied to the 9999 version for now,
and sent it upstream.

Additionally, I added an  export NDEBUG=1  command in src_compile:
without this, -g and -Werror are added after CFLAGS by the Makefile
possibly shadowing options like -ggdb3 that user might have set, or
causing a build to fail just because a warning was reported.

Bump copyright of touched ebuild files.

Ref: https://github.com/curl/trurl/pull/322
Signed-off-by: Emanuele Torre <torreemanuele6 <AT> gmail.com>
Signed-off-by: Sam James <sam <AT> gentoo.org>

 net-misc/trurl/Manifest                            |  1 +
 net-misc/trurl/files/trurl-0.14-fix-makefile.patch | 25 ++++++++++++++++++++++
 .../trurl/{trurl-9999.ebuild => trurl-0.14.ebuild} |  5 +++--
 net-misc/trurl/trurl-9999.ebuild                   |  5 +++--
 4 files changed, 32 insertions(+), 4 deletions(-)

diff --git a/net-misc/trurl/Manifest b/net-misc/trurl/Manifest
index 316593446d28..71fbfab765ea 100644
--- a/net-misc/trurl/Manifest
+++ b/net-misc/trurl/Manifest
@@ -1 +1,2 @@
+DIST trurl-0.14.tar.gz 47830 BLAKE2B 
15be36ef5c5989cf15d3983827055c793f15ae59efe8e02cc2f55ad9b19c528bb568aacc0583590017a6d6a3a74db1bd6bd3e18d3fee1c7c7d86e71f503d57f7
 SHA512 
25c1a3035095065368c8a11547e1d918b6f688e293982895a7bc27d9e161c0193ceccfaa0c2440f5c42a8ba4d5176a3f6a4fb843f5fa573328ef9baf5a438165
 DIST trurl-0.7.tar.gz 36624 BLAKE2B 
a63e8ec7f0b57006b5fa7a1d2ade1284dc2076474ef0425574ecb9b452c49d9a6148461a97e760287340d67a924612c1eb1fe188b6597b8147f818c18681190f
 SHA512 
9ecccd9b688d7bddba760bbd408a1b864d5818b2c538904662ab81b13bca6226d03a4d209c74841c83ee368e656243e92bc7f7be876dbd5c1736b7fc2c3f82d6

diff --git a/net-misc/trurl/files/trurl-0.14-fix-makefile.patch 
b/net-misc/trurl/files/trurl-0.14-fix-makefile.patch
new file mode 100644
index 000000000000..2787f21015fd
--- /dev/null
+++ b/net-misc/trurl/files/trurl-0.14-fix-makefile.patch
@@ -0,0 +1,25 @@
+See https://github.com/curl/trurl/pull/322
+--- a/Makefile
++++ b/Makefile
+@@ -28,10 +28,10 @@ ifndef TRURL_IGNORE_CURL_CONFIG
+ LDLIBS += $$(curl-config --libs)
+ CFLAGS += $$(curl-config --cflags)
+ endif
+-CFLAGS += -W -Wall -Wshadow -Werror -pedantic
++CFLAGS += -W -Wall -Wshadow -pedantic
+ CFLAGS += -Wconversion -Wmissing-prototypes -Wwrite-strings -Wsign-compare 
-Wno-sign-conversion
+ ifndef NDEBUG
+-CFLAGS += -g
++CFLAGS += -Werror -g
+ endif
+ MANUAL = trurl.1
+ 
+@@ -43,7 +43,7 @@ INSTALL ?= install
+ PYTHON3 ?= python3
+ 
+ $(TARGET): $(OBJS)
+-      $(CC) $(OBJS) -o $(TARGET) $(LDFLAGS) $(LDLIBS)
++      $(CC) $(LDFLAGS) $(OBJS) -o $(TARGET) $(LDLIBS)
+ 
+ trurl.o: trurl.c version.h
+ 

diff --git a/net-misc/trurl/trurl-9999.ebuild b/net-misc/trurl/trurl-0.14.ebuild
similarity index 90%
copy from net-misc/trurl/trurl-9999.ebuild
copy to net-misc/trurl/trurl-0.14.ebuild
index 2a3befe7c83d..5dfbbc31163e 100644
--- a/net-misc/trurl/trurl-9999.ebuild
+++ b/net-misc/trurl/trurl-0.14.ebuild
@@ -1,4 +1,4 @@
-# Copyright 2023 Gentoo Authors
+# Copyright 2023-2024 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
@@ -30,7 +30,7 @@ RDEPEND="${DEPEND}"
 BDEPEND="test? ( ${PYTHON_DEPS} )"
 
 PATCHES=(
-       "${FILESDIR}"/${PN}-0.7-fix-makefile.patch
+       "${FILESDIR}"/${PN}-0.14-fix-makefile.patch
 )
 
 pkg_setup() {
@@ -39,6 +39,7 @@ pkg_setup() {
 
 src_compile() {
        tc-export CC
+       export NDEBUG=1
 
        default
 }

diff --git a/net-misc/trurl/trurl-9999.ebuild b/net-misc/trurl/trurl-9999.ebuild
index 2a3befe7c83d..5dfbbc31163e 100644
--- a/net-misc/trurl/trurl-9999.ebuild
+++ b/net-misc/trurl/trurl-9999.ebuild
@@ -1,4 +1,4 @@
-# Copyright 2023 Gentoo Authors
+# Copyright 2023-2024 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
@@ -30,7 +30,7 @@ RDEPEND="${DEPEND}"
 BDEPEND="test? ( ${PYTHON_DEPS} )"
 
 PATCHES=(
-       "${FILESDIR}"/${PN}-0.7-fix-makefile.patch
+       "${FILESDIR}"/${PN}-0.14-fix-makefile.patch
 )
 
 pkg_setup() {
@@ -39,6 +39,7 @@ pkg_setup() {
 
 src_compile() {
        tc-export CC
+       export NDEBUG=1
 
        default
 }

Reply via email to