summaryrefslogtreecommitdiff
path: root/illumos-grub/debian/rules
diff options
context:
space:
mode:
Diffstat (limited to 'illumos-grub/debian/rules')
-rwxr-xr-xillumos-grub/debian/rules82
1 files changed, 82 insertions, 0 deletions
diff --git a/illumos-grub/debian/rules b/illumos-grub/debian/rules
new file mode 100755
index 0000000..3be4523
--- /dev/null
+++ b/illumos-grub/debian/rules
@@ -0,0 +1,82 @@
+#!/usr/bin/make -f
+
+include /usr/share/dpkg/buildflags.mk
+
+export DH_VERBOSE = 1
+
+cmd := \
+ vt \
+
+man := \
+
+unpack: unpack-stamp
+unpack-stamp:
+ dh_testdir
+ dh_illumos_gate --build \
+ $(man) \
+ usr/src/grub \
+
+
+ # Buggy and unused:
+ echo > usr/src/Makefile.msg.targ
+
+ # Use GNU ld:
+ sed -i '/LD_ALTEXEC/d' usr/env.sh
+
+ touch $@
+
+patch: patch-stamp
+patch-stamp: unpack-stamp
+ dh_testdir
+ [ ! -f debian/patches/series ] || QUILT_PATCHES=debian/patches quilt push -a || test $$? = 2
+ touch $@
+
+unpatch:
+ dh_testdir
+ [ ! -f debian/patches/series ] || QUILT_PATCHES=debian/patches quilt pop -a -f || test $$? = 2
+ rm -f patch-stamp
+
+dirs-stamp: unpack-stamp
+ . usr/env.sh; mkdir -p \
+ debian/tmp/usr/lib
+ touch $@
+
+install: install-stamp
+
+install-stamp: build-stamp
+ touch $@
+
+build build-arch build-indep: build-stamp
+build-stamp: dirs-stamp patch-stamp
+ dh_illumos_make --native usr/src/grub -m sunmake
+ touch $@
+
+binary binary-arch binary-indep: binary-stamp
+binary-stamp: install-stamp
+ dh_testdir
+ dh_testroot
+ dh_installdirs
+ dh_install
+ dh_strip
+ dh_installman
+ dh_installdocs
+ dh_installexamples
+ dh_installchangelogs
+ dh_bash-completion
+ dh_link
+ dh_compress
+ dh_fixperms
+ dh_installdeb
+ dh_shlibdeps
+ dh_strip
+ dh_gencontrol
+ dh_md5sums
+ dh_builddeb
+ touch $@
+
+clean: unpatch
+ dh_testdir
+ dh_testroot
+ dh_clean
+ rm -rf usr .pc
+