1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104
|
#!/usr/bin/make -f
# You must remove unused comment lines for the released package.
#export DH_VERBOSE = 1
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
export DEB_CFLAGS_MAINT_APPEND = -Wall -pedantic
export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed
export JAVA_HOME=/usr/lib/jvm/default-java
export CLASSPATH=/usr/share/java/csv.jar:/usr/share/java/debug-disable.jar:/usr/share/java/itext.jar
export GTEST_DIR=/usr/src/gtest
DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
# mapping all i.86 to x86 for Alljoyn
CPU=$(shell dpkg-architecture -qDEB_HOST_GNU_CPU | sed -e 's/i.86/x86/')
BUILDARCH=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
OS=linux
export VERSION := 15.04
export SONAME := 1504
export VARIANT := release
export SCONS_ARGS := CPU=$(CPU) OS=$(OS) VARIANT=$(VARIANT) V=1 GTEST_DIR=$(GTEST_DIR)
export BUILD_DIR := $(CURDIR)/build/$(OS)/$(CPU)/$(VARIANT)/dist
export OBJ_DIR := $(CURDIR)/build/$(OS)/$(CPU)/$(VARIANT)/obj
%:
dh $@
override_dh_auto_build:
(cd sample_apps; \
scons BINDINGS=cpp $(SCONS_ARGS) \
WS=off BT=off ICE=off \
)
(cd time; \
scons BINDINGS=cpp $(SCONS_ARGS) \
WS=off BT=off ICE=off \
)
(cd config; \
scons BINDINGS=cpp $(SCONS_ARGS) \
WS=off BT=off ICE=off \
)
(cd services_common; \
scons BINDINGS=cpp $(SCONS_ARGS) \
WS=off BT=off ICE=off \
)
(cd controlpanel; \
scons BINDINGS=cpp $(SCONS_ARGS) \
WS=off BT=off ICE=off \
)
(cd onboarding; \
scons BINDINGS=cpp $(SCONS_ARGS) \
WS=off BT=off ICE=off \
)
(cd notification; \
scons BINDINGS=cpp $(SCONS_ARGS) \
WS=off BT=off ICE=off \
)
touch ./to-be.removed-now.md5
find ./* |grep '\.md5'|xargs rm
dh_auto_build
override_dh_auto_clean:
# see explanation of -I for dpkg-source
# as this dir contains an {arch}, dpkg-source ignores it
# "arm" in Alljoyn world means openWRT+cross compiling
# so this is not needed for Debian
rm -rf build_core/conf/linux/arm
rm -f sample_apps/.sconsign.dblite
rm -rf sample_apps/.sconf_temp
rm -f services_common/.sconsign.dblite
rm -rf services_common/.sconf_temp
rm -f notification/.sconsign.dblite
rm -rf notification/.sconf_temp
rm -f onboarding/.sconsign.dblite
rm -rf onboarding/.sconf_temp
rm -f controlpanel/.sconsign.dblite
rm -rf controlpanel/.sconf_temp
rm -f time/.sconsign.dblite
rm -rf time/.sconf_temp
rm -f config/.sconsign.dblite
rm -rf config/.sconf_temp
touch ./to-be.removed-now.md5
find ./* |grep '\.md5'|xargs rm
rm -rf sample_apps/build
rm -rf services_common/build
rm -rf notification/build
rm -rf onboarding/build
rm -rf controlpanel/build
rm -rf time/build
rm -rf config/build
dh_auto_clean
override_dh_install:
dh_install
# improve stuff
chmod 644 debian/alljoyn-services-1504/etc/alljoyn/*.conf
override_dh_installchangelogs:
cat */ReleaseNotes.txt > ReleaseNotes.txt
dh_installchangelogs ReleaseNotes.txt
rm ReleaseNotes.txt
dh_installchangelogs
|