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
|
#!/usr/bin/make -f
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
# Optional P2 optimization. Don't mess with this unless you have gcc 2.95+
# and know what it does.
#OPT=-march=i686
CXX = g++
CPPFLAGS:=$(shell dpkg-buildflags --get CPPFLAGS)
CFLAGS:=$(shell dpkg-buildflags --get CFLAGS)
CXXFLAGS:=$(shell dpkg-buildflags --get CXXFLAGS)
LDFLAGS:=$(shell dpkg-buildflags --get LDFLAGS)
ifeq ($(DEB_BUILD_GNU_TYPE), $(DEB_HOST_GNU_TYPE))
confflags += $(DEB_HOST_GNU_TYPE)
else
confflags += --host $(DEB_BUILD_GNU_TYPE) --build $(DEB_HOST_GNU_TYPE)
endif
build: build-arch build-indep
build-arch: build-stamp
dh_testdir
autoreconf -i -f
automake
./configure $(confflags) --prefix=/usr --with-pthreads
$(MAKE) CXX="$(CXX)" CXXFLAGS="$(CXXFLAGS)" LDFLAGS="$(LDFLAGS)" CPPFLAGS="$(CPPFLAGS)"
touch build-arch
build-indep: build-stamp
build-stamp:
touch build-stamp
clean:
dh_testdir
dh_testroot
rm -f build-arch build-stamp
[ ! -f Makefile ] || $(MAKE) distclean
rm -f mkinstalldirs missing install-sh INSTALL depcomp configure aclocal.m4
rm -f Makefile Makefile.in
rm -f apps/Makefile apps/Makefile.in
rm -f libs/Makefile libs/Makefile.in
dh_clean
binary-arch: build
dh_testdir
dh_testroot
dh_prep
dh_installdirs usr/bin
cp apps/splay debian/splay/usr/bin/
dh_strip
dh_installdocs AUTHORS README README.LIB
dh_installman apps/splay.1
dh_installchangelogs ChangeLog
dh_compress
dh_fixperms
dh_installdeb
dh_shlibdeps
dh_gencontrol
dh_builddeb
binary-indep: build
binary: binary-arch binary-indep
.PHONY: clean binary-indep binary-arch binary
|