File: rules

package info (click to toggle)
fdb 5.19.0-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 78,856 kB
  • sloc: cpp: 36,785; sh: 4,380; python: 1,334; makefile: 32; ansic: 8
file content (51 lines) | stat: -rwxr-xr-x 1,434 bytes parent folder | download | duplicates (2)
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
#!/usr/bin/make -f

#export DH_VERBOSE=1

DPKG_EXPORT_BUILDFLAGS = 1
include /usr/share/dpkg/buildflags.mk
include /usr/share/dpkg/pkg-info.mk

ARCH:=$(shell dpkg --print-architecture)
LIBDIR:=/usr/lib/${DEB_HOST_MULTIARCH}
DESTDIR:=$(CURDIR)/debian/tmp
BUILDDIR:=debian/build

ARCH_PMEM:= amd64 arm64 ppc64el
DO_PMEM:= $(if $(filter $(DEB_TARGET_ARCH), $(ARCH_PMEM)),ON,OFF)

ARCH_NORADOS:= alpha ppc64 sparc64
DO_RADOS:= $(if $(filter $(DEB_TARGET_ARCH), $(ARCH_NORADOS)),OFF,ON)
DO_RADOS:= Off

# The magic debhelper  rule
%:
	dh $@ --buildsystem=ecbuild --builddirectory=$(BUILDDIR)


# Disable for now
BUILD_FLAGS:=  -DENABLE_RPATHS=OFF \
		-DENABLE_RELATIVE_RPATHS=OFF \
		-DENABLE_RADOSFDB=$(DO_RADOS) \
		-DENABLE_LUSTRE=OFF  \
		-DENABLE_FDB_DOCUMENTATION=ON 

override_dh_auto_configure:
	mkdir -p  $(BUILDDIR)/data  
	( cd $(BUILDDIR)/data ; tar axpf $(CURDIR)/../fdb_$(DEB_VERSION_UPSTREAM).orig-data.tar.xz )
	dh_auto_configure -- \
		      ${BUILD_FLAGS}


override_dh_auto_install:
	dh_auto_install --builddirectory=debian/build
	# Fixup cmake files. Hack. can we do better with patches to upstream ?
	sed -i -e 's%$${_IMPORT_PREFIX}/include%/usr/include/${DEB_HOST_MULTIARCH}%g' $(DESTDIR)/$(LIBDIR)/cmake/fdb5/fdb5-targets.cmake

override_dh_auto_test:
	LD_LIBRARY_PATH=$(BUILDDIR)/lib dh_auto_test ||  echo "Ignoring test failures" 

override_dh_fixperms-arch:
	chrpath -d debian/fdb5/usr/bin/fdb-move
	dh_fixperms