File: rules

package info (click to toggle)
elastix 4.8-10
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 54,376 kB
  • ctags: 15,302
  • sloc: cpp: 54,754; lisp: 4,121; python: 658; sh: 226; xml: 182; makefile: 30
file content (49 lines) | stat: -rwxr-xr-x 1,342 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
#!/usr/bin/make -f

export DEB_BUILD_MAINT_OPTIONS = hardening=+all
export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed
export DEB_CXXFLAGS_MAINT_APPEND  = -fvisibility=hidden

EPOCH_DATE:=$(shell date -u -d ${SOURCE_DATE_EPOCH} +%d.%m.%Y)

%:
	dh $@ --sourcedirectory=src

binary: binary-arch binary-indep

binary-indep: doc-stamp
	dh $@ --sourcedirectory=src --parallel


# Need -DUSE_KNNGraphAlphaMutualInformationMetric:BOOL=ON, otherwise
# KNN is not built, and link of elastix fails.
#
DEB_CMAKE_EXTRA_FLAGS += \
	-DCMAKE_INSTALL_PREFIX=/usr \
	-DCMAKE_BUILD_TYPE=RELEASE \
	-DCMAKE_SKIP_RPATH=ON \
	-DSOURCE_DATE_EPOCH=$SOURCE_DATE_EPOCH \
	-DELASTIX_USE_MEVISDICOMTIFF:BOOL=OFF \
	-DUSE_KNNGraphAlphaMutualInformationMetric:BOOL=ON

override_dh_auto_configure:
	dh_auto_configure -- $(DEB_CMAKE_EXTRA_FLAGS)

override_dh_builddeb:
	dh_builddeb -- -Z xz

doc: doc-stamp

doc-stamp: help/html/index.html dox/manual/manual.pdf
	touch $@

# build-deps: doxygen, latex, dot
help/html/index.html: help/doxyfile.out
	doxygen $<
	rm help/html/*.md5

dox/manual/manual.pdf: dox/manual/manual.tex
	sed -ie 's/^%\\date{/\\date{'"$(EPOCH_DATE)"'/' dox/manual/manual.tex 
	sed -ie 's/\\today/'"$(EPOCH_DATE)"'/' dox/manual/manual.tex 
	cd dox/manual && latex manual && bibtex manual && latex manual && latex manual && latex manual && dvipdf manual