2 # Made with the aid of dh_make, by Craig Small
3 # Sample debian/rules that uses debhelper. GNU copyright 1997 by Joey Hess.
4 # Some lines taken from debmake, by Christoph Lameter.
5 # $Id: rules,v 1.7 1999/03/12 22:34:34 mblevin Exp $
8 # Uncomment this to turn on verbose mode.
11 # Find the libapt-pkg major version for use in other control files
12 export LIBAPT_MAJOR
=`egrep '^MAJOR=' apt-pkg/makefile |cut -d '=' -f 2`
15 build-stamp
: configure
18 cd build
; ..
/configure
20 # cd build && CXXFLAGS="-g -Wall -D_POSIX_C_SOURCE=199309" ../configure --disable-nls --disable-static --prefix=/usr
21 # cd build && make all-hdr
24 # Add here commands to compile the package.
34 # Add here commands to clean up after the build process.
39 # Build architecture-independent files here.
40 binary-indep
: build libapt-pkg-doc
41 # We have nothing to do by default.
43 # Build architecture-dependent files here.
44 binary-arch
: build apt libapt-pkg-dev
47 # dh_testversion -papt
51 dh_installdirs
-papt usr
/bin usr
/lib
/apt
/methods usr
/lib
/dpkg
/methods
/apt etc
/apt usr
/doc
/apt var
/cache
/apt
/archives
/partial var
/state
/apt
/lists
/partial
53 cp build
/bin
/apt-
* debian
/tmp
/usr
/bin
/
55 # install the shared libs
56 find build
/bin
/ -type f
-name
"libapt-pkg.so.*" -exec cp
-a
"{}" debian
/tmp
/usr
/lib
/ \
;
57 find build
/bin
/ -type l
-name
"libapt-pkg.so.*" -exec cp
-a
"{}" debian
/tmp
/usr
/lib
/ \
;
59 cp build
/bin
/methods
/* debian
/tmp
/usr
/lib
/apt
/methods
/
61 cp build
/scripts
/dselect
/* debian
/tmp
/usr
/lib
/dpkg
/methods
/apt
/
62 # cp debian/sources.list debian/tmp/etc/apt/
64 # Copy the users guide
65 cp build
/docs
/guide.text debian
/tmp
/usr
/doc
/apt
/users-guide.txt
66 mkdir debian
/tmp
/usr
/doc
/apt
/users-guide.html
/
67 cp
-a build
/docs
/guide.html
/* debian
/tmp
/usr
/doc
/apt
/users-guide.html
/
69 # Copy the offline guide
70 cp build
/docs
/offline.text debian
/tmp
/usr
/doc
/apt
/offline.txt
71 mkdir debian
/tmp
/usr
/doc
/apt
/offline.html
/
72 cp
-a build
/docs
/offline.html
/* debian
/tmp
/usr
/doc
/apt
/offline.html
/
74 cp
-a debian
/dhelp debian
/tmp
/usr
/doc
/apt
/.dhelp
76 # head -n 500 ChangeLog > debian/ChangeLog
79 dh_installexamples
-papt build
/docs
/examples
/*
80 # dh_installmenu -papt
81 # dh_installinit -papt
82 # dh_installcron -papt
83 dh_installmanpages
-papt
85 # dh_undocumented -papt
86 dh_installchangelogs
-papt
92 LD_LIBRARY_PATH
=debian
/tmp
/usr
/lib dh_shlibdeps
-papt
93 echo libapt-pkg
:major
=${LIBAPT_MAJOR} >> debian
/substvars
95 dh_makeshlibs
-m
${LIBAPT_MAJOR} -Vlibapt-pkg
${LIBAPT_MAJOR} -papt
100 dh_testdir
-plibapt-pkg-dev
101 dh_testroot
-plibapt-pkg-dev
102 dh_clean
-plibapt-pkg-dev
-k
103 dh_installdirs
-plibapt-pkg-dev usr
/lib usr
/include/apt-pkg
105 ln
-s libapt-pkg.so.
${LIBAPT_MAJOR} debian
/libapt-pkg-dev
/usr
/lib
/libapt-pkg.so
107 cp build
/include/apt-pkg
/*.h debian
/libapt-pkg-dev
/usr
/include/apt-pkg
/
109 dh_installdocs
-plibapt-pkg-dev
110 dh_installchangelogs
-plibapt-pkg-dev
111 dh_strip
-plibapt-pkg-dev
112 dh_compress
-plibapt-pkg-dev
113 dh_fixperms
-plibapt-pkg-dev
114 dh_installdeb
-plibapt-pkg-dev
115 dh_shlibdeps
-plibapt-pkg-dev
116 dh_gencontrol
-plibapt-pkg-dev
117 dh_md5sums
-plibapt-pkg-dev
118 dh_builddeb
-plibapt-pkg-dev
120 libapt-pkg-doc
: build
121 dh_testdir
-plibapt-pkg-doc
122 dh_testroot
-plibapt-pkg-doc
123 dh_clean
-plibapt-pkg-doc
-k
124 dh_installdirs
-plibapt-pkg-doc usr
/doc
/apt usr
/doc
/libapt-pkg-doc
126 cp
-a build
/docs
/cache
* build
/docs
/design
* build
/docs
/dpkg-tech
* \
127 build
/docs
/files
* build
/docs
/method
* debian
/libapt-pkg-doc
/usr
/doc
/apt
/
128 cp
-a debian
/libapt-pkg-doc.dhelp debian
/libapt-pkg-doc
/usr
/doc
/libapt-pkg-doc
/.dhelp
130 dh_installdocs
-plibapt-pkg-doc
131 dh_installchangelogs
-plibapt-pkg-doc
132 dh_strip
-plibapt-pkg-doc
133 dh_compress
-plibapt-pkg-doc
134 dh_fixperms
-plibapt-pkg-doc
135 dh_installdeb
-plibapt-pkg-doc
136 dh_shlibdeps
-plibapt-pkg-doc
137 dh_gencontrol
-plibapt-pkg-doc
138 dh_md5sums
-plibapt-pkg-doc
139 dh_builddeb
-plibapt-pkg-doc
142 @echo
>&2 'source and diff are obsolete - use dpkg-source -b'; false
149 # Update from CVS and then configure for build
150 super-l33ch
: l33ch Makefile.in
155 l33ch-stamp
: super-l33ch
159 -find
-name Makefile.in
-print0 | xargs
-0r
rm -f
160 find
-name ChangeLog | xargs
rm -f
163 binary
: binary-indep binary-arch
164 .PHONY
: build
clean binary-indep binary-arch binary