1 |
commit: 52b1d1bf7ce8a7a58c60118a301fb0ba3f1d4729 |
2 |
Author: Michał Górny <mgorny <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Feb 26 07:58:23 2018 +0000 |
4 |
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Feb 26 08:04:39 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=52b1d1bf |
7 |
|
8 |
sys-freebsd/freebsd-usbin: Revert "Remove 9.1" |
9 |
|
10 |
Restore 9.1 version. Its removal was premature, and we should fix |
11 |
the CI problems via masking old versions in new profiles instead. |
12 |
|
13 |
sys-freebsd/freebsd-usbin/Manifest | 10 ++ |
14 |
.../files/freebsd-usbin-9.1-bsdxml2expat.patch | 12 ++ |
15 |
.../files/freebsd-usbin-9.1-kldxref.patch | 30 ++++ |
16 |
.../freebsd-usbin/freebsd-usbin-9.1-r1.ebuild | 170 +++++++++++++++++++++ |
17 |
4 files changed, 222 insertions(+) |
18 |
|
19 |
diff --git a/sys-freebsd/freebsd-usbin/Manifest b/sys-freebsd/freebsd-usbin/Manifest |
20 |
index f3dcd89d595..f9c678f284c 100644 |
21 |
--- a/sys-freebsd/freebsd-usbin/Manifest |
22 |
+++ b/sys-freebsd/freebsd-usbin/Manifest |
23 |
@@ -1 +1,11 @@ |
24 |
+DIST freebsd-contrib-9.1.tar.bz2 54751432 BLAKE2B 8a30e78021e6388d679637d2dbe0ed3f4896d3902064baaafa79de9c328171cbcb895b0ffd3d0d0cd3ca25c93a73584ed4900b45bd672a73b15b75721de59de5 SHA512 71be13049258c6e6b5e4f63cc16da5d349a89d68f04d87446e4ad33ae8bf2a93ea67d9c256b7bec60b61e65db0487268070cfb77a484c3ac0f8ba368b48c2438 |
25 |
+DIST freebsd-etc-9.1.tar.bz2 207776 BLAKE2B 61fbfa11dfcd24c007c20940a4b7cc802dfb9a991e41433840c57f113eaaa9e2b833a15f48d60c706e55d941b0a999baabd0c33197cffd522b67c57eaa9460f1 SHA512 4fbe56fde519cf2f44e39a8869efa26c34f703cf540f4a83389da8d170873d7c6fb18e4010e643b8d793cfc5c55d15eeb198057a5b2a8da9d9e8f791801bf314 |
26 |
+DIST freebsd-gnu-9.1.tar.bz2 795778 BLAKE2B a922a8bd2c8a7ddbac757e7db900109918bf214a34988adb45bdb11e5c829445cac9b13b0ed27ec62603aeae1e3230af362682182494db0ec95ff47cbfd7d927 SHA512 b05f2a5a10bdaeef19dfd0e962bc09f1571288a831e9345f404b920037f47db5c0ca3d620d1cbdd138b18bca1c3feab5b211b57e3041727341e5238cb9feb4fd |
27 |
+DIST freebsd-include-9.1.tar.bz2 146881 BLAKE2B 3db8570a8c841ec1c9ceff479bd0ef9b146b2a343d6596892c9d8a9f9193404f6c62712cb96d7416c6e5cc4c46e7fb942421c47e1bc2c707dde534e2050be442 SHA512 779c8315ce2b10b343bb62e331525d510b0d68ce5d665a1672bd6f4d1eff6445bc6b7a0f178b319828aa203c4e4c04c561ce793052703f4f936ce9711280a0c9 |
28 |
+DIST freebsd-lib-9.1.tar.bz2 3206685 BLAKE2B 67f93b7951fc03e877ee525d53b81ba49c8c1a70041c30aac97665d5dab7b3f2817fdb3bbb1475be66c33a7f996309e9020f1a3d1154fab8e2f6789f5ae0bb18 SHA512 40d0c36b6b889c404fa0e0afa38ba4e84a55bc88ffa2f98a70afbd7a32c4f32c158617ba770567d082a986d62c09b3ec8db3dc5ab853ee1c9bbe0b90bb82396e |
29 |
+DIST freebsd-libexec-9.1.tar.bz2 304592 BLAKE2B 994543ac910e4703d36682f6c0550596e340605754b9386770660f0ed0e70f8d437185f2010e6be795a8cc508aa7d69c90cc0a0df968c5dd8de4c5c4bb38e8c2 SHA512 7baa4160dda2610250dd52f445e24478e0f1ea10bce21fcd0e5d1b856f399b896adc334114de0c7f61a5637e4349bb1688fdbe5c72798d8568ae791114710b92 |
30 |
+DIST freebsd-sbin-9.1.tar.bz2 1273913 BLAKE2B c00fea446a19311020ae081ba00d6c7d0b3b0365ab2046ec24252c2b02d4b4079fb7bbbf0d17432e2a1efb0788b552d684b1b91bbbb05d2c1712a93380a89b49 SHA512 9f186602b7de96f268c352ca386986652fddf5570e7eca1afa8c0d2bdc83b57df1198efe47f36dd5c7a6abf4f9c935f1c8207a4a12a6b2153bd6c3c6292719dc |
31 |
DIST freebsd-src-11.1.tar.xz 147661560 BLAKE2B a9e6ba9d0e12c8b56ac58575d5f02931edbb6a3545d9dccae78810d2d0470a29b29dd7f724b03b8afafbca23717a71346e4cfbd3530e0f40118a23609c3f414e SHA512 b97707ec7a601ca6bcb682c45f6d94a38484301ac24630d7285eff6f88b027ce6900c93fc62f8ce36e0cf32c91f73a9d1c999db397b7f8782fd74a8551a03aca |
32 |
+DIST freebsd-sys-9.1.tar.bz2 32588103 BLAKE2B 7f94a4735c6a17b39a86fa0fda0682924b18e4b466dc6319a5df889522aaeaffaa87e1b76582c48ae034df8c20169c8cea93bbd3d6e7abd0526716686f88dfe8 SHA512 7dc9d9e00dde8f592bb171f4386d02b655b73cb4f153fe5ec063d010a148ef0639eae0dcdb3eeb09ecd1e3653c69e49a2d261329fa6d0381d2ddabe258ddde6d |
33 |
+DIST freebsd-ubin-9.1.tar.bz2 1910472 BLAKE2B 4bab770072543d9eb25ce7ce450084e0eb9ca603deb58886a26495a92a05373f4f8f5821c65dc76365bf325a7291e6b630b00af5ba895784093d450163637504 SHA512 74ae0aceec8597aa66c3f1ab313f0685a3c63d7273c36ae7baf8794275ad9bca241c60c3f6281cccf6d531d250d7611099977d3b1a27279cef3586401b6af05e |
34 |
+DIST freebsd-usbin-9.1.tar.bz2 2670916 BLAKE2B 353c7e641c0cccf25b99cb454368bd3001cd6b85a15956b1ee2de1ab240c420602e04bf6d0389aca0bdd4f7d1206a6848516e58a17eda4881d849f078b71a139 SHA512 21c234312f70eb35cd2926519efc1f61592892f5d0940786dbeb959c3c5ec7819a51ae95c6e8a1a06aa01f669350fe0fd3dd7c4ec8a84dd6b90f24cb192356ca |
35 |
|
36 |
diff --git a/sys-freebsd/freebsd-usbin/files/freebsd-usbin-9.1-bsdxml2expat.patch b/sys-freebsd/freebsd-usbin/files/freebsd-usbin-9.1-bsdxml2expat.patch |
37 |
new file mode 100644 |
38 |
index 00000000000..bddc0c77f21 |
39 |
--- /dev/null |
40 |
+++ b/sys-freebsd/freebsd-usbin/files/freebsd-usbin-9.1-bsdxml2expat.patch |
41 |
@@ -0,0 +1,12 @@ |
42 |
+diff -Nur work.orig/usr.sbin/ctladm/ctladm.c work/usr.sbin/ctladm/ctladm.c |
43 |
+--- work.orig/usr.sbin/ctladm/ctladm.c 2012-07-12 13:25:58.000000000 +0900 |
44 |
++++ work/usr.sbin/ctladm/ctladm.c 2012-07-16 05:37:14.000000000 +0900 |
45 |
+@@ -60,7 +60,7 @@ |
46 |
+ #include <errno.h> |
47 |
+ #include <err.h> |
48 |
+ #include <ctype.h> |
49 |
+-#include <bsdxml.h> |
50 |
++#include <expat.h> |
51 |
+ #include <cam/scsi/scsi_all.h> |
52 |
+ #include <cam/scsi/scsi_message.h> |
53 |
+ #include <cam/ctl/ctl.h> |
54 |
|
55 |
diff --git a/sys-freebsd/freebsd-usbin/files/freebsd-usbin-9.1-kldxref.patch b/sys-freebsd/freebsd-usbin/files/freebsd-usbin-9.1-kldxref.patch |
56 |
new file mode 100644 |
57 |
index 00000000000..95bd665ded6 |
58 |
--- /dev/null |
59 |
+++ b/sys-freebsd/freebsd-usbin/files/freebsd-usbin-9.1-kldxref.patch |
60 |
@@ -0,0 +1,30 @@ |
61 |
+Index: usr.sbin/kldxref/kldxref.c |
62 |
+=================================================================== |
63 |
+--- usr.sbin/kldxref/kldxref.c (revision 265111) |
64 |
++++ usr.sbin/kldxref/kldxref.c (working copy) |
65 |
+@@ -274,6 +274,16 @@ usage(void) |
66 |
+ exit(1); |
67 |
+ } |
68 |
+ |
69 |
++static int |
70 |
++compare(const FTSENT *const *a, const FTSENT *const *b) |
71 |
++{ |
72 |
++ if ((*a)->fts_info == FTS_D && (*b)->fts_info != FTS_D) |
73 |
++ return 1; |
74 |
++ if ((*a)->fts_info != FTS_D && (*b)->fts_info == FTS_D) |
75 |
++ return -1; |
76 |
++ return strcmp((*a)->fts_name, (*b)->fts_name); |
77 |
++} |
78 |
++ |
79 |
+ int |
80 |
+ main(int argc, char *argv[]) |
81 |
+ { |
82 |
+@@ -315,7 +325,7 @@ main(int argc, char *argv[]) |
83 |
+ err(1, "%s", argv[0]); |
84 |
+ } |
85 |
+ |
86 |
+- ftsp = fts_open(argv, fts_options, 0); |
87 |
++ ftsp = fts_open(argv, fts_options, compare); |
88 |
+ if (ftsp == NULL) |
89 |
+ exit(1); |
90 |
+ |
91 |
|
92 |
diff --git a/sys-freebsd/freebsd-usbin/freebsd-usbin-9.1-r1.ebuild b/sys-freebsd/freebsd-usbin/freebsd-usbin-9.1-r1.ebuild |
93 |
new file mode 100644 |
94 |
index 00000000000..2627caf7733 |
95 |
--- /dev/null |
96 |
+++ b/sys-freebsd/freebsd-usbin/freebsd-usbin-9.1-r1.ebuild |
97 |
@@ -0,0 +1,170 @@ |
98 |
+# Copyright 1999-2018 Gentoo Foundation |
99 |
+# Distributed under the terms of the GNU General Public License v2 |
100 |
+ |
101 |
+EAPI=2 |
102 |
+ |
103 |
+inherit bsdmk freebsd flag-o-matic eutils |
104 |
+ |
105 |
+DESCRIPTION="FreeBSD /usr/sbin tools" |
106 |
+SLOT="0" |
107 |
+KEYWORDS="~amd64-fbsd ~x86-fbsd" |
108 |
+ |
109 |
+SRC_URI="mirror://gentoo/${P}.tar.bz2 |
110 |
+ mirror://gentoo/${CONTRIB}.tar.bz2 |
111 |
+ mirror://gentoo/${UBIN}.tar.bz2 |
112 |
+ mirror://gentoo/${LIB}.tar.bz2 |
113 |
+ mirror://gentoo/${SBIN}.tar.bz2 |
114 |
+ mirror://gentoo/${ETC}.tar.bz2 |
115 |
+ mirror://gentoo/${GNU}.tar.bz2 |
116 |
+ nis? ( mirror://gentoo/${LIBEXEC}.tar.bz2 ) |
117 |
+ build? ( mirror://gentoo/${SYS}.tar.bz2 |
118 |
+ mirror://gentoo/${INCLUDE}.tar.bz2 )" |
119 |
+ |
120 |
+RDEPEND="=sys-freebsd/freebsd-lib-${RV}*[usb?,bluetooth?,netware?] |
121 |
+ =sys-freebsd/freebsd-libexec-${RV}* |
122 |
+ =sys-freebsd/freebsd-contrib-${RV}* |
123 |
+ acpi? ( sys-power/iasl ) |
124 |
+ build? ( sys-apps/baselayout ) |
125 |
+ ssl? ( dev-libs/openssl ) |
126 |
+ >=app-arch/libarchive-3 |
127 |
+ sys-apps/tcp-wrappers |
128 |
+ dev-util/dialog |
129 |
+ dev-libs/libelf |
130 |
+ >=dev-libs/libedit-20120311.3.0-r1 |
131 |
+ net-libs/libpcap |
132 |
+ kerberos? ( app-crypt/heimdal )" |
133 |
+DEPEND="${RDEPEND} |
134 |
+ =sys-freebsd/freebsd-mk-defs-${RV}* |
135 |
+ =sys-freebsd/freebsd-ubin-${RV}* |
136 |
+ !build? ( =sys-freebsd/freebsd-sources-${RV}* ) |
137 |
+ sys-apps/texinfo |
138 |
+ sys-devel/flex" |
139 |
+ |
140 |
+S="${WORKDIR}/usr.sbin" |
141 |
+ |
142 |
+IUSE="acpi atm audit bluetooth floppy ipv6 kerberos minimal netware nis pam ssl usb build" |
143 |
+ |
144 |
+pkg_setup() { |
145 |
+ # Release crunch is something like minimal. It seems to remove everything |
146 |
+ # which is not needed to work. |
147 |
+ use minimal && mymakeopts="${mymakeopts} RELEASE_CRUNCH= " |
148 |
+ |
149 |
+ use acpi || mymakeopts="${mymakeopts} WITHOUT_ACPI= " |
150 |
+ use atm || mymakeopts="${mymakeopts} WITHOUT_ATM= " |
151 |
+ use audit || mymakeopts="${mymakeopts} WITHOUT_AUDIT= " |
152 |
+ use bluetooth || mymakeopts="${mymakeopts} WITHOUT_BLUETOOTH= " |
153 |
+ use ipv6 || mymakeopts="${mymakeopts} WITHOUT_INET6= WITHOUT_INET6_SUPPORT= " |
154 |
+ use netware || mymakeopts="${mymakeopts} WITHOUT_IPX= WITHOUT_IPX_SUPPORT= WITHOUT_NCP= " |
155 |
+ use nis || mymakeopts="${mymakeopts} WITHOUT_NIS= " |
156 |
+ use pam || mymakeopts="${mymakeopts} WITHOUT_PAM_SUPPORT= " |
157 |
+ use ssl || mymakeopts="${mymakeopts} WITHOUT_OPENSSL= " |
158 |
+ use usb || mymakeopts="${mymakeopts} WITHOUT_USB= " |
159 |
+ use floppy || mymakeopts="${mymakeopts} WITHOUT_FLOPPY= " |
160 |
+ use kerberos || mymakeopts="${mymakeopts} WITHOUT_GSSAPI= " |
161 |
+ |
162 |
+ mymakeopts="${mymakeopts} WITHOUT_BIND_NAMED= WITHOUT_BIND_DNSSEC= WITHOUT_PF= WITHOUT_LPR= WITHOUT_SENDMAIL= WITHOUT_AUTHPF= WITHOUT_MAILWRAPPER= " |
163 |
+ |
164 |
+ append-flags $(test-flags -fno-strict-aliasing) |
165 |
+} |
166 |
+ |
167 |
+PATCHES=( |
168 |
+ "${FILESDIR}/${PN}-adduser.patch" |
169 |
+ "${FILESDIR}/${PN}-9.0-newsyslog.patch" |
170 |
+ "${FILESDIR}/${PN}-9.1-bsdxml2expat.patch" |
171 |
+ "${FILESDIR}/${PN}-9.1-kldxref.patch" |
172 |
+ ) |
173 |
+ |
174 |
+REMOVE_SUBDIRS=" |
175 |
+ named named-checkzone named-checkconf rndc rndc-confgen |
176 |
+ dnssec-keygen dnssec-signzone |
177 |
+ tcpdchk tcpdmatch |
178 |
+ sendmail praliases editmap mailstats makemap |
179 |
+ sysinstall cron mailwrapper ntp bsnmpd |
180 |
+ tcpdump ndp inetd |
181 |
+ wpa/wpa_supplicant wpa/hostapd wpa/hostapd_cli wpa/wpa_cli wpa/wpa_passphrase |
182 |
+ zic amd |
183 |
+ pkg pkg_install freebsd-update service" |
184 |
+ |
185 |
+src_prepare() { |
186 |
+ if ! use build; then |
187 |
+ ln -s "/usr/src/sys-${RV}" "${WORKDIR}/sys" |
188 |
+ ln -s "/usr/include" "${WORKDIR}/include" |
189 |
+ else |
190 |
+ dummy_mk mount_smbfs |
191 |
+ fi |
192 |
+ # Don't install mtree format manpage |
193 |
+ # it's installed by libarchive. |
194 |
+ sed -e "s: mtree.5::g" -i "${S}"/mtree/Makefile |
195 |
+} |
196 |
+ |
197 |
+src_install() { |
198 |
+ # By creating these directories we avoid having to do a |
199 |
+ # more complex hack |
200 |
+ dodir /usr/share/doc |
201 |
+ dodir /sbin |
202 |
+ dodir /usr/libexec |
203 |
+ dodir /usr/bin |
204 |
+ |
205 |
+ # FILESDIR is used by some makefiles which will install files |
206 |
+ # in the wrong place, just put it in the doc directory. |
207 |
+ mkinstall DOCDIR=/usr/share/doc/${PF} || die "Install failed" |
208 |
+ |
209 |
+ # Most of these now come from openrc. |
210 |
+ for util in nfs rpc.statd rpc.lockd; do |
211 |
+ newinitd "${FILESDIR}/"${util}.initd ${util} || die |
212 |
+ if [[ -e "${FILESDIR}"/${util}.confd ]]; then \ |
213 |
+ newconfd "${FILESDIR}"/${util}.confd ${util} || die |
214 |
+ fi |
215 |
+ done |
216 |
+ |
217 |
+ for class in daily monthly weekly; do |
218 |
+ cat - > "${T}/periodic.${class}" <<EOS |
219 |
+#!/bin/sh |
220 |
+/usr/sbin/periodic ${class} |
221 |
+EOS |
222 |
+ exeinto /etc/cron.${class} |
223 |
+ newexe "${T}/periodic.${class}" periodic |
224 |
+ done |
225 |
+ |
226 |
+ # Install the pw.conf file to let pw use Gentoo's skel location |
227 |
+ insinto /etc |
228 |
+ doins "${FILESDIR}/pw.conf" || die |
229 |
+ |
230 |
+ cd "${WORKDIR}/etc" |
231 |
+ doins apmd.conf syslog.conf newsyslog.conf nscd.conf || die |
232 |
+ |
233 |
+ insinto /etc/ppp |
234 |
+ doins ppp/ppp.conf || die |
235 |
+ |
236 |
+ if use bluetooth; then |
237 |
+ insinto /etc/bluetooth |
238 |
+ doins bluetooth/* || die |
239 |
+ rm -f "${D}"/etc/bluetooth/Makefile |
240 |
+ fi |
241 |
+ |
242 |
+ # Install the periodic stuff (needs probably to be ported in a more |
243 |
+ # gentooish way) |
244 |
+ cd "${WORKDIR}/etc/periodic" |
245 |
+ |
246 |
+ doperiodic daily daily/*.accounting |
247 |
+ doperiodic monthly monthly/*.accounting |
248 |
+} |
249 |
+ |
250 |
+pkg_postinst() { |
251 |
+ # We need to run pwd_mkdb if key files are not present |
252 |
+ # If they are, then there is no need to run pwd_mkdb |
253 |
+ if [[ ! -e "${ROOT}etc/passwd" || ! -e "${ROOT}etc/pwd.db" || ! -e "${ROOT}etc/spwd.db" ]] ; then |
254 |
+ if [[ -e "${ROOT}etc/master.passwd" ]] ; then |
255 |
+ einfo "Generating passwd files from ${ROOT}etc/master.passwd" |
256 |
+ "${ROOT}"usr/sbin/pwd_mkdb -p -d "${ROOT}etc" "${ROOT}etc/master.passwd" |
257 |
+ else |
258 |
+ eerror "${ROOT}etc/master.passwd does not exist!" |
259 |
+ eerror "You will no be able to log into your system!" |
260 |
+ fi |
261 |
+ fi |
262 |
+ |
263 |
+ for logfile in messages security auth.log maillog lpd-errs xferlog cron \ |
264 |
+ debug.log slip.log ppp.log; do |
265 |
+ [[ -f "${ROOT}/var/log/${logfile}" ]] || touch "${ROOT}/var/log/${logfile}" |
266 |
+ done |
267 |
+} |