]> git.proxmox.com Git - frr.git/blob - Makefile
makefile: convert to use simple parenthesis
[frr.git] / Makefile
1 include /usr/share/dpkg/default.mk
2
3 PACKAGE=frr
4
5 SRCDIR=frr
6 BUILDDIR=build-$(PACKAGE)-$(DEB_VERSION_UPSTREAM)
7
8 GITVERSION:=$(shell git rev-parse HEAD)
9
10 MAIN_DEB=$(PACKAGE)_$(DEB_VERSION)_$(DEB_BUILD_ARCH).deb
11 OTHER_DEBS=\
12 frr-doc_$(DEB_VERSION)_all.deb \
13 frr-pythontools_$(DEB_VERSION)_all.deb \
14 frr-snmp_$(DEB_VERSION)_$(DEB_BUILD_ARCH).deb \
15
16 DBG_DEBS=\
17 frr-dbgsym_$(DEB_VERSION)_$(DEB_BUILD_ARCH).deb \
18 frr-snmp-dbgsym_$(DEB_VERSION)_$(DEB_BUILD_ARCH).deb \
19
20 DEBS=$(MAIN_DEB) $(OTHER_DEBS) $(DBG_DEBS)
21
22 all: $(DEBS)
23 @echo $(DEBS)
24
25 .PHONY: submodule
26 submodule:
27 test -f "$(SRCDIR)/debian/changelog" || git submodule update --init
28
29 $(BUILDDIR): submodule debian/changelog
30 rm -rf $(BUILDDIR) $(BUILDDIR).tmp
31 cp -a $(SRCDIR) $(BUILDDIR).tmp
32 rm $(BUILDDIR).tmp/debian/changelog
33 cp -a debian/* $(BUILDDIR).tmp/debian/
34 mv $(BUILDDIR).tmp $(BUILDDIR)
35
36 .PHONY: deb
37 deb: $(DEBS)
38 $(OTHER_DEBS) $(DBG_DEBS): $(MAIN_DEB)
39 $(MAIN_DEB): $(BUILDDIR)
40 cd $(BUILDDIR); dpkg-buildpackage -b -uc -us --build-profiles="pkg.frr.nortrlib"
41 lintian $(DEBS)
42
43 .PHONY: upload
44 upload: $(DEBS)
45 tar cf - $(DEBS)|ssh -X repoman@repo.proxmox.com -- upload --product pve --dist bullseye
46
47 .PHONY: distclean
48 distclean: clean
49
50 .PHONY: clean
51 clean:
52 rm -rf *~ debian/*~ *.deb build-$(PACKAGE)* *.changes *.dsc *.buildinfo
53
54 .PHONY: dinstall
55 dinstall: deb
56 dpkg -i $(DEBS)