diff options
| author | andersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2000-06-19 09:21:34 +0000 |
|---|---|---|
| committer | andersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2000-06-19 09:21:34 +0000 |
| commit | e986a42e0cf4a23f0c7e22673432ca4ced000ca4 (patch) | |
| tree | a4fd9464af4329277055e0b2cab83b8057b84ade /debian/rules | |
| parent | 24f4443efa2909f1f68801758979a0c2b7172566 (diff) | |
| download | busybox-w32-e986a42e0cf4a23f0c7e22673432ca4ced000ca4.tar.gz busybox-w32-e986a42e0cf4a23f0c7e22673432ca4ced000ca4.tar.bz2 busybox-w32-e986a42e0cf4a23f0c7e22673432ca4ced000ca4.zip | |
Added support for building debian packages.
-Erik
git-svn-id: svn://busybox.net/trunk/busybox@657 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'debian/rules')
| -rwxr-xr-x | debian/rules | 119 |
1 files changed, 119 insertions, 0 deletions
diff --git a/debian/rules b/debian/rules new file mode 100755 index 000000000..163f1d0d4 --- /dev/null +++ b/debian/rules | |||
| @@ -0,0 +1,119 @@ | |||
| 1 | #!/usr/bin/make -f | ||
| 2 | |||
| 3 | # This is a bit unusual, in that I have to completely recompile everything | ||
| 4 | # twice. The first is the normal, dynamically linked package. The second is | ||
| 5 | # for the statically linked package. This file has been adjusted accordingly. | ||
| 6 | |||
| 7 | # This is the debhelper compatability version to use. | ||
| 8 | export DH_COMPAT=1 | ||
| 9 | |||
| 10 | bb=debian/tmp | ||
| 11 | bbs=debian/busybox-static | ||
| 12 | |||
| 13 | clean: | ||
| 14 | dh_testdir | ||
| 15 | dh_testroot | ||
| 16 | rm -f build-stamp-busybox build-stamp-busybox-static | ||
| 17 | -$(MAKE) clean | ||
| 18 | -rm -rf $(bb) $(bbs) | ||
| 19 | dh_clean | ||
| 20 | |||
| 21 | half_clean: | ||
| 22 | dh_testdir | ||
| 23 | dh_testroot | ||
| 24 | rm -rf $(bbs) build-stamp-busybox-static | ||
| 25 | -$(MAKE) clean | ||
| 26 | |||
| 27 | build: build-stamp-busybox | ||
| 28 | build-stamp-busybox: | ||
| 29 | dh_testdir | ||
| 30 | $(MAKE) | ||
| 31 | touch build-stamp-busybox | ||
| 32 | |||
| 33 | install: build | ||
| 34 | dh_testdir | ||
| 35 | dh_testroot | ||
| 36 | dh_clean -k | ||
| 37 | dh_installdirs | ||
| 38 | $(MAKE) "PREFIX=$(bb)" install | ||
| 39 | mkdir -p $(bb)/usr/share/man/man1 | ||
| 40 | cp docs/BusyBox.1 $(bb)/usr/share/man/man1/busybox.1 | ||
| 41 | |||
| 42 | # Now for the statically linked stuff | ||
| 43 | build-static: build-stamp-busybox-static | ||
| 44 | build-stamp-busybox-static: | ||
| 45 | dh_testdir | ||
| 46 | $(MAKE) DOSTATIC=true | ||
| 47 | touch build-stamp-busybox-static | ||
| 48 | |||
| 49 | install-static: build | ||
| 50 | dh_testdir | ||
| 51 | dh_testroot | ||
| 52 | dh_clean -k | ||
| 53 | dh_installdirs | ||
| 54 | # Do not run 'make install', since we do not want all the symlinks. | ||
| 55 | # This just installes the busybox binary... | ||
| 56 | #$(MAKE) "PREFIX=$(bbs)" install | ||
| 57 | mkdir -p $(bbs)/bin/ | ||
| 58 | cp busybox $(bbs)/bin/busybox | ||
| 59 | mkdir -p $(bbs)/usr/share/man/man1/ | ||
| 60 | cp docs/BusyBox.1 $(bbs)/usr/share/man/man1/busybox.1 | ||
| 61 | |||
| 62 | do_static: half_clean build-static install-static | ||
| 63 | |||
| 64 | |||
| 65 | # Build architecture-independent files here. | ||
| 66 | binary-indep: | ||
| 67 | # We have nothing to do by default. | ||
| 68 | |||
| 69 | # Build architecture-dependent files here. | ||
| 70 | binary-arch: busybox busybox-static clean | ||
| 71 | |||
| 72 | busybox: install | ||
| 73 | @echo "--- Building: $@" | ||
| 74 | dh_testdir | ||
| 75 | dh_testroot | ||
| 76 | dh_installdirs | ||
| 77 | dh_installdocs -p$@ docs/BusyBox.txt \ | ||
| 78 | docs/BusyBox.html docs/busybox.lineo.com AUTHORS README TODO | ||
| 79 | rm -rf $(bb)/usr/share/doc/busybox/busybox.lineo.com/CVS \ | ||
| 80 | $(bb)/usr/share/doc/busybox/busybox.lineo.com/.cvsignore \ | ||
| 81 | $(bb)/usr/share/doc/busybox/busybox.lineo.com/images/CVS \ | ||
| 82 | $(bb)/usr/share/doc/busybox/busybox.lineo.com/images/.cvsignore | ||
| 83 | #dh_undocumented -p$@ | ||
| 84 | dh_installchangelogs -p$@ Changelog | ||
| 85 | dh_strip -p$@ | ||
| 86 | dh_compress -p$@ | ||
| 87 | dh_fixperms -p$@ | ||
| 88 | dh_installdeb -p$@ | ||
| 89 | dh_shlibdeps -p$@ | ||
| 90 | dh_gencontrol -p$@ | ||
| 91 | dh_md5sums -p$@ | ||
| 92 | dh_builddeb -p$@ | ||
| 93 | |||
| 94 | |||
| 95 | busybox-static: do_static | ||
| 96 | @echo "--- Building: $@" | ||
| 97 | dh_testdir | ||
| 98 | dh_testroot | ||
| 99 | dh_installdirs | ||
| 100 | dh_installdocs -p$@ docs/BusyBox.txt \ | ||
| 101 | docs/BusyBox.html docs/busybox.lineo.com AUTHORS README TODO | ||
| 102 | rm -rf $(bbs)/usr/share/doc/busybox-static/busybox.lineo.com/CVS \ | ||
| 103 | $(bbs)/usr/share/doc/busybox-static/busybox.lineo.com/.cvsignore \ | ||
| 104 | $(bbs)/usr/share/doc/busybox-static/busybox.lineo.com/images/CVS \ | ||
| 105 | $(bbs)/usr/share/doc/busybox-static/busybox.lineo.com/images/.cvsignore | ||
| 106 | dh_undocumented -p$@ | ||
| 107 | dh_installchangelogs -p$@ Changelog | ||
| 108 | dh_strip -p$@ | ||
| 109 | dh_compress -p$@ | ||
| 110 | dh_fixperms -p$@ | ||
| 111 | dh_installdeb -p$@ | ||
| 112 | dh_shlibdeps -p$@ | ||
| 113 | dh_gencontrol -p$@ | ||
| 114 | dh_md5sums -p$@ | ||
| 115 | dh_builddeb -p$@ | ||
| 116 | |||
| 117 | |||
| 118 | binary: binary-indep binary-arch | ||
| 119 | .PHONY: build clean binary-indep binary-arch binary install | ||
