2009-08-29 23:09:22 +00:00
|
|
|
#!/usr/bin/make -f
|
|
|
|
#
|
|
|
|
# Ubuntu/Debian build rules file for OOlite
|
|
|
|
# Copyright (c) 2007 Chris Crowther <hikari@hikari.org.uk>
|
|
|
|
#
|
|
|
|
# Originally based on the exemplar hello project.
|
|
|
|
#
|
|
|
|
# Re-written by Darren Salt
|
|
|
|
# Tweaked by Michael Werle
|
|
|
|
|
|
|
|
GSMAKE = gs_make
|
|
|
|
JS_SRC = deps/Cross-platform-deps/SpiderMonkey/js/src
|
|
|
|
|
|
|
|
CFLAGS += -g
|
|
|
|
ifeq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
|
|
|
|
CFLAGS += -O2
|
|
|
|
GSMAKE += debug=no
|
|
|
|
override EXT =
|
|
|
|
else
|
|
|
|
CFLAGS += -O0
|
|
|
|
GSMAKE += debug=yes
|
|
|
|
override EXT = .dbg
|
|
|
|
endif
|
|
|
|
export CFLAGS
|
|
|
|
|
|
|
|
export GNUSTEP_INSTALLATION_DOMAIN = SYSTEM
|
|
|
|
|
2010-06-29 15:37:49 +00:00
|
|
|
build: build-stamp
|
2009-08-29 23:09:22 +00:00
|
|
|
build-stamp:
|
|
|
|
dh_testdir
|
|
|
|
$(MAKE) -C $(JS_SRC)/fdlibm -f Makefile.ref BUILD_OPT=1
|
|
|
|
$(MAKE) -C $(JS_SRC) -f Makefile.ref BUILD_OPT=1
|
2010-06-02 19:14:29 +00:00
|
|
|
$(GSMAKE) libespeak=yes
|
2009-08-29 23:09:22 +00:00
|
|
|
touch $@
|
|
|
|
|
2010-06-29 15:37:49 +00:00
|
|
|
clean: clean-stamp
|
2009-08-29 23:09:22 +00:00
|
|
|
clean-stamp:
|
|
|
|
dh_testdir
|
|
|
|
rm -f build-stamp
|
|
|
|
$(GSMAKE) clean
|
|
|
|
$(MAKE) -C $(JS_SRC)/fdlibm -f Makefile.ref clean
|
|
|
|
$(MAKE) -C $(JS_SRC) -f Makefile.ref clean
|
|
|
|
rm -rf oolite.app oolite.debug
|
|
|
|
rm -f http+_www.apple.com_DTDs_PropertyList-1.0.dtd
|
|
|
|
find $(JS_SRC) -name Linux_All_OPT.OBJ | xargs -r rm -rf
|
|
|
|
dh_clean
|
|
|
|
|
|
|
|
install: build
|
|
|
|
dh_testdir
|
|
|
|
dh_testroot
|
|
|
|
dh_clean -k
|
|
|
|
dh_installdirs
|
|
|
|
ifneq (,$(EXT))
|
2009-10-12 21:57:48 +00:00
|
|
|
cp -a "oolite.app/oolite$(EXT)" oolite.app/oolite
|
2009-08-29 23:09:22 +00:00
|
|
|
endif
|
|
|
|
|
|
|
|
binary-indep: build install
|
|
|
|
dh_testdir
|
|
|
|
dh_testroot
|
2009-09-03 06:36:25 +00:00
|
|
|
dh_installchangelogs -i Doc/CHANGELOG.TXT
|
2009-08-29 23:09:22 +00:00
|
|
|
dh_installdocs -i
|
|
|
|
dh_install -i
|
|
|
|
cd debian/oolite-data/usr/lib/GNUstep/Applications/oolite.app && rm -f oolite Resources/Info-gnustep.plist
|
|
|
|
find debian/oolite-data -name .svn | xargs -r rm -rf
|
|
|
|
dh_link -i
|
|
|
|
dh_strip -i
|
2009-09-03 06:36:25 +00:00
|
|
|
dh_compress -i -X.pdf -X.rtf
|
2009-08-29 23:09:22 +00:00
|
|
|
dh_fixperms -i
|
2009-10-08 09:05:40 +00:00
|
|
|
-dh_lintian -i # Do not fail here, since dh_lintian is only present in debhelper >= 6.0.7, and Ubuntu Hardy has 6.0.4
|
2009-08-29 23:09:22 +00:00
|
|
|
dh_installdeb -i
|
|
|
|
dh_gencontrol -i
|
|
|
|
dh_md5sums -i
|
|
|
|
dh_builddeb -i
|
|
|
|
|
|
|
|
binary-arch: build install
|
|
|
|
dh_testdir
|
|
|
|
dh_testroot
|
|
|
|
dh_installman -a debian/oolite.6
|
|
|
|
dh_installmenu -a
|
|
|
|
dh_install -a
|
2009-11-30 19:49:34 +00:00
|
|
|
dh_desktop -a installers/FreeDesktop/oolite.desktop
|
2009-08-29 23:09:22 +00:00
|
|
|
rm -rf debian/oolite/usr/share/doc/oolite
|
|
|
|
find debian/oolite -name .svn | xargs -r rm -rf
|
|
|
|
dh_link -a
|
|
|
|
dh_strip -a
|
|
|
|
dh_compress -a
|
|
|
|
dh_fixperms -a
|
2009-10-08 09:05:40 +00:00
|
|
|
-dh_lintian -a # Do not fail here, since dh_lintian is only present in debhelper >= 6.0.7, and Ubuntu Hardy has 6.0.4
|
2009-08-29 23:09:22 +00:00
|
|
|
dh_installdeb -a
|
|
|
|
dh_shlibdeps -a
|
|
|
|
dh_gencontrol -a
|
|
|
|
dh_md5sums -a
|
|
|
|
dh_builddeb -a
|
|
|
|
|
|
|
|
binary: binary-arch binary-indep
|
|
|
|
|
|
|
|
.PHONY: binary binary-arch binary-indep build clean install
|