1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196
|
# $Id: /trunk/debian/dists/libnss-db/debian/packages 8 2005-12-19T10:45:54.723393Z dexter $
# If the debian/rules or debian/control file is missing, rebuild the file:
#
# $ yada rebuild control
# $ yada rebuild rules
%define autoconf_version
%define automake_version 1.9
%define libdb_version 4.3
%define backup_files \
ABOUT-NLS Makefile.am Makefile.in acconfig.h aclocal.m4 config.guess \
config.h.in config.sub configure configure.in ltmain.sh mkinstalldirs \
src/Makefile.in
%define clean_files \
Makefile.in~ VAR_DB autom4te.cache configure.in~ depcomp \
libnss-db.default libnss-db.default.new depconf makedb.1 \
m4/Makefile.in po/pl.gmo po/Makevars src/db-compat-copy-makedb.c
# Other macros:
# autoconf_version=%{autoconf_version}
# automake_version=%{automake_version}
# libdb_version=%{libdb_version}
# backup_files=%{backup_files}
# clean_files=%{clean_files}
Source: libnss-db
Section: admin
Priority: standard
Maintainer: Piotr Roszatycki <dexter@debian.org>
Standards-Version: 3.6.2
Upstream-Source: <URL:ftp://sources.redhat.com/pub/glibc/releases/nss_db-(.*)\.tar.gz>
Home-Page: <URL:http://www.gnu.org/software/libc/>
Description: NSS module for using Berkeley Databases as a naming service
Copyright: GPL
Copyright (C) 2000, 2001 Free Software Foundation, Inc.
# autoconf-stamp
Build-Depends: autoconf%{autoconf_version}, automake%{automake_version}
# libtoolize
Build-Depends: libtool
# gettextize
Build-Depends: gettext
# IPC::Run (gettextize does not allow to run in batch)
Build-Depends: libipc-run-perl
# pod2man
Build-Depends: perl
# Berkeley DB library
Build-Depends: libdb%{libdb_version}-dev
# --with-selinux
Build-Depends: libselinux1-dev [!hurd-i386 !kfreebsd-i386]
Patches: patches/*.patch
Major-Changes:
%`cd debian/patches; ls *.patch | sed -e 's/^/ /'`
Build: bash
CC=${CC:-gcc}
CFLAGS=${CFLAGS:--Wall -pedantic -g}
if [ "${DEB_BUILD_OPTIONS#*noopt}" != "$DEB_BUILD_OPTIONS" ]; then
CFLAGS="$CFLAGS -O0"
else
CFLAGS="$CFLAGS -O2"
fi
if [ "$DEB_HOST_GNU_SYSTEM" = "linux" ]; then
WITH_SELINUX="--with-selinux"
fi
.
CPP=`$CC -print-prog-name=cpp || true`
CPP=${CPP:-cpp}
.
VAR_DB=`echo | $CPP -include paths.h -dD | awk '$1 == "#define" && $2 == "_PATH_VARDB" { print $3 }' | tr -d '"' || true`
VAR_DB=${VAR_DB%/}
VAR_DB=${VAR_DB:-/var/db}
.
echo $VAR_DB > VAR_DB
.
if ! [ -f backup-stamp ]; then
for f in %{backup_files}; do
if ! [ -e $f.bak ]; then
cp -a $f $f.bak
fi
done
sleep 1 && touch backup-stamp
fi
.
if ! [ gettextize-stamp -nt backup-stamp ]; then
perl -MIPC::Run=start,pump -e '
@rs = qw(gettextize --force --copy --no-changelog --intl);
$h=start \@rs, \$in, \$out;
until ($out =~ /Press Return to acknowledge/) { pump $h; print "\r$out"; flush STDOUT; }'
rm -f *~ intl/*~ m4/*.in
sleep 1 && touch gettextize-stamp
fi
.
if ! [ autoconf-stamp -nt gettextize-stamp ]; then
rm -f acconfig.h aclocal.m4 config.h.in configure ltmain.sh
cp po/Makevars.template po/Makevars
perl -MIPC::Run=start -e '
@rs = qw(gettextize --force --copy --no-changelog --intl);
$h=start \@rs, \$in, \$out;
until ($out =~ /Press Return to acknowledge/) { $h->pump; print "\r$out"; flush STDOUT; }
$h->kill_kill;'
rm -f *~ intl/*~ m4/*.in
libtoolize --force --copy
aclocal-%{automake_version} -I m4
autoheader
automake-%{automake_version} --add-missing --copy
autoconf
sleep 1 && touch autoconf-stamp
fi
.
if ! [ configure-stamp -nt autoconf-stamp ]; then
test -d build || mkdir build
pushd build
CC="$CC" CFLAGS="$CFLAGS"
../configure \
--prefix=/usr \
$WITH_SELINUX
popd
sleep 1 && touch configure-stamp
fi
.
if ! [ build-stamp -nt configure-stamp ]; then
pushd build
make
if ! [ makedb.1 -nt debian/man/makedb.pod ]; then
pod2man --center="Debian GNU/Linux" --release="Debian" ../debian/man/makedb.pod makedb.1
fi
if ! [ libnss-db.default -nt debian/conf/default ]; then
sed 's|@VAR_DB@|'"$VAR_DB"'|g' ../debian/conf/default > libnss-db.default.new
mv -f libnss-db.default.new libnss-db.default
fi
popd
sleep 1 && touch build-stamp
fi
Clean: sh
rm -rf build || true
for f in %{backup_files}; do
test -e $f.bak && test -e $f && rm -rf $f
test -e $f.bak && mv -f $f.bak $f
done
rm -f *-stamp || true
rm -rf %{clean_files} || true
Package: libnss-db
Architecture: any
Depends: make, []
Description: NSS module for using Berkeley Databases as a naming service
nss_db is a set of C library extensions which allow Berkeley Databases
to be used as a primary source of aliases, ethers, groups, hosts,
networks, protocol, users, RPCs, services, and shadow passwords (instead
of or in addition to using flat files or NIS). Install nss_db if your
flat name service files are too large and lookups are slow.
Install: sh
VAR_DB=$(cat VAR_DB)
pushd build
make install DESTDIR=$ROOT slibdir=/usr/lib
chmod -x $ROOT/usr/lib/*.so
yada install -conf -as libnss-db -into /etc/default libnss-db.default
yada install -man makedb.1
popd
yada install -data -as Makefile -into $VAR_DB debian/scripts/db-Makefile
yada install -doc -as changelog ChangeLog
yada install -doc NEWS README
Postinst: sh
if [ "$1" = "configure" ]; then
if [ -n "$2" ]; then
if dpkg --compare-versions $2 lt 2.1.1-12 && \
dpkg --compare-versions $2 gt 2.1.1-0pre1.3
then
if [ -f /var/db/passwd.db ]; then
mv /var/db /var/db.old
ln -sf /var/lib/misc /var/db
cp -a /var/db.old/*.db /var/lib/misc/.
rm -rf /var/db.old
elif [ -f /var/state/glibc/passwd.db ]; then
mv /var/state/glibc /var/state/glibc.old
ln -sf /var/lib/misc /var/state/glibc
cp -a /var/state/glibc.old/*.db /var/lib/misc/.
rm -rf /var/state/glibc.old
fi
fi
fi
if [ -x /etc/init.d/nscd ]; then
if [ -x /usr/sbin/invoke-rc.d ]; then
invoke-rc.d nscd restart
else
/etc/init.d/nscd restart
fi
fi
fi
Contains: libs
Overrides:
non-dev-pkg-with-shlib-symlink usr/lib/libnss_db-2.2.3.so usr/lib/libnss_db.so
no-shlibs-control-file usr/lib/libnss_db-2.2.3.so
|