File: rules

package info (click to toggle)
libbluray 1%3A0.2.2-1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 4,840 kB
  • sloc: java: 15,630; ansic: 13,319; sh: 11,096; makefile: 230; xml: 26
file content (54 lines) | stat: -rwxr-xr-x 1,402 bytes parent folder | download
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
#!/usr/bin/make -f

DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
DEB_BUILD_ARCH_OS ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH_OS)
DEB_BUILD_ARCH := $(shell dpkg-architecture -qDEB_BUILD_ARCH)

confflags := --libdir=/usr/lib/$(DEB_HOST_MULTIARCH) --enable-doxygen-doc

# enable bdjava on linux hosts only
ifneq (,$(findstring linux,$(DEB_BUILD_ARCH_OS)))

# openjdk-6_6b23~pre8-2 and later have multiarchified JAVA_HOME
JAVA_HOME=/usr/lib/jvm/java-6-openjdk-$(DEB_BUILD_ARCH)
ifeq (,$(wildcard $(JAVA_HOME)))
JAVA_HOME=/usr/lib/jvm/java-6-openjdk
ifeq (,$(wildcard $(JAVA_HOME)))
     $(info "warning: No suitable jni.h was found. Package will most probably FTBFS!")
endif
endif

$(info Located java at $(JAVA_HOME))
confflags += --enable-bdjava --with-jdk=$(JAVA_HOME)
endif

# Set CFLAGS to DEB_CFLAGS
CFLAGS=$(shell dpkg-buildflags --get CFLAGS 2>/dev/null | sed -e 's/-O2//g')

ifneq (,$(findstring linux,$(DEB_BUILD_ARCH_OS)))
%:
	dh $@ --parallel --with javahelper
else
%:
	dh $@ --parallel
endif

override_dh_auto_configure:
	dh_auto_configure -- $(confflags)

override_dh_auto_build:
	dh_auto_build
	make doxygen-doc

override_dh_strip:
	dh_strip -plibbluray1 --dbg-package=libbluray1-dbg

override_dh_installdocs:
	dh_installdocs --exclude=jquery.js

override_dh_clean:
	dh_clean
	rm -rf src/libbluray/bdj/build

get-orig-source:
	$(dir $_)libbluray-get-orig-source