Switch to pkgsrc-2011Q4.
[dragonfly.git] / etc / Makefile.usr
CommitLineData
95f63bef 1# Makefile.usr - installed as /usr/Makefile
809ae383 2#
95f63bef 3# Provides simple targets to download and maintain /usr/src, /usr/pkgsrc etc.
809ae383 4
fe70af21
MD
5GITHOST?=git.dragonflybsd.org
6
e2dbfa0b 7help all:
4922fbd1
MD
8 @echo "HELP:"
9 @echo ""
10.if exists(${.CURDIR}/pkgsrc/.git)
11.if exists(${.CURDIR}/pkgsrc/Makefile)
12 @echo " make pkgsrc-update - update your pkgsrc repo from the net"
13.else
14 @echo " make pkgsrc-checkout - initial checkout of your pre-packaged"
15 @echo " pkgsrc repo."
16 @echo " make pkgsrc-update - update your pkgsrc repo from the net"
17 @echo " after the initial checkout."
18.endif
19.else
20 @echo " make pkgsrc-create - fetch initial pkgsrc repo from the net"
3ab6e27a 21 @echo " make pkgsrc-create-repo - fetch pkgsrc repo only, no checkout"
4922fbd1
MD
22 @echo " make pkgsrc-update - update your pkgsrc repo from the net"
23.endif
809ae383 24 @echo ""
4922fbd1
MD
25.if exists(${.CURDIR}/src/.git)
26.if exists(${.CURDIR}/src/Makefile)
27 @echo " make src-update - update your src repo from the net"
28.else
29 @echo " make src-checkout - initial checkout of your pre-packaged src repo"
30 @echo " make src-update - update your src repo from the net"
31 @echo " after the initial checkout."
32.endif
33.else
34 @echo " make src-create - fetch initial src repo from the net"
03ac22da 35 @echo " make src-create-shallow - fetch initial history-free src repo"
3ab6e27a 36 @echo " make src-create-repo - fetch src repo only, no checkout"
4922fbd1
MD
37 @echo " make src-update - update your src repo from the net"
38.endif
809ae383 39 @echo ""
4922fbd1
MD
40.if exists(${.CURDIR}/src-sys.tgz)
41 @echo " make release-sys-extract - extract the pre-packaged sys-only sources"
42.endif
f03b7956 43 @echo ""
4922fbd1
MD
44 @echo "If automating please feel free to run git pull's from cron."
45 @echo "We prefer once a day but you can run them more often if you"
46 @echo "desire."
809ae383 47 @echo ""
4922fbd1
MD
48 @echo "If you have a repo previously maintained via CVS you should"
49 @echo "rm -rf it (save any local modifications) and then use the"
50 @echo "make src-create and/or make pkgsrc-create to set up the initial"
51 @echo "git repo."
52
3ab6e27a 53pkgsrc-create-repo:
4922fbd1
MD
54 @echo "If problems occur you may have to rm -rf pkgsrc and try again."
55 @echo ""
56 mkdir -p ${.CURDIR}/pkgsrc
57 cd ${.CURDIR}/pkgsrc && git init
58 cd ${.CURDIR}/pkgsrc && \
fe70af21 59 git remote add origin git://${GITHOST}/pkgsrcv2.git
4922fbd1 60 cd ${.CURDIR}/pkgsrc && git fetch origin
95f63bef 61 cd ${.CURDIR}/pkgsrc && git branch master origin/master
eb83a3ea 62 cd ${.CURDIR}/pkgsrc && git branch pkgsrc-2011Q4 origin/pkgsrc-2011Q4
3ab6e27a
MD
63
64pkgsrc-create: pkgsrc-create-repo
eb83a3ea 65 cd ${.CURDIR}/pkgsrc && git checkout pkgsrc-2011Q4
4922fbd1 66 cd ${.CURDIR}/pkgsrc && git pull
809ae383
MD
67
68pkgsrc-checkout:
eb83a3ea 69 cd ${.CURDIR}/pkgsrc && git checkout pkgsrc-2011Q4
809ae383
MD
70
71pkgsrc-update:
4922fbd1 72 cd ${.CURDIR}/pkgsrc && git pull
f03b7956 73
3ab6e27a 74src-create-repo:
4922fbd1
MD
75 @echo "If problems occur you may have to rm -rf src and try again."
76 @echo ""
77 mkdir -p ${.CURDIR}/src
78 cd ${.CURDIR}/src && git init
79 cd ${.CURDIR}/src && \
fe70af21 80 git remote add origin git://${GITHOST}/dragonfly.git
4922fbd1
MD
81 cd ${.CURDIR}/src && git fetch origin
82 cd ${.CURDIR}/src && git branch master origin/master
3ab6e27a
MD
83
84src-create: src-create-repo
4922fbd1
MD
85 cd ${.CURDIR}/src && git checkout master
86 cd ${.CURDIR}/src && git pull
f03b7956 87
03ac22da
MD
88src-create-shallow:
89 @echo "If problems occur you may have to rm -rf src and try again."
90 @echo ""
91 mkdir -p ${.CURDIR}/src
92 cd ${.CURDIR}/src && git init
93 cd ${.CURDIR}/src && \
bf00df77 94 git remote add origin git://${GITHOST}/dragonfly.git
03ac22da
MD
95 cd ${.CURDIR}/src && git fetch --depth=1 origin
96 cd ${.CURDIR}/src && git branch master origin/master
97 cd ${.CURDIR}/src && git checkout master
98 cd ${.CURDIR}/src && git pull
99
4922fbd1
MD
100src-checkout:
101 cd ${.CURDIR}/src && git checkout master
e2dbfa0b 102
4922fbd1
MD
103src-update:
104 cd ${.CURDIR}/src && git pull
e2dbfa0b 105
809ae383 106release-sys-extract:
4922fbd1 107 cd ${.CURDIR} && tar xvpzf src-sys.tgz
809ae383 108