3
# Uncomment this to turn on verbose mode.
5
# Not yet a CLI app (until mono 2.0 allows Silverlight 2.0 features)
6
#export MONO_SHARED_DIR=$(CURDIR)
7
#DEB_CLI_API_VERSION = 1.9
9
# Mangle environment variables which differ between Debian & Ubuntu.
10
# Assume Debian behaviour by default.
11
DISTRO = "$(shell lsb_release -si)"
12
XULRUNNER_19_PLUGDIR = "usr/lib/mozilla/plugins"
13
ifeq ($(DISTRO),"Ubuntu")
14
XULRUNNER_19_PLUGDIR = "usr/lib/xulrunner-addons/plugins"
17
config.status: configure
19
./configure --prefix=/usr --with-cairo=system --with-ff3=yes --with-alsa=yes --with-pulseaudio=yes \
22
upstream_version=$(shell uscan --dehs | sed -n 's/.*<upstream-version>\(.*\)<\/upstream-version>.*/\1/p')
23
CURVER = $(shell dpkg-parsechangelog | grep ^Version | cut -d' ' -f2 | cut -d'-' -f1)
25
[ -d ../tarballs ] || mkdir ../tarballs
28
--download-version $(CURVER) \
34
build-stamp: config.status
42
rm -f build-stamp configure-stamp
43
# Not a Mono package yet, no .wapi
44
# rm -rf $(MONO_SHARED_DIR)/.wapi
45
rm -f build/config.make
46
[ ! -f Makefile ] || $(MAKE) distclean
54
$(MAKE) DESTDIR=$(CURDIR)/debian/tmp install
55
# Mangle rpath for lintain cleanness
56
chrpath -d $(CURDIR)/debian/tmp/usr/lib/moon/plugin/libmoonplugin-ff3bridge.so
57
chrpath -d $(CURDIR)/debian/tmp/usr/lib/moon/plugin/libmoonplugin.so
58
dh_install --list-missing --sourcedir=debian/tmp
60
binary-indep: build install
62
binary-arch: build install
65
dh_installchangelogs ChangeLog
66
dh_installdocs -A AUTHORS
68
# Call dh_link manually, so we can change the plugin folder per-distro
69
dh_link -pmoonlight-plugin-mozilla \
70
usr/lib/moon/plugin/libmoonloader.so $(XULRUNNER_19_PLUGDIR)/libmoonloader.so
71
#dark magics in libmoonloader seem to find these files all by itself, only libmoonloader is needed
72
#usr/lib/moon/plugin/libmoonplugin-ff3bridge.so $(XULRUNNER_19_PLUGDIR)/libmoonplugin-ff3bridge.so \
73
#usr/lib/moon/plugin/libmoonplugin.so $(XULRUNNER_19_PLUGDIR)/libmoonplugin.so \
79
dh_makeshlibs -plibmoon -pmoonlight-plugin-core
86
binary: binary-indep binary-arch
87
.PHONY: build clean binary-indep binary-arch binary install