forked from Ravenports/Ravenports
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgettext
608 lines (548 loc) · 14.4 KB
/
gettext
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
# Buildsheet autogenerated by ravenadm tool -- Do not edit.
NAMEBASE= gettext
VERSION= 0.19.8.1
KEYWORDS= devel
VARIANTS= standard
SDESC[standard]= GNU internationalization and localization system
HOMEPAGE= http://www.gnu.org/software/gettext/
CONTACT= nobody
DOWNLOAD_GROUPS= main
SITES[main]= GNU/gettext
DISTFILE[1]= gettext-0.19.8.1.tar.xz:main
DF_INDEX= 1
SPKGS[standard]= complete
runtime
tools
asprintf
docs
OPTIONS_AVAILABLE= none
OPTIONS_STANDARD= none
RUN_DEPENDS= libiconv:static:standard
USES= charsetfix cpe iconv libtool c++:asprintf
LICENSE= GPLv3+:runtime LGPL21+:runtime
LICENSE_TERMS= runtime:{{WRKDIR}}/TERMS
LICENSE_FILE= GPLv3+:{{WRKSRC}}/COPYING
LGPL21+:{{WRKSRC}}/gettext-runtime/intl/COPYING.LIB
LICENSE_SCHEME= multi
INFO= runtime:autosprintf
runtime:gettext
CPE_PRODUCT= gettext
CPE_VENDOR= gnu
FPC_EQUIVALENT= devel/gettext
INFO_SUBDIR= .
MUST_CONFIGURE= gnu
CONFIGURE_ARGS= --disable-csharp
--disable-java
--disable-openmp
--with-included-glib
--with-included-libcroco
--with-included-libunistring
--with-included-libxml
--without-emacs
--without-git
CONFIGURE_ENV= ac_cv_lib_rt_sched_yield=no
INSTALL_TARGET= install-strip
INSTALL_REQ_TOOLCHAIN= yes
PLIST_SUB= VERSION=0.19.8
TEST_TARGET= check
post-patch:
# Do not install csharp and java documentation.
${REINPLACE_CMD} -E '/^SUBDIRS =/s/(intl-csharp|intl-java)//g' \
${WRKSRC}/gettext-runtime/Makefile.in
# Do not install html copies of manpages.
${REINPLACE_CMD} \
-e '/^all-local:/s/html-local//' \
-e '/^install-data-local:/s/install-html//' \
-e '/^installdirs-local:/s/installdirs-html//' \
${WRKSRC}/gettext-runtime/libasprintf/Makefile.in \
${WRKSRC}/gettext-runtime/man/Makefile.in
post-install-linux:
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/preloadable_libintl.so
post-install-freebsd:
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libintl.so
post-install-dragonfly:
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libintl.so
post-install:
${MV} ${STAGEDIR}${PREFIX}/share/gettext-0.19.8 \
${STAGEDIR}${PREFIX}/share/gettext/0.19.8
post-extract:
${AWK} -e '/HAVE_CONFIG_H/ {exit}; {print}' \
${WRKSRC}/gettext-runtime/src/gettext.c > ${WRKDIR}/TERMS
${AWK} -e '/HAVE_CONFIG_H/ {exit}; {print}' \
${WRKSRC}/gettext-runtime/intl/textdomain.c >> ${WRKDIR}/TERMS
post-install-sunos:
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libintl.so
[FILE:164:descriptions/desc.runtime]
GNU gettext is a framework of libraries and tools for internationalisation
and localisation of software.
This package contains the runtime libraries and programs.
[FILE:163:descriptions/desc.tools]
GNU gettext is a framework of libraries and tools for internationalisation
and localisation of software.
This package contains development and translation tools.
[FILE:194:descriptions/desc.asprintf]
GNU gettext is a framework of libraries and tools for internationalisation
and localisation of software.
This package contains the asprintf library which has a runtime dependency
on libstdc++.
[FILE:102:distinfo]
105556dbc5c3fbbc2aa0edb46d22d055748b6f5c7cd7a8d99f8e7eb84e938be4 7209808 gettext-0.19.8.1.tar.xz
[FILE:2710:manifests/plist.runtime.standard]
%%ONLY-DRAGONFLY%%include/libintl.h
%%ONLY-DRAGONFLY%%lib/
libintl.a
libintl.so
libintl.so.8
libintl.so.8.1.5
%%ONLY-DRAGONFLY%%share/locale/locale.alias
%%ONLY-FREEBSD%%include/libintl.h
%%ONLY-FREEBSD%%lib/
libintl.a
libintl.so
libintl.so.8
libintl.so.8.1.5
%%ONLY-FREEBSD%%share/locale/locale.alias
%%ONLY-LINUX%%lib/preloadable_libintl.so
%%ONLY-SUNOS%%include/libintl.h
%%ONLY-SUNOS%%lib/
libintl.a
libintl.so
libintl.so.8
libintl.so.8.1.5
%%ONLY-SUNOS%%share/locale/locale.alias
bin/
envsubst
gettext
gettext.sh
ngettext
share/gettext/ABOUT-NLS
share/locale/be/LC_MESSAGES/gettext-runtime.mo
share/locale/bg/LC_MESSAGES/gettext-runtime.mo
share/locale/ca/LC_MESSAGES/gettext-runtime.mo
share/locale/cs/LC_MESSAGES/gettext-runtime.mo
share/locale/da/LC_MESSAGES/gettext-runtime.mo
share/locale/de/LC_MESSAGES/gettext-runtime.mo
share/locale/el/LC_MESSAGES/gettext-runtime.mo
share/locale/en@boldquot/LC_MESSAGES/gettext-runtime.mo
share/locale/en@quot/LC_MESSAGES/gettext-runtime.mo
share/locale/eo/LC_MESSAGES/gettext-runtime.mo
share/locale/es/LC_MESSAGES/gettext-runtime.mo
share/locale/et/LC_MESSAGES/gettext-runtime.mo
share/locale/fi/LC_MESSAGES/gettext-runtime.mo
share/locale/fr/LC_MESSAGES/gettext-runtime.mo
share/locale/ga/LC_MESSAGES/gettext-runtime.mo
share/locale/gl/LC_MESSAGES/gettext-runtime.mo
share/locale/hr/LC_MESSAGES/gettext-runtime.mo
share/locale/hu/LC_MESSAGES/gettext-runtime.mo
share/locale/id/LC_MESSAGES/gettext-runtime.mo
share/locale/it/LC_MESSAGES/gettext-runtime.mo
share/locale/ja/LC_MESSAGES/gettext-runtime.mo
share/locale/ko/LC_MESSAGES/gettext-runtime.mo
share/locale/nb/LC_MESSAGES/gettext-runtime.mo
share/locale/nl/LC_MESSAGES/gettext-runtime.mo
share/locale/nn/LC_MESSAGES/gettext-runtime.mo
share/locale/pl/LC_MESSAGES/gettext-runtime.mo
share/locale/pt/LC_MESSAGES/gettext-runtime.mo
share/locale/pt_BR/LC_MESSAGES/gettext-runtime.mo
share/locale/ro/LC_MESSAGES/gettext-runtime.mo
share/locale/ru/LC_MESSAGES/gettext-runtime.mo
share/locale/sk/LC_MESSAGES/gettext-runtime.mo
share/locale/sl/LC_MESSAGES/gettext-runtime.mo
share/locale/sr/LC_MESSAGES/gettext-runtime.mo
share/locale/sv/LC_MESSAGES/gettext-runtime.mo
share/locale/tr/LC_MESSAGES/gettext-runtime.mo
share/locale/uk/LC_MESSAGES/gettext-runtime.mo
share/locale/vi/LC_MESSAGES/gettext-runtime.mo
share/locale/zh_CN/LC_MESSAGES/gettext-runtime.mo
share/locale/zh_HK/LC_MESSAGES/gettext-runtime.mo
share/locale/zh_TW/LC_MESSAGES/gettext-runtime.mo
share/man/man1/
envsubst.1.gz
gettext.1.gz
ngettext.1.gz
share/man/man3/
bind_textdomain_codeset.3.gz
bindtextdomain.3.gz
dcgettext.3.gz
dcngettext.3.gz
dgettext.3.gz
dngettext.3.gz
gettext.3.gz
ngettext.3.gz
textdomain.3.gz
[FILE:4493:manifests/plist.tools.standard]
bin/
autopoint
gettextize
msgattrib
msgcat
msgcmp
msgcomm
msgconv
msgen
msgexec
msgfilter
msgfmt
msggrep
msginit
msgmerge
msgunfmt
msguniq
recode-sr-latin
xgettext
include/gettext-po.h
lib/
libgettextlib-%%VERSION%%.1.so
libgettextlib.so
libgettextpo.a
libgettextpo.so
libgettextpo.so.0
libgettextpo.so.0.5.4
libgettextsrc-%%VERSION%%.1.so
libgettextsrc.so
lib/gettext/
cldr-plurals
hostname
project-id
urlget
user-email
share/aclocal/
codeset.m4
extern-inline.m4
fcntl-o.m4
gettext.m4
glibc2.m4
glibc21.m4
iconv.m4
intdiv0.m4
intl.m4
intldir.m4
intlmacosx.m4
intmax.m4
inttypes-pri.m4
inttypes_h.m4
lcmessage.m4
lib-ld.m4
lib-link.m4
lib-prefix.m4
lock.m4
longlong.m4
nls.m4
po.m4
printf-posix.m4
progtest.m4
size_max.m4
stdint_h.m4
threadlib.m4
uintmax_t.m4
visibility.m4
wchar_t.m4
wint_t.m4
xsize.m4
share/gettext/
archive.dir.tar.xz
config.rpath
gettext.h
javaversion.class
msgunfmt.tcl
share/gettext/%%VERSION%%/its/
appdata.its
appdata.loc
glade.loc
glade1.its
glade2.its
gsettings.its
gsettings.loc
gtkbuilder.its
share/gettext/intl/
COPYING.LIB
Makefile.in
VERSION
bindtextdom.c
config.charset
dcgettext.c
dcigettext.c
dcngettext.c
dgettext.c
dngettext.c
eval-plural.h
explodename.c
export.h
finddomain.c
gettext.c
gettextP.h
gmo.h
hash-string.c
hash-string.h
intl-compat.c
intl-exports.c
l10nflist.c
langprefs.c
libgnuintl.in.h
libintl.rc
loadinfo.h
loadmsgcat.c
localcharset.c
localcharset.h
locale.alias
localealias.c
localename.c
lock.c
lock.h
log.c
ngettext.c
os2compat.c
os2compat.h
osdep.c
plural-exp.c
plural-exp.h
plural.c
plural.y
printf-args.c
printf-args.h
printf-parse.c
printf-parse.h
printf.c
ref-add.sin
ref-del.sin
relocatable.c
relocatable.h
setlocale.c
textdomain.c
threadlib.c
tsearch.c
tsearch.h
vasnprintf.c
vasnprintf.h
vasnwprintf.h
verify.h
version.c
wprintf-parse.h
xsize.c
xsize.h
share/gettext/po/
Makefile.in.in
Makevars.template
Rules-quot
boldquot.sed
insert-header.sin
quot.sed
remove-potcdate.sin
share/gettext/projects/
index
team-address
share/gettext/projects/GNOME/
team-address
teams.html
teams.url
trigger
share/gettext/projects/KDE/
team-address
teams.html
teams.url
trigger
share/gettext/projects/TP/
team-address
teams.html
teams.url
trigger
share/gettext/styles/
po-default.css
po-emacs-x.css
po-emacs-xterm.css
po-emacs-xterm16.css
po-emacs-xterm256.css
po-vim.css
share/locale/be/LC_MESSAGES/gettext-tools.mo
share/locale/bg/LC_MESSAGES/gettext-tools.mo
share/locale/ca/LC_MESSAGES/gettext-tools.mo
share/locale/cs/LC_MESSAGES/gettext-tools.mo
share/locale/da/LC_MESSAGES/gettext-tools.mo
share/locale/de/LC_MESSAGES/gettext-tools.mo
share/locale/el/LC_MESSAGES/gettext-tools.mo
share/locale/en@boldquot/LC_MESSAGES/gettext-tools.mo
share/locale/en@quot/LC_MESSAGES/gettext-tools.mo
share/locale/es/LC_MESSAGES/gettext-tools.mo
share/locale/et/LC_MESSAGES/gettext-tools.mo
share/locale/eu/LC_MESSAGES/gettext-tools.mo
share/locale/fi/LC_MESSAGES/gettext-tools.mo
share/locale/fr/LC_MESSAGES/gettext-tools.mo
share/locale/gl/LC_MESSAGES/gettext-tools.mo
share/locale/id/LC_MESSAGES/gettext-tools.mo
share/locale/it/LC_MESSAGES/gettext-tools.mo
share/locale/ja/LC_MESSAGES/gettext-tools.mo
share/locale/ko/LC_MESSAGES/gettext-tools.mo
share/locale/nb/LC_MESSAGES/gettext-tools.mo
share/locale/nl/LC_MESSAGES/gettext-tools.mo
share/locale/nn/LC_MESSAGES/gettext-tools.mo
share/locale/pa/LC_MESSAGES/gettext-tools.mo
share/locale/pl/LC_MESSAGES/gettext-tools.mo
share/locale/pt/LC_MESSAGES/gettext-tools.mo
share/locale/pt_BR/LC_MESSAGES/gettext-tools.mo
share/locale/ro/LC_MESSAGES/gettext-tools.mo
share/locale/ru/LC_MESSAGES/gettext-tools.mo
share/locale/sk/LC_MESSAGES/gettext-tools.mo
share/locale/sl/LC_MESSAGES/gettext-tools.mo
share/locale/sr/LC_MESSAGES/gettext-tools.mo
share/locale/sv/LC_MESSAGES/gettext-tools.mo
share/locale/tr/LC_MESSAGES/gettext-tools.mo
share/locale/uk/LC_MESSAGES/gettext-tools.mo
share/locale/vi/LC_MESSAGES/gettext-tools.mo
share/locale/zh_CN/LC_MESSAGES/gettext-tools.mo
share/locale/zh_TW/LC_MESSAGES/gettext-tools.mo
share/man/man1/
autopoint.1.gz
gettextize.1.gz
msgattrib.1.gz
msgcat.1.gz
msgcmp.1.gz
msgcomm.1.gz
msgconv.1.gz
msgen.1.gz
msgexec.1.gz
msgfilter.1.gz
msgfmt.1.gz
msggrep.1.gz
msginit.1.gz
msgmerge.1.gz
msgunfmt.1.gz
msguniq.1.gz
recode-sr-latin.1.gz
xgettext.1.gz
[FILE:98:manifests/plist.asprintf.standard]
include/autosprintf.h
lib/
libasprintf.a
libasprintf.so
libasprintf.so.0
libasprintf.so.0.0.0
[FILE:478:patches/patch-gettext-runtime_configure]
--- gettext-runtime/configure.orig 2016-06-11 13:00:53 UTC
+++ gettext-runtime/configure
@@ -16966,7 +16966,7 @@ if test "x$ac_cv_lib_pthread_pthread_kil
# thread: pthread_create from libc will fail, whereas
# pthread_create will actually create a thread.
case "$host_os" in
- solaris* | hpux*)
+ solaris* | hpux* | dragonfly* | freebsd*)
$as_echo "#define PTHREAD_IN_USE_DETECTION_HARD 1" >>confdefs.h
[FILE:953:patches/patch-gettext-runtime_intl_threadlib.c]
--- gettext-runtime/intl/threadlib.c.orig 2016-03-20 07:37:53 UTC
+++ gettext-runtime/intl/threadlib.c
@@ -29,11 +29,10 @@
# if PTHREAD_IN_USE_DETECTION_HARD
-/* The function to be executed by a dummy thread. */
-static void *
-dummy_thread_func (void *arg)
+static pthread_once_t dummy_once_control = PTHREAD_ONCE_INIT;
+static void
+dummy_once_func (void)
{
- return arg;
}
int
@@ -44,19 +43,10 @@ glthread_in_use (void)
if (!tested)
{
- pthread_t thread;
-
- if (pthread_create (&thread, NULL, dummy_thread_func, NULL) != 0)
- /* Thread creation failed. */
+ if (pthread_once (&dummy_once_control, dummy_once_func) != 0)
result = 0;
else
- {
- /* Thread creation works. */
- void *retval;
- if (pthread_join (thread, &retval) != 0)
- abort ();
- result = 1;
- }
+ result = 1;
tested = 1;
}
return result;
[FILE:474:patches/patch-gettext-tools_configure]
--- gettext-tools/configure.orig 2016-06-11 13:01:07 UTC
+++ gettext-tools/configure
@@ -19321,7 +19321,7 @@ if test "x$ac_cv_lib_pthread_pthread_kil
# thread: pthread_create from libc will fail, whereas
# pthread_create will actually create a thread.
case "$host_os" in
- solaris* | hpux*)
+ solaris* | hpux* | dragonfly* | freebsd*)
$as_echo "#define PTHREAD_IN_USE_DETECTION_HARD 1" >>confdefs.h
[FILE:979:patches/patch-gettext-tools_gnulib-lib_glthread_threadlib.c]
--- gettext-tools/gnulib-lib/glthread/threadlib.c.orig 2014-07-14 07:28:34 UTC
+++ gettext-tools/gnulib-lib/glthread/threadlib.c
@@ -29,11 +29,10 @@
# if PTHREAD_IN_USE_DETECTION_HARD
-/* The function to be executed by a dummy thread. */
-static void *
-dummy_thread_func (void *arg)
+static pthread_once_t dummy_once_control = PTHREAD_ONCE_INIT;
+static void
+dummy_once_func (void)
{
- return arg;
}
int
@@ -44,19 +43,10 @@ glthread_in_use (void)
if (!tested)
{
- pthread_t thread;
-
- if (pthread_create (&thread, NULL, dummy_thread_func, NULL) != 0)
- /* Thread creation failed. */
+ if (pthread_once (&dummy_once_control, dummy_once_func) != 0)
result = 0;
else
- {
- /* Thread creation works. */
- void *retval;
- if (pthread_join (thread, &retval) != 0)
- abort ();
- result = 1;
- }
+ result = 1;
tested = 1;
}
return result;
[FILE:983:patches/patch-gettext-tools_libgettextpo_glthread_threadlib.c]
--- gettext-tools/libgettextpo/glthread/threadlib.c.orig 2014-07-14 07:29:10 UTC
+++ gettext-tools/libgettextpo/glthread/threadlib.c
@@ -29,11 +29,10 @@
# if PTHREAD_IN_USE_DETECTION_HARD
-/* The function to be executed by a dummy thread. */
-static void *
-dummy_thread_func (void *arg)
+static pthread_once_t dummy_once_control = PTHREAD_ONCE_INIT;
+static void
+dummy_once_func (void)
{
- return arg;
}
int
@@ -44,19 +43,10 @@ glthread_in_use (void)
if (!tested)
{
- pthread_t thread;
-
- if (pthread_create (&thread, NULL, dummy_thread_func, NULL) != 0)
- /* Thread creation failed. */
+ if (pthread_once (&dummy_once_control, dummy_once_func) != 0)
result = 0;
else
- {
- /* Thread creation works. */
- void *retval;
- if (pthread_join (thread, &retval) != 0)
- abort ();
- result = 1;
- }
+ result = 1;
tested = 1;
}
return result;