|
|
@@ -35,23 +35,25 @@ Packager: The OpenPKG Project
|
|
|
Distribution: OpenPKG [EVAL]
|
|
|
Group: DNS
|
|
|
License: GPL
|
|
|
-Version: 1.0.2
|
|
|
-Release: 20030413
|
|
|
+Version: 1.1.0b
|
|
|
+Release: 20030416
|
|
|
+
|
|
|
+# package option
|
|
|
+%option with_fsl yes
|
|
|
|
|
|
# list of sources
|
|
|
Source0: http://www.nlnetlabs.nl/downloads/nsd/nsd-%{version}.tar.gz
|
|
|
Source1: rc.nsd
|
|
|
Source2: nsd.zones
|
|
|
-Source3: nsdc.conf
|
|
|
+Source3: nsd.conf
|
|
|
Source4: example.com
|
|
|
Source5: fsl.nsd
|
|
|
-Patch0: nsd.patch
|
|
|
|
|
|
# build information
|
|
|
Prefix: %{l_prefix}
|
|
|
BuildRoot: %{l_buildroot}
|
|
|
-BuildPreReq: OpenPKG, openpkg >= 20030103, fsl, make
|
|
|
-PreReq: OpenPKG, openpkg >= 20030103, fsl
|
|
|
+BuildPreReq: OpenPKG, openpkg >= 20030415, fsl, make
|
|
|
+PreReq: OpenPKG, openpkg >= 20030415, fsl
|
|
|
AutoReq: no
|
|
|
AutoReqProv: no
|
|
|
|
|
|
@@ -64,23 +66,29 @@ AutoReqProv: no
|
|
|
|
|
|
%prep
|
|
|
%setup -q
|
|
|
- %patch -p0
|
|
|
|
|
|
%build
|
|
|
+ # configure programs
|
|
|
+ CC="%{l_cc}" \
|
|
|
+ CFLAGS="%{l_cflags -O}" \
|
|
|
+ LDFLAGS="%{l_ldflags}" \
|
|
|
+ ./configure \
|
|
|
+ --prefix=%{l_prefix} \
|
|
|
+ --with-configdir=%{l_prefix}/etc/nsd \
|
|
|
+ --with-configfile=%{l_prefix}/etc/nsd/nsd.conf \
|
|
|
+ --with-pidfile=%{l_prefix}/var/nsd/nsd.pid \
|
|
|
+ --with-zonesdir=%{l_prefix}/etc/nsd \
|
|
|
+ --with-zonesfile=%{l_prefix}/etc/nsd/nsd.zones \
|
|
|
+ --with-dbfile=%{l_prefix}/var/nsd/nsd.db \
|
|
|
+ --with-user="%{l_ruid}.%{l_rgid}" \
|
|
|
+ --with-namedxfer=%{l_prefix}/libexec/bind/named-xfer \
|
|
|
+ --with-libwrap="%{l_fsl_ldflags} %{l_fsl_libs}" \
|
|
|
+ --enable-bind8-stats \
|
|
|
+ --disable-shared \
|
|
|
+ --disable-nls
|
|
|
+
|
|
|
# build programs
|
|
|
- %{l_make} %{l_mflags -O} \
|
|
|
- CC="%{l_cc}" \
|
|
|
- CFLAGS="%{l_cflags -O}" \
|
|
|
- NSDUSER="%{l_ruid}.%{l_rgid}" \
|
|
|
- NAMEDXFER="%{l_prefix}/libexec/bind/named-xfer" \
|
|
|
- NSDKEYSDIR="%{l_prefix}/etc/nsd/keys" \
|
|
|
- PREFIX="%{l_prefix}" \
|
|
|
- NSDZONESDIR="%{l_prefix}/etc/nsd" \
|
|
|
- NSDZONES="%{l_prefix}/etc/nsd/nsd.zones" \
|
|
|
- NSDDB="%{l_prefix}/var/nsd/nsd.db" \
|
|
|
- NSDPIDFILE="%{l_prefix}/var/nsd/nsd.pid" \
|
|
|
- FEATURES="-DLOG_NOTIFIES -DBIND8_STATS" \
|
|
|
- LIBWRAP="`%{l_prefix}/bin/fsl-config --all --ldflags --libs`"
|
|
|
+ %{l_make} %{l_mflags -O}
|
|
|
|
|
|
%install
|
|
|
rm -rf $RPM_BUILD_ROOT
|
|
|
@@ -96,17 +104,25 @@ AutoReqProv: no
|
|
|
|
|
|
# perform default installation procedure
|
|
|
%{l_make} %{l_mflags} install \
|
|
|
- PREFIX="$RPM_BUILD_ROOT%{l_prefix}" \
|
|
|
- NSDZONESDIR="$RPM_BUILD_ROOT%{l_prefix}/etc/nsd" \
|
|
|
- NSDZONES="$RPM_BUILD_ROOT%{l_prefix}/etc/nsd/nsd.zones" \
|
|
|
- NSDDB="$RPM_BUILD_ROOT%{l_prefix}/var/nsd/nsd.db" \
|
|
|
- NSDPIDFILE="$RPM_BUILD_ROOT%{l_prefix}/var/nsd/nsd.pid" \
|
|
|
- INSTALL="%{l_shtool} install -c"
|
|
|
+ prefix=$RPM_BUILD_ROOT%{l_prefix} \
|
|
|
+ exec_prefix=$RPM_BUILD_ROOT%{l_prefix} \
|
|
|
+ configdir=$RPM_BUILD_ROOT%{l_prefix}/etc/nsd \
|
|
|
+ configfile=$RPM_BUILD_ROOT%{l_prefix}/etc/nsd/nsd.conf \
|
|
|
+ pidfile=$RPM_BUILD_ROOT%{l_prefix}/var/nsd/nsd.pid \
|
|
|
+ zonesdir=$RPM_BUILD_ROOT%{l_prefix}/etc/nsd \
|
|
|
+ zonesfile=$RPM_BUILD_ROOT%{l_prefix}/etc/nsd/nsd.zones \
|
|
|
+ dbfile=$RPM_BUILD_ROOT%{l_prefix}/var/nsd/nsd.db
|
|
|
+
|
|
|
+ # post-adjustments
|
|
|
+ rm -f $RPM_BUILD_ROOT%{l_prefix}/etc/nsd/nsd.zones.sample
|
|
|
+ rm -f $RPM_BUILD_ROOT%{l_prefix}/etc/nsd/nsd.conf.sample
|
|
|
|
|
|
# install default configuration
|
|
|
%{l_shtool} install -c -m 644 \
|
|
|
- %{SOURCE nsdc.conf} $RPM_BUILD_ROOT%{l_prefix}/etc/nsd/
|
|
|
+ -e 's;@l_prefix@;%{l_prefix};g' \
|
|
|
+ %{SOURCE nsd.conf} $RPM_BUILD_ROOT%{l_prefix}/etc/nsd/
|
|
|
%{l_shtool} install -c -m 644 \
|
|
|
+ -e 's;@l_prefix@;%{l_prefix};g' \
|
|
|
%{SOURCE nsd.zones} $RPM_BUILD_ROOT%{l_prefix}/etc/nsd/
|
|
|
%{l_shtool} install -c -m 644 \
|
|
|
%{SOURCE example.com} $RPM_BUILD_ROOT%{l_prefix}/etc/nsd/nsd.db/
|
|
|
@@ -128,6 +144,7 @@ AutoReqProv: no
|
|
|
# determine installation files
|
|
|
%{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
|
|
|
%{l_files_std} \
|
|
|
+ '%config %{l_prefix}/etc/nsd/*' \
|
|
|
'%not %dir %{l_prefix}/etc/rc.d' \
|
|
|
'%not %dir %{l_prefix}/etc/fsl' \
|
|
|
'%attr(755,%{l_rusr},%{l_rgrp}) %{l_prefix}/var/nsd'
|