File: rules

package info (click to toggle)
pgagent 3.4.0-3
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 356 kB
  • ctags: 211
  • sloc: cpp: 1,697; sql: 560; xml: 100; ansic: 52; makefile: 33; sh: 9
file content (37 lines) | stat: -rwxr-xr-x 1,122 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
#!/usr/bin/make -f

%:
	dh $@

override_dh_auto_configure:
	cmake . -DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_C_FLAGS="$(CFLAGS)" \
		-DCMAKE_LD_FLAGS="-Wl,-z,defs" \
		-DCMAKE_CXX_FLAGS="$(CXXFLAGS)" \
		-DCMAKE_SKIP_RPATH=ON \
		-DCMAKE_VERBOSE_MAKEFILE=ON \
		-DWX_VERSION=$(shell wx-config --release) \
		-DwxWidgets_USE_STATIC=OFF \
		-DWX_STATIC=OFF \
		-DSTATIC_BUILD=OFF

# install extension files for the other PostgreSQL versions
override_dh_link:
	set -ex; \
	version=$$(basename debian/pgagent/usr/share/postgresql/*); \
	for v in $(shell pg_buildext supported-versions); do \
		test $$v = $$version && continue; \
		mkdir -p debian/pgagent/usr/share/postgresql/$$v/extension; \
		(cd debian/pgagent/usr/share/postgresql/$$v/extension && \
			ln -vs ../../$$version/extension/* .); \
	done

override_dh_gencontrol:
	dh_gencontrol -- -VPostgresql:Version="$(shell pg_buildext supported-versions)"

override_dh_auto_clean:
	dh_auto_clean
	# there is no "cmake clean" command
	rm -rf CMakeCache.txt CMakeFiles/ cmake_install.cmake CPack* install_manifest.txt Makefile
	$(MAKE) -C test clean
	rm -f test/pgagent.out