File: rules

package info (click to toggle)
spark 2012.0.deb-11
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 29,268 kB
  • ctags: 3,106
  • sloc: ada: 186,243; cpp: 13,497; makefile: 685; yacc: 440; lex: 176; ansic: 119; sh: 16
file content (43 lines) | stat: -rwxr-xr-x 952 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
#!/usr/bin/make -f

# FFLAGS because there are no Ada flags, and using CFLAGS results in a lot of warnings
ADA_OPT = -gnatyN $(shell dpkg-buildflags --get FFLAGS)
ADA_LINK = $(shell dpkg-buildflags --get LDFLAGS)

ifeq (,$(filter noopt,$(DEB_BUILD_OPTIONS)))
	ADA_OPT += -fdata-sections -ffunction-sections
	ADA_LINK += -Wl,--gc-sections
endif

ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
	NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
	SPARKCPUS = $(NUMJOBS)
else
	SPARKCPUS = 1
endif

export ADA_OPT ADA_LINK SPARKCPUS

%:
	dh $@ --with swi_prolog

override_dh_auto_clean:
	$(MAKE) reallycleanall

override_dh_auto_build:
	# create empty directories that can be destroyed by git
	mkdir -p victor/vct/bin
	mkdir -p bin
	mkdir -p share/spark

	dh_auto_build

override_dh_auto_install:
	# nothing

override_dh_auto_test:
	# nothing

override_dh_install:
	dh_install
	rm -r debian/spark/usr/lib/spark/current/spark_