rules 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102
  1. #!/usr/bin/make -f
  2. # Sample debian/rules that uses debhelper.
  3. # GNU copyright 1997 to 1999 by Joey Hess.
  4. # Uncomment this to turn on verbose mode.
  5. #export DH_VERBOSE=1
  6. # These are used for cross-compiling and for saving the configure script
  7. # from having to guess our platform (since we know it already)
  8. DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
  9. DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
  10. ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
  11. CFLAGS += -g
  12. endif
  13. ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
  14. INSTALL_PROGRAM += -s
  15. endif
  16. config.status: configure
  17. dh_testdir
  18. # Add here commands to configure the package.
  19. ./configure --host=$(DEB_HOST_GNU_TYPE) \
  20. --build=$(DEB_BUILD_GNU_TYPE) \
  21. --prefix=/usr \
  22. --mandir=\$${prefix}/share/man \
  23. --infodir=\$${prefix}/share/info
  24. build: build-stamp
  25. build-stamp: config.status
  26. dh_testdir
  27. # Add here commands to compile the package.
  28. $(MAKE)
  29. #/usr/bin/docbook-to-man debian/tcpreplay.sgml > tcpreplay.1
  30. touch build-stamp
  31. clean:
  32. dh_testdir
  33. dh_testroot
  34. rm -f build-stamp
  35. # Add here commands to clean up after the build process.
  36. [ ! -f Makefile ] || $(MAKE) distclean
  37. -test -r /usr/share/misc/config.sub && \
  38. cp -f /usr/share/misc/config.sub config.sub
  39. -test -r /usr/share/misc/config.guess && \
  40. cp -f /usr/share/misc/config.guess config.guess
  41. dh_clean
  42. install: build
  43. dh_testdir
  44. dh_testroot
  45. dh_clean -k
  46. dh_installdirs
  47. # Add here commands to install the package into debian/tcpreplay.
  48. $(MAKE) install prefix=$(CURDIR)/debian/tcpreplay/usr
  49. # Build architecture-independent files here.
  50. binary-indep: build install
  51. # We have nothing to do by default.
  52. # Build architecture-dependent files here.
  53. binary-arch: build install
  54. dh_testdir
  55. dh_testroot
  56. # dh_installdebconf
  57. dh_installdocs
  58. # dh_installexamples
  59. # dh_installmenu
  60. # dh_installlogrotate
  61. # dh_installemacsen
  62. # dh_installpam
  63. # dh_installmime
  64. # dh_installinit
  65. dh_installcron
  66. dh_installman
  67. # dh_installinfo
  68. # dh_undocumented
  69. dh_installchangelogs docs/CHANGELOG
  70. dh_link
  71. dh_strip
  72. dh_compress
  73. dh_fixperms
  74. # dh_makeshlibs
  75. dh_installdeb
  76. # dh_perl
  77. dh_shlibdeps
  78. dh_gencontrol
  79. dh_md5sums
  80. dh_builddeb
  81. binary: binary-indep binary-arch
  82. .PHONY: build clean binary-indep binary-arch binary install