mirror of
https://github.com/vivier/EMILE.git
synced 2024-12-23 01:29:34 +00:00
102 lines
2.3 KiB
Makefile
102 lines
2.3 KiB
Makefile
#!/usr/bin/make -f
|
|
# Sample debian/rules that uses debhelper.
|
|
# This file is public domain software, originally written by Joey Hess.
|
|
|
|
# Uncomment this to turn on verbose mode.
|
|
|
|
DEB_BUILD_ARCH ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH)
|
|
DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH)
|
|
|
|
ifeq ($(DEB_HOST_ARCH),$(DEB_BUILD_ARCH))
|
|
CROSS_COMPILE=
|
|
else
|
|
CROSS_COMPILE=$(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)-
|
|
endif
|
|
|
|
ifeq ($(DEB_BUILD_ARCH),m68k)
|
|
M68K_CROSS_COMPILE=
|
|
target=all
|
|
target_install=install
|
|
else
|
|
M68K_CROSS_COMPILE=m68k-linux-gnu-
|
|
M68K_GCC_PATH=$(shell $(M68K_CROSS_COMPILE)gcc -dumpversion)
|
|
ifeq ($(M68K_GCC_PATH),)
|
|
target=docs tools
|
|
target_install=tools-install docs-install
|
|
CHMOD_BOOT=0
|
|
else
|
|
target=all
|
|
target_install=install
|
|
CHMOD_BOOT=1
|
|
endif
|
|
endif
|
|
|
|
build: build-stamp
|
|
build-stamp:
|
|
dh_testdir
|
|
# Add here commands to compile the package.
|
|
$(MAKE) M68K_CROSS_COMPILE="$(M68K_CROSS_COMPILE)" CROSS_COMPILE="$(CROSS_COMPILE)" $(target)
|
|
touch build-stamp
|
|
|
|
clean:
|
|
dh_testdir
|
|
dh_testroot
|
|
rm -f build-stamp
|
|
|
|
# Add here commands to clean up after the build process.
|
|
-$(MAKE) clean
|
|
|
|
dh_clean
|
|
|
|
install: build
|
|
dh_testdir
|
|
dh_testroot
|
|
dh_clean -k
|
|
dh_installdirs
|
|
|
|
# Add here commands to install the package into debian/<packagename>
|
|
$(MAKE) DESTDIR=`pwd`/debian/tmp $(target_install)
|
|
if test -d `pwd`/debian/tmp/boot/emile/; then chmod -x `pwd`/debian/tmp/boot/emile/*; fi
|
|
if test -d `pwd`/debian/tmp/lib/emile/; then chmod -x `pwd`/debian/tmp/lib/emile/*; fi
|
|
|
|
|
|
# Build architecture-independent files here.
|
|
binary-indep: build install
|
|
dh_testroot -i
|
|
dh_installchangelogs -i
|
|
dh_installdocs -i
|
|
dh_installexamples -i
|
|
dh_install --sourcedir=debian/tmp -i
|
|
dh_installman -i
|
|
dh_link -i
|
|
dh_strip -i
|
|
dh_compress -i
|
|
dh_fixperms -i
|
|
dh_installdeb -i
|
|
dh_shlibdeps -i
|
|
dh_gencontrol -i
|
|
dh_md5sums -i
|
|
dh_builddeb -i
|
|
|
|
# Build architecture-dependent files here.
|
|
binary-arch: build install
|
|
dh_testdir -a
|
|
dh_testroot -a
|
|
dh_installchangelogs -a
|
|
dh_installdocs -a
|
|
dh_installexamples -a
|
|
dh_install --sourcedir=debian/tmp -a
|
|
dh_installman -a
|
|
dh_link -a
|
|
dh_strip -a
|
|
dh_compress -a
|
|
dh_fixperms -a
|
|
dh_installdeb -a
|
|
dh_shlibdeps -a
|
|
dh_gencontrol -a
|
|
dh_md5sums -a
|
|
dh_builddeb -a
|
|
|
|
binary: binary-indep binary-arch
|
|
.PHONY: build clean binary-indep binary-arch binary install
|