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 Cristoph Lameter.
6 # Uncomment this to turn on verbose mode.
9 # These are used for cross-compiling and for saving the configure script
10 # from having to guess our platform (since we know it already)
11 DEB_HOST_GNU_TYPE ?
= $(shell dpkg-architecture
-qDEB_HOST_GNU_TYPE
)
12 DEB_BUILD_GNU_TYPE ?
= $(shell dpkg-architecture
-qDEB_BUILD_GNU_TYPE
)
14 TARGET_DIR
= $(CURDIR
)/debian
/adacurses
15 SAMPLE_DIR
= $(TARGET_DIR
)/usr
/bin
/AdaCurses
19 ifneq (,$(findstring noopt
,$(DEB_BUILD_OPTIONS
)))
24 ifeq (,$(findstring nostrip
,$(DEB_BUILD_OPTIONS
)))
29 configure
: configure-stamp
33 CFLAGS
="$(CFLAGS)" .
/configure \
34 --host
=$(DEB_HOST_GNU_TYPE
) \
35 --build
=$(DEB_BUILD_GNU_TYPE
) \
37 --disable-rpath-link \
39 --with-ada-sharedlib \
45 build-stamp
: configure-stamp
56 [ ! -f makefile
] ||
$(MAKE
) distclean
58 rm -f configure-stamp build-stamp install-stamp
62 install: install-stamp
63 install-stamp
: build-stamp
69 $(MAKE
) install DESTDIR
=$(TARGET_DIR
)
71 # FIXME: it would be nice to make these into separate packages
72 ( cd samples
&& $(MAKE
) install.examples DESTDIR
=$(TARGET_DIR
) BINDIR
=$(SAMPLE_DIR
) )
73 ( cd doc
&& $(MAKE
) install.html DESTDIR
=$(TARGET_DIR
) )
77 # Build architecture-independent files here.
78 binary-indep
: build
install
79 # No binary-indep target.
81 # Build architecture-dependent files here.
82 binary-arch
: build
install
87 dh_installchangelogs NEWS
98 binary
: binary-indep binary-arch
99 .PHONY
: build
clean binary-indep binary-arch binary
install install-stamp