From: Nick Porter Date: Mon, 12 Feb 2024 10:34:58 +0000 (+0000) Subject: Include rlm_unbound in packaging X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c62819c76ee7d3760d0ac27de95b15d9c6dc50eb;p=thirdparty%2Ffreeradius-server.git Include rlm_unbound in packaging Same as v3.2 --- diff --git a/debian/control.in b/debian/control.in index 52b7421ee7a..b242ea9be4b 100644 --- a/debian/control.in +++ b/debian/control.in @@ -29,6 +29,7 @@ Build-Depends: @BUILDDEPS@ debhelper (>= 9), libsqlite3-dev, libssl-dev, libtalloc-dev, + libunbound-dev, libwbclient-dev, libykclient-dev, libyubikey-dev, @@ -201,6 +202,13 @@ Description: Memcached module for FreeRADIUS server The FreeRADIUS server can cache data in memcached and this package contains the required module. +Package: freeradius-unbound +Architecture: any +Depends: freeradius (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends}, ${dist:Depends} +Description: Unbound module for FreeRADIUS server + This package is required to add libunbound DNS functionality to the + FreeRADIUS server. + Package: freeradius-yubikey Architecture: any Depends: freeradius (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends}, ${dist:Depends} diff --git a/debian/freeradius-unbound.install b/debian/freeradius-unbound.install new file mode 100644 index 00000000000..b9b88a5a891 --- /dev/null +++ b/debian/freeradius-unbound.install @@ -0,0 +1 @@ +usr/lib/freeradius/rlm_unbound.so diff --git a/debian/freeradius-unbound.lintian-overrides b/debian/freeradius-unbound.lintian-overrides new file mode 100644 index 00000000000..4d1de6e413a --- /dev/null +++ b/debian/freeradius-unbound.lintian-overrides @@ -0,0 +1,3 @@ +# There's plenty in the description of this package to identify +# what it does. +freeradius-unbound: extended-description-is-probably-too-short diff --git a/debian/freeradius-unbound.postinst b/debian/freeradius-unbound.postinst new file mode 100644 index 00000000000..091efb07a8a --- /dev/null +++ b/debian/freeradius-unbound.postinst @@ -0,0 +1,19 @@ +#! /bin/sh + +set -e + +case "$1" in + configure) + if [ -x "`which invoke-rc.d 2>/dev/null`" ]; then + invoke-rc.d freeradius force-reload || true + else + /etc/init.d/freeradius force-reload + fi + ;; +esac + +#DEBHELPER# + +exit 0 + + diff --git a/redhat/freeradius.spec b/redhat/freeradius.spec index 448481c23ff..a3a6e7882a1 100644 --- a/redhat/freeradius.spec +++ b/redhat/freeradius.spec @@ -18,6 +18,9 @@ # Build without Python %bcond_without rlm_python +# Build without unbound +%bcond_without rlm_unbound + # Many distributions have extremely old versions of OpenSSL # if you'd like to build with the FreeRADIUS openssl packages # which are installed in /opt/openssl you should pass @@ -476,6 +479,18 @@ Requires: freeradius-libfreeradius-curl = %{version} %description rest This plugin provides the ability to interact with REST APIs for the FreeRADIUS server project. +%if %{with rlm_unbound} +%package unbound +Summary: Unbound DNS support for FreeRADIUS +Group: System Environment/Daemons +Requires: %{name} = %{version}-%{release} +Requires: unbound +BuildRequires: unbound-devel + +%description unbound +This plugin provides unbound DNS support for the FreeRADIUS server project. +%endif + %if %{with rlm_lua} %package lua Summary: Lua support for FreeRADIUS @@ -636,6 +651,7 @@ export RADIUSD_VERSION_RELEASE="%{release}" %{autoconf_mod_with rlm_securid} \ %{autoconf_mod_with rlm_sigtran} \ %{autoconf_mod_with rlm_sql_oracle} \ + %{autoconf_mod_with rlm_unbound} \ %{autoconf_mod_with rlm_yubikey} \ %if %{without ldap} --without-libfreeradius-ldap \ @@ -756,9 +772,6 @@ touch $RPM_BUILD_ROOT/var/log/radius/{radutmp,radius.log} %__rm -rf $RPM_BUILD_ROOT/%{_sysconfdir}/raddb/mods-config/sql/main/oracle %__rm -rf $RPM_BUILD_ROOT/%{_sysconfdir}/raddb/mods-config/sql/driver/oracle %endif -%if %{without rlm_unbound} -%__rm -rf $RPM_BUILD_ROOT/%{_sysconfdir}/raddb/mods-config/unbound -%endif %__rm -rf $RPM_BUILD_ROOT/%{_libdir}/freeradius/rlm_test.so # remove header files, we don't ship a devel package and the @@ -1110,6 +1123,10 @@ fi %attr(640,root,radiusd) %config(noreplace) %{_sysconfdir}/raddb/mods-config/sql/driver/oracle %endif +%if %{with rlm_unbound} +%config(noreplace) %{_sysconfdir}/raddb/mods-config/unbound/default.conf +%endif + %files utils %exclude /usr/bin/*_tests %exclude /usr/bin/unit_test_* @@ -1236,6 +1253,13 @@ fi %defattr(-,root,root) %{_libdir}/freeradius/rlm_rest.so +%if %{with rlm_unbound} +%files unbound +%defattr(-,root,root) +%{_libdir}/freeradius/rlm_unbound.so +%doc %{_mandir}/man5/rlm_unbound.5.gz +%endif + %if %{with rlm_sigtran} %files sigtran %defattr(-,root,root)