Sun Nov 20 16:20:24 2011 UTC ()
pkgtools/tinderbox-dragonfly: Update to version 3.4.1

Besides syncing with FreeBSD Tinderbox 3.4.1, the following updates were
included:
1) Creating bulkbuild handling script
2) Created postPortBuild hook script to support bulk builds
3) Fixed fake "wrong arch" error due to funky licenses
4) Deviated "mark_failed()" from Tinderbox-FreeBSD to fire postPortBuild
   hook for ports marked failed due to failed dependency
5) Added tc_command.pl patch that should have gone in previous update to
   support pkgsrc scan bulk script


(marino)
diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/Makefile
diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/PLIST
diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/distinfo
diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/patches/patch-aa
diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/patches/patch-ai
diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/patches/patch-ar
diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/patches/patch-as
diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/patches/patch-aw
diff -r1.1 -r0 pkgsrc/pkgtools/tinderbox-dragonfly/patches/patch-ag
diff -r1.1 -r0 pkgsrc/pkgtools/tinderbox-dragonfly/patches/patch-ah

cvs diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/Attic/Makefile (expand / switch to unified diff)

--- pkgsrc/pkgtools/tinderbox-dragonfly/Attic/Makefile 2011/11/14 02:00:19 1.2
+++ pkgsrc/pkgtools/tinderbox-dragonfly/Attic/Makefile 2011/11/20 16:20:24 1.3
@@ -1,63 +1,66 @@ @@ -1,63 +1,66 @@
1# $NetBSD: Makefile,v 1.2 2011/11/14 02:00:19 marino Exp $ 1# $NetBSD: Makefile,v 1.3 2011/11/20 16:20:24 marino Exp $
2# 2#
3 3
4DISTNAME= tinderbox-dragonfly-${TBOX_VERSION} 4DISTNAME= tinderbox-dragonfly-${TBOX_VERSION}
5PKGREVISION= 1 
6CATEGORIES= pkgtools 5CATEGORIES= pkgtools
7MASTER_SITES= http://tinderbox.marcuscom.com/ 6MASTER_SITES= http://tinderbox.marcuscom.com/
8DISTFILES= tinderbox-${TBOX_VERSION}.tar.gz 7DISTFILES= tinderbox-${TBOX_VERSION}.tar.gz
9 8
10MAINTAINER= draco@marino.st 9MAINTAINER= draco@marino.st
11HOMEPAGE= http://tinderbox/marcuscom.com 10HOMEPAGE= http://tinderbox/marcuscom.com
12COMMENT= Tinderbox package building system (pkgsrc) 11COMMENT= Tinderbox package building system (pkgsrc)
13LICENSE= modified-bsd 12LICENSE= modified-bsd
14 13
15DEPENDS+= p5-Compress-Bzip2>=2:../../archivers/p5-Compress-Bzip2 14DEPENDS+= p5-Compress-Bzip2>=2:../../archivers/p5-Compress-Bzip2
16DEPENDS+= csup>=20100101:../../net/csup 15DEPENDS+= csup>=20100101:../../net/csup
17DEPENDS+= scmgit>1.6:../../devel/scmgit 16DEPENDS+= scmgit>1.6:../../devel/scmgit
18 17
19TBOX_VERSION= 3.4 18TBOX_VERSION= 3.4.1
20PKG_DESTDIR_SUPPORT= user-destdir 19PKG_DESTDIR_SUPPORT= user-destdir
21ONLY_FOR_PLATFORM= DragonFly-*-* 20ONLY_FOR_PLATFORM= DragonFly-*-*
22 21
23USE_TOOLS+= perl perl:run 22USE_TOOLS+= perl perl:run
24NO_CONFIGURE= yes 23NO_CONFIGURE= yes
25NO_BUILD= yes 24NO_BUILD= yes
26RCD_SCRIPTS= tinderd 25RCD_SCRIPTS= tinderd
27WRKSRC= ${WRKDIR}/tinderbox-${TBOX_VERSION} 26WRKSRC= ${WRKDIR}/tinderbox-${TBOX_VERSION}
28TRASH= ${WRKDIR}/trash 27TRASH= ${WRKDIR}/trash
29MAN_FILES_cmd= ${SED} -ne "s,^man/man1/,,p" PLIST 28MAN_FILES_cmd= ${SED} -ne "s,^man/man1/,,p" PLIST
30MAN_FILES= ${MAN_FILES_cmd:sh} 29MAN_FILES= ${MAN_FILES_cmd:sh}
31 30
32INSTALLATION_DIRS+= tinderbox/scripts 31INSTALLATION_DIRS+= tinderbox/scripts
33INSTALLATION_DIRS+= ${PKGMANDIR}/man1 32INSTALLATION_DIRS+= ${PKGMANDIR}/man1
34 33
35SUBST_CLASSES+= paths 34SUBST_CLASSES+= paths
36SUBST_FILES.paths+= contrib/bulk/add_all_packages.sh 35SUBST_FILES.paths+= contrib/bulk/add_all_packages.sh
 36SUBST_FILES.paths+= contrib/bulk/bulk_hook_1.sh
 37SUBST_FILES.paths+= contrib/bulk/bulkbuild.sh
37SUBST_SED.paths+= -e 's,@TINROOT@,${PREFIX}/tinderbox,g' 38SUBST_SED.paths+= -e 's,@TINROOT@,${PREFIX}/tinderbox,g'
38SUBST_STAGE.paths= post-patch 39SUBST_STAGE.paths= post-patch
39 40
40.include "options.mk" 41.include "options.mk"
41 42
42post-extract: 43post-extract:
43 ${MKDIR} ${TRASH} 44 ${MKDIR} ${TRASH}
44.if empty(PKG_OPTIONS:Mwebui) 45.if empty(PKG_OPTIONS:Mwebui)
45 mv ${WRKSRC}/webui ${TRASH} 46 mv ${WRKSRC}/webui ${TRASH}
46.endif 47.endif
47 mv ${WRKSRC}/etc/rc.d ${TRASH} 48 mv ${WRKSRC}/etc/rc.d ${TRASH}
48 ${MKDIR} ${WRKSRC}/contrib/bulk 49 ${MKDIR} ${WRKSRC}/contrib/bulk
49 ${CP} ${FILESDIR}/add_all_packages.sh.in \ 50 for dossier in add_all_packages bulk_hook_1 bulkbuild; do \
50 ${WRKSRC}/contrib/bulk/add_all_packages.sh 51 ${CP} ${FILESDIR}/$${dossier}.sh.in \
 52 ${WRKSRC}/contrib/bulk/$${dossier}.sh; \
 53 done
51 chmod 755 ${WRKSRC}/contrib/bulk/* 54 chmod 755 ${WRKSRC}/contrib/bulk/*
52 55
53post-patch: 56post-patch:
54.if !empty(PKG_OPTIONS:Manybody) 57.if !empty(PKG_OPTIONS:Manybody)
55 perl -i -pe 's/^if \[ `id -u` != 0 \]; then/if false; then/' \ 58 perl -i -pe 's/^if \[ `id -u` != 0 \]; then/if false; then/' \
56 ${WRKSRC}/tc 59 ${WRKSRC}/tc
57.endif 60.endif
58 cd ${WRKSRC} && ${FIND} -E . -regex '.*(orig|bak)' -exec ${RM} {} \; 61 cd ${WRKSRC} && ${FIND} -E . -regex '.*(orig|bak)' -exec ${RM} {} \;
59 62
60do-install: 63do-install:
61 for manual in ${MAN_FILES}; do \ 64 for manual in ${MAN_FILES}; do \
62 ${INSTALL_MAN} ${WRKSRC}/man/man1/$${manual} ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1; \ 65 ${INSTALL_MAN} ${WRKSRC}/man/man1/$${manual} ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1; \
63 done 66 done

cvs diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/Attic/PLIST (expand / switch to unified diff)

--- pkgsrc/pkgtools/tinderbox-dragonfly/Attic/PLIST 2011/11/14 02:00:19 1.2
+++ pkgsrc/pkgtools/tinderbox-dragonfly/Attic/PLIST 2011/11/20 16:20:24 1.3
@@ -1,34 +1,36 @@ @@ -1,34 +1,36 @@
1@comment $NetBSD: PLIST,v 1.2 2011/11/14 02:00:19 marino Exp $ 1@comment $NetBSD: PLIST,v 1.3 2011/11/20 16:20:24 marino Exp $
2man/man1/tc-configCcache.1 2man/man1/tc-configCcache.1
3man/man1/tc-configDistfile.1 3man/man1/tc-configDistfile.1
4man/man1/tc-configGet.1 4man/man1/tc-configGet.1
5man/man1/tc-configJail.1 5man/man1/tc-configJail.1
6man/man1/tc-configTinderd.1 6man/man1/tc-configTinderd.1
7man/man1/tc-init.1 7man/man1/tc-init.1
8share/examples/rc.d/tinderd 8share/examples/rc.d/tinderd
9tinderbox/scripts/.version 9tinderbox/scripts/.version
10tinderbox/scripts/README 10tinderbox/scripts/README
11tinderbox/scripts/ds.ph.dist 11tinderbox/scripts/ds.ph.dist
12tinderbox/scripts/contrib/hooks/compress_wrkdir/README.txt 12tinderbox/scripts/contrib/hooks/compress_wrkdir/README.txt
13tinderbox/scripts/contrib/hooks/compress_wrkdir/compress_wrkdir.sh 13tinderbox/scripts/contrib/hooks/compress_wrkdir/compress_wrkdir.sh
14tinderbox/scripts/contrib/hooks/kse-fix/libmap.conf 14tinderbox/scripts/contrib/hooks/kse-fix/libmap.conf
15tinderbox/scripts/contrib/hooks/kse-fix/README.txt 15tinderbox/scripts/contrib/hooks/kse-fix/README.txt
16tinderbox/scripts/contrib/hooks/kse-fix/kse-fix.sh 16tinderbox/scripts/contrib/hooks/kse-fix/kse-fix.sh
17tinderbox/scripts/contrib/hooks/make-jobs-safe/README.txt 17tinderbox/scripts/contrib/hooks/make-jobs-safe/README.txt
18tinderbox/scripts/contrib/hooks/make-jobs-safe/make-jobs-safe.sh 18tinderbox/scripts/contrib/hooks/make-jobs-safe/make-jobs-safe.sh
19tinderbox/scripts/contrib/hooks/mass-build-pgsql/README.txt 19tinderbox/scripts/contrib/hooks/mass-build-pgsql/README.txt
20tinderbox/scripts/contrib/hooks/mass-build-pgsql/mass-build-pgsql.sh 20tinderbox/scripts/contrib/hooks/mass-build-pgsql/mass-build-pgsql.sh
21tinderbox/scripts/contrib/bulk/add_all_packages.sh 21tinderbox/scripts/contrib/bulk/add_all_packages.sh
 22tinderbox/scripts/contrib/bulk/bulkbuild.sh
 23tinderbox/scripts/contrib/bulk/bulk_hook_1.sh
22tinderbox/scripts/etc/env/.keep_me 24tinderbox/scripts/etc/env/.keep_me
23tinderbox/scripts/lib/Tinderbox/Build.pm 25tinderbox/scripts/lib/Tinderbox/Build.pm
24tinderbox/scripts/lib/Tinderbox/BuildPortsQueue.pm 26tinderbox/scripts/lib/Tinderbox/BuildPortsQueue.pm
25tinderbox/scripts/lib/Tinderbox/Config.pm 27tinderbox/scripts/lib/Tinderbox/Config.pm
26tinderbox/scripts/lib/Tinderbox/Hook.pm 28tinderbox/scripts/lib/Tinderbox/Hook.pm
27tinderbox/scripts/lib/Tinderbox/Jail.pm 29tinderbox/scripts/lib/Tinderbox/Jail.pm
28tinderbox/scripts/lib/Tinderbox/MakeCache.pm 30tinderbox/scripts/lib/Tinderbox/MakeCache.pm
29tinderbox/scripts/lib/Tinderbox/Port.pm 31tinderbox/scripts/lib/Tinderbox/Port.pm
30tinderbox/scripts/lib/Tinderbox/PortFailPattern.pm 32tinderbox/scripts/lib/Tinderbox/PortFailPattern.pm
31tinderbox/scripts/lib/Tinderbox/PortFailReason.pm 33tinderbox/scripts/lib/Tinderbox/PortFailReason.pm
32tinderbox/scripts/lib/Tinderbox/PortsTree.pm 34tinderbox/scripts/lib/Tinderbox/PortsTree.pm
33tinderbox/scripts/lib/Tinderbox/TinderObject.pm 35tinderbox/scripts/lib/Tinderbox/TinderObject.pm
34tinderbox/scripts/lib/Tinderbox/TinderboxDS.pm 36tinderbox/scripts/lib/Tinderbox/TinderboxDS.pm
@@ -63,34 +65,36 @@ tinderbox/scripts/upgrade/build_ports.ma @@ -63,34 +65,36 @@ tinderbox/scripts/upgrade/build_ports.ma
63tinderbox/scripts/upgrade/build_ports_queue.map 65tinderbox/scripts/upgrade/build_ports_queue.map
64tinderbox/scripts/upgrade/builds.map 66tinderbox/scripts/upgrade/builds.map
65tinderbox/scripts/upgrade/config.map 67tinderbox/scripts/upgrade/config.map
66tinderbox/scripts/upgrade/hooks.map 68tinderbox/scripts/upgrade/hooks.map
67tinderbox/scripts/upgrade/jails.map 69tinderbox/scripts/upgrade/jails.map
68tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.0_to_3.1.sql 70tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.0_to_3.1.sql
69tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.1_to_3.2.sql 71tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.1_to_3.2.sql
70tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.2_to_3.2.1.sql 72tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.2_to_3.2.1.sql
71tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.2.1_to_3.2.2.sql 73tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.2.1_to_3.2.2.sql
72tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.2.2_to_3.2.3.sql 74tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.2.2_to_3.2.3.sql
73tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.2.3_to_3.2.4.sql 75tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.2.3_to_3.2.4.sql
74tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.2.4_to_3.2.5.sql 76tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.2.4_to_3.2.5.sql
75tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.2.5_to_3.2.6.sql 77tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.2.5_to_3.2.6.sql
 78tinderbox/scripts/upgrade/mig_mysql_tinderbox-3.2.6_to_3.3.sql
76tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.0_to_3.1.sql 79tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.0_to_3.1.sql
77tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.1_to_3.2.sql 80tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.1_to_3.2.sql
78tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.2_to_3.2.1.sql 81tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.2_to_3.2.1.sql
79tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.2.1_to_3.2.2.sql 82tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.2.1_to_3.2.2.sql
80tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.2.2_to_3.2.3.sql 83tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.2.2_to_3.2.3.sql
81tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.2.3_to_3.2.4.sql 84tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.2.3_to_3.2.4.sql
82tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.2.4_to_3.2.5.sql 85tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.2.4_to_3.2.5.sql
83tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.2.5_to_3.2.6.sql 86tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.2.5_to_3.2.6.sql
 87tinderbox/scripts/upgrade/mig_pgsql_tinderbox-3.2.6_to_3.3.sql
84tinderbox/scripts/upgrade/order.lst 88tinderbox/scripts/upgrade/order.lst
85tinderbox/scripts/upgrade/user_permissions.map 89tinderbox/scripts/upgrade/user_permissions.map
86${PLIST.WEBUI}tinderbox/scripts/webui/core/Build.php 90${PLIST.WEBUI}tinderbox/scripts/webui/core/Build.php
87${PLIST.WEBUI}tinderbox/scripts/webui/core/BuildGroups.php 91${PLIST.WEBUI}tinderbox/scripts/webui/core/BuildGroups.php
88${PLIST.WEBUI}tinderbox/scripts/webui/core/BuildPortsQueue.php 92${PLIST.WEBUI}tinderbox/scripts/webui/core/BuildPortsQueue.php
89${PLIST.WEBUI}tinderbox/scripts/webui/core/Config.php 93${PLIST.WEBUI}tinderbox/scripts/webui/core/Config.php
90${PLIST.WEBUI}tinderbox/scripts/webui/core/Hooks.php 94${PLIST.WEBUI}tinderbox/scripts/webui/core/Hooks.php
91${PLIST.WEBUI}tinderbox/scripts/webui/core/Jail.php 95${PLIST.WEBUI}tinderbox/scripts/webui/core/Jail.php
92${PLIST.WEBUI}tinderbox/scripts/webui/core/LogfilePattern.php 96${PLIST.WEBUI}tinderbox/scripts/webui/core/LogfilePattern.php
93${PLIST.WEBUI}tinderbox/scripts/webui/core/Port.php 97${PLIST.WEBUI}tinderbox/scripts/webui/core/Port.php
94${PLIST.WEBUI}tinderbox/scripts/webui/core/PortFailPattern.php 98${PLIST.WEBUI}tinderbox/scripts/webui/core/PortFailPattern.php
95${PLIST.WEBUI}tinderbox/scripts/webui/core/PortFailReason.php 99${PLIST.WEBUI}tinderbox/scripts/webui/core/PortFailReason.php
96${PLIST.WEBUI}tinderbox/scripts/webui/core/PortsTree.php 100${PLIST.WEBUI}tinderbox/scripts/webui/core/PortsTree.php

cvs diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/Attic/distinfo (expand / switch to unified diff)

--- pkgsrc/pkgtools/tinderbox-dragonfly/Attic/distinfo 2011/11/14 02:00:19 1.2
+++ pkgsrc/pkgtools/tinderbox-dragonfly/Attic/distinfo 2011/11/20 16:20:24 1.3
@@ -1,32 +1,30 @@ @@ -1,32 +1,30 @@
1$NetBSD: distinfo,v 1.2 2011/11/14 02:00:19 marino Exp $ 1$NetBSD: distinfo,v 1.3 2011/11/20 16:20:24 marino Exp $
2 2
3SHA1 (tinderbox-3.4.tar.gz) = bcabfc7544945b9e832fa573fd13a48005e2a598 3SHA1 (tinderbox-3.4.1.tar.gz) = bfa81429749cb3045887d54a7d83d76632404870
4RMD160 (tinderbox-3.4.tar.gz) = 4783292e3d89f9ded643d57c1f0055b5fc53e3a9 4RMD160 (tinderbox-3.4.1.tar.gz) = 00b74f300c202e45d224b1c6c1bde1d8c21f3e44
5Size (tinderbox-3.4.tar.gz) = 147218 bytes 5Size (tinderbox-3.4.1.tar.gz) = 147755 bytes
6SHA1 (patch-aa) = 13f228c8f4b1e1df590f7e0a9687dd219d6b08a5 6SHA1 (patch-aa) = dbc9dec65413065b2c492a15b70c0ea1928c8798
7SHA1 (patch-ab) = bead83362c0dbba1b71d11a076efb439fe3ac545 7SHA1 (patch-ab) = bead83362c0dbba1b71d11a076efb439fe3ac545
8SHA1 (patch-ac) = 7f62eacc4bea13a4fa36f6d84dab8750ca842366 8SHA1 (patch-ac) = 7f62eacc4bea13a4fa36f6d84dab8750ca842366
9SHA1 (patch-ad) = 12c92ac0aeaf04260151d2e9e305cb6594cc3107 9SHA1 (patch-ad) = 12c92ac0aeaf04260151d2e9e305cb6594cc3107
10SHA1 (patch-ae) = 57443a64d043d6549f19c99b431ea45ad29ba41e 10SHA1 (patch-ae) = 57443a64d043d6549f19c99b431ea45ad29ba41e
11SHA1 (patch-ag) = 9f83f30fab9efe424c197d3f9fe8d7b3c3b924bc 11SHA1 (patch-ai) = b3ece9f6651a3ea2fc762a7818971fe69a18f6ef
12SHA1 (patch-ah) = ddfdb143e7eee5e838b8ab9affbf6992016f05f1 
13SHA1 (patch-ai) = 19ec42335fbc37eed602222b20e8e21a20434baf 
14SHA1 (patch-aj) = 5a6565b6844f6dbd7bb0dcd5aba74d722ae2e61b 12SHA1 (patch-aj) = 5a6565b6844f6dbd7bb0dcd5aba74d722ae2e61b
15SHA1 (patch-ak) = af511026851a0faa893d461c4de44895d0d04410 13SHA1 (patch-ak) = af511026851a0faa893d461c4de44895d0d04410
16SHA1 (patch-al) = 0418a6aacc1ce7071a859bf69e8a29e47b64e197 14SHA1 (patch-al) = 0418a6aacc1ce7071a859bf69e8a29e47b64e197
17SHA1 (patch-am) = 26c9b09e99254d6d12e907876e191822ec3354f2 15SHA1 (patch-am) = 26c9b09e99254d6d12e907876e191822ec3354f2
18SHA1 (patch-an) = f91e604e1487f99374fc3119475ab775cf8257de 16SHA1 (patch-an) = f91e604e1487f99374fc3119475ab775cf8257de
19SHA1 (patch-ao) = b8635fa0fb158855a1f20d29f9251e045e2b9357 17SHA1 (patch-ao) = b8635fa0fb158855a1f20d29f9251e045e2b9357
20SHA1 (patch-ap) = 6dc77ea10efb8bdf26f4fc2330f89b70cba8aaab 18SHA1 (patch-ap) = 6dc77ea10efb8bdf26f4fc2330f89b70cba8aaab
21SHA1 (patch-aq) = 7cc9e2f723d192038d196da94fdfd8c569559458 19SHA1 (patch-aq) = 7cc9e2f723d192038d196da94fdfd8c569559458
22SHA1 (patch-ar) = c57b04957c9ba3a140a623972d5e18e130f8dbc8 20SHA1 (patch-ar) = 7cdf8aa5c0e0b44c9a1b4e7b878d616c251e62d9
23SHA1 (patch-as) = 3cbee34e564ce7b46e17e04422770acee877e0dd 21SHA1 (patch-as) = 4406f887e23b31bc2e1f2e8a55476125ee1bce8a
24SHA1 (patch-at) = f46d54fab4f94e0b6778d26ac84ce933f734c6d5 22SHA1 (patch-at) = f46d54fab4f94e0b6778d26ac84ce933f734c6d5
25SHA1 (patch-au) = 27e654af19184d3a5a9028442b80556417bd45c8 23SHA1 (patch-au) = 27e654af19184d3a5a9028442b80556417bd45c8
26SHA1 (patch-av) = 806b9d4538f13d54b023b9630b74f3b859a65f67 24SHA1 (patch-av) = 806b9d4538f13d54b023b9630b74f3b859a65f67
27SHA1 (patch-aw) = 77446405f7c969d2b7b43e234bd7bcde533ed4a2 25SHA1 (patch-aw) = 73f14c8d3d8df6afd987e5c30dbb658565bf3568
28SHA1 (patch-az) = 91526a66f47d53357703b2739c1384d4012e7c6c 26SHA1 (patch-az) = 91526a66f47d53357703b2739c1384d4012e7c6c
29SHA1 (patch-ba) = 636adea0d3fb22132e2a6d81fd016a9560017aca 27SHA1 (patch-ba) = 636adea0d3fb22132e2a6d81fd016a9560017aca
30SHA1 (patch-bb) = 7a007428deeea2f243cebcc84a42e0c5fbebc9a7 28SHA1 (patch-bb) = 7a007428deeea2f243cebcc84a42e0c5fbebc9a7
31SHA1 (patch-bc) = 4d85687520e2c0d3bd6ab03c4ba9dc3f6ad6c98c 29SHA1 (patch-bc) = 4d85687520e2c0d3bd6ab03c4ba9dc3f6ad6c98c
32SHA1 (patch-be) = f5e0e9a00de8d1f8b16d36f7cbe23ecc3daee47d 30SHA1 (patch-be) = f5e0e9a00de8d1f8b16d36f7cbe23ecc3daee47d

cvs diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-aa (expand / switch to unified diff)

--- pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-aa 2011/11/14 02:00:20 1.2
+++ pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-aa 2011/11/20 16:20:24 1.3
@@ -1,19 +1,19 @@ @@ -1,19 +1,19 @@
1$NetBSD: patch-aa,v 1.2 2011/11/14 02:00:20 marino Exp $ 1$NetBSD: patch-aa,v 1.3 2011/11/20 16:20:24 marino Exp $
2 2
3--- ../FreeBSD/lib/tc_command.sh 2011-10-16 00:52:55.000000000 +0000 3--- ../FreeBSD/lib/tc_command.sh 2011-11-20 13:11:37.088510000 +0000
4+++ lib/tc_command.sh 4+++ lib/tc_command.sh
5@@ -27,21 +27,46 @@ 5@@ -27,21 +27,46 @@
6 # $MCom: portstools/tinderbox/lib/tc_command.sh,v 1.101.2.45 2011/10/17 01:01:23 marcus Exp $ 6 # $MCom: portstools/tinderbox/lib/tc_command.sh,v 1.101.2.48 2011/11/15 07:04:35 marcus Exp $
7 # 7 #
8  8
9-export _defaultUpdateHost="cvsup18.FreeBSD.org" 9-export _defaultUpdateHost="cvsup18.FreeBSD.org"
10+export _defaultUpdateHost="cvsup.netbsd.se" 10+export _defaultUpdateHost="cvsup.netbsd.se"
11 export _defaultUpdateType="CSUP" 11 export _defaultUpdateType="CSUP"
12+export _defaultDragonHost="http://mirror.physik-pool.tu-berlin.de/DragonFlyBSD/dflysnap" 12+export _defaultDragonHost="http://mirror.physik-pool.tu-berlin.de/DragonFlyBSD/dflysnap"
13+export _defaultDragonType="RELEASE" 13+export _defaultDragonType="RELEASE"
14+export _defaultGitSrcHost="koan.bondconsult.net" 14+export _defaultGitSrcHost="koan.bondconsult.net"
15  15
16 #--------------------------------------------------------------------------- 16 #---------------------------------------------------------------------------
17 # Generic routines 17 # Generic routines
18 #--------------------------------------------------------------------------- 18 #---------------------------------------------------------------------------
19+commandTreeChecks () { 19+commandTreeChecks () {
@@ -188,178 +188,208 @@ $NetBSD: patch-aa,v 1.2 2011/11/14 02:00 @@ -188,178 +188,208 @@ $NetBSD: patch-aa,v 1.2 2011/11/14 02:00
188- echo "${2}: cleaning out old directories" 188- echo "${2}: cleaning out old directories"
189- cleanDirs ${2} ${treeDir} 189- cleanDirs ${2} ${treeDir}
190- fi 190- fi
191- if [ ! -d ${treeDir} ]; then 191- if [ ! -d ${treeDir} ]; then
192- echo "${2}: creating top-level directory" 192- echo "${2}: creating top-level directory"
193- mkdir -p ${treeDir} >/dev/null 2>&1 193- mkdir -p ${treeDir} >/dev/null 2>&1
194+ updateCmd=/usr/pkg/bin/csup 194+ updateCmd=/usr/pkg/bin/csup
195+ commandTreeChecks ${updateCmd} ${2} ${3} 195+ commandTreeChecks ${updateCmd} ${2} ${3}
196+ if [ "$?" -eq "1" ]; then 196+ if [ "$?" -eq "1" ]; then
197+ exit 1 197+ exit 1
198 fi 198 fi
199  199
200 ( echo "*default host=${4}" 200 ( echo "*default host=${4}"
201@@ -160,6 +190,45 @@ generateUpdateCode () { 201@@ -159,49 +189,42 @@ generateUpdateCode () {
 202 ) > ${treeDir}/update.sh
202 chmod +x ${treeDir}/update.sh 203 chmod +x ${treeDir}/update.sh
203 ;; 204 ;;
 205- "SVN")
 206- if [ -z "${8}" ]; then
 207- echo "ERROR: ${1} ${2}: no protocol specified for ${3}"
 208- exit 1
 209- fi
204  210
 211- if [ -z "${9}" ]; then
 212- echo "ERROR: ${1} ${2}: no host directory specified for ${3}"
205+ "GIT") # ONLY USED FOR RETREIVING DRAGONFLY SOURCE FOR BUILDING JAIL 213+ "GIT") # ONLY USED FOR RETREIVING DRAGONFLY SOURCE FOR BUILDING JAIL
206+ if [ -z "${5}" -o "${5}" = "UNUSED" ]; then 214+ if [ -z "${5}" -o "${5}" = "UNUSED" ]; then
207+ echo "ERROR: ${1} ${2}: no git branch specified for ${3}" 215+ echo "ERROR: ${1} ${2}: no git branch specified for ${3}"
208+ exit 1 216 exit 1
209+ fi 217 fi
210+ 218
 219- updateCmd="/usr/local/bin/svn"
 220-
 221- if [ ! -x "${updateCmd}" ]; then
 222- echo "ERROR: ${2} ${3}: ${updateCmd} missing"
211+ updateCmd=/usr/pkg/bin/git 223+ updateCmd=/usr/pkg/bin/git
212+ commandTreeChecks ${updateCmd} ${2} ${3} 224+ commandTreeChecks ${updateCmd} ${2} ${3}
213+ if [ "$?" -eq "1" ]; then 225+ if [ "$?" -eq "1" ]; then
214+ exit 1 226 exit 1
215+ fi 227 fi
216+ 228
217+ ( echo "#!/bin/sh" 229- if [ -d ${treeDir} ]; then
 230- echo "${2}: cleaning out old directories"
 231- cleanDirs ${2} ${treeDir}
 232- fi
 233-
 234- if [ ! -d ${treeDir} ]; then
 235- echo "${2}: creating top-level directory"
 236- mkdir -p ${treeDir} >/dev/null 2>&1
 237- fi
 238-
 239- case ${1} in
 240- "jail") treeSubDir="src"
 241- ;;
 242- "portstree") treeSubDir="ports"
 243- ;;
 244- esac
 245-
 246 ( echo "#!/bin/sh"
 247- echo "cd ${treeDir}"
 248- echo "if [ ! -d ${treeDir}/${treeSubDir} ]; then"
 249- echo "${updateCmd} co ${8}://${4}/${9} ${treeSubDir}"
218+ echo "echo 'SERVER: ${4}'" 250+ echo "echo 'SERVER: ${4}'"
219+ echo "echo 'BRANCH: ${5}'" 251+ echo "echo 'BRANCH: ${5}'"
220+ echo "if [ -d ${treeDir}/src ]; then" 252+ echo "if [ -d ${treeDir}/src ]; then"
221+ echo " cd ${treeDir}/src" 253+ echo " cd ${treeDir}/src"
222+ echo "else" 254 echo "else"
 255- echo "cd ${treeDir}/${treeSubDir}"
 256- echo "${updateCmd} up"
223+ echo " echo 'Creating shallow source repository.'" 257+ echo " echo 'Creating shallow source repository.'"
224+ echo " mkdir ${treeDir}/src" 258+ echo " mkdir ${treeDir}/src"
225+ echo " cd ${treeDir}/src" 259+ echo " cd ${treeDir}/src"
226+ echo " mkdir ../tmp ../obj" 260+ echo " mkdir ../tmp ../obj"
227+ echo " ${updateCmd} init" 261+ echo " ${updateCmd} init"
228+ echo " ${updateCmd} remote add origin git://${4}/dragonfly.git" 262+ echo " ${updateCmd} remote add origin git://${4}/dragonfly.git"
229+ echo " ${updateCmd} fetch --depth=1 origin" 263+ echo " ${updateCmd} fetch --depth=1 origin"
230+ echo " ${updateCmd} branch master origin/master" 264+ echo " ${updateCmd} branch master origin/master"
231+ echo " echo 'Repository creation complete.'" 265+ echo " echo 'Repository creation complete.'"
232+ echo "fi" 266 echo "fi"
233+ echo "BRANCH=\`${updateCmd} branch | /usr/bin/grep -w ${5}\`" 267+ echo "BRANCH=\`${updateCmd} branch | /usr/bin/grep -w ${5}\`"
234+ echo "if [ \"\${BRANCH}\" = \"\" ]; then" 268+ echo "if [ \"\${BRANCH}\" = \"\" ]; then"
235+ echo " ${updateCmd} branch ${5} origin/${5}" 269+ echo " ${updateCmd} branch ${5} origin/${5}"
236+ echo "fi" 270+ echo "fi"
237+ echo "echo 'Ready to pull updates from branch.'" 271+ echo "echo 'Ready to pull updates from branch.'"
238+ echo "${updateCmd} checkout ${5}" 272+ echo "${updateCmd} checkout ${5}"
239+ echo "${updateCmd} pull" 273+ echo "${updateCmd} pull"
240+ ) > ${treeDir}/update.sh 274 ) > ${treeDir}/update.sh
241+ chmod +x ${treeDir}/update.sh 275 chmod +x ${treeDir}/update.sh
242+ ;; 276 ;;
243+ 277@@ -223,6 +246,15 @@ setupDefaults () {
244 *) echo "ERROR: ${1} ${2}: unknown update type: ${3}" 
245 exit 1;; 
246  
247@@ -177,6 +246,15 @@ setupDefaults () { 
248 if [ -z "${defaultUpdateType}" ]; then 278 if [ -z "${defaultUpdateType}" ]; then
249 export defaultUpdateType=${_defaultUpdateType} 279 export defaultUpdateType=${_defaultUpdateType}
250 fi 280 fi
251+ if [ -z "${defaultDragonHost}" ]; then 281+ if [ -z "${defaultDragonHost}" ]; then
252+ export defaultDragonHost=${_defaultDragonHost} 282+ export defaultDragonHost=${_defaultDragonHost}
253+ fi 283+ fi
254+ if [ -z "${defaultDragonfType}" ]; then 284+ if [ -z "${defaultDragonfType}" ]; then
255+ export defaultDragonType=${_defaultDragonType} 285+ export defaultDragonType=${_defaultDragonType}
256+ fi 286+ fi
257+ if [ -z "${defaultGitSrcHost}" ]; then 287+ if [ -z "${defaultGitSrcHost}" ]; then
258+ export defaultGitSrcHost=${_defaultGitSrcHost} 288+ export defaultGitSrcHost=${_defaultGitSrcHost}
259+ fi 289+ fi
260 } 290 }
261  291
262 tcExists () { 292 tcExists () {
263@@ -211,16 +289,21 @@ updateTree () { 293@@ -257,16 +289,21 @@ updateTree () {
264  294
265 echo "${name}: updating ${what} with ${updateCmd}" 295 echo "${name}: updating ${what} with ${updateCmd}"
266  296
267+ logpipe=/tmp/tbox_logpipe 297+ logpipe=/tmp/tbox_logpipe
268+ mkfifo ${logpipe} 298+ mkfifo ${logpipe}
269+ tee ${dir}/update.log < ${logpipe} & 299+ tee ${dir}/update.log < ${logpipe} &
270 if [ "${updateCmd}" = "USER" ]; then 300 if [ "${updateCmd}" = "USER" ]; then
271- eval ${dir}/update.sh ${name} > ${dir}/update.log 2>&1 301- eval ${dir}/update.sh ${name} > ${dir}/update.log 2>&1
272+ ${dir}/update.sh ${name} > ${logpipe} 302+ ${dir}/update.sh ${name} > ${logpipe}
273 else 303 else
274- eval ${dir}/update.sh > ${dir}/update.log 2>&1 304- eval ${dir}/update.sh > ${dir}/update.log 2>&1
275+ ${dir}/update.sh > ${logpipe} 305+ ${dir}/update.sh > ${logpipe}
276 fi 306 fi
277 if [ $? -ne 0 ]; then 307 if [ $? -ne 0 ]; then
278+ rm ${logpipe} 308+ rm ${logpipe}
279 echo "updateTree: ${what} ${name}: update failed" 309 echo "updateTree: ${what} ${name}: update failed"
280 echo " see ${dir}/update.log for more details" 310 echo " see ${dir}/update.log for more details"
281 return 1 311 return 1
282 fi 312 fi
283+ rm ${logpipe} 313+ rm ${logpipe}
284 } 314 }
285  315
286 #--------------------------------------------------------------------------- 316 #---------------------------------------------------------------------------
287@@ -228,8 +311,8 @@ updateTree () { 317@@ -274,8 +311,8 @@ updateTree () {
288 #--------------------------------------------------------------------------- 318 #---------------------------------------------------------------------------
289  319
290 Setup () { 320 Setup () {
291- MAN_PREREQS="lang/perl5.[81]*" 321- MAN_PREREQS="lang/perl5.[81]*"
292- OPT_PREREQS="lang/php[45] databases/pear-MDB2 www/php[45]-session archivers/p5-Compress-Bzip2" 322- OPT_PREREQS="lang/php[45] databases/pear-MDB2 www/php[45]-session archivers/p5-Compress-Bzip2"
293+ MAN_PREREQS="perl" 323+ MAN_PREREQS="perl"
294+ OPT_PREREQS="php php*-pear-MDB2 p5-Compress-Bzip2" 324+ OPT_PREREQS="php php*-pear-MDB2 p5-Compress-Bzip2"
295 PREF_FILES="tinderbox.ph" 325 PREF_FILES="tinderbox.ph"
296 README="$(tinderLoc scripts README)" 326 README="$(tinderLoc scripts README)"
297 TINDERBOX_URL="http://tinderbox.marcuscom.com/" 327 TINDERBOX_URL="http://tinderbox.marcuscom.com/"
298@@ -509,7 +592,7 @@ Upgrade () { 328@@ -555,7 +592,7 @@ Upgrade () {
299 for jail in ${jails}; do 329 for jail in ${jails}; do
300 f=$(tinderLoc jail ${jail}) 330 f=$(tinderLoc jail ${jail})
301 ucmd=$(${tc} getUpdateCmd -j ${jail} 2>/dev/null) 331 ucmd=$(${tc} getUpdateCmd -j ${jail} 2>/dev/null)
302- if [ x"${ucmd}" != x"CVSUP" -a x"${ucmd}" != x"CSUP" -a x"${ucmd}" != x"NONE" ]; then 332- if [ x"${ucmd}" != x"CVSUP" -a x"${ucmd}" != x"CSUP" -a x"${ucmd}" != x"NONE" ]; then
303+ if [ x"${ucmd}" != x"CSUP" -a x"${ucmd}" != x"NONE" ]; then 333+ if [ x"${ucmd}" != x"CSUP" -a x"${ucmd}" != x"NONE" ]; then
304 if [ -f "${ucmd}" ]; then 334 if [ -f "${ucmd}" ]; then
305 mv -f "${ucmd}" "${f}/update.sh" 335 mv -f "${ucmd}" "${f}/update.sh"
306 chmod +x "${f}/update.sh" 336 chmod +x "${f}/update.sh"
307@@ -524,11 +607,8 @@ Upgrade () { 337@@ -570,11 +607,8 @@ Upgrade () {
308 tinderEcho "WARN: You must manually set the update command for ${jail} to \"USER\" using the query ${query}." 338 tinderEcho "WARN: You must manually set the update command for ${jail} to \"USER\" using the query ${query}."
309 fi 339 fi
310 fi 340 fi
311- elif [ x"${ucmd}" = x"CVSUP" -o x"${ucmd}" = x"CSUP" ]; then 341- elif [ x"${ucmd}" = x"CVSUP" -o x"${ucmd}" = x"CSUP" ]; then
312- updateCmd="/usr/bin/csup" 342- updateCmd="/usr/bin/csup"
313- if [ x"${ucmd}" = x"CVSUP" ]; then 343- if [ x"${ucmd}" = x"CVSUP" ]; then
314- updateCmd="/usr/local/bin/cvsup" 344- updateCmd="/usr/local/bin/cvsup"
315- fi 345- fi
316+ elif [ x"${ucmd}" = x"CSUP" ]; then 346+ elif [ x"${ucmd}" = x"CSUP" ]; then
317+ updateCmd="/usr/pkg/bin/csup" 347+ updateCmd="/usr/pkg/bin/csup"
318 ( echo "#!/bin/sh" 348 ( echo "#!/bin/sh"
319 echo "${updateCmd} ${f}/supfile" 349 echo "${updateCmd} ${f}/supfile"
320 ) > ${f}/update.sh 350 ) > ${f}/update.sh
321@@ -542,7 +622,7 @@ Upgrade () { 351@@ -588,7 +622,7 @@ Upgrade () {
322 for portstree in ${portstrees}; do 352 for portstree in ${portstrees}; do
323 f=$(tinderLoc portstree ${portstree}) 353 f=$(tinderLoc portstree ${portstree})
324 ucmd=$(${tc} getUpdateCmd -p ${portstree} 2>/dev/null) 354 ucmd=$(${tc} getUpdateCmd -p ${portstree} 2>/dev/null)
325- if [ x"${ucmd}" != x"CVSUP" -a x"${ucmd}" != x"CSUP" -a x"${ucmd}" != x"NONE" ]; then 355- if [ x"${ucmd}" != x"CVSUP" -a x"${ucmd}" != x"CSUP" -a x"${ucmd}" != x"NONE" ]; then
326+ if [ x"${ucmd}" != x"CSUP" -a x"${ucmd}" != x"NONE" ]; then 356+ if [ x"${ucmd}" != x"CSUP" -a x"${ucmd}" != x"NONE" ]; then
327 if [ -f "${ucmd}" ]; then 357 if [ -f "${ucmd}" ]; then
328 mv -f "${ucmd}" "${f}/update.sh" 358 mv -f "${ucmd}" "${f}/update.sh"
329 chmod +x "${f}/update.sh" 359 chmod +x "${f}/update.sh"
330@@ -557,17 +637,14 @@ Upgrade () { 360@@ -603,17 +637,14 @@ Upgrade () {
331 tinderEcho "WARN: You must manually set the update command for ${portstree} to \"USER\" using the query ${query}." 361 tinderEcho "WARN: You must manually set the update command for ${portstree} to \"USER\" using the query ${query}."
332 fi 362 fi
333 fi 363 fi
334- elif [ x"${ucmd}" = x"CVSUP" -o x"${ucmd}" = "CSUP" ]; then 364- elif [ x"${ucmd}" = x"CVSUP" -o x"${ucmd}" = "CSUP" ]; then
335- updateCmd="/usr/bin/csup" 365- updateCmd="/usr/bin/csup"
336- if [ x"${ucmd}" = x"CVSUP" ]; then 366- if [ x"${ucmd}" = x"CVSUP" ]; then
337- updateCmd="/usr/local/bin/cvsup" 367- updateCmd="/usr/local/bin/cvsup"
338- fi 368- fi
339+ elif [ x"${ucmd}" = "CSUP" ]; then 369+ elif [ x"${ucmd}" = "CSUP" ]; then
340+ updateCmd="/usr/pkg/bin/csup" 370+ updateCmd="/usr/pkg/bin/csup"
341 ( echo "#!/bin/sh" 371 ( echo "#!/bin/sh"
342 echo "${updateCmd} ${f}/supfile" 372 echo "${updateCmd} ${f}/supfile"
343 ) > ${f}/update.sh 373 ) > ${f}/update.sh
344 chmod +x ${f}/update.sh 374 chmod +x ${f}/update.sh
345- if [ -f "${f}/ports-supfile" ]; then 375- if [ -f "${f}/ports-supfile" ]; then
346- mv -f "${f}/ports-supfile" "${f}/supfile" 376- mv -f "${f}/ports-supfile" "${f}/supfile"
347+ if [ -f "${f}/pkgsrc-supfile" ]; then 377+ if [ -f "${f}/pkgsrc-supfile" ]; then
348+ mv -f "${f}/pkgsrc-supfile" "${f}/supfile" 378+ mv -f "${f}/pkgsrc-supfile" "${f}/supfile"
349 fi 379 fi
350 fi 380 fi
351 done 381 done
352@@ -741,38 +818,55 @@ buildJail () { 382@@ -787,38 +818,55 @@ buildJail () {
353 return 1 383 return 1
354 fi 384 fi
355  385
356- if [ "${updateCmd}" = "LFTP" ]; then 386- if [ "${updateCmd}" = "LFTP" ]; then
357- export DESTDIR=${J_TMPDIR} 387- export DESTDIR=${J_TMPDIR}
358- cd ${jailBase}/sets/base && yes | sh ./install.sh > ${jailBase}/world.tmp 2>&1 388- cd ${jailBase}/sets/base && yes | sh ./install.sh > ${jailBase}/world.tmp 2>&1
359+ if [ "${updateCmd}" = "RELEASE" -o "${updateCmd}" = "SNAPSHOT" ]; then 389+ if [ "${updateCmd}" = "RELEASE" -o "${updateCmd}" = "SNAPSHOT" ]; then
360+ iso_image=`ls ${jailBase}/sets` 390+ iso_image=`ls ${jailBase}/sets`
361+ /usr/bin/tar -xf ${jailBase}/sets/${iso_image} -C ${J_TMPDIR} > ${jailBase}/world.tmp 2>&1 391+ /usr/bin/tar -xf ${jailBase}/sets/${iso_image} -C ${J_TMPDIR} > ${jailBase}/world.tmp 2>&1
362 rc=$? 392 rc=$?
363- if [ ${rc} -eq 0 -a -d "${jailBase}/sets/lib32" ]; then 393- if [ ${rc} -eq 0 -a -d "${jailBase}/sets/lib32" ]; then
364- cd ${jailBase}/sets/lib32 && yes | sh ./install.sh >> ${jailBase}/world.tmp 2>&1 394- cd ${jailBase}/sets/lib32 && yes | sh ./install.sh >> ${jailBase}/world.tmp 2>&1
365- rc=$? 395- rc=$?
@@ -412,38 +442,39 @@ $NetBSD: patch-aa,v 1.2 2011/11/14 02:00 @@ -412,38 +442,39 @@ $NetBSD: patch-aa,v 1.2 2011/11/14 02:00
412  442
413 if [ -n "${NO_JAIL_JOBS}" ]; then 443 if [ -n "${NO_JAIL_JOBS}" ]; then
414 factor=1 444 factor=1
415 fi 445 fi
416  446
417- cd ${SRCBASE} && env DESTDIR=${J_TMPDIR} ${crossEnv} \ 447- cd ${SRCBASE} && env DESTDIR=${J_TMPDIR} ${crossEnv} \
418- make -j${factor} -DNO_CLEAN world > ${jailBase}/world.tmp 2>&1 448- make -j${factor} -DNO_CLEAN world > ${jailBase}/world.tmp 2>&1
419+ cd ${SRCBASE} && env DESTDIR=${J_TMPDIR} \ 449+ cd ${SRCBASE} && env DESTDIR=${J_TMPDIR} \
420+ make -DNO_GCC41 -DNO_GAMES -DNOPROFILE -j${factor} world \ 450+ make -DNO_GCC41 -DNO_GAMES -DNOPROFILE -j${factor} world \
421+ > ${jailBase}/world.tmp 2>&1 451+ > ${jailBase}/world.tmp 2>&1
422 rc=$? 452 rc=$?
423 execute_hook "postJailBuild" "JAIL=${jailName} DESTDIR=${J_TMPDIR} JAIL_ARCH=${jailArch} MY_ARCH=${myArch} JAIL_OBJDIR=${JAIL_OBJDIR} SRCBASE=${SRCBASE} PB=${pb} RC=${rc}" 453 execute_hook "postJailBuild" "JAIL=${jailName} DESTDIR=${J_TMPDIR} JAIL_ARCH=${jailArch} MY_ARCH=${myArch} JAIL_OBJDIR=${JAIL_OBJDIR} SRCBASE=${SRCBASE} PB=${pb} RC=${rc}"
424 if [ ${rc} -ne 0 ]; then 454 if [ ${rc} -ne 0 ]; then
425@@ -783,21 +877,80 @@ buildJail () { 455@@ -829,21 +877,80 @@ buildJail () {
426 # Make a complete distribution 456 # Make a complete distribution
427 echo "${jailName}: making distribution" 457 echo "${jailName}: making distribution"
428  458
429- # determine if we're cross-building world 459- # determine if we're cross-building world
430- crossEnv="" 460- crossEnv=""
431- if [ "${jailArch}" != "${myArch}" ]; then 461- if [ "${jailArch}" != "${myArch}" ]; then
432- crossEnv="TARGET_ARCH=${jailArch} MACHINE_ARCH=${jailArch} MAKEOBJDIRPREFIX=${J_OBJDIR}/${jailArch} MACHINE=${jailArch}" 462- crossEnv="TARGET_ARCH=${jailArch}"
433- fi 463- fi
434- cd ${SRCBASE}/etc && env DESTDIR=${J_TMPDIR} ${crossEnv} \ 464- cd ${SRCBASE} && env DESTDIR=${J_TMPDIR} ${crossEnv} \
 465- make distribution > ${jailBase}/distribution.tmp 2>&1
435+ cd ${SRCBASE}/etc && env DESTDIR=${J_TMPDIR} \ 466+ cd ${SRCBASE}/etc && env DESTDIR=${J_TMPDIR} \
436 make -m ${J_TMPDIR}/usr/share/mk distribution > ${jailBase}/distribution.tmp 2>&1 467+ make -m ${J_TMPDIR}/usr/share/mk distribution > ${jailBase}/distribution.tmp 2>&1
437 if [ $? -ne 0 ]; then 468 if [ $? -ne 0 ]; then
438 echo "ERROR: distribution failed - see ${jailBase}/distribution.tmp" 469 echo "ERROR: distribution failed - see ${jailBase}/distribution.tmp"
439 buildJailCleanup 1 ${jailName} ${J_SRCDIR} 470 buildJailCleanup 1 ${jailName} ${J_SRCDIR}
440+ return 1 471+ return 1
441 fi 472 fi
442+ 473+
443+ # Bootstrap pkgsrc tools using host machine's pkgsrc for source files 474+ # Bootstrap pkgsrc tools using host machine's pkgsrc for source files
444+ echo "${jailName}: bootstrapping pkgsrc basic tools" 475+ echo "${jailName}: bootstrapping pkgsrc basic tools"
445+ 476+
446+ CYCLE="devel/bmake \ 477+ CYCLE="devel/bmake \
447+ sysutils/install-sh \ 478+ sysutils/install-sh \
448+ pkgtools/bootstrap-mk-files \ 479+ pkgtools/bootstrap-mk-files \
449+ pkgtools/libnbcompat \ 480+ pkgtools/libnbcompat \
@@ -500,179 +531,200 @@ $NetBSD: patch-aa,v 1.2 2011/11/14 02:00 @@ -500,179 +531,200 @@ $NetBSD: patch-aa,v 1.2 2011/11/14 02:00
500+ execute_hook "postJailBuild" "JAIL=${jailName} DESTDIR=${J_TMPDIR} JAIL_ARCH=${jailArch} MY_ARCH=${myArch} JAIL_OBJDIR=${JAIL_OBJDIR} SRCBASE=${SRCBASE} PB=${pb} RC=${rc}" 531+ execute_hook "postJailBuild" "JAIL=${jailName} DESTDIR=${J_TMPDIR} JAIL_ARCH=${jailArch} MY_ARCH=${myArch} JAIL_OBJDIR=${JAIL_OBJDIR} SRCBASE=${SRCBASE} PB=${pb} RC=${rc}"
501+ if [ $? -ne 0 ]; then 532+ if [ $? -ne 0 ]; then
502+ echo "buildJail: Terminating Jail build since hook postJailBuild failed." 533+ echo "buildJail: Terminating Jail build since hook postJailBuild failed."
503+ buildJailCleanup 1 ${jailName} ${J_SRCDIR} 534+ buildJailCleanup 1 ${jailName} ${J_SRCDIR}
504+ return 1 535+ return 1
505+ fi 536+ fi
506 fi 537 fi
507  538
508 # Various hacks to keep the ports building environment happy 539 # Various hacks to keep the ports building environment happy
509- touch -f ${J_TMPDIR}/etc/fstab 540- touch -f ${J_TMPDIR}/etc/fstab
510  541
511 MTREE_DIR=${SRCBASE}/etc/mtree 542 MTREE_DIR=${SRCBASE}/etc/mtree
512 mtree -deU -f ${MTREE_DIR}/BSD.root.dist \ 543 mtree -deU -f ${MTREE_DIR}/BSD.root.dist \
513@@ -809,11 +962,8 @@ buildJail () { 544@@ -855,11 +962,8 @@ buildJail () {
514 mtree -deU -f ${MTREE_DIR}/BSD.local.dist \ 545 mtree -deU -f ${MTREE_DIR}/BSD.local.dist \
515 -p ${J_TMPDIR}/usr/local >/dev/null 2>&1 546 -p ${J_TMPDIR}/usr/local >/dev/null 2>&1
516  547
517- date '+%Y%m%d' > ${J_TMPDIR}/var/db/port.mkversion 548- date '+%Y%m%d' > ${J_TMPDIR}/var/db/port.mkversion
518 mkdir -p ${J_TMPDIR}/var/run 549 mkdir -p ${J_TMPDIR}/var/run
519  550
520- rm -f ${J_TMPDIR}/usr/lib/aout/lib*_p.a 551- rm -f ${J_TMPDIR}/usr/lib/aout/lib*_p.a
521- 552-
522 # Create the jail tarball 553 # Create the jail tarball
523 echo "${jailName}: creating tarball" 554 echo "${jailName}: creating tarball"
524 jailDir=$(tinderLoc jail ${jailName}) 555 jailDir=$(tinderLoc jail ${jailName})
525@@ -827,7 +977,7 @@ buildJail () { 556@@ -873,7 +977,7 @@ buildJail () {
526 fi 557 fi
527  558
528 # Move new logfiles into place 559 # Move new logfiles into place
529- for logfile in world distribution 560- for logfile in world distribution
530+ for logfile in world distribution pkgsrc 561+ for logfile in world distribution pkgsrc
531 do 562 do
532 rm -f ${jailBase}/${logfile}.log 563 rm -f ${jailBase}/${logfile}.log
533 mv -f ${jailBase}/${logfile}.tmp ${jailBase}/${logfile}.log 2>/dev/null 564 mv -f ${jailBase}/${logfile}.tmp ${jailBase}/${logfile}.log 2>/dev/null
534@@ -883,22 +1033,22 @@ createJail () { 565@@ -927,29 +1031,25 @@ createJail () {
 566 jailArch=$(uname -m)
 567 mountSrc=""
535 init=1 568 init=1
 569- protocol=""
 570- updateHostDirectory=""
536  571
537 setupDefaults 572 setupDefaults
538- updateHost=${defaultUpdateHost} 573- updateHost=${defaultUpdateHost}
539- updateType=${defaultUpdateType} 574- updateType=${defaultUpdateType}
540+ updateHostISO=${defaultDragonHost} 575+ updateHostISO=${defaultDragonHost}
541+ updateHostSRC=${defaultGitSrcHost} 576+ updateHostSRC=${defaultGitSrcHost}
542+ updateType=${defaultDragonType} 577+ updateType=${defaultDragonType}
543  578
544 # argument handling 579 # argument handling
545- while getopts a:d:j:m:t:u:CH:I arg >/dev/null 2>&1 580- while getopts a:d:j:m:t:u:CD:H:IP: arg >/dev/null 2>&1
546+ while getopts d:j:m:t:u:H:I arg >/dev/null 2>&1 581+ while getopts d:j:m:t:u:H:I arg >/dev/null 2>&1
547 do 582 do
548 case "${arg}" in 583 case "${arg}" in
549  584
550- a) jailArch="${OPTARG}";; 585- a) jailArch="${OPTARG}";;
551 d) descr="${OPTARG}";; 586 d) descr="${OPTARG}";;
552 j) jailName="${OPTARG}";; 587 j) jailName="${OPTARG}";;
553 m) mountSrc="${OPTARG}";; 588 m) mountSrc="${OPTARG}";;
554 t) updateTag="${OPTARG}";; 589 t) updateTag="${OPTARG}";;
555 u) updateType="${OPTARG}";; 590 u) updateType="${OPTARG}";;
556- C) updateCompress=1;; 591- C) updateCompress=1;;
 592- D) updateHostDirectory="${OPTARG}";;
557- H) updateHost="${OPTARG}";; 593- H) updateHost="${OPTARG}";;
558+ H) updateHostISO="${OPTARG}" 594+ H) updateHostISO="${OPTARG}"
559+ updateHostSRC="${OPTTAG}";; 595+ updateHostSRC="${OPTTAG}";;
560 I) init=0;; 596 I) init=0;;
 597- P) protocol="${OPTARG}";;
561 ?) return 1;; 598 ?) return 1;;
562  599
563@@ -913,7 +1063,7 @@ createJail () { 600 esac
 601@@ -963,7 +1063,7 @@ createJail () {
564  602
565 valid=$(echo ${jailName} | awk '{if (/^[[:digit:]]/) {print;}}') 603 valid=$(echo ${jailName} | awk '{if (/^[[:digit:]]/) {print;}}')
566 if [ -z "${valid}" ]; then 604 if [ -z "${valid}" ]; then
567- echo "createJail: jail name must begin with a FreeBSD major version" 605- echo "createJail: jail name must begin with a FreeBSD major version"
568+ echo "createJail: jail name must begin with a DragonFly BSD major version" 606+ echo "createJail: jail name must begin with a DragonFly BSD major version"
569 return 1 607 return 1
570 fi 608 fi
571  609
572@@ -927,6 +1077,17 @@ createJail () { 610@@ -977,10 +1077,20 @@ createJail () {
573 return 1 611 return 1
574 fi 612 fi
575  613
576+ if [ "${updateType}" = "CSUP" ]; then 614+ if [ "${updateType}" = "CSUP" ]; then
577+ echo "createJail: CSUP type cannot be used for DragonFly sources" 615+ echo "createJail: CSUP type cannot be used for DragonFly sources"
578+ return 1 616+ return 1
579+ fi 617+ fi
580+ 618+
581+ updateHost=${updateHostISO} 619+ updateHost=${updateHostISO}
582+ if [ "${updateType}" = "GIT" ]; then 620+ if [ "${updateType}" = "GIT" ]; then
583+ updateHost=${updateHostSRC} 621+ updateHost=${updateHostSRC}
584+ fi 622+ fi
585+ 623+
586+ 624+
587 echo "${jailName}: initializing tree" 625 echo "${jailName}: initializing tree"
588 generateUpdateCode jail ${jailName} ${updateType} ${updateHost} \ 626 generateUpdateCode jail ${jailName} ${updateType} ${updateHost} \
589 ${updateTag} ${updateCompress} ${jailArch} 627- ${updateTag} ${updateCompress} ${jailArch} \
590@@ -1040,20 +1201,21 @@ createPortsTree () { 628- ${protocol} ${updateHostDirectory}
 629+ ${updateTag} ${updateCompress} ${jailArch}
 630
 631 echo -n "${jailName}: adding to datastore... "
 632
 633@@ -1091,28 +1201,25 @@ createPortsTree () {
591 init=1 634 init=1
592 mountSrc="" 635 mountSrc=""
593 portsTreeName="" 636 portsTreeName=""
 637- protocol=""
 638- updateHostDirectory=""
594+ cvsTag="." 639+ cvsTag="."
595  640
596 setupDefaults 641 setupDefaults
597 updateHost=${defaultUpdateHost} 642 updateHost=${defaultUpdateHost}
598 updateType=${defaultUpdateType} 643 updateType=${defaultUpdateType}
599  644
600 # argument handling 645 # argument handling
601- while getopts d:m:p:u:w:CH:I arg >/dev/null 2>&1 646- while getopts d:m:p:u:w:CD:H:IP: arg >/dev/null 2>&1
602+ while getopts d:m:t:p:w:CH:I arg >/dev/null 2>&1 647+ while getopts d:m:t:p:w:CH:I arg >/dev/null 2>&1
603 do 648 do
604 case "${arg}" in 649 case "${arg}" in
605  650
606 d) descr="${OPTARG}";; 651 d) descr="${OPTARG}";;
607 m) mountSrc="${OPTARG}";; 652 m) mountSrc="${OPTARG}";;
608 p) portsTreeName="${OPTARG}";; 653 p) portsTreeName="${OPTARG}";;
609- u) updateType="${OPTARG}";; 654- u) updateType="${OPTARG}";;
610+ t) cvsTag="${OPTARG}";; 655+ t) cvsTag="${OPTARG}";;
611 w) cvswebUrl="${OPTARG}";; 656 w) cvswebUrl="${OPTARG}";;
612 C) updateCompress=1;; 657 C) updateCompress=1;;
 658- D) updateHostDirectory="${OPTARG}";;
613 H) updateHost="${OPTARG}";; 659 H) updateHost="${OPTARG}";;
614@@ -1079,9 +1241,15 @@ createPortsTree () { 660 I) init=0;;
 661- P) protocol="${OPTARG}";;
 662 ?) return 1;;
 663
 664 esac
 665@@ -1134,10 +1241,15 @@ createPortsTree () {
615 return 1 666 return 1
616 fi 667 fi
617  668
618+ if [ "${updateType}" != "CSUP" ]; then 669+ if [ "${updateType}" != "CSUP" ]; then
619+ echo "createPortsTree: The defaultUpdateType variable in env was changed to ${updateType}" 670+ echo "createPortsTree: The defaultUpdateType variable in env was changed to ${updateType}"
620+ echo "Please change it back to 'CSUP', which is the only method supported to get pkgsrc" 671+ echo "Please change it back to 'CSUP', which is the only method supported to get pkgsrc"
621+ return 1 672+ return 1
622+ fi 673+ fi
623+ 674+
624 echo "${portsTreeName}: initializing tree" 675 echo "${portsTreeName}: initializing tree"
625 generateUpdateCode portstree ${portsTreeName} ${updateType} \ 676 generateUpdateCode portstree ${portsTreeName} ${updateType} \
626- ${updateHost} "." ${updateCompress} 677- ${updateHost} "." ${updateCompress} "" \
 678- ${protocol} ${updateHostDirectory}
627+ ${updateHost} ${cvsTag} ${updateCompress} 679+ ${updateHost} ${cvsTag} ${updateCompress}
628  680
629 # add portstree to datastore 681 # add portstree to datastore
630 echo -n "${portsTreeName}: adding to datastore... " 682 echo -n "${portsTreeName}: adding to datastore... "
631@@ -1158,7 +1326,7 @@ enterBuild () { 683@@ -1214,7 +1326,7 @@ enterBuild () {
632 fi 684 fi
633  685
634 sleepName=$(echo ${portDir} | sed -e 'y/\//_/') 686 sleepName=$(echo ${portDir} | sed -e 'y/\//_/')
635- portFullDir=${buildRoot}/usr/ports/${portDir} 687- portFullDir=${buildRoot}/usr/ports/${portDir}
636+ portFullDir=${buildRoot}/usr/pkgsrc/${portDir} 688+ portFullDir=${buildRoot}/usr/pkgsrc/${portDir}
637  689
638 if [ ! -d ${portFullDir} ]; then 690 if [ ! -d ${portFullDir} ]; then
639 echo "enterBuild: Build environment does not exist yet, sleeping." 691 echo "enterBuild: Build environment does not exist yet, sleeping."
640@@ -1182,7 +1350,7 @@ enterBuild () { 692@@ -1238,7 +1350,7 @@ enterBuild () {
641 sleep 15 693 sleep 15
642 done 694 done
643  695
644- echo  696- echo 
645+ echo 697+ echo
646 cp $(tinderLoc scripts lib/enterbuild) ${buildRoot}/root 698 cp $(tinderLoc scripts lib/enterbuild) ${buildRoot}/root
647 chroot ${buildRoot} /root/enterbuild ${portDir} 699 chroot ${buildRoot} /root/enterbuild ${portDir}
648 rm -f ${buildRoot}/tmp/.sleep_${sleepName} 700 rm -f ${buildRoot}/tmp/.sleep_${sleepName}
649@@ -1269,7 +1437,6 @@ makeBuild () { 701@@ -1325,7 +1437,6 @@ makeBuild () {
650 resetBuild () { 702 resetBuild () {
651 # set up defaults 703 # set up defaults
652 build="" 704 build=""
653- nullfs="" 705- nullfs=""
654 cleandistfiles="0" 706 cleandistfiles="0"
655  707
656 # argument handling 708 # argument handling
657@@ -1278,7 +1445,6 @@ resetBuild () { 709@@ -1334,7 +1445,6 @@ resetBuild () {
658 case "${arg}" in 710 case "${arg}" in
659  711
660 b) build="${OPTARG}";; 712 b) build="${OPTARG}";;
661- n) nullfs="-n";; 713- n) nullfs="-n";;
662 ?) exit 1;; 714 ?) exit 1;;
663  715
664 esac 716 esac
665@@ -1434,22 +1600,23 @@ tinderbuild_setup () { 717@@ -1490,22 +1600,23 @@ tinderbuild_setup () {
666 echo "tinderbuild: Finalizing chroot environment" 718 echo "tinderbuild: Finalizing chroot environment"
667  719
668 # Mount ports/ 720 # Mount ports/
669- if ! requestMount -t buildports -b ${build} -r ${nullfs}; then 721- if ! requestMount -t buildports -b ${build} -r ${nullfs}; then
670+ if ! requestMount -t buildports -b ${build} -r ; then 722+ if ! requestMount -t buildports -b ${build} -r ; then
671 echo "tinderbuild: cannot mount ports source" 723 echo "tinderbuild: cannot mount ports source"
672 tinderbuild_cleanup 1 724 tinderbuild_cleanup 1
673 fi 725 fi
674- ln -sf ../a/ports ${buildRoot}/usr/ports 726- ln -sf ../a/ports ${buildRoot}/usr/ports
675+ rm -rf ${buildRoot}/usr/pkgsrc 727+ rm -rf ${buildRoot}/usr/pkgsrc
676+ ln -s ../a/pkgsrc ${buildRoot}/usr/pkgsrc 728+ ln -s ../a/pkgsrc ${buildRoot}/usr/pkgsrc
677  729
678 # Mount src/ 730 # Mount src/
@@ -681,112 +733,112 @@ $NetBSD: patch-aa,v 1.2 2011/11/14 02:00 @@ -681,112 +733,112 @@ $NetBSD: patch-aa,v 1.2 2011/11/14 02:00
681 echo "tinderbuild: cannot mount jail source" 733 echo "tinderbuild: cannot mount jail source"
682 tinderbuild_cleanup 1 734 tinderbuild_cleanup 1
683 fi 735 fi
684  736
685 # For use by pnohang 737 # For use by pnohang
686 # XXX: though killall may not work since it's a dynamic executable 738 # XXX: though killall may not work since it's a dynamic executable
687- cp -p /rescue/mount /rescue/umount ${buildRoot}/sbin 739- cp -p /rescue/mount /rescue/umount ${buildRoot}/sbin
688- cp -p /rescue/ps ${buildRoot}/bin 740- cp -p /rescue/ps ${buildRoot}/bin
689+ cp -p /sbin/mount /sbin/umount ${buildRoot}/sbin 741+ cp -p /sbin/mount /sbin/umount ${buildRoot}/sbin
690+ cp -p /bin/ps ${buildRoot}/bin 742+ cp -p /bin/ps ${buildRoot}/bin
691  743
692 # Mount /dev, since we're going to be chrooting shortly 744 # Mount /dev, since we're going to be chrooting shortly
693 mount -t devfs devfs ${buildRoot}/dev >/dev/null 2>&1 745 mount -t devfs devfs ${buildRoot}/dev >/dev/null 2>&1
694@@ -1466,12 +1633,6 @@ tinderbuild_setup () { 746@@ -1522,12 +1633,6 @@ tinderbuild_setup () {
695 tinderbuild_cleanup 1 747 tinderbuild_cleanup 1
696 fi 748 fi
697  749
698- # Hack to fix some recent pkg_add problems in some releases 750- # Hack to fix some recent pkg_add problems in some releases
699- pitar=$(tinderLoc jail ${jail})/pkg_install.tar 751- pitar=$(tinderLoc jail ${jail})/pkg_install.tar
700- if [ -f ${pitar} ]; then 752- if [ -f ${pitar} ]; then
701- tar -C ${buildRoot} -xf ${pitar} 753- tar -C ${buildRoot} -xf ${pitar}
702- fi 754- fi
703- 755-
704 # Handle the distfile cache 756 # Handle the distfile cache
705 if [ -n "${DISTFILE_CACHE}" ]; then 757 if [ -n "${DISTFILE_CACHE}" ]; then
706 if ! requestMount -t builddistcache -b ${build} \ 758 if ! requestMount -t builddistcache -b ${build} \
707@@ -1501,7 +1662,7 @@ tinderbuild_setup () { 759@@ -1557,7 +1662,7 @@ tinderbuild_setup () {
708 mkdir -p ${ccacheDir} $(tinderLoc buildccache ${build}) 760 mkdir -p ${ccacheDir} $(tinderLoc buildccache ${build})
709  761
710 if ! requestMount -t buildccache -b ${build} \ 762 if ! requestMount -t buildccache -b ${build} \
711- -s ${ccacheDir} ${nullfs}; then 763- -s ${ccacheDir} ${nullfs}; then
712+ -s ${ccacheDir} ; then 764+ -s ${ccacheDir} ; then
713 echo "tinderbuild: cannot mount ccache" 765 echo "tinderbuild: cannot mount ccache"
714 tinderbuild_cleanup 1 766 tinderbuild_cleanup 1
715 fi 767 fi
716@@ -1518,8 +1679,7 @@ tinderbuild_setup () { 768@@ -1574,8 +1679,7 @@ tinderbuild_setup () {
717  769
718 mkdir -p ${optionsDir} $(tinderLoc buildoptions ${build}) 770 mkdir -p ${optionsDir} $(tinderLoc buildoptions ${build})
719  771
720- if ! requestMount -t buildoptions -b ${build} \ 772- if ! requestMount -t buildoptions -b ${build} \
721- -s ${optionsDir} ${nullfs}; then 773- -s ${optionsDir} ${nullfs}; then
722+ if ! requestMount -t buildoptions -b ${build} -s ${optionsDir} ; then 774+ if ! requestMount -t buildoptions -b ${build} -s ${optionsDir} ; then
723 echo "tinderbuild: cannot mount options" 775 echo "tinderbuild: cannot mount options"
724 tinderbuild_cleanup 1 776 tinderbuild_cleanup 1
725 fi 777 fi
726@@ -1602,10 +1762,9 @@ tinderbuild () { 778@@ -1658,10 +1762,9 @@ tinderbuild () {
727 cleanpackages=0 779 cleanpackages=0
728 init=0 780 init=0
729 jobs=1 781 jobs=1
730- onceonly=0 782- onceonly=0
731+ twice=0 783+ twice=0
732 onlymake=0 784 onlymake=0
733 noduds="" 785 noduds=""
734- nullfs="" 786- nullfs=""
735 pbargs="" 787 pbargs=""
736 skipmake=0 788 skipmake=0
737 updateports=0 789 updateports=0
738@@ -1652,9 +1811,8 @@ tinderbuild () { 790@@ -1708,9 +1811,8 @@ tinderbuild () {
739 x-fetch-original) pbargs="${pbargs} -fetch-original";; 791 x-fetch-original) pbargs="${pbargs} -fetch-original";;
740 x-noclean) pbargs="${pbargs} -noclean";; 792 x-noclean) pbargs="${pbargs} -noclean";;
741 x-nolog) pbargs="${pbargs} -nolog";; 793 x-nolog) pbargs="${pbargs} -nolog";;
742- x-nullfs) pbargs="${pbargs} -nullfs"; nullfs="-n";; 794- x-nullfs) pbargs="${pbargs} -nullfs"; nullfs="-n";;
743 x-plistcheck) pbargs="${pbargs} -plistcheck";; 795 x-plistcheck) pbargs="${pbargs} -plistcheck";;
744- x-onceonly) onceonly=1;; 796- x-onceonly) onceonly=1;;
745+ x-twice) twice=1;; 797+ x-twice) twice=1;;
746  798
747 -*) return 1;; 799 -*) return 1;;
748 *) ports="${ports} $1";; 800 *) ports="${ports} $1";;
749@@ -1780,7 +1938,8 @@ tinderbuild () { 801@@ -1836,7 +1938,8 @@ tinderbuild () {
750 echo "tinderbuild: cannot mount portstree: ${portstree}" 802 echo "tinderbuild: cannot mount portstree: ${portstree}"
751 exit 1 803 exit 1
752 fi 804 fi
753- env PORTSDIR=$(tinderLoc portstree ${portstree})/ports \ 805- env PORTSDIR=$(tinderLoc portstree ${portstree})/ports \
754+ env PORTSDIR=$(tinderLoc portstree ${portstree})/pkgsrc \ 806+ env PORTSDIR=$(tinderLoc portstree ${portstree})/pkgsrc \
755+ OPTNFILE=$(tinderLoc options $build)/pkg_options \ 807+ OPTNFILE=$(tinderLoc options $build)/pkg_options \
756 $(tinderLoc scripts lib/makemake) ${noduds} ${build} ${ports} 808 $(tinderLoc scripts lib/makemake) ${noduds} ${build} ${ports}
757 ) 809 )
758 if [ $? -ne 0 ]; then 810 if [ $? -ne 0 ]; then
759@@ -1799,10 +1958,6 @@ tinderbuild () { 811@@ -1855,10 +1958,6 @@ tinderbuild () {
760  812
761 # Set up the chrooted environment 813 # Set up the chrooted environment
762 osmajor=$(echo ${jail} | sed -E -e 's|(^[[:digit:]]+).*$|\1|') 814 osmajor=$(echo ${jail} | sed -E -e 's|(^[[:digit:]]+).*$|\1|')
763- if [ ${osmajor} -lt 6 ]; then 815- if [ ${osmajor} -lt 6 ]; then
764- echo "tinderbuild: unhandled OS version: ${osmajor}" 816- echo "tinderbuild: unhandled OS version: ${osmajor}"
765- tinderbuild_cleanup 1 817- tinderbuild_cleanup 1
766- fi 818- fi
767  819
768 tinderbuild_setup 820 tinderbuild_setup
769  821
770@@ -1810,7 +1965,7 @@ tinderbuild () { 822@@ -1866,7 +1965,7 @@ tinderbuild () {
771 ${tc} updateBuildStatus -b ${build} -s PORTBUILD 823 ${tc} updateBuildStatus -b ${build} -s PORTBUILD
772 tinderbuild_phase 0 ${jobs} ${pkgDir} 824 tinderbuild_phase 0 ${jobs} ${pkgDir}
773 error=$? 825 error=$?
774- if [ ${onceonly} -ne 1 ]; then 826- if [ ${onceonly} -ne 1 ]; then
775+ if [ ${twice} -eq 1 ]; then 827+ if [ ${twice} -eq 1 ]; then
776 if [ ${error} -ne 0 ] ; then 828 if [ ${error} -ne 0 ] ; then
777 tinderbuild_setup 829 tinderbuild_setup
778 fi 830 fi
779@@ -1829,21 +1984,46 @@ init () { 831@@ -1885,21 +1984,46 @@ init () {
780 mkdir -p ${pb}/${dir} 832 mkdir -p ${pb}/${dir}
781 done 833 done
782  834
783- read -p "Enter a default cvsup host [${_defaultUpdateHost}]: " host 835- read -p "Enter a default cvsup host [${_defaultUpdateHost}]: " host
784+ read -p "Enter a default cvsup server for pkgsrc [${_defaultUpdateHost}]: " host 836+ read -p "Enter a default cvsup server for pkgsrc [${_defaultUpdateHost}]: " host
785 if [ -z "${host}" ]; then 837 if [ -z "${host}" ]; then
786 host=${_defaultUpdateHost} 838 host=${_defaultUpdateHost}
787 fi 839 fi
788  840
789- read -p "Enter a default update type or command [${_defaultUpdateType}]: " type 841- read -p "Enter a default update type or command [${_defaultUpdateType}]: " type
790- if [ -z "${type}" ]; then 842- if [ -z "${type}" ]; then
791- type=${_defaultUpdateType} 843- type=${_defaultUpdateType}
792+ # Update type is not optional, it's CSUP only, so we won't ask. 844+ # Update type is not optional, it's CSUP only, so we won't ask.
@@ -819,37 +871,37 @@ $NetBSD: patch-aa,v 1.2 2011/11/14 02:00 @@ -819,37 +871,37 @@ $NetBSD: patch-aa,v 1.2 2011/11/14 02:00
819 globalenv=$(tinderLoc scripts etc/env)/GLOBAL 871 globalenv=$(tinderLoc scripts etc/env)/GLOBAL
820 echo "export defaultUpdateHost=${host}" >> ${globalenv} 872 echo "export defaultUpdateHost=${host}" >> ${globalenv}
821- echo "export defaultUpdateType=${type}" >> ${globalenv} 873- echo "export defaultUpdateType=${type}" >> ${globalenv}
822+ echo "export defaultUpdateType=${_defaultUpdateType}" >> ${globalenv} 874+ echo "export defaultUpdateType=${_defaultUpdateType}" >> ${globalenv}
823+ echo "export defaultDragonHost=${dragonhost}" >> ${globalenv} 875+ echo "export defaultDragonHost=${dragonhost}" >> ${globalenv}
824+ echo "export defaultDragonType=${_defaultDragonType}" >> ${globalenv} 876+ echo "export defaultDragonType=${_defaultDragonType}" >> ${globalenv}
825+ echo "export defaultGitSrcHost=${gitsrchost}" >> ${globalenv} 877+ echo "export defaultGitSrcHost=${gitsrchost}" >> ${globalenv}
826  878
827- tinderEcho "Default update host and type have been set. These can be changed later by modifying ${globalenv}." 879- tinderEcho "Default update host and type have been set. These can be changed later by modifying ${globalenv}."
828+ tinderEcho "The defaults have been set. These can be changed later by modifying ${globalenv}." 880+ tinderEcho "The defaults have been set. These can be changed later by modifying ${globalenv}."
829  881
830 return 0 882 return 0
831 } 883 }
832@@ -1892,7 +2072,8 @@ addPortToBuild () { 884@@ -1948,7 +2072,8 @@ addPortToBuild () {
833 buildenv ${jail} ${portsTree} ${build} 885 buildenv ${jail} ${portsTree} ${build}
834 buildenvNoHost ${build} 886 buildenvNoHost ${build}
835  887
836- export PORTSDIR=$(tinderLoc portstree ${portsTree})/ports 888- export PORTSDIR=$(tinderLoc portstree ${portsTree})/ports
837+ export PORTSDIR=$(tinderLoc portstree ${portsTree})/pkgsrc 889+ export PORTSDIR=$(tinderLoc portstree ${portsTree})/pkgsrc
838+ export OPTNFILE=$(tinderLoc options $build)/pkg_options 890+ export OPTNFILE=$(tinderLoc options $build)/pkg_options
839 if [ -z "${portDir}" ]; then 891 if [ -z "${portDir}" ]; then
840 ${tc} addPortToOneBuild -b ${build} ${norecurse} 892 ${tc} addPortToOneBuild -b ${build} ${norecurse}
841 else 893 else
842@@ -1902,36 +2083,7 @@ addPortToBuild () { 894@@ -1958,36 +2083,7 @@ addPortToBuild () {
843 fi 895 fi
844 ${tc} addPortToOneBuild -b ${build} -d ${portDir} ${norecurse} 896 ${tc} addPortToOneBuild -b ${build} -d ${portDir} ${norecurse}
845 fi 897 fi
846- if [ ${options} -eq 1 -a ${OPTIONS_ENABLED} -eq 1 ]; then 898- if [ ${options} -eq 1 -a ${OPTIONS_ENABLED} -eq 1 ]; then
847- pdirs="" 899- pdirs=""
848- if [ -z "${portDir}" ]; then 900- if [ -z "${portDir}" ]; then
849- pdirs=$(${tc} getPortsForBuild -b ${build} 2>/dev/null) 901- pdirs=$(${tc} getPortsForBuild -b ${build} 2>/dev/null)
850- else 902- else
851- pdirs="${PORTSDIR}/${portDir}" 903- pdirs="${PORTSDIR}/${portDir}"
852- fi 904- fi
853- rmconfig=true 905- rmconfig=true
854- if [ ${cleanOptions} -eq 1 ]; then 906- if [ ${cleanOptions} -eq 1 ]; then
855- if [ -z "${norecurse}" ]; then 907- if [ -z "${norecurse}" ]; then
@@ -867,51 +919,51 @@ $NetBSD: patch-aa,v 1.2 2011/11/14 02:00 @@ -867,51 +919,51 @@ $NetBSD: patch-aa,v 1.2 2011/11/14 02:00
867- ( cd ${pdir} && ${rmconfig} \ 919- ( cd ${pdir} && ${rmconfig} \
868- && make -k config-recursive ) 920- && make -k config-recursive )
869- else 921- else
870- ( cd ${pdir} && ${rmconfig} \ 922- ( cd ${pdir} && ${rmconfig} \
871- && make config ) 923- && make config )
872- fi 924- fi
873- fi 925- fi
874- done 926- done
875- fi 927- fi
876+ # FreeBSD-style interactive option entering not supported yet 928+ # FreeBSD-style interactive option entering not supported yet
877  929
878 if [ -n "${save_SRCBASE}" ]; then 930 if [ -n "${save_SRCBASE}" ]; then
879 export SRCBASE=${save_SRCBASE} 931 export SRCBASE=${save_SRCBASE}
880@@ -2118,10 +2270,7 @@ copyBuild () { 932@@ -2174,10 +2270,7 @@ copyBuild () {
881 if [ ! -d ${destOptionsDir} ]; then 933 if [ ! -d ${destOptionsDir} ]; then
882 mkdir -p ${destOptionsDir} 934 mkdir -p ${destOptionsDir}
883 fi 935 fi
884- ( 936- (
885- cd ${srcOptionsDir} 937- cd ${srcOptionsDir}
886- tar -cpf - . | tar -C ${destOptionsDir} -xpf - 938- tar -cpf - . | tar -C ${destOptionsDir} -xpf -
887- ) 939- )
888+ cp ${srcOptionsDir}/pkg_options ${destOptionsDir} 940+ cp ${srcOptionsDir}/pkg_options ${destOptionsDir}
889 else 941 else
890 echo "copyBuild: not copying OPTIONS to ${dest} since it has no OPTIONS directory" 942 echo "copyBuild: not copying OPTIONS to ${dest} since it has no OPTIONS directory"
891 fi 943 fi
892@@ -2237,13 +2386,13 @@ tbcleanup () { 944@@ -2293,13 +2386,13 @@ tbcleanup () {
893 pathFound=0 945 pathFound=0
894 for portstree in ${portstrees} ; do 946 for portstree in ${portstrees} ; do
895 path=$(tinderLoc portstree ${portstree}) 947 path=$(tinderLoc portstree ${portstree})
896- path="${path}/ports/${port}/Makefile" 948- path="${path}/ports/${port}/Makefile"
897+ path="${path}/pkgsrc/${port}/Makefile" 949+ path="${path}/pkgsrc/${port}/Makefile"
898 if [ -e ${path} ]; then 950 if [ -e ${path} ]; then
899 if [ ${cleanDistfiles} = 1 ]; then 951 if [ ${cleanDistfiles} = 1 ]; then
900 oldcwd=${PWD} 952 oldcwd=${PWD}
901 path=$(tinderLoc portstree ${portstree}) 953 path=$(tinderLoc portstree ${portstree})
902- cd "${path}/ports/${port}" 954- cd "${path}/ports/${port}"
903- distinfo=$(env PORTSDIR="${path}/ports" make -V MD5_FILE) 955- distinfo=$(env PORTSDIR="${path}/ports" make -V MD5_FILE)
904+ cd "${path}/pkgsrc/${port}" 956+ cd "${path}/pkgsrc/${port}"
905+ distinfo=$(env PORTSDIR="${path}/pkgsrc" bmake -V MD5_FILE) 957+ distinfo=$(env PORTSDIR="${path}/pkgsrc" bmake -V MD5_FILE)
906 if [ -f "${distinfo}" ]; then 958 if [ -f "${distinfo}" ]; then
907 for df in $(grep '^MD5' ${distinfo} | awk -F '[\(\)]' '{print $2}'); do 959 for df in $(grep '^MD5' ${distinfo} | awk -F '[\(\)]' '{print $2}'); do
908 if ! grep -q "^${df}\$" ${disttmp}; then 960 if ! grep -q "^${df}\$" ${disttmp}; then
909@@ -2327,7 +2476,7 @@ tbcleanup () { 961@@ -2383,7 +2476,7 @@ tbcleanup () {
910 fi 962 fi
911  963
912 path=$(tinderLoc portstree ${portstree}) 964 path=$(tinderLoc portstree ${portstree})
913- path="${path}/ports/${port}/Makefile" 965- path="${path}/ports/${port}/Makefile"
914+ path="${path}/pkgsrc/${port}/Makefile" 966+ path="${path}/pkgsrc/${port}/Makefile"
915  967
916 if [ ! -e ${path} ]; then 968 if [ ! -e ${path} ]; then
917 echo "Removing build port database entry for nonexistent port ${build}/${port}" 969 echo "Removing build port database entry for nonexistent port ${build}/${port}"

cvs diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-ai (expand / switch to unified diff)

--- pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-ai 2011/11/14 02:00:20 1.2
+++ pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-ai 2011/11/20 16:20:24 1.3
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1$NetBSD: patch-ai,v 1.2 2011/11/14 02:00:20 marino Exp $ 1$NetBSD: patch-ai,v 1.3 2011/11/20 16:20:24 marino Exp $
2 2
3--- ../FreeBSD/lib/portbuild 2011-10-16 00:52:55.000000000 +0000 3--- ../FreeBSD/lib/portbuild 2011-10-16 00:52:55.000000000 +0000
4+++ lib/portbuild 4+++ lib/portbuild
5@@ -5,7 +5,7 @@ 5@@ -5,7 +5,7 @@
6 . ${pb}/scripts/lib/tinderlib.sh 6 . ${pb}/scripts/lib/tinderlib.sh
7  7
8 usage () { 8 usage () {
9- echo "usage: $0 <build name> <jail name> <portstree name> [-noclean] [-plistcheck] [-nullfs] [-fetch-original] [-nolog] ED PD FD BD RD TD pkgname dirname" 9- echo "usage: $0 <build name> <jail name> <portstree name> [-noclean] [-plistcheck] [-nullfs] [-fetch-original] [-nolog] ED PD FD BD RD TD pkgname dirname"
10+ echo "usage: $0 <build name> <jail name> <portstree name> [-noclean] [-plistcheck] [-fetch-original] [-nolog] ED PD FD BD RD TD pkgname dirname" 10+ echo "usage: $0 <build name> <jail name> <portstree name> [-noclean] [-plistcheck] [-fetch-original] [-nolog] ED PD FD BD RD TD pkgname dirname"
11 exit 1 11 exit 1
12 } 12 }
13  13
14@@ -17,9 +17,10 @@ cleanup() 14@@ -17,9 +17,10 @@ cleanup()
@@ -27,91 +27,98 @@ $NetBSD: patch-ai,v 1.2 2011/11/14 02:00 @@ -27,91 +27,98 @@ $NetBSD: patch-ai,v 1.2 2011/11/14 02:00
27@@ -31,11 +32,8 @@ cleanup() 27@@ -31,11 +32,8 @@ cleanup()
28 rm -rf ${chroot}/tmp/* 28 rm -rf ${chroot}/tmp/*
29  29
30 chroot ${chroot} /sbin/ldconfig -R 30 chroot ${chroot} /sbin/ldconfig -R
31- if [ ${ARCH} = "i386" ]; then 31- if [ ${ARCH} = "i386" ]; then
32- chroot ${chroot} /sbin/ldconfig -aout -R 32- chroot ${chroot} /sbin/ldconfig -aout -R
33- fi 33- fi
34 else 34 else
35- ${tc} resetBuild -b ${build} ${nullfs} 35- ${tc} resetBuild -b ${build} ${nullfs}
36+ ${tc} resetBuild -b ${build} 36+ ${tc} resetBuild -b ${build}
37 fi 37 fi
38 fi 38 fi
39  39
40@@ -56,7 +54,12 @@ mark_failed() { 40@@ -56,13 +54,19 @@ mark_failed() {
41 return 41 return
42 fi 42 fi
43  43
44- dependents=$(grep ${pkgname} ${mf} | grep '^[[:space:]]\{1,\}@' | awk '{print $NF}' | sed -e 's|^/usr/ports/||' | grep -v ${portdir}) 44- dependents=$(grep ${pkgname} ${mf} | grep '^[[:space:]]\{1,\}@' | awk '{print $NF}' | sed -e 's|^/usr/ports/||' | grep -v ${portdir})
45+ dependents=$(grep ${pkgname} ${mf} | \ 45+ dependents=$(grep ${pkgname} ${mf} | \
46+ grep '^[[:space:]]\{1,\}@' | \ 46+ grep '^[[:space:]]\{1,\}@' | \
47+ awk '{print $NF}' | \ 47+ awk '{print $NF}' | \
48+ sed -e 's|^/usr/pkgsrc/||' | \ 48+ sed -e 's|^/usr/pkgsrc/||' | \
49+ sed -e 's|^../../||' | \ 49+ sed -e 's|^../../||' | \
50+ grep -v ${portdir}) 50+ grep -v ${portdir})
51 if [ $? -ne 0 ]; then 51 if [ $? -ne 0 ]; then
52 return 52 return
53 fi 53 fi
54@@ -71,7 +74,6 @@ mark_failed() { 54
 55 for dep in ${dependents}; do
 56 ${tc} updatePortStatus -d ${dep} -b ${branch} -L -s DEPEND -p ${portdir}
 57+ execute_hook "postPortBuild" "PACKAGE_NAME=${pkgname} BUILD=${branch} JAIL=${jail} PORTSTREE=${portstree} CHROOT=${chroot} PORTDIR=${dep} PB=${pb} STATUS=DEPEND FAIL_REASON=DEPEND TOTAL_SIZE=0"
 58 done
 59 }
 60
 61@@ -71,7 +75,6 @@ mark_failed() {
55 error=0 62 error=0
56 init=0 63 init=0
57 noclean=0 64 noclean=0
58-nullfs="" 65-nullfs=""
59 fetchorig=0 66 fetchorig=0
60 nolog=0 67 nolog=0
61 plistcheck="" 68 plistcheck=""
62@@ -107,9 +109,6 @@ while [ $# -gt 0 -a ${doneargs} -eq 0 ]; 69@@ -107,9 +110,6 @@ while [ $# -gt 0 -a ${doneargs} -eq 0 ];
63 x-plistcheck) plistcheck="plistcheck" 70 x-plistcheck) plistcheck="plistcheck"
64 shift;; 71 shift;;
65  72
66- x-nullfs) nullfs="-n" 73- x-nullfs) nullfs="-n"
67- shift;; 74- shift;;
68- 75-
69 x-fetch-original) fetchorig=1 76 x-fetch-original) fetchorig=1
70 shift;; 77 shift;;
71  78
72@@ -151,7 +150,7 @@ echo ${dirname} 79@@ -151,7 +151,7 @@ echo ${dirname}
73 tc=$(tinderLoc scripts tc) 80 tc=$(tinderLoc scripts tc)
74 chroot=$(tinderLoc buildroot ${build}) 81 chroot=$(tinderLoc buildroot ${build})
75 echo "chroot is: ${chroot}" 82 echo "chroot is: ${chroot}"
76-portdir=$(echo ${dirname} | sed -e 's|^/usr/ports/||') 83-portdir=$(echo ${dirname} | sed -e 's|^/usr/ports/||')
77+portdir=$(echo ${dirname} | sed -e 's|^/usr/pkgsrc/||') 84+portdir=$(echo ${dirname} | sed -e 's|^/usr/pkgsrc/||')
78  85
79 total_size=$(${tc} getPortTotalSize -d ${portdir} -b ${build}) 86 total_size=$(${tc} getPortTotalSize -d ${portdir} -b ${build})
80 execute_hook "prePortBuild" "PACKAGE_NAME=${pkgname} BUILD=${build} JAIL=${jail} PORTSTREE=${portstree} CHROOT=${chroot} PORTDIR=${portdir} PB=${pb} TOTAL_SIZE=${total_size}" 87 execute_hook "prePortBuild" "PACKAGE_NAME=${pkgname} BUILD=${build} JAIL=${jail} PORTSTREE=${portstree} CHROOT=${chroot} PORTDIR=${portdir} PB=${pb} TOTAL_SIZE=${total_size}"
81@@ -167,7 +166,7 @@ if [ -f ${dudsfile} ]; then 88@@ -167,7 +167,7 @@ if [ -f ${dudsfile} ]; then
82 if grep -qxF ${pkgname} ${dudsfile}; then 89 if grep -qxF ${pkgname} ${dudsfile}; then
83 echo "skipping ${pkgname} (found in duds)" 90 echo "skipping ${pkgname} (found in duds)"
84 ${tc} updatePortStatus -d ${portdir} -b ${build} \ 91 ${tc} updatePortStatus -d ${portdir} -b ${build} \
85- -L -s DUD -v ${pkgname} 92- -L -s DUD -v ${pkgname}
86+ -L -s DUD -v ${pkgname} -r arch 93+ -L -s DUD -v ${pkgname} -r arch
87 mark_failed ${tc} ${build} ${pkgname} ${portdir} 94 mark_failed ${tc} ${build} ${pkgname} ${portdir}
88 execute_hook "postPortBuild" "PACKAGE_NAME=${pkgname} BUILD=${build} JAIL=${jail} PORTSTREE=${portstree} CHROOT=${chroot} STATUS=DUD PORTDIR=${portdir} PB=${pb} FAIL_REASON=dud TOTAL_SIZE=0" 95 execute_hook "postPortBuild" "PACKAGE_NAME=${pkgname} BUILD=${build} JAIL=${jail} PORTSTREE=${portstree} CHROOT=${chroot} STATUS=DUD PORTDIR=${portdir} PB=${pb} FAIL_REASON=dud TOTAL_SIZE=0"
89 exit 1 96 exit 1
90@@ -175,12 +174,12 @@ if [ -f ${dudsfile} ]; then 97@@ -175,12 +175,12 @@ if [ -f ${dudsfile} ]; then
91 fi 98 fi
92  99
93 # directories to clean 100 # directories to clean
94+# These are created/recreated after blowing the directories away 101+# These are created/recreated after blowing the directories away
95 cleandirs="${LOCALBASE} /compat /var/db/pkg" 102 cleandirs="${LOCALBASE} /compat /var/db/pkg"
96  103
97 for dir in ${cleandirs}; do 104 for dir in ${cleandirs}; do
98 cleanDirs ${build} ${chroot}${dir} 105 cleanDirs ${build} ${chroot}${dir}
99 done 106 done
100-rm -rf ${chroot}/var/db/pkg/* 107-rm -rf ${chroot}/var/db/pkg/*
101  108
102 # reset mtrees for plist checking 109 # reset mtrees for plist checking
103 mtree -deU -f ${chroot}/etc/mtree/BSD.root.dist \ 110 mtree -deU -f ${chroot}/etc/mtree/BSD.root.dist \
104@@ -190,17 +189,48 @@ mtree -deU -f ${chroot}/etc/mtree/BSD.va 111@@ -190,17 +190,48 @@ mtree -deU -f ${chroot}/etc/mtree/BSD.va
105 mtree -deU -f ${chroot}/etc/mtree/BSD.usr.dist \ 112 mtree -deU -f ${chroot}/etc/mtree/BSD.usr.dist \
106 -p ${chroot}/usr >/dev/null 2>&1 113 -p ${chroot}/usr >/dev/null 2>&1
107  114
108-mkdir -p ${chroot}${LOCALBASE} 115-mkdir -p ${chroot}${LOCALBASE}
109-if [ -f ${chroot}/a/ports/Templates/BSD.local.dist ]; then 116-if [ -f ${chroot}/a/ports/Templates/BSD.local.dist ]; then
110- mtree -deU -f ${chroot}/a/ports/Templates/BSD.local.dist -p ${chroot}${LOCALBASE} \ 117- mtree -deU -f ${chroot}/a/ports/Templates/BSD.local.dist -p ${chroot}${LOCALBASE} \
111+if [ -f ${chroot}/a/pkgsrc/Templates/BSD.local.dist ]; then 118+if [ -f ${chroot}/a/pkgsrc/Templates/BSD.local.dist ]; then
112+ mtree -deU -f ${chroot}/a/pkgsrc/Templates/BSD.local.dist -p ${chroot}${LOCALBASE} \ 119+ mtree -deU -f ${chroot}/a/pkgsrc/Templates/BSD.local.dist -p ${chroot}${LOCALBASE} \
113 >/dev/null 2>&1 120 >/dev/null 2>&1
114 else 121 else
115 mtree -deU -f ${chroot}/etc/mtree/BSD.local.dist -p ${chroot}${LOCALBASE} \ 122 mtree -deU -f ${chroot}/etc/mtree/BSD.local.dist -p ${chroot}${LOCALBASE} \
116 >/dev/null 2>&1 123 >/dev/null 2>&1
117 fi 124 fi
@@ -145,126 +152,126 @@ $NetBSD: patch-ai,v 1.2 2011/11/14 02:00 @@ -145,126 +152,126 @@ $NetBSD: patch-ai,v 1.2 2011/11/14 02:00
145+# better not to have two sources. 152+# better not to have two sources.
146+ 153+
147+more_mkconf=$(tinderLoc options ${build})/more_mk.conf 154+more_mkconf=$(tinderLoc options ${build})/more_mk.conf
148+if [ -f ${more_mkconf} ]; then 155+if [ -f ${more_mkconf} ]; then
149+ cat ${more_mkconf} | awk "!/^[ \t]*($|#|PKG_OPTIONS\.|MAKE_JOBS=)/" \ 156+ cat ${more_mkconf} | awk "!/^[ \t]*($|#|PKG_OPTIONS\.|MAKE_JOBS=)/" \
150+ >> ${chroot}${LOCALBASE}/etc/mk.conf 157+ >> ${chroot}${LOCALBASE}/etc/mk.conf
151+fi 158+fi
152+ 159+
153+# mount linprocfs if available 160+# mount linprocfs if available
154+if [ ${ARCH} = "i386" ]; then 161+if [ ${ARCH} = "i386" ]; then
155 mkdir -p ${chroot}/compat/linux/proc 162 mkdir -p ${chroot}/compat/linux/proc
156 mount -t linprocfs linprocfs ${chroot}/compat/linux/proc 163 mount -t linprocfs linprocfs ${chroot}/compat/linux/proc
157 fi 164 fi
158@@ -251,8 +281,10 @@ if [ x"${CCACHE_ENABLED}" = x"1" ]; then 165@@ -251,8 +282,10 @@ if [ x"${CCACHE_ENABLED}" = x"1" ]; then
159 export PATH=/opt:${PATH} 166 export PATH=/opt:${PATH}
160 fi 167 fi
161  168
162-if [ x"${OPTIONS_ENABLED}" = x"1" ]; then 169-if [ x"${OPTIONS_ENABLED}" = x"1" ]; then
163- export PORT_DBDIR=/var/db/ports 170- export PORT_DBDIR=/var/db/ports
164+export PKG_OPTIONS_FILE= 171+export PKG_OPTIONS_FILE=
165+original_options=$(tinderLoc options ${build})/pkg_options 172+original_options=$(tinderLoc options ${build})/pkg_options
166+if [ x"${OPTIONS_ENABLED}" = x"1" -a -f ${original_options} ]; then 173+if [ x"${OPTIONS_ENABLED}" = x"1" -a -f ${original_options} ]; then
167+ export PKG_OPTIONS_FILE=/var/db/options/pkg_options 174+ export PKG_OPTIONS_FILE=/var/db/options/pkg_options
168 fi 175 fi
169  176
170 echo "building $pkgname in $chroot" 177 echo "building $pkgname in $chroot"
171@@ -264,11 +296,7 @@ packages=$(tinderLoc packages ${build}) 178@@ -264,11 +297,7 @@ packages=$(tinderLoc packages ${build})
172 major_version=$(echo ${jail} | sed -E -e 's|(^[[:digit:]]+).*$|\1|') 179 major_version=$(echo ${jail} | sed -E -e 's|(^[[:digit:]]+).*$|\1|')
173  180
174 if [ -n "${DISTFILE_CACHE}" ]; then 181 if [ -n "${DISTFILE_CACHE}" ]; then
175- export DISTCACHE=/distcache 182- export DISTCACHE=/distcache
176- if [ ${fetchorig} -eq 0 ]; then 183- if [ ${fetchorig} -eq 0 ]; then
177- _MSO='file:///distcache/${DIST_SUBDIR}/' 184- _MSO='file:///distcache/${DIST_SUBDIR}/'
178- export MASTER_SITE_OVERRIDE="${_MSO} ${MASTER_SITE_OVERRIDE}" 185- export MASTER_SITE_OVERRIDE="${_MSO} ${MASTER_SITE_OVERRIDE}"
179- fi 186- fi
180+ export DISTDIR=/distcache 187+ export DISTDIR=/distcache
181 fi 188 fi
182  189
183 if [ -n "${DISTFILE_URI}" ]; then 190 if [ -n "${DISTFILE_URI}" ]; then
184@@ -282,7 +310,7 @@ mkdir -p ${chroot}/tmp/depends ${chroot} 191@@ -282,7 +311,7 @@ mkdir -p ${chroot}/tmp/depends ${chroot}
185 echo "building ${pkgname} in directory ${chroot}" | \ 192 echo "building ${pkgname} in directory ${chroot}" | \
186 tee ${chroot}/tmp/${pkgname}.log 193 tee ${chroot}/tmp/${pkgname}.log
187  194
188-trap "cleanup ${chroot} ${noclean} ${error} \"${cleandirs}\" ${pkgname} ${build} ${nullfs}" 1 2 3 9 10 11 15 195-trap "cleanup ${chroot} ${noclean} ${error} \"${cleandirs}\" ${pkgname} ${build} ${nullfs}" 1 2 3 9 10 11 15
189+trap "cleanup ${chroot} ${noclean} ${error} \"${cleandirs}\" ${pkgname} ${build}" 1 2 3 9 10 11 15 196+trap "cleanup ${chroot} ${noclean} ${error} \"${cleandirs}\" ${pkgname} ${build}" 1 2 3 9 10 11 15
190  197
191 # Don't build in a world-writable standard directory because some ports 198 # Don't build in a world-writable standard directory because some ports
192 # hardcode this path and try to load things from it at runtime, which is 199 # hardcode this path and try to load things from it at runtime, which is
193@@ -294,7 +322,7 @@ if [ x"${CCACHE_ENABLED}" ]; then 200@@ -294,7 +323,7 @@ if [ x"${CCACHE_ENABLED}" ]; then
194 unset CCACHE_DISABLE 201 unset CCACHE_DISABLE
195 fi 202 fi
196  203
197-_ldconfig_dirs="/lib /usr/lib /usr/lib/compat" 204-_ldconfig_dirs="/lib /usr/lib /usr/lib/compat"
198+_ldconfig_dirs="/usr/lib" 205+_ldconfig_dirs="/usr/lib"
199 ldconfig_dirs="" 206 ldconfig_dirs=""
200 for i in ${_ldconfig_dirs}; do 207 for i in ${_ldconfig_dirs}; do
201 if [ -d ${chroot}/${i} ]; then 208 if [ -d ${chroot}/${i} ]; then
202@@ -302,9 +330,6 @@ for i in ${_ldconfig_dirs}; do 209@@ -302,9 +331,6 @@ for i in ${_ldconfig_dirs}; do
203 fi 210 fi
204 done 211 done
205 chroot ${chroot} /sbin/ldconfig ${ldconfig_dirs} 212 chroot ${chroot} /sbin/ldconfig ${ldconfig_dirs}
206-if [ ${ARCH} = "i386" ]; then 213-if [ ${ARCH} = "i386" ]; then
207- chroot ${chroot} /sbin/ldconfig -aout /usr/lib/aout /usr/lib/compat/aout 214- chroot ${chroot} /sbin/ldconfig -aout /usr/lib/aout /usr/lib/compat/aout
208-fi 215-fi
209  216
210 set x $ED $FD $PD $BD $RD $TD 217 set x $ED $FD $PD $BD $RD $TD
211 shift 1 218 shift 1
212@@ -337,7 +362,7 @@ if [ $? -ne 0 ]; then 219@@ -337,7 +363,7 @@ if [ $? -ne 0 ]; then
213 exit 1 220 exit 1
214 fi 221 fi
215  222
216-chroot ${chroot} /buildscript ${dirname} 1 "$ED" "$PD" "$FD" "$BD" "$RD" "$TD" "${plistcheck}" 2>&1 | tee -a ${chroot}/tmp/${pkgname}.log 223-chroot ${chroot} /buildscript ${dirname} 1 "$ED" "$PD" "$FD" "$BD" "$RD" "$TD" "${plistcheck}" 2>&1 | tee -a ${chroot}/tmp/${pkgname}.log
217+chroot ${chroot} /buildscript ${dirname} 1 "$ED" "$PD" "$FD" "$BD" "$RD" "$TD" "${pkgname}" "${plistcheck}" 2>&1 | tee -a ${chroot}/tmp/${pkgname}.log 224+chroot ${chroot} /buildscript ${dirname} 1 "$ED" "$PD" "$FD" "$BD" "$RD" "$TD" "${pkgname}" "${plistcheck}" 2>&1 | tee -a ${chroot}/tmp/${pkgname}.log
218 if [ -f ${chroot}/tmp/status ]; then 225 if [ -f ${chroot}/tmp/status ]; then
219 error=$(cat ${chroot}/tmp/status) 226 error=$(cat ${chroot}/tmp/status)
220 else 227 else
221@@ -351,14 +376,7 @@ errorsDir=$(tinderLoc builderrors ${buil 228@@ -351,14 +377,7 @@ errorsDir=$(tinderLoc builderrors ${buil
222  229
223 if [ "${error}" = "0" ]; then 230 if [ "${error}" = "0" ]; then
224 ln -sf ${pkgname}.log2 ${chroot}/tmp/make.log 231 ln -sf ${pkgname}.log2 ${chroot}/tmp/make.log
225- # Cache the distfiles if requested. We will wait a maximum of 232- # Cache the distfiles if requested. We will wait a maximum of
226- # ten minutes before giving up on the lock. 233- # ten minutes before giving up on the lock.
227- if [ -n "${DISTFILE_CACHE}" ]; then 234- if [ -n "${DISTFILE_CACHE}" ]; then
228- lockf -t 600 ${chroot}${DISTCACHE}/.lock tar -C ${chroot}/${DISTDIR} \ 235- lockf -t 600 ${chroot}${DISTCACHE}/.lock tar -C ${chroot}/${DISTDIR} \
229- -cf - . | tar --unlink -C ${chroot}${DISTCACHE} -xvf - 236- -cf - . | tar --unlink -C ${chroot}${DISTCACHE} -xvf -
230- fi 237- fi
231- 238-
232- chroot ${chroot} /usr/bin/nice -n $nice /buildscript ${dirname} 2 "$ED" "$PD" "$FD" "$BD" "$RD" "$TD" "${plistcheck}" > ${chroot}/tmp/${pkgname}.log2 2>&1 239- chroot ${chroot} /usr/bin/nice -n $nice /buildscript ${dirname} 2 "$ED" "$PD" "$FD" "$BD" "$RD" "$TD" "${plistcheck}" > ${chroot}/tmp/${pkgname}.log2 2>&1
233+ chroot ${chroot} /usr/bin/nice -n $nice /buildscript ${dirname} 2 "$ED" "$PD" "$FD" "$BD" "$RD" "$TD" "${pkgname}" "${plistcheck}" > ${chroot}/tmp/${pkgname}.log2 2>&1 240+ chroot ${chroot} /usr/bin/nice -n $nice /buildscript ${dirname} 2 "$ED" "$PD" "$FD" "$BD" "$RD" "$TD" "${pkgname}" "${plistcheck}" > ${chroot}/tmp/${pkgname}.log2 2>&1
234  241
235 grep pnohang ${chroot}/tmp/${pkgname}.log2 242 grep pnohang ${chroot}/tmp/${pkgname}.log2
236 cat ${chroot}/tmp/${pkgname}.log2 >> ${chroot}/tmp/${pkgname}.log 243 cat ${chroot}/tmp/${pkgname}.log2 >> ${chroot}/tmp/${pkgname}.log
237@@ -372,6 +390,7 @@ if [ "${error}" = "0" ]; then 244@@ -372,6 +391,7 @@ if [ "${error}" = "0" ]; then
238 cp ${chroot}/tmp/${pkgname}.log ${logsDir}/${pkgname}.log 245 cp ${chroot}/tmp/${pkgname}.log ${logsDir}/${pkgname}.log
239 fi 246 fi
240 if [ -n "${logdir}" ]; then 247 if [ -n "${logdir}" ]; then
241+ rm -f ${logdir}/${pkgname}.log${lext} 248+ rm -f ${logdir}/${pkgname}.log${lext}
242 if [ ${docopy} -eq 1 ]; then 249 if [ ${docopy} -eq 1 ]; then
243 cp ${logsDir}/${pkgname}.log${lext} ${logdir}/${pkgname}.log${lext} 250 cp ${logsDir}/${pkgname}.log${lext} ${logdir}/${pkgname}.log${lext}
244 else 251 else
245@@ -388,6 +407,7 @@ if [ "${error}" = "0" ]; then 252@@ -388,6 +408,7 @@ if [ "${error}" = "0" ]; then
246 cp ${chroot}/tmp/work.tbz ${workDir}/${pkgname}.tbz 253 cp ${chroot}/tmp/work.tbz ${workDir}/${pkgname}.tbz
247 fi 254 fi
248  255
249+ rm -f ${errorsDir}/${pkgname}.log* 256+ rm -f ${errorsDir}/${pkgname}.log*
250 if [ "${error}" = "0" ]; then 257 if [ "${error}" = "0" ]; then
251 if [ ! -z "${last_version}" ]; then 258 if [ ! -z "${last_version}" ]; then
252 oldpkgs=$(find ${packages} -name "${last_version}${PKGSUFFIX}") 259 oldpkgs=$(find ${packages} -name "${last_version}${PKGSUFFIX}")
253@@ -400,8 +420,8 @@ if [ "${error}" = "0" ]; then 260@@ -400,8 +421,8 @@ if [ "${error}" = "0" ]; then
254 tar --unlink -C ${packages} -xvf - 261 tar --unlink -C ${packages} -xvf -
255 [ -f ${packages}/All/${pkgname}${PKGSUFFIX} ] && \ 262 [ -f ${packages}/All/${pkgname}${PKGSUFFIX} ] && \
256 touch ${packages}/All/${pkgname}${PKGSUFFIX} 263 touch ${packages}/All/${pkgname}${PKGSUFFIX}
257- rm -f ${errorsDir}/${pkgname}.log* 264- rm -f ${errorsDir}/${pkgname}.log*
258- if bzgrep -q "${pkgname} is marked as broken: " ${logsDir}/${pkgname}.log${lext} ; then 265- if bzgrep -q "${pkgname} is marked as broken: " ${logsDir}/${pkgname}.log${lext} ; then
259+ BROKE=`zgrep -q "${pkgname} is marked as broken: " ${logsDir}/${pkgname}.log${lext}` 266+ BROKE=`zgrep -q "${pkgname} is marked as broken: " ${logsDir}/${pkgname}.log${lext}`
260+ if [ "${BROKE}" != "" ] ; then 267+ if [ "${BROKE}" != "" ] ; then
261 status="BROKEN" 268 status="BROKEN"
262 elif [ -f ${chroot}/tmp/leftovers ]; then 269 elif [ -f ${chroot}/tmp/leftovers ]; then
263 status="LEFTOVERS" 270 status="LEFTOVERS"
264@@ -476,5 +496,5 @@ else 271@@ -476,5 +497,5 @@ else
265 execute_hook "postPortBuild" "PACKAGE_NAME=${pkgname} BUILD=${build} JAIL=${jail} PORTSTREE=${portstree} CHROOT=${chroot} STATUS=FAIL PORTDIR=${portdir} PB=${pb} ${reasonenv} TOTAL_SIZE=${total_size}" 272 execute_hook "postPortBuild" "PACKAGE_NAME=${pkgname} BUILD=${build} JAIL=${jail} PORTSTREE=${portstree} CHROOT=${chroot} STATUS=FAIL PORTDIR=${portdir} PB=${pb} ${reasonenv} TOTAL_SIZE=${total_size}"
266 fi 273 fi
267  274
268-cleanup ${chroot} ${noclean} ${error} "${cleandirs}" ${pkgname} ${build} ${nullfs} 275-cleanup ${chroot} ${noclean} ${error} "${cleandirs}" ${pkgname} ${build} ${nullfs}
269+cleanup ${chroot} ${noclean} ${error} "${cleandirs}" ${pkgname} ${build} 276+cleanup ${chroot} ${noclean} ${error} "${cleandirs}" ${pkgname} ${build}
270 exit ${error} 277 exit ${error}

cvs diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-ar (expand / switch to unified diff)

--- pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-ar 2011/11/14 02:00:20 1.2
+++ pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-ar 2011/11/20 16:20:24 1.3
@@ -1,16 +1,16 @@ @@ -1,16 +1,16 @@
1$NetBSD: patch-ar,v 1.2 2011/11/14 02:00:20 marino Exp $ 1$NetBSD: patch-ar,v 1.3 2011/11/20 16:20:24 marino Exp $
2 2
3--- ../FreeBSD/README 2011-10-30 17:11:08.876006000 +0000 3--- ../FreeBSD/README 2011-11-20 13:18:28.333065000 +0000
4+++ README 4+++ README
5@@ -2,23 +2,30 @@ 5@@ -2,23 +2,30 @@
6  6
7 Tinderbox is a package building system for FreeBSD ports, based on 7 Tinderbox is a package building system for FreeBSD ports, based on
8 official Portbuild scripts used on pointyhat building cluster. 8 official Portbuild scripts used on pointyhat building cluster.
9- Tinderbox was written by Joe Marcus Clarke. 9- Tinderbox was written by Joe Marcus Clarke.
10+ Tinderbox was written by Joe Marcus Clarke, and has 10+ Tinderbox was written by Joe Marcus Clarke, and has
11+ been ported to DragonFly BSD by John Marino. 11+ been ported to DragonFly BSD by John Marino.
12  12
13 You can define multiple jails (base system versions) and multiple 13 You can define multiple jails (base system versions) and multiple
14 portstrees. The combination of jail and portstree is called a 14 portstrees. The combination of jail and portstree is called a
15 build. A Tinderbox jail is not what is understood as a jail in 15 build. A Tinderbox jail is not what is understood as a jail in
16- FreeBSD, it is in fact a given world in a chroot. Tinderbox 16- FreeBSD, it is in fact a given world in a chroot. Tinderbox
@@ -47,41 +47,41 @@ $NetBSD: patch-ar,v 1.2 2011/11/14 02:00 @@ -47,41 +47,41 @@ $NetBSD: patch-ar,v 1.2 2011/11/14 02:00
47  47
48- * ports-mgmt/tinderbox-devel which tracks HEAD and might contain 48- * ports-mgmt/tinderbox-devel which tracks HEAD and might contain
49- additional experimental patches not (yet) present in the CVS. 49- additional experimental patches not (yet) present in the CVS.
50+ The pkgsrc/DragonFly version of Tinderbox repository is 50+ The pkgsrc/DragonFly version of Tinderbox repository is
51+ located at https://github.com/jrmarino/pkgsrc-tinderbox 51+ located at https://github.com/jrmarino/pkgsrc-tinderbox
52  52
53 -------------------------------------------------------------- 53 --------------------------------------------------------------
54  54
55 Chapter 2 Requirements 55 Chapter 2 Requirements
56  56
57- Recent FreeBSD (development happens on 9-CURRENT only, but 57- Recent FreeBSD (development happens on 9-CURRENT only, but
58- Tinderbox is known to work on RELENG_7 and RELENG_8 too), Perl 5.8 58- Tinderbox is known to work on RELENG_7 and RELENG_8 too), Perl 5.8
59- or later (lang/perl5.8), and either MySQL 4.1 or later 59- or later (lang/perl5.8), and either MySQL 4.1 or later
60- (databases/mysql41-server) or PostgreSQL 7.4 or later 60- (databases/mysql41-server) or PostgreSQL 8.2 or later
61- (databases/postgres74-server). 61- (databases/postgresql82-server).
62+ Recent DragonFly, Perl 5.8 or later (lang/perl5), and either  62+ Recent DragonFly, Perl 5.8 or later (lang/perl5), and either
63+ MySQL 5.0 or later (databases/mysql51-server) or  63+ MySQL 5.0 or later (databases/mysql51-server) or
64+ PostgreSQL 8.4 or later (databases/postgres84-server). 64+ PostgreSQL 8.4 or later (databases/postgres84-server).
65  65
66 If MySQL is used, the MySQL Perl module must also be installed 66 If MySQL is used, the MySQL Perl module must also be installed
67- (databases/p5-DBD-mysql41). If PostgreSQL is used, the Pg Perl 67- (databases/p5-DBD-mysql41). If PostgreSQL is used, the Pg Perl
68- module must also be installed (databases/p5-DBD-Pg). 68- module must also be installed (databases/p5-DBD-Pg).
69+ (databases/p5-DBD-mysql). If PostgreSQL is used, the Pg Perl 69+ (databases/p5-DBD-mysql). If PostgreSQL is used, the Pg Perl
70+ module must also be installed (databases/p5-DBD-postgresql). 70+ module must also be installed (databases/p5-DBD-postgresql).
71  71
72- Please note, however, that is is recommended that either MySQL 5.0 72- Note: Please note, however, that is is recommended that for
73- or PostgreSQL 8.1 (or later) be used. There are currently no plans 73- MySQL version 5.0 or later be used. There are currently no plans
74- to make this a requirement, but it may happen in the future. 74- to make this a requirement, but it may happen in the future.
75- 75-
76- PHP 4.x is now EOL, so the web front-end (found in the webui/ 76- PHP 4.x is now EOL, so the web front-end (found in the webui/
77- subdirectory) requires PHP 5 (lang/php5), PEAR::MDB2_Driver_mysql 77- subdirectory) requires PHP 5 (lang/php5), PEAR::MDB2_Driver_mysql
78- (databases/pear-MDB2_Driver_mysql) or PEAR::MDB2_Driver_pgsql 78- (databases/pear-MDB2_Driver_mysql) or PEAR::MDB2_Driver_pgsql
79- (databases/pear-MDB2_Driver_pgsql), PHP Session 79- (databases/pear-MDB2_Driver_pgsql), PHP Session
80- (www/php5-session), and one of the PHP MySQL 80- (www/php5-session), and one of the PHP MySQL
81- (databases/php5-mysql) or PHP Pgsql (databases/php5-pgsql) 81- (databases/php5-mysql) or PHP Pgsql (databases/php5-pgsql)
82- depending on your choice of backend database above. 82- depending on your choice of backend database above.
83+ The web front-end (found in the webui/ subdirectory)  83+ The web front-end (found in the webui/ subdirectory)
84+ requires PHP 5 (lang/php5), 84+ requires PHP 5 (lang/php5),
85+ PEAR::MDB2_Driver_mysql (databases/pear-MDB2_Driver_mysql) or 85+ PEAR::MDB2_Driver_mysql (databases/pear-MDB2_Driver_mysql) or
86+ PEAR::MDB2_Driver_pgsql (databases/pear-MDB2_Driver_pgsql), 86+ PEAR::MDB2_Driver_pgsql (databases/pear-MDB2_Driver_pgsql),
87+ and one of the PHP MySQL (databases/php-mysql) or  87+ and one of the PHP MySQL (databases/php-mysql) or
@@ -536,30 +536,21 @@ $NetBSD: patch-ar,v 1.2 2011/11/14 02:00 @@ -536,30 +536,21 @@ $NetBSD: patch-ar,v 1.2 2011/11/14 02:00
536- Tinderbox can be run in a FreeBSD jail with some concessions. 536- Tinderbox can be run in a FreeBSD jail with some concessions.
537+ Tinderbox can be run in a DragonFly jail with some concessions. 537+ Tinderbox can be run in a DragonFly jail with some concessions.
538  538
539 Since neither NFS nor nullfs (at the time of writing) are usable 539 Since neither NFS nor nullfs (at the time of writing) are usable
540 in a jail, we cannot simply install and use as normal. Instead, we 540 in a jail, we cannot simply install and use as normal. Instead, we
541 simply use a chroot. 541 simply use a chroot.
542  542
543 1. Create a jail for your Tinderbox using the instructions in the 543 1. Create a jail for your Tinderbox using the instructions in the
544- FreeBSD Handbook. 544- FreeBSD Handbook.
545+ DragonFly Handbook. 545+ DragonFly Handbook.
546  546
547 2. Install dependencies into the jail (Chapter 2). 547 2. Install dependencies into the jail (Chapter 2).
548  548
549@@ -919,7 +936,7 @@ 
550  
551 # mkdir ${pb} 
552 # cd ${pb} && \ 
553- fetch -o - path_to_tinderbox-3.3.tar.gz | \ 
554+ fetch -o - path_to_tinderbox-3.4.tar.gz | \ 
555 tar xvf - 
556  
557 4. Now we need to leave the jail, and on the host system chroot 
558@@ -938,7 +955,6 @@ 549@@ -938,7 +955,6 @@
559 tinderd_enable="YES" 550 tinderd_enable="YES"
560 tinderd_chroot="${jail_dir}" 551 tinderd_chroot="${jail_dir}"
561 tinderd_directory="${pb}" 552 tinderd_directory="${pb}"
562- tinderd_flags="-nullfs" 553- tinderd_flags="-nullfs"
563  554
564 7. Install a web server of your choice in the jail, and follow 555 7. Install a web server of your choice in the jail, and follow
565 the webserver setup. 556 the webserver setup.

cvs diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-as (expand / switch to unified diff)

--- pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-as 2011/11/14 02:00:20 1.2
+++ pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-as 2011/11/20 16:20:24 1.3
@@ -1,36 +1,36 @@ @@ -1,36 +1,36 @@
1$NetBSD: patch-as,v 1.2 2011/11/14 02:00:20 marino Exp $ 1$NetBSD: patch-as,v 1.3 2011/11/20 16:20:24 marino Exp $
2 2
3--- ../FreeBSD/lib/tc_command.pl 2011-10-16 00:52:55.000000000 +0000 3--- ../FreeBSD/lib/tc_command.pl 2011-11-20 13:05:28.355724000 +0000
4+++ lib/tc_command.pl 4+++ lib/tc_command.pl
5@@ -1,4 +1,4 @@ 5@@ -1,4 +1,4 @@
6-#!/usr/bin/perl 6-#!/usr/bin/perl
7+#!/usr/pkg/bin/perl 7+#!/usr/pkg/bin/perl
8 #- 8 #-
9 # Copyright (c) 2004-2008 FreeBSD GNOME Team <freebsd-gnome@FreeBSD.org> 9 # Copyright (c) 2004-2008 FreeBSD GNOME Team <freebsd-gnome@FreeBSD.org>
10 # All rights reserved. 10 # All rights reserved.
11@@ -188,15 +188,15 @@ my $ds = new Tinderbox::TinderboxDS(); 11@@ -188,15 +188,15 @@ my $ds = new Tinderbox::TinderboxDS();
12 help => 12 help =>
13 "Add a jail to the datastore (do NOT call this directly; use createJail instead)", 13 "Add a jail to the datastore (do NOT call this directly; use createJail instead)",
14 usage => 14 usage =>
15- "-j <jail name> -u CSUP|CVSUP|LFTP|USER|NONE -t <jail tag> [-d <jail description>] [-m <src mount source>] [-a <arch>]", 15- "-j <jail name> -u CSUP|CVSUP|LFTP|SVN|USER|NONE -t <jail tag> [-d <jail description>] [-m <src mount source>] [-a <arch>]",
16+ "-j <jail name> -u GIT|RELEASE|SNAPSHOT|USER|NONE -t <jail tag> [-d <jail description>] [-m <src mount source>] [-a <arch>]", 16+ "-j <jail name> -u GIT|RELEASE|SNAPSHOT|USER|NONE -t <jail tag> [-d <jail description>] [-m <src mount source>] [-a <arch>]",
17 optstr => 'm:j:t:u:d:a:', 17 optstr => 'm:j:t:u:d:a:',
18 }, 18 },
19 "addPortsTree" => { 19 "addPortsTree" => {
20 func => \&addPortsTree, 20 func => \&addPortsTree,
21 help => "Add a portstree to the datastore", 21 help => "Add a portstree to the datastore",
22 usage => 22 usage =>
23- "-p <portstree name> -u CSUP|CVSUP|USER|NONE [-d <portstree description>] [-m <ports mount source>] [-w <CVSweb URL>]", 23- "-p <portstree name> -u CSUP|CVSUP|SVN|USER|NONE [-d <portstree description>] [-m <ports mount source>] [-w <CVSweb URL>]",
24- optstr => 'm:p:u:d:w:', 24- optstr => 'm:p:u:d:w:',
25+ "-p <portstree name> [-t <cvs tag>] [-d <portstree description>] [-m <ports mount source>] [-w <CVSweb URL>]", 25+ "-p <portstree name> [-t <cvs tag>] [-d <portstree description>] [-m <ports mount source>] [-w <CVSweb URL>]",
26+ optstr => 'm:p:u:t:d:w:', 26+ optstr => 'm:p:u:t:d:w:',
27 }, 27 },
28 "addPort" => { 28 "addPort" => {
29 help => "Add a port to the datastore", 29 help => "Add a port to the datastore",
30@@ -240,9 +240,16 @@ my $ds = new Tinderbox::TinderboxDS(); 30@@ -240,9 +240,16 @@ my $ds = new Tinderbox::TinderboxDS();
31 func => \&getDependenciesForPort, 31 func => \&getDependenciesForPort,
32 help => "Get stored dependencies for a given port and build", 32 help => "Get stored dependencies for a given port and build",
33 usage => 33 usage =>
34- "-b <build name> -d <port directory> [-t EXTRACT_DEPENDS|PATCH_DEPENDS|FETCH_DEPENDS|BUILD_DEPENDS|LIB_DEPENDS|RUN_DEPENDS|TEST_DEPENDS]", 34- "-b <build name> -d <port directory> [-t EXTRACT_DEPENDS|PATCH_DEPENDS|FETCH_DEPENDS|BUILD_DEPENDS|LIB_DEPENDS|RUN_DEPENDS|TEST_DEPENDS]",
35+ "-b <build name> -d <port directory> [-t EXTRACT_DEPENDS|PATCH_DEPENDS|FETCH_DEPENDS|BUILD_DEPENDS|LIB_DEPENDS|RUN_DEPENDS|TEST_DEPENDS|DEPENDS]", 35+ "-b <build name> -d <port directory> [-t EXTRACT_DEPENDS|PATCH_DEPENDS|FETCH_DEPENDS|BUILD_DEPENDS|LIB_DEPENDS|RUN_DEPENDS|TEST_DEPENDS|DEPENDS]",
36 optstr => 'b:d:t:', 36 optstr => 'b:d:t:',
@@ -39,37 +39,37 @@ $NetBSD: patch-as,v 1.2 2011/11/14 02:00 @@ -39,37 +39,37 @@ $NetBSD: patch-as,v 1.2 2011/11/14 02:00
39+ func => \&getDependencyCascades, 39+ func => \&getDependencyCascades,
40+ help => "Get unique dependencies of port's dependencies, recursively", 40+ help => "Get unique dependencies of port's dependencies, recursively",
41+ usage => 41+ usage =>
42+ "-b <build name> -d <port directory>", 42+ "-b <build name> -d <port directory>",
43+ optstr => 'b:d:', 43+ optstr => 'b:d:',
44+ }, 44+ },
45 "listHooks" => { 45 "listHooks" => {
46 func => \&listHooks, 46 func => \&listHooks,
47 help => 47 help =>
48@@ -560,15 +567,15 @@ my $ds = new Tinderbox::TinderboxDS(); 48@@ -560,15 +567,15 @@ my $ds = new Tinderbox::TinderboxDS();
49 "createJail" => { 49 "createJail" => {
50 help => "Create a new jail", 50 help => "Create a new jail",
51 usage => 51 usage =>
52- "-j <jailname> -u CSUP|CVSUP|LFTP|USER|NONE [-t <tag>] [-d <description>] [-C] [-H <updatehost>] [-m <mountsrc>] [-I] [-a <arch>]", 52- "-j <jailname> -u CSUP|CVSUP|LFTP|SVN|USER|NONE [-t <tag>] [-d <description>] [-C] [-P <protocol>] [-H <updatehost>] [-D <updatehostdirectory>] [-m <mountsrc>] [-I] [-a <arch>]",
53- optstr => 'j:t:d:CH:m:u:Ia:', 53- optstr => 'j:t:d:CP:H:D:m:u:Ia:',
54+ "-j <jailname> -u GIT|RELEASE|SNAPSHOT|USER|NONE -t <tag> [-d <description>] [-H <updatehost>] [-m <mountsrc>] [-I]", 54+ "-j <jailname> -u GIT|RELEASE|SNAPSHOT|USER|NONE -t <tag> [-d <description>] [-H <updatehost>] [-m <mountsrc>] [-I]",
55+ optstr => 'j:t:d:H:m:u:I:', 55+ optstr => 'j:t:d:H:m:u:I:',
56 }, 56 },
57  57
58 "createPortsTree" => { 58 "createPortsTree" => {
59 help => "Create a new portstree", 59 help => "Create a new portstree",
60 usage => 60 usage =>
61- "-p <portstreename> -u CSUP|CVSUP|USER|NONE [-d <description>] [-C] [-H <updatehost>] [-m <mountsrc>] [-w <cvsweburl>] [-I]", 61- "-p <portstreename> -u CSUP|CVSUP|SVN|USER|NONE [-d <description>] [-C] [-P <protocol>] [-H <updatehost>] [-D <updatehostdirectory>] [-m <mountsrc>] [-w <cvsweburl>] [-I]",
62- optstr => 'p:d:CH:Im:u:w:', 62- optstr => 'p:d:CP:H:Im:u:w:',
63+ "-p <portstreename> [-t <cvs tag>] [-d <description>] [-C] [-H <updatehost>] [-m <mountsrc>] [-w <cvsweburl>] [-I]", 63+ "-p <portstreename> [-t <cvs tag>] [-d <description>] [-C] [-H <updatehost>] [-m <mountsrc>] [-w <cvsweburl>] [-I]",
64+ optstr => 'p:t:d:CH:Im:u:w:', 64+ optstr => 'p:t:d:CH:Im:u:w:',
65 }, 65 },
66  66
67 "createBuild" => { 67 "createBuild" => {
68@@ -592,21 +599,21 @@ my $ds = new Tinderbox::TinderboxDS(); 68@@ -592,21 +599,21 @@ my $ds = new Tinderbox::TinderboxDS();
69  69
70 "resetBuild" => { 70 "resetBuild" => {
71 help => "Cleanup and reset a Build environment", 71 help => "Cleanup and reset a Build environment",
72- usage => "-b <buildname> [-n]", 72- usage => "-b <buildname> [-n]",
73- optstr => 'b:n', 73- optstr => 'b:n',
74+ usage => "-b <buildname>", 74+ usage => "-b <buildname>",
75+ optstr => 'b:', 75+ optstr => 'b:',
@@ -81,69 +81,115 @@ $NetBSD: patch-as,v 1.2 2011/11/14 02:00 @@ -81,69 +81,115 @@ $NetBSD: patch-as,v 1.2 2011/11/14 02:00
81- "-b <build name> [-init] [-cleanpackages] [-updateports] [-skipmake] [-noclean] [-noduds] [-plistcheck] [-nullfs] [-cleandistfiles] [-fetch-original] [-onceonly] [portdir/portname [...]]", 81- "-b <build name> [-init] [-cleanpackages] [-updateports] [-skipmake] [-noclean] [-noduds] [-plistcheck] [-nullfs] [-cleandistfiles] [-fetch-original] [-onceonly] [portdir/portname [...]]",
82+ "-b <build name> [-init] [-cleanpackages] [-updateports] [-skipmake] [-noclean] [-noduds] [-plistcheck] [-cleandistfiles] [-fetch-original] [-onceonly] [portdir/portname [...]]", 82+ "-b <build name> [-init] [-cleanpackages] [-updateports] [-skipmake] [-noclean] [-noduds] [-plistcheck] [-cleandistfiles] [-fetch-original] [-onceonly] [portdir/portname [...]]",
83 optstr => 'b:', 83 optstr => 'b:',
84 }, 84 },
85  85
86 "updatePortsTree" => { 86 "updatePortsTree" => {
87 help => "Update an existing ports tree", 87 help => "Update an existing ports tree",
88 usage => "-p <portstreename>", 88 usage => "-p <portstreename>",
89- optstr => 'p', 89- optstr => 'p',
90+ optstr => 'p:', 90+ optstr => 'p:',
91 }, 91 },
92  92
93 "copyBuild" => { 93 "copyBuild" => {
94@@ -1489,7 +1496,7 @@ sub addPortsTree { 94@@ -1489,8 +1496,18 @@ sub addPortsTree {
95 sub addPortToOneBuild { 95 sub addPortToOneBuild {
96 my $build = $ds->getBuildByName($opts->{'b'}); 96 my $build = $ds->getBuildByName($opts->{'b'});
97 my $makecache = 97 my $makecache =
98- new Tinderbox::MakeCache($ENV{'PORTSDIR'}, $ENV{'PKGSUFFIX'}); 98- new Tinderbox::MakeCache($ENV{'PORTSDIR'}, $ENV{'PKGSUFFIX'});
99+ new Tinderbox::MakeCache($ENV{'PORTSDIR'}, $ENV{'OPTNFILE'}); 99+ new Tinderbox::MakeCache($ENV{'PORTSDIR'}, $ENV{'OPTNFILE'});
100 my @bports = (); 100 my @bports = ();
 101+ my %oper_hash = (
 102+ EXTRACT_DEPENDS => 'ExtractDepends',
 103+ PATCH_DEPENDS => 'PatchDepends',
 104+ FETCH_DEPENDS => 'FetchDepends',
 105+ BUILD_DEPENDS => 'BuildDepends',
 106+ LIB_DEPENDS => 'LibDepends',
 107+ RUN_DEPENDS => 'RunDepends',
 108+ TEST_DEPENDS => 'TestDepends',
 109+ DEPENDS => 'Buildlink3Depends',
 110+ );
101  111
102 if (!$opts->{'d'}) { 112 if (!$opts->{'d'}) {
103@@ -1524,6 +1531,7 @@ sub addPortToOneBuild { 113 foreach my $port ($ds->getPortsForBuild($build)) {
104 LIB_DEPENDS => 'LibDepends', 114@@ -1502,7 +1519,25 @@ sub addPortToOneBuild {
105 RUN_DEPENDS => 'RunDepends', 115
106 TEST_DEPENDS => 'TestDepends', 116 if ($opts->{'R'}) {
107+ DEPENDS => 'Buildlink3Depends', 117 foreach my $pdir (@bports) {
108 ); 118- addPorts($pdir, $build, $makecache, undef);
 119+ my $pCls = addPorts($pdir, $build, $makecache, undef);
 120+ $ds->clearDependenciesForPort($pCls, $build, undef);
 121+ foreach my $deptype (keys %oper_hash) {
 122+ my $oper = $oper_hash{$deptype};
 123+ foreach my $dn ($makecache->$oper($pdir)) {
 124+ my $dep = $ds->getPortByDirectory($dn);
 125+ next if (!defined($dep));
 126+ if (
 127+ !$ds->addDependencyForPort(
 128+ $pCls, $build,
 129+ $deptype, $dep
 130+ )
 131+ )
 132+ {
 133+ warn "WARN: Failed to add $deptype entry for $pdir: "
 134+ . $ds->getError() . "\n";
 135+ }
 136+ }
 137+ }
 138 }
 139 } else {
 140 my @deps = @bports;
 141@@ -1516,15 +1551,6 @@ sub addPortToOneBuild {
 142 }
 143 foreach my $port (keys %seen) {
 144 my $pCls = $seen{$port};
 145- my %oper_hash = (
 146- EXTRACT_DEPENDS => 'ExtractDepends',
 147- PATCH_DEPENDS => 'PatchDepends',
 148- FETCH_DEPENDS => 'FetchDepends',
 149- BUILD_DEPENDS => 'BuildDepends',
 150- LIB_DEPENDS => 'LibDepends',
 151- RUN_DEPENDS => 'RunDepends',
 152- TEST_DEPENDS => 'TestDepends',
 153- );
109  154
110 $ds->clearDependenciesForPort($pCls, $build, undef); 155 $ds->clearDependenciesForPort($pCls, $build, undef);
111@@ -1548,7 +1556,6 @@ sub addPortToOneBuild { 156
 157@@ -1548,7 +1574,6 @@ sub addPortToOneBuild {
112 } 158 }
113 } 159 }
114 } 160 }
115- 161-
116 } 162 }
117 } 163 }
118  164
119@@ -1600,7 +1607,7 @@ sub addBuildPortsQueueEntry { 165@@ -1600,7 +1625,7 @@ sub addBuildPortsQueueEntry {
120 $ds->addBuildPortsQueueEntry($build, $portdir, $priority, 166 $ds->addBuildPortsQueueEntry($build, $portdir, $priority,
121 $user_id); 167 $user_id);
122 if (!$rc) { 168 if (!$rc) {
123- warn( "Failed to add port "  169- warn( "Failed to add port "
124+ warn( "Failed to add port " 170+ warn( "Failed to add port "
125 . $portdir 171 . $portdir
126 . " to the datastore: " 172 . " to the datastore: "
127 . $ds->getError() 173 . $ds->getError()
128@@ -1720,6 +1727,7 @@ sub getDependenciesForPort { 174@@ -1720,6 +1745,7 @@ sub getDependenciesForPort {
129 LIB_DEPENDS => 4, 175 LIB_DEPENDS => 4,
130 RUN_DEPENDS => 5, 176 RUN_DEPENDS => 5,
131 TEST_DEPEND => 6, 177 TEST_DEPEND => 6,
132+ DEPENDS => 7, 178+ DEPENDS => 7,
133 ); 179 );
134  180
135 if (!$opts->{'b'} || !$opts->{'d'}) { 181 if (!$opts->{'b'} || !$opts->{'d'}) {
136@@ -1773,6 +1781,50 @@ sub getDependenciesForPort { 182@@ -1773,6 +1799,50 @@ sub getDependenciesForPort {
137 ); 183 );
138 } 184 }
139 } 185 }
140+ 186+
141+sub getDependencyCascades { 187+sub getDependencyCascades {
142+ if (!$opts->{'b'} || !$opts->{'d'}) { 188+ if (!$opts->{'b'} || !$opts->{'d'}) {
143+ usage("getDependencyCascades"); 189+ usage("getDependencyCascades");
144+ } 190+ }
145+ 191+
146+ my $port = $ds->getPortByDirectory($opts->{'d'}); 192+ my $port = $ds->getPortByDirectory($opts->{'d'});
147+ if (!defined($port)) { 193+ if (!defined($port)) {
148+ cleanup($ds, 1, 194+ cleanup($ds, 1,
149+ "Port, " 195+ "Port, "

cvs diff -r1.2 -r1.3 pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-aw (expand / switch to unified diff)

--- pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-aw 2011/11/14 02:00:20 1.2
+++ pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-aw 2011/11/20 16:20:24 1.3
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1$NetBSD: patch-aw,v 1.2 2011/11/14 02:00:20 marino Exp $ 1$NetBSD: patch-aw,v 1.3 2011/11/20 16:20:24 marino Exp $
2 2
3--- ../FreeBSD/lib/Tinderbox/MakeCache.pm 2011-10-16 00:52:55.000000000 +0000 3--- ../FreeBSD/lib/Tinderbox/MakeCache.pm 2011-10-16 00:52:55.000000000 +0000
4+++ lib/Tinderbox/MakeCache.pm 4+++ lib/Tinderbox/MakeCache.pm
5@@ -31,14 +31,14 @@ use strict; 5@@ -31,14 +31,14 @@ use strict;
6  6
7 # a list of variables that we pull from the port Makefile 7 # a list of variables that we pull from the port Makefile
8 our @makeTargets = ( 8 our @makeTargets = (
9- 'PKGNAME', 'IGNORE', 9- 'PKGNAME', 'IGNORE',
10- 'NO_PACKAGE', 'FORBIDDEN', 10- 'NO_PACKAGE', 'FORBIDDEN',
11+ 'PKGNAME', '_CBBH', 11+ 'PKGNAME', '_CBBH',
12 'EXTRACT_DEPENDS', 'PATCH_DEPENDS', 12 'EXTRACT_DEPENDS', 'PATCH_DEPENDS',
13 'FETCH_DEPENDS', 'BUILD_DEPENDS', 13 'FETCH_DEPENDS', 'BUILD_DEPENDS',
14 'LIB_DEPENDS', 'RUN_DEPENDS', 14 'LIB_DEPENDS', 'RUN_DEPENDS',
@@ -19,66 +19,66 @@ $NetBSD: patch-aw,v 1.2 2011/11/14 02:00 @@ -19,66 +19,66 @@ $NetBSD: patch-aw,v 1.2 2011/11/14 02:00
19+ 'DISTFILES', 'BOOTSTRAP_DEPENDS', 19+ 'DISTFILES', 'BOOTSTRAP_DEPENDS',
20+ 'DEPENDS' 20+ 'DEPENDS'
21 ); 21 );
22  22
23 # Create a new cache object 23 # Create a new cache object
24@@ -48,6 +48,7 @@ sub new { 24@@ -48,6 +48,7 @@ sub new {
25 CACHE => undef, 25 CACHE => undef,
26 SEEN => undef, 26 SEEN => undef,
27 BASEDIR => shift, 27 BASEDIR => shift,
28+ OPTFILE => shift, 28+ OPTFILE => shift,
29 }, $name; 29 }, $name;
30  30
31 $self; 31 $self;
32@@ -60,20 +61,94 @@ sub _execMake { 32@@ -60,20 +61,95 @@ sub _execMake {
33 my $self = shift; 33 my $self = shift;
34 my $port = shift; 34 my $port = shift;
35 my @ret; 35 my @ret;
36- my $tmp; 36- my $tmp;
37+ my $target; 37+ my $target;
38+ my $deptype; 38+ my $deptype;
39+ my $tmp = ''; 39+ my $tmp = '';
40  40
41 return if ($self->{SEEN}->{$port} eq 1); 41 return if ($self->{SEEN}->{$port} eq 1);
42  42
43- $tmp = '-V ' . join(' -V ', @makeTargets); 43- $tmp = '-V ' . join(' -V ', @makeTargets);
44+ foreach $target (@makeTargets) { 44+ foreach $target (@makeTargets) {
45+ $tmp .= "-V '\${" . $target . "}' ";  45+ $tmp .= "-V '\${" . $target . "}' ";
46+ } 46+ }
47 my $dir = $self->{BASEDIR} . '/' . $port; 47 my $dir = $self->{BASEDIR} . '/' . $port;
48- @ret = split("\n", `cd $dir && make $tmp`); 48- @ret = split("\n", `cd $dir && make $tmp`);
49+ my $customOptions = $self->_package_options ($dir); 49+ my $customOptions = $self->_package_options ($dir);
50+ my $nativeOptions = $self->_native_preferences (); 50+ my $nativeOptions = $self->_native_preferences ();
51+ @ret = split("\n", `cd $dir && bmake $customOptions $nativeOptions $tmp`); 51+ @ret = split("\n", `cd $dir && bmake $customOptions $nativeOptions $tmp`);
52  52
53 foreach $tmp (@makeTargets) { 53 foreach $tmp (@makeTargets) {
54- $self->{CACHE}->{$port}{$tmp} = shift @ret; 54- $self->{CACHE}->{$port}{$tmp} = shift @ret;
55+ $deptype = $tmp; 55+ $deptype = $tmp;
56+ if (${tmp} eq "BOOTSTRAP_DEPENDS") { 56+ if (${tmp} eq "BOOTSTRAP_DEPENDS") {
57+ $deptype = "FETCH_DEPENDS"; 57+ $deptype = "FETCH_DEPENDS";
58+ } 58+ }
59+ $self->{CACHE}->{$port}{$deptype} = shift @ret; 59+ $self->{CACHE}->{$port}{$deptype} = shift @ret;
60 } 60 }
61 $self->{SEEN}->{$port} = 1; 61 $self->{SEEN}->{$port} = 1;
62 } 62 }
63  63
64+# Get option variable name and requested options 64+# Get option variable name and requested options
65+sub _package_options { 65+sub _package_options {
66+ my $self = shift; 66+ my $self = shift;
67+ my $dir = shift; 67+ my $dir = shift;
68+ unless (-e $self->{OPTFILE}) { 68+ unless (-e $self->{OPTFILE}) {
69+ return ""; 69+ return "";
70+ } 70+ }
71+ my @data = split("\n",  71+ my @data = split("\n",
72+ `cd $dir && bmake -V '\${PKGNAME}' -V '\${PKG_OPTIONS_VAR}'`); 72+ `cd $dir && bmake -V '\${PKGNAME}' -V '\${PKG_OPTIONS_VAR}'`);
73+ my $pkname = $data[0]; 73+ my $pkname = $data[0];
74+ my $optvar = $data[1]; 74+ my $optvar = $data[1];
75+ $pkname =~ s/nb[0-9]+$//; 75+ $pkname =~ s/nb[0-9]+$//;
76+ my $instruction = `grep ^$pkname: $self->{OPTFILE}`; 76+ my $instruction = `grep ^$pkname: $self->{OPTFILE}`;
77+ unless ($instruction) { 77+ unless ($instruction) {
78+ return ""; 78+ return "";
79+ } 79+ }
80+ my @customSet = split(/:/, $instruction); 80+ my @customSet = split(/:/, $instruction);
81+ unless (scalar (@customSet) >= 3) { 81+ unless (scalar (@customSet) >= 3) {
82+ return ""; 82+ return "";
83+ } 83+ }
84+ return $optvar . '="' . $customSet[2] . '"'; 84+ return $optvar . '="' . $customSet[2] . '"';
@@ -106,39 +106,40 @@ $NetBSD: patch-aw,v 1.2 2011/11/14 02:00 @@ -106,39 +106,40 @@ $NetBSD: patch-aw,v 1.2 2011/11/14 02:00
106+ my $result = ""; 106+ my $result = "";
107+ my $ppkgsrc=`grep PREFER_PKGSRC $moremk`; 107+ my $ppkgsrc=`grep PREFER_PKGSRC $moremk`;
108+ my $pnative=`grep PREFER_NATIVE $moremk`; 108+ my $pnative=`grep PREFER_NATIVE $moremk`;
109+ my $develop=`grep PKG_DEVELOPER $moremk`; 109+ my $develop=`grep PKG_DEVELOPER $moremk`;
110+ if ($ppkgsrc) { 110+ if ($ppkgsrc) {
111+ @worker = split(/=/, $ppkgsrc); 111+ @worker = split(/=/, $ppkgsrc);
112+ if (scalar (@worker) >= 2) { 112+ if (scalar (@worker) >= 2) {
113+ $result = 'PREFER_PKGSRC="' . $self->_trim($worker[1]) . '" '; 113+ $result = 'PREFER_PKGSRC="' . $self->_trim($worker[1]) . '" ';
114+ } 114+ }
115+ } 115+ }
116+ if ($pnative) { 116+ if ($pnative) {
117+ @worker = split(/=/, $pnative); 117+ @worker = split(/=/, $pnative);
118+ if (scalar (@worker) >= 2) { 118+ if (scalar (@worker) >= 2) {
119+ $result .= 'PREFER_NATIVE="' . $self->_trim($worker[1]) . '"'; 119+ $result .= 'PREFER_NATIVE="' . $self->_trim($worker[1]) . '" ';
120+ } 120+ }
121+ } 121+ }
122+ if ($develop) { 122+ if ($develop) {
123+ $result .= 'PKG_DEVELOPER=yes'; 123+ $result .= 'PKG_DEVELOPER=yes ';
124+ } 124+ }
 125+ $result .= 'SKIP_LICENSE_CHECK=yes ';
125+ return $result; 126+ return $result;
126+} 127+}
127+ 128+
128 # Internal function for returning a port variable 129 # Internal function for returning a port variable
129 sub _getVariable { 130 sub _getVariable {
130 my $self = shift; 131 my $self = shift;
131@@ -90,16 +165,28 @@ sub _getList { 132@@ -90,16 +166,28 @@ sub _getList {
132 my $port = shift; 133 my $port = shift;
133 my $item = shift; 134 my $item = shift;
134 my @deps; 135 my @deps;
135+ my $found; 136+ my $found;
136  137
137 $self->_execMake($port); 138 $self->_execMake($port);
138 foreach my $dep (split(/\s+/, $self->{CACHE}->{$port}{$item})) { 139 foreach my $dep (split(/\s+/, $self->{CACHE}->{$port}{$item})) {
139+ $dep =~ s/^\s+//; 140+ $dep =~ s/^\s+//;
140+ $dep =~ s/\s+$//; 141+ $dep =~ s/\s+$//;
141 my ($d, $ddir) = split(/:/, $dep); 142 my ($d, $ddir) = split(/:/, $dep);
142- if (!defined($ddir) || $item eq 'DEPENDS') { 143- if (!defined($ddir) || $item eq 'DEPENDS') {
143+ if (!defined($ddir)) { 144+ if (!defined($ddir)) {
144 $ddir = $d; 145 $ddir = $d;
@@ -149,81 +150,81 @@ $NetBSD: patch-aw,v 1.2 2011/11/14 02:00 @@ -149,81 +150,81 @@ $NetBSD: patch-aw,v 1.2 2011/11/14 02:00
149- push @deps, $ddir; 150- push @deps, $ddir;
150+ $found = 0; 151+ $found = 0;
151+ foreach my $storedep (@deps) { 152+ foreach my $storedep (@deps) {
152+ if ($storedep eq $ddir) { 153+ if ($storedep eq $ddir) {
153+ $found = 1; 154+ $found = 1;
154+ } 155+ }
155+ } 156+ }
156+ if (!$found) { 157+ if (!$found) {
157+ push @deps, $ddir; 158+ push @deps, $ddir;
158+ } 159+ }
159 } 160 }
160 } 161 }
161 return @deps; 162 return @deps;
162@@ -109,7 +196,7 @@ sub _getList { 163@@ -109,7 +197,7 @@ sub _getList {
163 sub Name { 164 sub Name {
164 my $self = shift; 165 my $self = shift;
165 my $port = shift; 166 my $port = shift;
166- return $self->_getVariable($port, 'PORTNAME'); 167- return $self->_getVariable($port, 'PORTNAME');
167+ return $self->_getVariable($port, 'PKGBASE'); 168+ return $self->_getVariable($port, 'PKGBASE');
168 } 169 }
169  170
170 # Package name 171 # Package name
171@@ -133,6 +220,13 @@ sub Maintainer { 172@@ -133,6 +221,13 @@ sub Maintainer {
172 return $self->_getVariable($port, 'MAINTAINER'); 173 return $self->_getVariable($port, 'MAINTAINER');
173 } 174 }
174  175
175+# Buildlink3 dependencies 176+# Buildlink3 dependencies
176+sub Buildlink3Depends { 177+sub Buildlink3Depends {
177+ my $self = shift; 178+ my $self = shift;
178+ my $port = shift; 179+ my $port = shift;
179+ return $self->_getList($port, 'DEPENDS'); 180+ return $self->_getList($port, 'DEPENDS');
180+} 181+}
181+ 182+
182 # Extract dependencies 183 # Extract dependencies
183 sub ExtractDepends { 184 sub ExtractDepends {
184 my $self = shift; 185 my $self = shift;
185@@ -189,8 +283,8 @@ sub IgnoreList { 186@@ -189,8 +284,8 @@ sub IgnoreList {
186  187
187 my $n = 0; 188 my $n = 0;
188 $self->_execMake($port); 189 $self->_execMake($port);
189- foreach my $var ('NO_PACKAGE', 'IGNORE', 'FORBIDDEN') { 190- foreach my $var ('NO_PACKAGE', 'IGNORE', 'FORBIDDEN') {
190- $n++ if ($self->{CACHE}->{$port}{$var} ne ""); 191- $n++ if ($self->{CACHE}->{$port}{$var} ne "");
191+ foreach my $var ('_CBBH') { 192+ foreach my $var ('_CBBH') {
192+ $n++ if ($self->{CACHE}->{$port}{$var} ne "yes"); 193+ $n++ if ($self->{CACHE}->{$port}{$var} ne "yes");
193 } 194 }
194 return $n eq 0 ? "" : $self->PkgName($port); 195 return $n eq 0 ? "" : $self->PkgName($port);
195 } 196 }
196@@ -206,6 +300,17 @@ sub FetchDependsList { 197@@ -206,6 +301,17 @@ sub FetchDependsList {
197 return grep { !$uniq{$_}++ } @deps; 198 return grep { !$uniq{$_}++ } @deps;
198 } 199 }
199  200
200+sub Buildlink3DependsList { 201+sub Buildlink3DependsList {
201+ my $self = shift; 202+ my $self = shift;
202+ my $port = shift; 203+ my $port = shift;
203+ 204+
204+ my @deps; 205+ my @deps;
205+ push(@deps, $self->Buildlink3Depends($port)); 206+ push(@deps, $self->Buildlink3Depends($port));
206+ 207+
207+ my %uniq; 208+ my %uniq;
208+ return grep { !$uniq{$_}++ } @deps; 209+ return grep { !$uniq{$_}++ } @deps;
209+} 210+}
210+ 211+
211 sub ExtractDependsList { 212 sub ExtractDependsList {
212 my $self = shift; 213 my $self = shift;
213 my $port = shift; 214 my $port = shift;
214@@ -250,6 +355,7 @@ sub BuildDependsList { 215@@ -250,6 +356,7 @@ sub BuildDependsList {
215 push(@deps, $self->FetchDepends($port)); 216 push(@deps, $self->FetchDepends($port));
216 push(@deps, $self->BuildDepends($port)); 217 push(@deps, $self->BuildDepends($port));
217 push(@deps, $self->LibDepends($port)); 218 push(@deps, $self->LibDepends($port));
218+ push(@deps, $self->Buildlink3Depends($port)); 219+ push(@deps, $self->Buildlink3Depends($port));
219  220
220 my %uniq; 221 my %uniq;
221 return grep { !$uniq{$_}++ } @deps; 222 return grep { !$uniq{$_}++ } @deps;
222@@ -263,6 +369,7 @@ sub RunDependsList { 223@@ -263,6 +370,7 @@ sub RunDependsList {
223 my @deps; 224 my @deps;
224 push(@deps, $self->LibDepends($port)); 225 push(@deps, $self->LibDepends($port));
225 push(@deps, $self->RunDepends($port)); 226 push(@deps, $self->RunDepends($port));
226+ push(@deps, $self->Buildlink3Depends($port)); 227+ push(@deps, $self->Buildlink3Depends($port));
227  228
228 my %uniq; 229 my %uniq;
229 return grep { !$uniq{$_}++ } @deps; 230 return grep { !$uniq{$_}++ } @deps;

File Deleted: pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-ag

File Deleted: pkgsrc/pkgtools/tinderbox-dragonfly/patches/Attic/patch-ah