summaryrefslogtreecommitdiff
path: root/postfix/Makefile
blob: aeb8a7bd104fff06cb0ac5f0349792083234c424 (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
ifeq "x$(KOLABPKGURI)" "x"
	KOLABPKGURI = http://files.kolab.org/server/development-2.2/openpkg-orig-srpms/
endif
ifeq "x$(KOLABRPMSRC)" "x"
	KOLABRPMSRC = $(HOME)/RPM/SRC
endif
ifeq "x$(KOLABRPMPKG)" "x"
	KOLABRPMPKG = $(HOME)/RPM/PKG
endif
ifeq "x$(KOLABCVSDIR)" "x"
	KOLABCVSDIR = $(CURDIR)
endif
ifeq "x$(RPM)" "x"
	RPM = $(HOME)/bin/openpkg rpm
endif

PACKAGE=postfix
VERSION=2.4.6
RELEASE=20080101
KOLABRELEASE=20080101_kolab

all: $(PACKAGE)-$(VERSION)-$(KOLABRELEASE).src.rpm

$(PACKAGE)-$(VERSION)-$(KOLABRELEASE).src.rpm: $(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm $(KOLABCVSDIR)/kolab.patch Makefile
	$(RPM) -ihv $(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm

	cd $(KOLABRPMSRC)/$(PACKAGE) && patch < $(KOLABCVSDIR)/kolab.patch && $(RPM) -ba $(PACKAGE).spec --define 'with_fsl yes' --define 'with_ssl yes' --define 'with_sasl yes' --define 'with_ldap yes'
	cp -p $(KOLABRPMPKG)/$(PACKAGE)-$(VERSION)-$(KOLABRELEASE).src.rpm $(KOLABCVSDIR)

$(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm:
	wget -c $(KOLABPKGURI)/$(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm

dist: all
	cp $(KOLABCVSDIR)/$(PACKAGE)-$(VERSION)-$(KOLABRELEASE).src.rpm ../stage/

clean:
	rm -f $(KOLABCVSDIR)/$(PACKAGE)-$(VERSION)-$(KOLABRELEASE).src.rpm