public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
To: git-commits@fedoraproject.org
Subject: [rpms/ldns] f43: Drop python2 support from spec, remove nested directory
Date: Thu, 11 Jun 2026 14:32:19 GMT	[thread overview]
Message-ID: <178118833966.1.987995859611008236.rpms-ldns-ee1ebc36cd4e@fedoraproject.org> (raw)

            A new commit has been pushed.

            Repo   : rpms/ldns
            Branch : f43
            Commit : ee1ebc36cd4e1fdc81b9c43f1107c02e0cceb74e
            Author : Petr Menšík <pemensik@redhat.com>
            Date   : 2025-12-05T14:03:05+01:00
            Stats  : +26/-88 in 3 file(s)
            URL    : https://src.fedoraproject.org/rpms/ldns/c/ee1ebc36cd4e1fdc81b9c43f1107c02e0cceb74e?branch=f43

            Log:
            Drop python2 support from spec, remove nested directory

Two variants of python are not build in any case. Python2 is not
supported on any release even in CentOS, drop the support from the spec.

Change patches to -p1 prefix, which is more common.

---
diff --git a/ldns-1.7.0-multilib.patch b/ldns-1.7.0-multilib.patch
index 0609b0c..e30d398 100644
--- a/ldns-1.7.0-multilib.patch
+++ b/ldns-1.7.0-multilib.patch
@@ -1,7 +1,17 @@
-diff --git a/ldns-1.8.4/packaging/ldns-config.in b/ldns-1.8.4/packaging/ldns-config.in
+From 6148e4f15d6ac375556ee91974ee95b433944f5e Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Petr=20Men=C5=A1=C3=ADk?= <pemensik@redhat.com>
+Date: Fri, 5 Dec 2025 13:42:27 +0100
+Subject: [PATCH] Multiarch patch for architecture independent headers
+
+Downstream only.
+---
+ packaging/ldns-config.in | 26 +++++++++++++++++++++-----
+ 1 file changed, 21 insertions(+), 5 deletions(-)
+
+diff --git a/packaging/ldns-config.in b/packaging/ldns-config.in
 index 623f77e..2b961f9 100755
---- a/ldns-1.8.4/packaging/ldns-config.in
-+++ b/ldns-1.8.4/packaging/ldns-config.in
+--- a/packaging/ldns-config.in
++++ b/packaging/ldns-config.in
 @@ -3,16 +3,28 @@
  prefix="@prefix@"
  exec_prefix="@exec_prefix@"
@@ -54,3 +64,6 @@ index 623f77e..2b961f9 100755
      fi
      if [ $arg = "--version" ]
      then
+-- 
+2.52.0
+

diff --git a/ldns-1.9-std23-bool.patch b/ldns-1.9-std23-bool.patch
index 42b4325..d09972a 100644
--- a/ldns-1.9-std23-bool.patch
+++ b/ldns-1.9-std23-bool.patch
@@ -1,4 +1,4 @@
-From d2fc4ef2f3c64b246c67ffb613d4d26c2d74f596 Mon Sep 17 00:00:00 2001
+From fa04eca688a78d88d96fd08b47a80fd8a73a8156 Mon Sep 17 00:00:00 2001
 From: =?UTF-8?q?Petr=20Men=C5=A1=C3=ADk?= <pemensik@redhat.com>
 Date: Thu, 4 Dec 2025 17:01:59 +0100
 Subject: [PATCH] Skip definition of bool on -std=c23 or newer
@@ -11,13 +11,13 @@ compile ldns in default settings.
 
 Signed-off-by: Petr Menšík <pemensik@redhat.com>
 ---
- ldns-1.8.4/ldns/common.h.in | 4 ++++
+ ldns/common.h.in | 4 ++++
  1 file changed, 4 insertions(+)
 
-diff --git a/ldns-1.8.4/ldns/common.h.in b/ldns-1.8.4/ldns/common.h.in
+diff --git a/ldns/common.h.in b/ldns/common.h.in
 index db55960..c4e473c 100644
---- a/ldns-1.8.4/ldns/common.h.in
-+++ b/ldns-1.8.4/ldns/common.h.in
+--- a/ldns/common.h.in
++++ b/ldns/common.h.in
 @@ -40,6 +40,10 @@
   */
  /*@ignore@*/

diff --git a/ldns.spec b/ldns.spec
index abbb775..c1b0dcf 100644
--- a/ldns.spec
+++ b/ldns.spec
@@ -1,11 +1,6 @@
 %global _hardened_build 1
 
 %bcond_without python3
-%if 0%{?rhel} > 7 || 0%{?fedora} > 29
-%bcond_with    python2
-%else
-%bcond_without python2
-%endif
 %bcond_without  perl
 %bcond_without  ecdsa
 %if 0%{?fedora} >= 26 || 0%{?rhel} > 7
@@ -18,7 +13,7 @@
 # GOST is not allowed in Fedora/RHEL due to legal reasons (not NIST ECC)
 %bcond_with     gost
 
-%if %{with python2} || %{with python3}
+%if %{with python3}
 %{?filter_setup:
 %global _ldns_internal_filter /^_ldns[.]so.*/d;
 %filter_from_requires %{_ldns_internal_filter}
@@ -69,9 +64,6 @@ BuildRequires: gcc-c++
 BuildRequires: doxygen
 BuildRequires: gnupg2
 
-%if %{with python2}
-BuildRequires: python2-devel, swig
-%endif
 %if %{with python3}
 BuildRequires: python3-devel, swig
 %endif
@@ -107,17 +99,6 @@ Requires: %{name}%{?_isa} = %{version}-%{release}
 Collection of tools to get, check or alter DNS(SEC) data.
 
 
-%if %{with python2}
-%package -n python2-ldns
-Summary: Python2 extensions for ldns
-Requires: %{name}%{?_isa} = %{version}-%{release}
-%{?python_provide:%python_provide python2-ldns}
-
-%description -n python2-ldns
-Python2 extensions for ldns
-%endif
-
-
 %if %{with python3}
 %package -n python3-ldns
 Summary: Python3 extensions for ldns
@@ -151,10 +132,7 @@ This package contains documentation for the ldns library
 %gpgverify -d 0 -s 1 -k 2
 %endif
 
-%autosetup -cn %{pkgname} -N
-pushd %{pkgname}
-
-%autopatch -p2
+%autosetup -n %{pkgname} -p1
 
 rm -f config.guess config.sub ltmain.sh
 # Use ax_python_devel from autoconf-archive
@@ -164,18 +142,8 @@ libtoolize -c --install
 autoreconf --install
 
 # copy common doc files - after here, since it may be patched
-cp -pr doc LICENSE README* Changelog ../
-cp -p contrib/ldnsx/LICENSE ../LICENSE.ldnsx
-cp -p contrib/ldnsx/README ../README.ldnsx
-popd
-
-%if %{with python3}
-cp -a %{pkgname} %{pkgname}_python3
-%endif
-
-%if %{with python2}
-cp -a %{pkgname} %{pkgname}_python2
-%endif
+cp -p contrib/ldnsx/LICENSE LICENSE.ldnsx
+cp -p contrib/ldnsx/README README.ldnsx
 
 
 %build
@@ -214,12 +182,6 @@ export CFLAGS CXXFLAGS LDFLAGS
   --with-trust-anchor=%{_sharedstatedir}/unbound/root.key \\\
   --disable-static \\\
 
-%if 0%{with python3}
-pushd %{pkgname}_python3
-%else
-pushd %{pkgname}
-%endif
-
 %configure \
   %{common_args} \
   --with-examples \
@@ -247,30 +209,10 @@ sed -e "s,-L%{_libdir},," -i packaging/ldns-config
 # specfic hardening options should not end up in ldns-config
 sed -i "s~$RPM_LD_FLAGS~~" packaging/ldns-config
 mv doc/html ../doc
-popd
-
-%if %{with python2}
-  pushd %{pkgname}_python2
-  %configure \
-    %{common_args} \
-    --with-pyldns PYTHON=%{__python2}
-
-  %make_build
-  sed -e "s,-L%{_libdir},," -i packaging/ldns-config
-  popd
-%endif
 
 
 
 %install
-rm -rf %{buildroot}
-
-%if %{with python3}
-pushd %{pkgname}_python3
-%else
-pushd %{pkgname}
-%endif
-
 mkdir -p %{buildroot}%{_libdir}/pkgconfig
 %make_install
 
@@ -286,14 +228,6 @@ rm -rf %{buildroot}%{python3_sitearch}/*.la
   rm -f %{buildroot}%{perl_vendorarch}/auto/DNS/LDNS/{.packlist,LDNS.bs}
   rm -f %{buildroot}%{perl_archlib}/perllocal.pod
 %endif
-popd
-
-%if %{with python2}
-  pushd %{pkgname}_python2
-  %make_install install-pyldns install-pyldnsx
-  rm -rf %{buildroot}%{_libdir}/*.la %{buildroot}%{python2_sitearch}/*.la
-  popd
-%endif
 
 # don't package xml files
 rm doc/*.xml
@@ -327,18 +261,9 @@ rm -rf doc/man
 %{_includedir}/%{name}/*.h
 %{_mandir}/man3/%{name}*.3*
 
-%if %{with python2}
-%files -n python2-ldns
-%doc %{pkgname}_python2/contrib/python/Changelog README.ldnsx
-%license LICENSE.ldnsx
-%{python2_sitearch}/%{name}.py*
-%{python2_sitearch}/%{name}x.py*
-%{python2_sitearch}/_%{name}.so*
-%endif
-
 %if %{with python3}
 %files -n python3-ldns
-%doc %{pkgname}_python3/contrib/python/Changelog README.ldnsx
+%doc contrib/python/Changelog README.ldnsx
 %license LICENSE.ldnsx
 %pycached %{python3_sitearch}/%{name}.py
 %pycached %{python3_sitearch}/%{name}x.py

                 reply	other threads:[~2026-06-11 14:32 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=178118833966.1.987995859611008236.rpms-ldns-ee1ebc36cd4e@fedoraproject.org \
    --to=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox