"Fossies" - the Fresh Open Source Software Archive

Member "rgdbm-2.1.42/debian/rules.in" (26 Jun 2007, 5803 Bytes) of package /linux/privat/old/rgdbm-2.1.42.tgz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Make source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 #!/usr/bin/make -f
    2 # debian/rules file - for RGDBM (@PACKAGE_VERSION@).
    3 #
    4 # Based on debian/rules file for GNU GDBM (1.8.3).
    5 # Inherited copyrights:
    6 #
    7 #   Copyright 1994,1995 by Ian Jackson.
    8 #   Copyright 1998-2006 by James Troup.
    9 #
   10 # This file copyright:
   11 #   Copyright 2007 (rgdbm) by Peter Breuer.
   12 #
   13 # Inherited copyright notice:
   14 #   I hereby give you perpetual unlimited permission to copy,
   15 #   modify and relicense this file, provided that you do not remove
   16 #   my name from the file itself.  (I assert my moral right of
   17 #   paternity under the Copyright, Designs and Patents Act 1988.)
   18 #   This file may have to be extensively modified
   19 #
   20 # This file copyright notice:
   21 #   Ditto and Amen.
   22 
   23 DEB_BUILD_GNU_TYPE  := $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
   24 DEB_HOST_GNU_TYPE   := $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
   25 
   26 STRIP=strip --remove-section=.comment --remove-section=.note
   27 
   28 install_dir=install -d -m 755
   29 install_file=install -m 644
   30 install_script=install -m 755
   31 install_binary=install -m 755 -s
   32 compress=gzip -9v
   33 
   34 build:
   35     $(checkdir)
   36 ifeq ($(DEB_BUILD_GNU_TYPE),$(DEB_HOST_GNU_TYPE))
   37     CFLAGS="-O2 -g -Wall -D_REENTRANT" ./configure \
   38     --prefix=/usr \
   39     --localstatedir=/var \
   40     --mandir=/usr/share/man
   41 else
   42     CFLAGS="-O2 -g -Wall -D_REENTRANT" ./configure \
   43     --prefix=/usr \
   44     --host=$(DEB_HOST_GNU_TYPE) \
   45     --localstatedir=/var \
   46     --mandir=/usr/share/man
   47 endif
   48     $(MAKE)
   49     touch build
   50 
   51 binary-indep:   checkroot build
   52     $(checkdir)
   53 
   54 binary-arch: binary-librgdbm binary-librgdbm-dev binary-rgdbm-server
   55 
   56 binary-librgdbm: checkroot build
   57     $(checkdir)
   58     rm -rf debian/tmp/
   59     
   60     $(MAKE) INSTALL_ROOT=$$(pwd)/debian/tmp \
   61             prefix=/usr \
   62             library library_install
   63     rm -fr debian/tmp/usr/include debian/tmp/usr/info \
   64            debian/tmp/usr/man debian/tmp/usr/lib/*.a \
   65                 debian/tmp/usr/lib/*.la \
   66            debian/tmp/usr/lib/*.so
   67     $(STRIP) --strip-unneeded debian/tmp/usr/lib/*.so*
   68     chmod 644 debian/tmp/usr/lib/*.so*
   69     
   70     $(install_dir) debian/tmp/DEBIAN
   71     $(install_file) debian/shlibs debian/tmp/DEBIAN/
   72     $(install_script) debian/postinst debian/postrm debian/tmp/DEBIAN/
   73     
   74     $(install_dir) debian/tmp/usr/share/doc/librgdbm/
   75     $(install_file) debian/changelog debian/tmp/usr/share/doc/librgdbm/changelog.Debian
   76     $(install_file) README debian/tmp/usr/share/doc/librgdbm/README
   77     $(compress) debian/tmp/usr/share/doc/librgdbm/*
   78     $(install_file) debian/copyright debian/tmp/usr/share/doc/librgdbm/copyright
   79     
   80     dpkg-shlibdeps debian/tmp/usr/lib/librgdbm.so.@PACKAGE_VERSION@
   81     dpkg-gencontrol -isp -plibrgdbm
   82     chown -R root.root debian/tmp/
   83     chmod -R go=rX debian/tmp/
   84     dpkg --build debian/tmp/ ..
   85 
   86 binary-librgdbm-dev: checkroot build
   87     $(checkdir)
   88     rm -fr debian/tmp/
   89     
   90     $(MAKE) INSTALL_ROOT=$$(pwd)/debian/tmp \
   91             prefix=/usr \
   92                 devel devel_install
   93     
   94     $(compress) debian/tmp/usr/share/man/man3/*
   95     cd debian/tmp/usr/share/man/man3 ; \
   96         for i in rgdbm_error rgdbm_errno rgdbm_open \
   97             rgdbm_close rgdbm_store rgdbm_fetch rgdbm_delete \
   98             rgdbm_firstkey rgdbm_nextkey rgdbm_reorganize \
   99             rgdbm_sync rgdbm_exists rgdbm_strerror \
  100             rgdbm_setopt rgdbm_connect rgdbm_disconnect ; do \
  101         ln -s rgdbm.3.gz $$i.3.gz ; \
  102         done
  103     
  104     $(install_dir) debian/tmp/DEBIAN/
  105     
  106     $(install_dir) debian/tmp/usr/share/doc/librgdbm-dev/
  107     $(install_file) debian/changelog \
  108             debian/tmp/usr/share/doc/librgdbm-dev/changelog.Debian
  109     $(install_file) README debian/tmp/usr/share/doc/librgdbm-dev/
  110     $(compress) debian/tmp/usr/share/doc/librgdbm-dev/*
  111     $(install_file) debian/copyright \
  112             debian/tmp/usr/share/doc/librgdbm-dev/copyright
  113     
  114     dpkg-gencontrol -isp -plibrgdbm-dev
  115     chown -R root.root debian/tmp/
  116     chmod -R go=rX debian/tmp/
  117     dpkg --build debian/tmp/ ..
  118 
  119 binary-rgdbm-server: checkroot build
  120     $(checkdir)
  121     rm -fr debian/tmp/
  122     
  123     $(MAKE) INSTALL_ROOT=$$(pwd)/debian/tmp \
  124             prefix=/usr \
  125                 server server_install
  126     
  127     $(compress) debian/tmp/usr/share/man/man8/*
  128     
  129     $(install_dir) debian/tmp/DEBIAN/
  130     $(install_script) debian/postinst.server debian/tmp/DEBIAN/postinst
  131     $(install_script) debian/prerm.server debian/tmp/DEBIAN/prerm
  132     
  133     $(install_dir) debian/tmp/usr/share/doc/rgdbm-server/
  134     $(install_file) debian/changelog \
  135             debian/tmp/usr/share/doc/rgdbm-server/changelog.Debian
  136     $(install_file) README debian/tmp/usr/share/doc/rgdbm-server/
  137     $(compress) debian/tmp/usr/share/doc/rgdbm-server/*
  138     $(install_file) debian/copyright \
  139             debian/tmp/usr/share/doc/rgdbm-server/copyright
  140     $(install_dir) debian/tmp/etc/init.d/
  141     $(install_file) debian/init.server debian/tmp/etc/init.d/gdbmd
  142     chmod +x debian/tmp/etc/init.d/gdbmd
  143     
  144     dpkg-gencontrol -isp -prgdbm-server
  145     chown -R root.root debian/tmp/
  146     chmod -R go=rX debian/tmp/
  147     dpkg --build debian/tmp/ ..
  148 
  149 binary-rgdbm-contrib: checkroot build
  150     $(checkdir)
  151     rm -fr debian/tmp/
  152     
  153     $(MAKE) INSTALL_ROOT=$$(pwd)/debian/tmp \
  154             prefix=/usr \
  155                 contrib contrib_install
  156     
  157     $(compress) debian/tmp/usr/share/man/man1/*
  158     
  159     $(install_dir) debian/tmp/DEBIAN/
  160     
  161     $(install_dir) debian/tmp/usr/share/doc/rgdbm-contrib/
  162     $(install_file) debian/changelog \
  163             debian/tmp/usr/share/doc/rgdbm-contrib/changelog.Debian
  164     $(install_file) README debian/tmp/usr/share/doc/rgdbm-contrib/
  165     $(compress) debian/tmp/usr/share/doc/rgdbm-contrib/*
  166     $(install_file) debian/copyright \
  167             debian/tmp/usr/share/doc/rgdbm-contrib/copyright
  168     
  169     dpkg-gencontrol -isp -prgdbm-contrib
  170     chown -R root.root debian/tmp/
  171     chmod -R go=rX debian/tmp/
  172     dpkg --build debian/tmp/ ..
  173 
  174 
  175 
  176 define checkdir
  177     test -f rgdbm.c -a -f debian/rules
  178 endef
  179 
  180 # Below here is fairly generic really
  181 
  182 binary:     binary-indep binary-arch
  183 
  184 source diff:
  185     @echo >&2 'source and diff are obsolete - use dpkg-source -b'; false
  186 
  187 checkroot:
  188     $(checkdir)
  189     test root = "`whoami`"
  190 
  191 .PHONY: binary binary-arch binary-indep clean checkroot