1 |
commit: 123285736eada0ef5cb1cdc7b45edaa7787b7829 |
2 |
Author: Manuel Rüger <mrueg <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Aug 28 03:35:15 2015 +0000 |
4 |
Commit: Manuel Rüger <mrueg <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Aug 28 03:35:15 2015 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=12328573 |
7 |
|
8 |
app-misc/getopt: Remove old |
9 |
|
10 |
Package-Manager: portage-2.2.20.1 |
11 |
|
12 |
app-misc/getopt/Manifest | 2 - |
13 |
app-misc/getopt/files/getopt-1.1.4-libintl.patch | 34 ------ |
14 |
.../getopt/files/getopt-1.1.4-longrename.patch | 118 --------------------- |
15 |
.../getopt/files/getopt-1.1.5-longrename.patch | 79 -------------- |
16 |
app-misc/getopt/getopt-1.1.4.ebuild | 64 ----------- |
17 |
app-misc/getopt/getopt-1.1.5.ebuild | 65 ------------ |
18 |
6 files changed, 362 deletions(-) |
19 |
|
20 |
diff --git a/app-misc/getopt/Manifest b/app-misc/getopt/Manifest |
21 |
index b7d7a89..a3c5f80 100644 |
22 |
--- a/app-misc/getopt/Manifest |
23 |
+++ b/app-misc/getopt/Manifest |
24 |
@@ -1,3 +1 @@ |
25 |
-DIST getopt-1.1.4.tar.gz 37163 SHA256 41083d9993c26792851e79b81a0991996a3f61e14998fdd607615cc3bf933bab SHA512 9ec9b5ca50a02b6ae772b133408e61fb9fcb5840c00f23d1c836a9c7ee86778211dcb1ecf5cdcaf9e2488b2db0671e29bc8be55f1a7ca4f1d48cc3921dfe04ad WHIRLPOOL 64e4942064930303ecc8cd6ea22f93ccd0c34415815f1e4fc43d2786b1e3bd511fac6d0aa6ef470b0a026a7776c4e0b345b1beada0c972203808232d0c331727 |
26 |
-DIST getopt-1.1.5.tar.gz 51794 SHA256 11893276b94b1629606ab75772143918a5713259950fbf4216288e246f19fbb6 SHA512 43597a1a8dd1dc188b6b4f0a8f8d438456013276aa1c719889e242ba2b526dccbca2fccd3d82d1541f4e0920fd277c101a436ed0c208124227481f792cb1cf75 WHIRLPOOL c5de1797b0c294a404ef8e801d86677d0b84fd6974e5d5ad8d234ae28db5446d0b13766362ecac459b3f8ce07d56282a3f0274b460d5d95118000762d9374815 |
27 |
DIST getopt-1.1.6.tar.gz 58926 SHA256 d0bf1dc642a993e7388a1cddfb9409bed375c21d5278056ccca3a0acd09dc5fe SHA512 aa5476e729f33ddd3f32f38b2565da319fdfe034f11549218d5d9953e70dad764e0d9a82bb10efe4043c86ae87f944619b8a2f29a197f592bd855699961d8e10 WHIRLPOOL 0fa96415fa5d9b001313b1491a0f260922dbb52ac72d6242e6ff332ac802e3d6cac2401c8e8a8f9cc09376d3c51f4b1cc3bd0f976dc857cd72c1ffc7b1d770da |
28 |
|
29 |
diff --git a/app-misc/getopt/files/getopt-1.1.4-libintl.patch b/app-misc/getopt/files/getopt-1.1.4-libintl.patch |
30 |
deleted file mode 100644 |
31 |
index 232e487..0000000 |
32 |
--- a/app-misc/getopt/files/getopt-1.1.4-libintl.patch |
33 |
+++ /dev/null |
34 |
@@ -1,34 +0,0 @@ |
35 |
-Index: getopt-1.1.4/Makefile |
36 |
-=================================================================== |
37 |
---- getopt-1.1.4.orig/Makefile |
38 |
-+++ getopt-1.1.4/Makefile |
39 |
-@@ -33,7 +33,10 @@ MSGFMT=msgfmt |
40 |
- LANGUAGES = cs de es fr it ja nl pt_BR |
41 |
- MOFILES:=$(patsubst %,po/%.mo,$(LANGUAGES)) |
42 |
- |
43 |
--CPPFLAGS=-DLIBCGETOPT=$(LIBCGETOPT) -DWITH_GETTEXT=$(WITH_GETTEXT) -DLOCALEDIR=\"$(localedir)\" -DNOT_UTIL_LINUX |
44 |
-+CPPFLAGS=-DLIBCGETOPT=$(LIBCGETOPT) -DLOCALEDIR=\"$(localedir)\" -DNOT_UTIL_LINUX |
45 |
-+ifeq ($(WITHOUT_GETTEXT),1) |
46 |
-+CPPFLAGS+=-DWITHOUT_GETTEXT |
47 |
-+endif |
48 |
- ifeq ($(LIBCGETOPT),0) |
49 |
- CPPFLAGS+=-I./gnu |
50 |
- endif |
51 |
-@@ -62,7 +65,7 @@ clean: clean_po |
52 |
- -$(RM) $(objects) $(binaries) |
53 |
- |
54 |
- getopt: $(objects) |
55 |
-- $(CC) $(LDFLAGS) -o $@ $(objects) |
56 |
-+ $(CC) $(LDFLAGS) -o $@ $(objects) $(LIBINTL) |
57 |
- |
58 |
- install: getopt install_po |
59 |
- $(INSTALL) -m 755 -d $(DESTDIR)$(bindir) $(DESTDIR)$(man1dir) |
60 |
-@@ -75,7 +78,7 @@ install_doc: |
61 |
- getopt-test.bash getopt-test.tcsh \ |
62 |
- $(DESTDIR)$(getoptdir) |
63 |
- |
64 |
--ifeq ($(WITH_GETTEXT),1) |
65 |
-+ifeq ($(WITHOUT_GETTEXT),0) |
66 |
- all_po: $(MOFILES) |
67 |
- install_po: all_po |
68 |
- $(INSTALL) -m 755 -d $(DESTDIR)$(localedir) |
69 |
|
70 |
diff --git a/app-misc/getopt/files/getopt-1.1.4-longrename.patch b/app-misc/getopt/files/getopt-1.1.4-longrename.patch |
71 |
deleted file mode 100644 |
72 |
index dc3ecb0..0000000 |
73 |
--- a/app-misc/getopt/files/getopt-1.1.4-longrename.patch |
74 |
+++ /dev/null |
75 |
@@ -1,118 +0,0 @@ |
76 |
-Index: getopt-1.1.4/getopt.c |
77 |
-=================================================================== |
78 |
---- getopt-1.1.4.orig/getopt.c |
79 |
-+++ getopt-1.1.4/getopt.c |
80 |
-@@ -88,7 +88,7 @@ void *our_malloc(size_t size) |
81 |
- { |
82 |
- void *ret=malloc(size); |
83 |
- if (! ret) { |
84 |
-- fprintf(stderr,_("%s: Out of memory!\n"),"getopt"); |
85 |
-+ fprintf(stderr,_("%s: Out of memory!\n"),"getopt-long"); |
86 |
- exit(3); |
87 |
- } |
88 |
- return(ret); |
89 |
-@@ -98,7 +98,7 @@ void *our_realloc(void *ptr, size_t size |
90 |
- { |
91 |
- void *ret=realloc(ptr,size); |
92 |
- if (! ret && size) { |
93 |
-- fprintf(stderr,_("%s: Out of memory!\n"),"getopt"); |
94 |
-+ fprintf(stderr,_("%s: Out of memory!\n"),"getopt-long"); |
95 |
- exit(3); |
96 |
- } |
97 |
- return(ret); |
98 |
-@@ -231,8 +231,8 @@ int generate_output(char * argv[],int ar |
99 |
- void parse_error(const char *message) |
100 |
- { |
101 |
- if (message) |
102 |
-- fprintf(stderr,"getopt: %s\n",message); |
103 |
-- fputs(_("Try `getopt --help' for more information.\n"),stderr); |
104 |
-+ fprintf(stderr,"getopt-long: %s\n",message); |
105 |
-+ fputs(_("Try `getopt-long --help' for more information.\n"),stderr); |
106 |
- exit(2); |
107 |
- } |
108 |
- |
109 |
-@@ -323,10 +323,10 @@ void set_shell(const char *new_shell) |
110 |
- |
111 |
- void print_help(void) |
112 |
- { |
113 |
-- fputs(_("Usage: getopt optstring parameters\n"),stderr); |
114 |
-- fputs(_(" getopt [options] [--] optstring parameters\n"),stderr); |
115 |
-- fputs(_(" getopt [options] -o|--options optstring [options] [--]\n"),stderr); |
116 |
-- fputs(_(" parameters\n"),stderr); |
117 |
-+ fputs(_("Usage: getopt-long optstring parameters\n"),stderr); |
118 |
-+ fputs(_(" getopt-long [options] [--] optstring parameters\n"),stderr); |
119 |
-+ fputs(_(" getopt-long [options] -o|--options optstring [options] [--]\n"),stderr); |
120 |
-+ fputs(_(" parameters\n"),stderr); |
121 |
- fputs(_(" -a, --alternative Allow long options starting with single -\n"),stderr); |
122 |
- fputs(_(" -h, --help This small usage guide\n"),stderr); |
123 |
- fputs(_(" -l, --longoptions=longopts Long options to be recognized\n"),stderr); |
124 |
-@@ -335,7 +335,7 @@ void print_help(void) |
125 |
- fputs(_(" -q, --quiet Disable error reporting by getopt(3)\n"),stderr); |
126 |
- fputs(_(" -Q, --quiet-output No normal output\n"),stderr); |
127 |
- fputs(_(" -s, --shell=shell Set shell quoting conventions\n"),stderr); |
128 |
-- fputs(_(" -T, --test Test for getopt(1) version\n"),stderr); |
129 |
-+ fputs(_(" -T, --test Test for getopt-long(1) version\n"),stderr); |
130 |
- fputs(_(" -u, --unqote Do not quote the output\n"),stderr); |
131 |
- fputs(_(" -V, --version Output version information\n"),stderr); |
132 |
- exit(2); |
133 |
-@@ -443,7 +443,7 @@ int main(int argc, char *argv[]) |
134 |
- quote=0; |
135 |
- break; |
136 |
- case 'V': |
137 |
-- printf(_("getopt (enhanced) 1.1.4\n")); |
138 |
-+ printf(_("getopt-long (enhanced) 1.1.4\n")); |
139 |
- exit(0); |
140 |
- case '?': |
141 |
- case ':': |
142 |
-Index: getopt-1.1.4/getopt-parse.bash |
143 |
-=================================================================== |
144 |
---- getopt-1.1.4.orig/getopt-parse.bash |
145 |
-+++ getopt-1.1.4/getopt-parse.bash |
146 |
-@@ -19,7 +19,7 @@ |
147 |
- # Note that we use `"$@"' to let each command-line parameter expand to a |
148 |
- # separate word. The quotes around `$@' are essential! |
149 |
- # We need TEMP as the `eval set --' would nuke the return value of getopt. |
150 |
--TEMP=`getopt -o ab:c:: --long a-long,b-long:,c-long:: \ |
151 |
-+TEMP=`getopt-long -o ab:c:: --long a-long,b-long:,c-long:: \ |
152 |
- -n 'example.bash' -- "$@"` |
153 |
- |
154 |
- if [ $? != 0 ] ; then echo "Terminating..." >&2 ; exit 1 ; fi |
155 |
-Index: getopt-1.1.4/getopt-parse.tcsh |
156 |
-=================================================================== |
157 |
---- getopt-1.1.4.orig/getopt-parse.tcsh |
158 |
-+++ getopt-1.1.4/getopt-parse.tcsh |
159 |
-@@ -26,7 +26,7 @@ |
160 |
- # as a list. The ':q` copies that list without doing any substitutions: |
161 |
- # each element of argv becomes a separate argument for getopt. The braces |
162 |
- # are needed because the result is also a list. |
163 |
--set temp=(`getopt -s tcsh -o ab:c:: --long a-long,b-long:,c-long:: -- $argv:q`) |
164 |
-+set temp=(`getopt-long -s tcsh -o ab:c:: --long a-long,b-long:,c-long:: -- $argv:q`) |
165 |
- if ($? != 0) then |
166 |
- echo "Terminating..." >/dev/stderr |
167 |
- exit 1 |
168 |
-Index: getopt-1.1.4/Makefile |
169 |
-=================================================================== |
170 |
---- getopt-1.1.4.orig/Makefile |
171 |
-+++ getopt-1.1.4/Makefile |
172 |
-@@ -85,7 +85,7 @@ install_po: all_po |
173 |
- for lang in $(LANGUAGES) ; do \ |
174 |
- dir=$(localedir)/$$lang/LC_MESSAGES; \ |
175 |
- $(INSTALL) -m 755 -d $(DESTDIR)$$dir ;\ |
176 |
-- $(INSTALL) -m 644 po/$$lang.mo $(DESTDIR)$$dir/getopt.mo ;\ |
177 |
-+ $(INSTALL) -m 644 po/$$lang.mo $(DESTDIR)$$dir/getopt-long.mo ;\ |
178 |
- done |
179 |
- clean_po: |
180 |
- $(RM) $(MOFILES) |
181 |
-Index: getopt-1.1.4/nls.h |
182 |
-=================================================================== |
183 |
---- getopt-1.1.4.orig/nls.h |
184 |
-+++ getopt-1.1.4/nls.h |
185 |
-@@ -29,7 +29,7 @@ |
186 |
- #ifndef GETOPT_NLS |
187 |
- #define GETOPT_NLS |
188 |
- |
189 |
--#define PACKAGE "getopt" |
190 |
-+#define PACKAGE "getopt-long" |
191 |
- |
192 |
- #ifndef WITHOUT_GETTEXT |
193 |
- #include <libintl.h> |
194 |
|
195 |
diff --git a/app-misc/getopt/files/getopt-1.1.5-longrename.patch b/app-misc/getopt/files/getopt-1.1.5-longrename.patch |
196 |
deleted file mode 100644 |
197 |
index 03f2ca5..0000000 |
198 |
--- a/app-misc/getopt/files/getopt-1.1.5-longrename.patch |
199 |
+++ /dev/null |
200 |
@@ -1,79 +0,0 @@ |
201 |
---- getopt-1.1.5/getopt-parse.bash |
202 |
-+++ getopt-1.1.5/getopt-parse.bash |
203 |
-@@ -19,7 +19,7 @@ |
204 |
- # Note that we use `"$@"' to let each command-line parameter expand to a |
205 |
- # separate word. The quotes around `$@' are essential! |
206 |
- # We need TEMP as the `eval set --' would nuke the return value of getopt. |
207 |
--TEMP=`getopt -o ab:c:: --long a-long,b-long:,c-long:: \ |
208 |
-+TEMP=`getopt-long -o ab:c:: --long a-long,b-long:,c-long:: \ |
209 |
- -n 'example.bash' -- "$@"` |
210 |
- |
211 |
- if [ $? != 0 ] ; then echo "Terminating..." >&2 ; exit 1 ; fi |
212 |
---- getopt-1.1.5/getopt-parse.tcsh |
213 |
-+++ getopt-1.1.5/getopt-parse.tcsh |
214 |
-@@ -26,7 +26,7 @@ |
215 |
- # as a list. The ':q` copies that list without doing any substitutions: |
216 |
- # each element of argv becomes a separate argument for getopt. The braces |
217 |
- # are needed because the result is also a list. |
218 |
--set temp=(`getopt -s tcsh -o ab:c:: --long a-long,b-long:,c-long:: -- $argv:q`) |
219 |
-+set temp=(`getopt-long -s tcsh -o ab:c:: --long a-long,b-long:,c-long:: -- $argv:q`) |
220 |
- if ($? != 0) then |
221 |
- echo "Terminating..." >/dev/stderr |
222 |
- exit 1 |
223 |
---- getopt-1.1.5/getopt.c |
224 |
-+++ getopt-1.1.5/getopt.c |
225 |
-@@ -320,10 +320,10 @@ |
226 |
- |
227 |
- static void __attribute__ ((__noreturn__)) print_help(void) |
228 |
- { |
229 |
-- fputs(_("Usage: getopt optstring parameters\n"), stderr); |
230 |
-- fputs(_(" getopt [options] [--] optstring parameters\n"), stderr); |
231 |
-- fputs(_(" getopt [options] -o|--options optstring [options] [--]\n"), stderr); |
232 |
-- fputs(_(" parameters\n"), stderr); |
233 |
-+ fputs(_("Usage: getopt-long optstring parameters\n"), stderr); |
234 |
-+ fputs(_(" getopt-long [options] [--] optstring parameters\n"), stderr); |
235 |
-+ fputs(_(" getopt-long [options] -o|--options optstring [options] [--]\n"), stderr); |
236 |
-+ fputs(_(" parameters\n"), stderr); |
237 |
- fputs(_("\nOptions:\n"), stderr); |
238 |
- fputs(_(" -a, --alternative Allow long options starting with single -\n"), stderr); |
239 |
- fputs(_(" -h, --help This small usage guide\n"), stderr); |
240 |
-@@ -333,7 +333,7 @@ |
241 |
- fputs(_(" -q, --quiet Disable error reporting by getopt(3)\n"), stderr); |
242 |
- fputs(_(" -Q, --quiet-output No normal output\n"), stderr); |
243 |
- fputs(_(" -s, --shell <shell> Set shell quoting conventions\n"), stderr); |
244 |
-- fputs(_(" -T, --test Test for getopt(1) version\n"), stderr); |
245 |
-+ fputs(_(" -T, --test Test for getopt-long(1) version\n"), stderr); |
246 |
- fputs(_(" -u, --unquote Do not quote the output\n"), stderr); |
247 |
- fputs(_(" -V, --version Output version information\n"), stderr); |
248 |
- fputc('\n', stderr); |
249 |
---- getopt-1.1.5/Makefile |
250 |
-+++ getopt-1.1.5/Makefile |
251 |
-@@ -32,7 +32,7 @@ |
252 |
- LANGUAGES = ca cs da de es et eu fi fr gl hu id it ja nl pl pt_BR ru sl sv tr uk vi zh_CN zh_TW |
253 |
- MOFILES:=$(patsubst %,po/%.mo,$(LANGUAGES)) |
254 |
- |
255 |
--CPPFLAGS=-DLIBCGETOPT=$(LIBCGETOPT) -DWITHOUT_GETTEXT=$(WITHOUT_GETTEXT) -DLOCALEDIR=\"$(localedir)\" -DNOT_UTIL_LINUX -Dprogram_invocation_short_name=\"$(PACKAGE)\" -Dprogram_version=\"$(VERSION)\" |
256 |
-+CPPFLAGS=-DLIBCGETOPT=$(LIBCGETOPT) -DWITHOUT_GETTEXT=$(WITHOUT_GETTEXT) -DLOCALEDIR=\"$(localedir)\" -DNOT_UTIL_LINUX -Dprogram_invocation_short_name=\"$(PACKAGE)-long\" -Dprogram_version=\"$(VERSION)\" |
257 |
- ifeq ($(LIBCGETOPT),0) |
258 |
- CPPFLAGS+=-I./gnu |
259 |
- endif |
260 |
-@@ -81,7 +81,7 @@ |
261 |
- for lang in $(LANGUAGES) ; do \ |
262 |
- dir=$(localedir)/$$lang/LC_MESSAGES; \ |
263 |
- $(INSTALL) -m 755 -d $(DESTDIR)$$dir ;\ |
264 |
-- $(INSTALL) -m 644 po/$$lang.mo $(DESTDIR)$$dir/getopt.mo ;\ |
265 |
-+ $(INSTALL) -m 644 po/$$lang.mo $(DESTDIR)$$dir/getopt-long.mo ;\ |
266 |
- done |
267 |
- clean_po: |
268 |
- $(RM) $(MOFILES) |
269 |
---- getopt-1.1.5/nls.h |
270 |
-+++ getopt-1.1.5/nls.h |
271 |
-@@ -29,7 +29,7 @@ |
272 |
- #ifndef GETOPT_NLS |
273 |
- #define GETOPT_NLS |
274 |
- |
275 |
--#define PACKAGE "getopt" |
276 |
-+#define PACKAGE "getopt-long" |
277 |
- |
278 |
- #if WITHOUT_GETTEXT |
279 |
- #define _(Text) (Text) |
280 |
|
281 |
diff --git a/app-misc/getopt/getopt-1.1.4.ebuild b/app-misc/getopt/getopt-1.1.4.ebuild |
282 |
deleted file mode 100644 |
283 |
index c808b17..0000000 |
284 |
--- a/app-misc/getopt/getopt-1.1.4.ebuild |
285 |
+++ /dev/null |
286 |
@@ -1,64 +0,0 @@ |
287 |
-# Copyright 1999-2012 Gentoo Foundation |
288 |
-# Distributed under the terms of the GNU General Public License v2 |
289 |
-# $Id$ |
290 |
- |
291 |
-EAPI=3 |
292 |
- |
293 |
-inherit toolchain-funcs eutils |
294 |
- |
295 |
-DESCRIPTION="getopt(1) replacement supporting GNU-style long options" |
296 |
-HOMEPAGE="http://software.frodo.looijaard.name/getopt/" |
297 |
-SRC_URI="http://software.frodo.looijaard.name/getopt/files/${P}.tar.gz" |
298 |
- |
299 |
-LICENSE="GPL-2" |
300 |
-SLOT="0" |
301 |
-KEYWORDS="~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x86-freebsd ~x86-interix ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~x64-solaris ~x86-solaris" |
302 |
-IUSE="nls" |
303 |
- |
304 |
-RDEPEND="nls? ( virtual/libintl )" |
305 |
-DEPEND="${RDEPEND} |
306 |
- nls? ( sys-devel/gettext )" |
307 |
- |
308 |
-src_prepare() { |
309 |
- epatch "${FILESDIR}/${P}-libintl.patch" |
310 |
- epatch "${FILESDIR}/${P}-longrename.patch" |
311 |
- |
312 |
- # hopefully this is portable enough |
313 |
- epatch "${FILESDIR}"/${P}-irix.patch |
314 |
-} |
315 |
- |
316 |
-src_compile() { |
317 |
- local nogettext="1" |
318 |
- local libintl="" |
319 |
- local libcgetopt=1 |
320 |
- |
321 |
- if use nls; then |
322 |
- nogettext=0 |
323 |
- has_version sys-libs/glibc || libintl="-lintl" |
324 |
- fi |
325 |
- |
326 |
- [[ ${CHOST} == *-irix* ]] && libcgetopt=0 |
327 |
- [[ ${CHOST} == *-interix* ]] && libcgetopt=0 |
328 |
- |
329 |
- emake CC="$(tc-getCC)" prefix="${EPREFIX}/usr" \ |
330 |
- LIBCGETOPT=${libcgetopt} \ |
331 |
- WITHOUT_GETTEXT=${nogettext} LIBINTL=${libintl} \ |
332 |
- CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" || die "emake failed" |
333 |
-} |
334 |
- |
335 |
-src_install() { |
336 |
- use nls && make prefix="${EPREFIX}/usr" DESTDIR="${D}" install_po |
337 |
- |
338 |
- into /usr |
339 |
- newbin getopt getopt-long |
340 |
- |
341 |
- # at least on interix, the system getopt is ... broken... |
342 |
- # util-linux, which would provide the getopt binary, does not build & |
343 |
- # install on interix/prefix, so, this has to provide it. |
344 |
- [[ ${CHOST} == *-interix* || ${CHOST} == *-mint* ]] && \ |
345 |
- dosym getopt-long /usr/bin/getopt |
346 |
- |
347 |
- newman getopt.1 getopt-long.1 |
348 |
- |
349 |
- dodoc "${S}/getopt-"*sh |
350 |
-} |
351 |
|
352 |
diff --git a/app-misc/getopt/getopt-1.1.5.ebuild b/app-misc/getopt/getopt-1.1.5.ebuild |
353 |
deleted file mode 100644 |
354 |
index 2bf8b78..0000000 |
355 |
--- a/app-misc/getopt/getopt-1.1.5.ebuild |
356 |
+++ /dev/null |
357 |
@@ -1,65 +0,0 @@ |
358 |
-# Copyright 1999-2014 Gentoo Foundation |
359 |
-# Distributed under the terms of the GNU General Public License v2 |
360 |
-# $Id$ |
361 |
- |
362 |
-EAPI=3 |
363 |
- |
364 |
-inherit toolchain-funcs eutils |
365 |
- |
366 |
-DESCRIPTION="getopt(1) replacement supporting GNU-style long options" |
367 |
-HOMEPAGE="http://software.frodo.looijaard.name/getopt/" |
368 |
-SRC_URI="http://software.frodo.looijaard.name/getopt/files/${P}.tar.gz" |
369 |
- |
370 |
-LICENSE="GPL-2" |
371 |
-SLOT="0" |
372 |
-KEYWORDS="~ppc-aix ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x64-freebsd ~x86-freebsd ~x86-interix ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~x64-solaris ~x86-solaris" |
373 |
-IUSE="nls" |
374 |
- |
375 |
-RDEPEND="nls? ( virtual/libintl )" |
376 |
-DEPEND="${RDEPEND} |
377 |
- nls? ( sys-devel/gettext )" |
378 |
- |
379 |
-src_prepare() { |
380 |
- epatch "${FILESDIR}"/${P}-libintl.patch |
381 |
- epatch "${FILESDIR}"/${P}-setlocale.patch |
382 |
- epatch "${FILESDIR}"/${P}-longrename.patch |
383 |
- |
384 |
- # hopefully this is portable enough |
385 |
- epatch "${FILESDIR}"/${PN}-1.1.4-irix.patch |
386 |
-} |
387 |
- |
388 |
-src_compile() { |
389 |
- local nogettext="1" |
390 |
- local libintl="" |
391 |
- local libcgetopt=1 |
392 |
- |
393 |
- if use nls; then |
394 |
- nogettext=0 |
395 |
- has_version sys-libs/glibc || libintl="-lintl" |
396 |
- fi |
397 |
- |
398 |
- [[ ${CHOST} == *-irix* ]] && libcgetopt=0 |
399 |
- [[ ${CHOST} == *-interix* ]] && libcgetopt=0 |
400 |
- |
401 |
- emake CC="$(tc-getCC)" prefix="${EPREFIX}/usr" \ |
402 |
- LIBCGETOPT=${libcgetopt} \ |
403 |
- WITHOUT_GETTEXT=${nogettext} LIBINTL=${libintl} \ |
404 |
- CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" || die "emake failed" |
405 |
-} |
406 |
- |
407 |
-src_install() { |
408 |
- use nls && make prefix="${EPREFIX}/usr" DESTDIR="${D}" install_po |
409 |
- |
410 |
- into /usr |
411 |
- newbin getopt getopt-long |
412 |
- |
413 |
- # at least on interix, the system getopt is ... broken... |
414 |
- # util-linux, which would provide the getopt binary, does not build & |
415 |
- # install on interix/prefix, so, this has to provide it. |
416 |
- [[ ${CHOST} == *-interix* || ${CHOST} == *-mint* ]] && \ |
417 |
- dosym getopt-long /usr/bin/getopt |
418 |
- |
419 |
- newman getopt.1 getopt-long.1 |
420 |
- |
421 |
- dodoc "${S}/getopt-"*sh |
422 |
-} |