-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
48 lines (36 loc) · 1.17 KB
/
Makefile
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
44
45
46
47
48
GIT = https://github.com/notqmail/notqmail
SHA = $$(git -C notqmail.git rev-parse ${BRANCH})
all:v
@xargs -I {} -n 1 make patches BRANCH={} <conf-branch
branches:v
@echo '>>> building all branches for patch ${PATCH}'
@xargs -I {} -n 1 make one BRANCH={} PATCH=${PATCH} <conf-branch
patches:v
@echo '>>> building all patches for branch ${BRANCH}'
@ls patch | sed 's/.patch$$//' |\
xargs -I {} -n 1 make one BRANCH=${BRANCH} PATCH={}
one:v notqmail.git
@make log/${SHA}-${PATCH}.log COMMIT=${SHA} PATCH=${PATCH}
log/${COMMIT}-${PATCH}.log:
@echo building $@
@-make build COMMIT=${COMMIT} PATCH=${PATCH} >[email protected] 2>&1
@mv [email protected] $@
build:v notqmail-${COMMIT}-${PATCH}
make -C notqmail-${COMMIT}-${PATCH} it
@echo ok
notqmail-${COMMIT}-${PATCH}: notqmail.git patch/${PATCH}.patch
rm -rf $@
git -C notqmail.git fetch origin ${COMMIT}
git -C notqmail.git archive --prefix=$@/ ${COMMIT} | tar xf -
cd $@; patch -f -p 1 <../patch/${PATCH}.patch
notqmail.git:
git clone --bare ${GIT} $@
README.md:v all
sh README.sh >$@
brokemaster:v
@make patches BRANCH=${BRANCH}
@make patches BRANCH=master
sh brokemaster.sh ${BRANCH}
clean:v
rm -rf notqmail-*/
v: # virtual target