File: rules

package info (click to toggle)
votca 2025.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky
  • size: 132,424 kB
  • sloc: xml: 345,964; cpp: 80,067; python: 15,957; sh: 4,580; perl: 2,169; javascript: 202; makefile: 34
file content (50 lines) | stat: -rwxr-xr-x 1,542 bytes parent folder | download | duplicates (3)
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
#!/usr/bin/make -f

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

export CTEST_OUTPUT_ON_FAILURE = On
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
export DPKG_EXPORT_BUILDFLAGS = 1
include /usr/share/dpkg/buildflags.mk

export PYTHONPATH=$(CURDIR)/debian/cma-4.0.0

# Decide whether to build tests.
ifeq (,$(findstring nocheck,$(DEB_BUILD_OPTIONS)))
	export CONFIG_BUILD_TESTS = -DBUILD_TESTING=TRUE  -DENABLE_REGRESSION_TESTING=TRUE
else
	export CONFIG_BUILD_TESTS = -DBUILD_TESTING=FALSE -DENABLE_REGRESSION_TESTING=FALSE
endif

override_dh_auto_configure:
	dh_auto_configure -- \
	-DBUILD_XTP=TRUE \
	-DINSTALL_CSGAPPS=TRUE \
	-DINJECT_MARCH_NATIVE=FALSE \
	$(CONFIG_BUILD_TESTS)
	# Override various blhc false positives.
#	@echo 'blhc: ignore-line-regexp: .*Looking for c\+\+ gmx_.*'
	@echo 'blhc: ignore-line-regexp: .*C\+\+ vector data structures.*'

override_dh_auto_build-indep:
	dh_auto_build
	# temporarily use bundled copy of cma to build documentation - not yet packaged separately
ifeq (,$(findstring nodoc,$(DEB_BUILD_OPTIONS)))
	make -C $(CURDIR)/obj-$(DEB_HOST_GNU_TYPE) sphinx
endif

override_dh_installdocs:
	mkdir -p $(CURDIR)/debian/tmp/usr/share/doc/votca/html
	-test -d $(CURDIR)/obj-$(DEB_HOST_GNU_TYPE)/sphinx.html && \
	cp -aru $(CURDIR)/obj-$(DEB_HOST_GNU_TYPE)/sphinx.html/* $(CURDIR)/debian/tmp/usr/share/doc/votca/html/
	dh_installdocs
	dh_link -i

override_dh_auto_clean:
	dh_auto_clean
	py3clean $(CURDIR)
	rm -rf $(CURDIR)/.pytest_cache

%:
	dh $@ --with bash-completion,python3,sphinxdoc