summaryrefslogtreecommitdiff
path: root/debian/rules
blob: 735776c23d0e8aa6ca21fd83d329ebbf014e599c (plain)
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
#!/usr/bin/make -f

CCFLAGS += -Wall -g -O$(if $(findstring noopt,$(DEB_BUILD_OPTIONS)),0,2)

binary-arch:
	dh_testdir
	dh_testroot
	dh_installdocs -s
	dh_installman -s
	dh_installchangelogs -s CHANGELOG
	dh_install -s
	chmod -R 755 debian/vlan/etc/network
	dh_strip -s
	dh_fixperms -s
	dh_compress -s
	dh_shlibdeps -s
	dh_gencontrol -s
	dh_installdeb -s
	dh_md5sums -s
	dh_builddeb -s

build:
	# upstream ships a macvlan_config binary
	#mv -f macvlan_config macvlan_config.orig
	# STRIP is to avoid the upstream stripping
	$(MAKE) CCFLAGS="$(CCFLAGS)" STRIP=true

clean:
	# restore macvlan_config binary shipped by upstream
	#-mv -f macvlan_config.orig macvlan_config
	dh_clean
	rm -f vconfig.h vconfig.o vconfig

binary-indep:

binary: binary-arch binary-indep

.PHONY: binary binary-arch binary-indep clean