package created using the webbuild interface [release 1.4.22-1mamba;Sun Apr 13 2014]

This commit is contained in:
Silvan Calarco 2024-01-05 18:48:21 +01:00
parent b3d8fee056
commit c3f713c269
2 changed files with 121 additions and 0 deletions

View File

@ -1,2 +1,4 @@
# unbound
Unbound is a validating, recursive, and caching DNS resolver.

119
unbound.spec Normal file
View File

@ -0,0 +1,119 @@
%define unbound_gid 65433
%define unbound_uid 65433
Name: unbound
Version: 1.4.22
Release: 1mamba
Summary: A validating, recursive, and caching DNS resolver
Group: Applications/Security
Vendor: openmamba
Distribution: openmamba
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: http://unbound.net/
Source: http://unbound.net/downloads/unbound-%{version}.tar.gz
License: BSD
## AUTOBUILDREQ-BEGIN
BuildRequires: glibc-devel
BuildRequires: libexpat-devel
BuildRequires: libopenssl-devel
## AUTOBUILDREQ-END
Requires: lib%{name} = %{?epoch:%epoch:}%{version}-%{release}
BuildRoot: %{_tmppath}/%{name}-%{version}-root
%description
Unbound is a validating, recursive, and caching DNS resolver.
%package -n lib%{name}
Group: System/Libraries
Summary: Shared libraries for %{name}
%description -n lib%{name}
This package contains shared libraries for %{name}.
%package -n lib%{name}-devel
Group: Development/Libraries
Summary: Development files for %{name}
Requires: lib%{name} = %{?epoch:%epoch:}%{version}-%{release}
%description -n lib%{name}-devel
This package contains libraries and header files for developing applications that use %{name}.
%debug_package
%prep
%setup -q
%build
%configure \
--with-conf-file=%{_localstatedir}/%{name}/unbound.conf \
--disable-rpath
%make
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%makeinstall
install -d 0700 %{buildroot}%{_localstatedir}/%{name}
install -D -m 0755 contrib/unbound.init %{buildroot}%{_initrddir}/unbound
# add symbolic link from /etc/unbound.conf -> /var/unbound/unbound.conf
ln -s %{_localstatedir}/unbound/unbound.conf %{buildroot}%{_sysconfdir}/unbound.conf
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%pre
if [ $1 -ge 1 ]; then
groupadd -r unbound -g %{unbound_gid} 2>/dev/null || true
useradd -r -g unbound -d /var/unbound -s /sbin/nologin \
-c "unbound name daemon" -u %{unbound_uid} unbound 2>/dev/null || true
fi
:
%post -n lib%{name} -p /sbin/ldconfig
%postun -n lib%{name} -p /sbin/ldconfig
%postun
if [ $1 -eq 0 ]; then
userdel unbound || true
groupdel unbound || true
fi
:
%files
%defattr(-,root,root)
%{_sysconfdir}/unbound.conf
%{_initrddir}/unbound
%{_sbindir}/unbound
%{_sbindir}/unbound-anchor
%{_sbindir}/unbound-checkconf
%{_sbindir}/unbound-control
%{_sbindir}/unbound-control-setup
%{_sbindir}/unbound-host
%dir %attr(0700, unbound, unbound) %{_localstatedir}/unbound
%attr(0700, unbound, unbound) %config %{_localstatedir}/unbound/unbound.conf
%{_mandir}/man1/unbound-host.1*
%{_mandir}/man5/unbound.conf.5*
%{_mandir}/man8/unbound-anchor.8*
%{_mandir}/man8/unbound-checkconf.8*
%{_mandir}/man8/unbound-control-setup.8*
%{_mandir}/man8/unbound-control.8*
%{_mandir}/man8/unbound.8*
%files -n lib%{name}
%defattr(-,root,root)
%{_libdir}/libunbound.so.*
%doc LICENSE
%files -n lib%{name}-devel
%defattr(-,root,root)
%{_includedir}/unbound.h
%{_libdir}/libunbound.a
%{_libdir}/libunbound.la
%{_libdir}/libunbound.so
%{_mandir}/man3/libunbound.3*
%{_mandir}/man3/ub_*.3*
%doc README
%changelog
* Sun Apr 13 2014 Silvan Calarco <silvan.calarco@mambasoft.it> 1.4.22-1mamba
- package created using the webbuild interface