1 |
commit: 0ce56d4b619d47990b776cdb8500259012c54204 |
2 |
Author: Necktwi Ozfguah <necktwi <AT> ferryfair <DOT> com> |
3 |
AuthorDate: Thu Feb 28 05:42:44 2019 +0000 |
4 |
Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Feb 28 10:44:02 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/musl.git/commit/?id=0ce56d4b |
7 |
|
8 |
sys-apps/groff: signbit support is assumed when crossbuilt. |
9 |
|
10 |
It should be done with musl as it is done with glibc. |
11 |
|
12 |
Package-Manager: Portage-2.3.51, Repoman-2.3.11 |
13 |
Signed-off-by: Necktwi Ozfguah <necktwi <AT> ferryfair.com> |
14 |
Signed-off-by: Anthony G. Basile <blueness <AT> gentoo.org> |
15 |
|
16 |
sys-apps/groff/Manifest | 1 + |
17 |
.../files/groff-1.19.2-man-unicode-dashes.patch | 24 +++++ |
18 |
.../groff/files/groff-1.22.2-parallel-mom.patch | 96 +++++++++++++++++++ |
19 |
.../groff/files/groff-1.22.3-parallel-mom.patch | 11 +++ |
20 |
sys-apps/groff/files/groff-1.22.4-musl.patch | 52 +++++++++++ |
21 |
sys-apps/groff/groff-1.22.4.ebuild | 102 +++++++++++++++++++++ |
22 |
sys-apps/groff/metadata.xml | 8 ++ |
23 |
7 files changed, 294 insertions(+) |
24 |
|
25 |
diff --git a/sys-apps/groff/Manifest b/sys-apps/groff/Manifest |
26 |
new file mode 100644 |
27 |
index 0000000..67a1953 |
28 |
--- /dev/null |
29 |
+++ b/sys-apps/groff/Manifest |
30 |
@@ -0,0 +1 @@ |
31 |
+DIST groff-1.22.4.tar.gz 4137480 BLAKE2B cdda8a7e8e42b8d8991656ecfbffe0cd0ed5d8932467cab2f3c1eecb3365f4a5c03321b6ed929d451c3dfb00a46046a781303a1c55c4aa65eb7d178fb36b1cbc SHA512 1c42d3cd71efaf067b5850945d9097fa1f0fadd5e2b6ba7446bd9d4f439fe1ad058e4ddb0d4e0f503682137dfc7c822944ce1e3e5cf981673f8ba197ea77126d |
32 |
|
33 |
diff --git a/sys-apps/groff/files/groff-1.19.2-man-unicode-dashes.patch b/sys-apps/groff/files/groff-1.19.2-man-unicode-dashes.patch |
34 |
new file mode 100644 |
35 |
index 0000000..276460f |
36 |
--- /dev/null |
37 |
+++ b/sys-apps/groff/files/groff-1.19.2-man-unicode-dashes.patch |
38 |
@@ -0,0 +1,24 @@ |
39 |
+format dashes as dashes so as to not confuse people |
40 |
+ |
41 |
+http://bugs.gentoo.org/16108 |
42 |
+http://bugs.gentoo.org/17580 |
43 |
+http://bugs.gentoo.org/121502 |
44 |
+ |
45 |
+--- a/tmac/man.local |
46 |
++++ b/tmac/man.local |
47 |
+@@ -1,2 +1,6 @@ |
48 |
+ .\" This file is loaded after an-old.tmac. |
49 |
+ .\" Put any local modifications to an-old.tmac here. |
50 |
++.if '\*[.T]'utf8' \{\ |
51 |
++. char \- \N'45' |
52 |
++. char - \N'45' |
53 |
++.\} |
54 |
+--- a/tmac/mdoc.local |
55 |
++++ b/tmac/mdoc.local |
56 |
+@@ -1,2 +1,6 @@ |
57 |
+ .\" This file is loaded after doc.tmac. |
58 |
+ .\" Put any local modifications to doc.tmac here. |
59 |
++.if '\*[.T]'utf8' \{\ |
60 |
++. char \- \N'45' |
61 |
++. char - \N'45' |
62 |
++.\} |
63 |
|
64 |
diff --git a/sys-apps/groff/files/groff-1.22.2-parallel-mom.patch b/sys-apps/groff/files/groff-1.22.2-parallel-mom.patch |
65 |
new file mode 100644 |
66 |
index 0000000..7cf3c22 |
67 |
--- /dev/null |
68 |
+++ b/sys-apps/groff/files/groff-1.22.2-parallel-mom.patch |
69 |
@@ -0,0 +1,96 @@ |
70 |
+From 9f3af719383ab525c86ee0f514e268ef8494330a Mon Sep 17 00:00:00 2001 |
71 |
+From: Mike Frysinger <vapier@g.o> |
72 |
+Date: Fri, 6 Dec 2013 20:40:10 -0500 |
73 |
+Subject: [PATCH] fix parallel build w/gropdf and mom examples |
74 |
+ |
75 |
+The contrib/mom/examples/ directory uses the helper script from |
76 |
+src/devices/gropdf/. Currently though, parallel builds might fail |
77 |
+like so: |
78 |
+ |
79 |
+... |
80 |
+make[2]: Entering directory `.../groff-1.22.2/contrib/mom' |
81 |
+GROFF_COMMAND_PREFIX= GROFF_BIN_PATH="`echo .../groff-1.22.2/src/roff/groff .../groff-1.22.2/src/roff/troff .../groff-1.22.2/src/devices/grops .../groff-1.22.2/src/devices/gropdf | sed -e 's| *|:|g'`" PDFMOM_BIN_PATH=".../groff-1.22.2/src/devices/gropdf" .../groff-1.22.2/src/devices/gropdf/pdfmom -F.../groff-1.22.2/font -F.../groff-1.22.2/font -M.../groff-1.22.2/tmac -M.../groff-1.22.2/tmac -M. examples/letter.mom >examples/letter.pdf |
82 |
+GROFF_COMMAND_PREFIX= GROFF_BIN_PATH="`echo .../groff-1.22.2/src/roff/groff .../groff-1.22.2/src/roff/troff .../groff-1.22.2/src/devices/grops .../groff-1.22.2/src/devices/gropdf | sed -e 's| *|:|g'`" PDFMOM_BIN_PATH=".../groff-1.22.2/src/devices/gropdf" .../groff-1.22.2/src/devices/gropdf/pdfmom -F.../groff-1.22.2/font -F.../groff-1.22.2/font -M.../groff-1.22.2/tmac -M.../groff-1.22.2/tmac -M. examples/mom-pdf.mom >examples/mom-pdf.pdf |
83 |
+/bin/sh: .../groff-1.22.2/src/devices/gropdf/pdfmom: No such file or directory |
84 |
+make[2]: *** [examples/letter.pdf] Error 127 |
85 |
+/bin/sh: .../groff-1.22.2/src/devices/gropdf/pdfmom: No such file or directory |
86 |
+make[2]: *** [examples/mom-pdf.pdf] Error 127 |
87 |
+make[2]: Leaving directory `.../groff-1.22.2/contrib/mom' |
88 |
+make[1]: *** [contrib/mom] Error 2 |
89 |
+... |
90 |
+make[2]: Entering directory `.../groff-1.22.2/src/devices/gropdf' |
91 |
+sed -f .../groff-1.22.2/arch/misc/shdeps.sed \ |
92 |
+ -e "s|@VERSION@|1.22.2|" \ |
93 |
+ -e "s|@PERLPATH@|/usr/bin/perl|" ./pdfmom.pl >pdfmom |
94 |
+ |
95 |
+The top level makefile tries to account for this in general with OTHERDIRS, |
96 |
+but looks like src/devices/gropdf/ was added to this variable (which holds |
97 |
+contrib/mom/ too) because gropdf installs a shell script, and the other |
98 |
+prog vars require it to be a dir of things to compile. |
99 |
+ |
100 |
+Declare a new prog var for holding shell scripts. |
101 |
+ |
102 |
+URL: http://crbug.com/324116 |
103 |
+URL: https://bugs.gentoo.org/487276 |
104 |
+Signed-off-by: Mike Frysinger <vapier@g.o> |
105 |
+ |
106 |
+2013-12-06 Mike Frysinger <vapier@g.o> |
107 |
+ |
108 |
+ * Makefile.in (SHPROGDIRS): Declare. |
109 |
+ (PROGDIRS): Add $(SHPROGDIRS). |
110 |
+ (OTHERDIRS): Delete src/devices/gropdf. |
111 |
+ ($(SHPROGDIRS):): Add to existing rule. |
112 |
+ ($(OTHERDIRS):): Depend on $(SHPROGDIRS). |
113 |
+--- |
114 |
+ Makefile.in | 8 +++++--- |
115 |
+ 1 file changed, 5 insertions(+), 3 deletions(-) |
116 |
+ |
117 |
+diff --git a/Makefile.in b/Makefile.in |
118 |
+index a794de7..8e478af 100644 |
119 |
+--- a/Makefile.in |
120 |
++++ b/Makefile.in |
121 |
+@@ -602,12 +602,15 @@ CCPROGDIRS=\ |
122 |
+ src/utils/addftinfo |
123 |
+ CPROGDIRS=\ |
124 |
+ src/utils/pfbtops |
125 |
++SHPROGDIRS=\ |
126 |
++ src/devices/gropdf |
127 |
+ PROGDEPDIRS=\ |
128 |
+ arch/misc |
129 |
+ PROGDIRS=\ |
130 |
+ $(PROGDEPDIRS) \ |
131 |
+ $(CCPROGDIRS) \ |
132 |
+ $(CPROGDIRS) \ |
133 |
++ $(SHPROGDIRS) \ |
134 |
+ $(XPROGDIRS) |
135 |
+ DEVDIRS=\ |
136 |
+ font/devps \ |
137 |
+@@ -637,7 +640,6 @@ OTHERDIRS=\ |
138 |
+ contrib/glilypond \ |
139 |
+ contrib/hdtbl \ |
140 |
+ contrib/pdfmark \ |
141 |
+- src/devices/gropdf \ |
142 |
+ font/devpdf \ |
143 |
+ contrib/mom \ |
144 |
+ contrib/gdiffmk |
145 |
+@@ -778,7 +780,7 @@ $(CCPROGDIRS): FORCE $(LIBDIRS) |
146 |
+ -f $(top_srcdir)/Makefile.ccpg \ |
147 |
+ -f Makefile.dep $(do) |
148 |
+ |
149 |
+-$(DEVDIRS) $(XDEVDIRS) $(OTHERDEVDIRS) $(TTYDEVDIRS): FORCE $(PROGDEPDIRS) $(CCPROGDIRS) $(CPROGDIRS) |
150 |
++$(DEVDIRS) $(XDEVDIRS) $(OTHERDEVDIRS) $(TTYDEVDIRS) $(SHPROGDIRS): FORCE $(PROGDEPDIRS) $(CCPROGDIRS) $(CPROGDIRS) |
151 |
+ @$(ENVSETUP); \ |
152 |
+ if test $(srcdir) = .; then \ |
153 |
+ srcdir=.; \ |
154 |
+@@ -809,7 +811,7 @@ $(GNULIBDIRS): FORCE |
155 |
+ $(MAKE) ACLOCAL=: AUTOCONF=: AUTOHEADER=: AUTOMAKE=: $(do) ;; \ |
156 |
+ esac |
157 |
+ |
158 |
+-$(OTHERDIRS): $(PROGDEPDIRS) $(CCPROGDIRS) $(CPROGDIRS) |
159 |
++$(OTHERDIRS): $(PROGDEPDIRS) $(CCPROGDIRS) $(CPROGDIRS) $(SHPROGDIRS) |
160 |
+ |
161 |
+ $(INCDIRS) $(PROGDEPDIRS) $(OTHERDIRS): FORCE |
162 |
+ @$(ENVSETUP); \ |
163 |
+-- |
164 |
+1.8.4.3 |
165 |
+ |
166 |
|
167 |
diff --git a/sys-apps/groff/files/groff-1.22.3-parallel-mom.patch b/sys-apps/groff/files/groff-1.22.3-parallel-mom.patch |
168 |
new file mode 100644 |
169 |
index 0000000..10661ac |
170 |
--- /dev/null |
171 |
+++ b/sys-apps/groff/files/groff-1.22.3-parallel-mom.patch |
172 |
@@ -0,0 +1,11 @@ |
173 |
+--- groff-1.22.3/Makefile.in |
174 |
++++ groff-1.22.3/Makefile.in |
175 |
+@@ -864,7 +864,7 @@ |
176 |
+ -f $(top_srcdir)/Makefile.ccpg \ |
177 |
+ -f Makefile.dep $(do) |
178 |
+ |
179 |
+-$(DEVDIRS) $(XDEVDIRS) $(OTHERDEVDIRS) $(TTYDEVDIRS): FORCE \ |
180 |
++$(DEVDIRS) $(XDEVDIRS) $(OTHERDEVDIRS) $(TTYDEVDIRS) $(SHPROGDIRS): FORCE \ |
181 |
+ $(PROGDEPDIRS) $(CCPROGDIRS) $(CPROGDIRS) |
182 |
+ @$(ENVSETUP); \ |
183 |
+ if test $(srcdir) = .; then \ |
184 |
|
185 |
diff --git a/sys-apps/groff/files/groff-1.22.4-musl.patch b/sys-apps/groff/files/groff-1.22.4-musl.patch |
186 |
new file mode 100644 |
187 |
index 0000000..0ed0e09 |
188 |
--- /dev/null |
189 |
+++ b/sys-apps/groff/files/groff-1.22.4-musl.patch |
190 |
@@ -0,0 +1,52 @@ |
191 |
+diff --git a/gnulib_m4/signbit.m4 b/gnulib_m4/signbit.m4 |
192 |
+index 9e7884d..ef1ed6f 100644 |
193 |
+--- a/gnulib_m4/signbit.m4 |
194 |
++++ b/gnulib_m4/signbit.m4 |
195 |
+@@ -29,12 +29,12 @@ AC_DEFUN([gl_SIGNBIT], |
196 |
+ [gl_cv_func_signbit=yes], |
197 |
+ [gl_cv_func_signbit=no], |
198 |
+ [case "$host_os" in |
199 |
+- # Guess yes on glibc systems. |
200 |
+- *-gnu* | gnu*) gl_cv_func_signbit="guessing yes" ;; |
201 |
+- # Guess yes on native Windows. |
202 |
+- mingw*) gl_cv_func_signbit="guessing yes" ;; |
203 |
+- # If we don't know, assume the worst. |
204 |
+- *) gl_cv_func_signbit="guessing no" ;; |
205 |
++ # Guess yes on glibc systems. |
206 |
++ *-gnu* | gnu* | *musl*) gl_cv_func_signbit="guessing yes" ;; |
207 |
++ # Guess yes on native Windows. |
208 |
++ mingw*) gl_cv_func_signbit="guessing yes" ;; |
209 |
++ # If we don't know, assume the worst. |
210 |
++ *) gl_cv_func_signbit="guessing no" ;; |
211 |
+ esac |
212 |
+ ]) |
213 |
+ ]) |
214 |
+@@ -60,17 +60,17 @@ AC_DEFUN([gl_SIGNBIT], |
215 |
+ [gl_cv_func_signbit_gcc=yes], |
216 |
+ [gl_cv_func_signbit_gcc=no], |
217 |
+ [case "$host_os" in |
218 |
+- # Guess yes on glibc systems. |
219 |
+- *-gnu* | gnu*) gl_cv_func_signbit_gcc="guessing yes" ;; |
220 |
+- # Guess yes on mingw, no on MSVC. |
221 |
+- mingw*) if test -n "$GCC"; then |
222 |
+- gl_cv_func_signbit_gcc="guessing yes" |
223 |
+- else |
224 |
+- gl_cv_func_signbit_gcc="guessing no" |
225 |
+- fi |
226 |
+- ;; |
227 |
+- # If we don't know, assume the worst. |
228 |
+- *) gl_cv_func_signbit_gcc="guessing no" ;; |
229 |
++ # Guess yes on glibc systems. |
230 |
++ *-gnu* | gnu* | *musl*) gl_cv_func_signbit_gcc="guessing yes" ;; |
231 |
++ # Guess yes on mingw, no on MSVC. |
232 |
++ mingw*) if test -n "$GCC"; then |
233 |
++ gl_cv_func_signbit_gcc="guessing yes" |
234 |
++ else |
235 |
++ gl_cv_func_signbit_gcc="guessing no" |
236 |
++ fi |
237 |
++ ;; |
238 |
++ # If we don't know, assume the worst. |
239 |
++ *) gl_cv_func_signbit_gcc="guessing no" ;; |
240 |
+ esac |
241 |
+ ]) |
242 |
+ ]) |
243 |
|
244 |
diff --git a/sys-apps/groff/groff-1.22.4.ebuild b/sys-apps/groff/groff-1.22.4.ebuild |
245 |
new file mode 100644 |
246 |
index 0000000..20bcc24 |
247 |
--- /dev/null |
248 |
+++ b/sys-apps/groff/groff-1.22.4.ebuild |
249 |
@@ -0,0 +1,102 @@ |
250 |
+# Copyright 1999-2019 Gentoo Authors |
251 |
+# Distributed under the terms of the GNU General Public License v2 |
252 |
+ |
253 |
+EAPI=6 |
254 |
+ |
255 |
+inherit toolchain-funcs |
256 |
+ |
257 |
+MY_P="${P/_/.}" |
258 |
+ |
259 |
+DESCRIPTION="Text formatter used for man pages" |
260 |
+HOMEPAGE="https://www.gnu.org/software/groff/groff.html" |
261 |
+SRC_URI="mirror://gnu/groff/${MY_P}.tar.gz |
262 |
+ mirror://gnu-alpha/groff/${MY_P}.tar.gz" |
263 |
+ |
264 |
+LICENSE="GPL-2" |
265 |
+SLOT="0" |
266 |
+[[ "${PV}" == *_rc* ]] || \ |
267 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
268 |
+IUSE="examples X" |
269 |
+ |
270 |
+RDEPEND=" |
271 |
+ X? ( |
272 |
+ x11-libs/libX11 |
273 |
+ x11-libs/libXt |
274 |
+ x11-libs/libXmu |
275 |
+ x11-libs/libXaw |
276 |
+ x11-libs/libSM |
277 |
+ x11-libs/libICE |
278 |
+ )" |
279 |
+DEPEND="${RDEPEND} |
280 |
+ dev-lang/perl |
281 |
+ sys-apps/texinfo" |
282 |
+ |
283 |
+DOCS=( BUG-REPORT ChangeLog MORE.STUFF NEWS PROBLEMS PROJECTS README TODO ) |
284 |
+ |
285 |
+S="${WORKDIR}/${MY_P}" |
286 |
+ |
287 |
+PATCHES=( |
288 |
+ "${FILESDIR}"/${PN}-1.19.2-man-unicode-dashes.patch #16108 #17580 #121502 |
289 |
+ "${FILESDIR}"/${PN}-1.22.4-musl.patch |
290 |
+) |
291 |
+ |
292 |
+src_prepare() { |
293 |
+ default |
294 |
+ |
295 |
+ # honor Gentoo's docdir |
296 |
+ sed -i -e "s|^docdir =.*|docdir = \"${EPREFIX%/}/usr/share/doc/${PF}\"|g" \ |
297 |
+ Makefile.in \ |
298 |
+ || die "failed to modify Makefile.in" |
299 |
+ |
300 |
+ local pfx=$(usex prefix ' Prefix' '') |
301 |
+ cat <<-EOF >> tmac/mdoc.local |
302 |
+ .ds volume-operating-system Gentoo${pfx} |
303 |
+ .ds operating-system Gentoo${pfx}/${KERNEL} |
304 |
+ .ds default-operating-system Gentoo${pfx}/${KERNEL} |
305 |
+ EOF |
306 |
+ |
307 |
+ # make sure we don't get a crappy `g' nameprefix on UNIX systems with real |
308 |
+ # troff (GROFF_G macro runs some test to see, its own troff doesn't satisfy) |
309 |
+ sed -i -e 's/^[ \t]\+g=g$/g=/' configure || die |
310 |
+} |
311 |
+ |
312 |
+src_configure() { |
313 |
+ local myeconfargs=( |
314 |
+ --with-appresdir="${EPREFIX%/}"/usr/share/X11/app-defaults |
315 |
+ $(use_with X x) |
316 |
+ ) |
317 |
+ econf "${myeconfargs[@]}" |
318 |
+} |
319 |
+ |
320 |
+src_compile() { |
321 |
+ if tc-is-cross-compiler ; then |
322 |
+ local CROSS_ARGS=( |
323 |
+ GROFFBIN="$(type -P groff)" |
324 |
+ TROFFBIN="$(type -P troff)" |
325 |
+ GROFF_BIN_DIR= |
326 |
+ GROFF_BIN_PATH= |
327 |
+ ) |
328 |
+ else |
329 |
+ unset CROSS_ARGS |
330 |
+ fi |
331 |
+ |
332 |
+ emake AR="$(tc-getAR)" "${CROSS_ARGS[@]}" |
333 |
+} |
334 |
+ |
335 |
+src_install() { |
336 |
+ default |
337 |
+ |
338 |
+ # The following links are required for man #123674 |
339 |
+ dosym eqn /usr/bin/geqn |
340 |
+ dosym tbl /usr/bin/gtbl |
341 |
+ |
342 |
+ if ! use examples ; then |
343 |
+ # The pdf files might not be generated if ghostscript is unavailable. #602020 |
344 |
+ local pdf="${ED%/}/usr/share/doc/${PF}/examples/mom/mom-pdf.pdf" |
345 |
+ if [[ -e ${pdf} ]] ; then |
346 |
+ # Keep mom-pdf.pdf since it's more of a manual than an example. #454196 #516732 |
347 |
+ mv "${pdf}" "${ED%/}"/usr/share/doc/${PF}/pdf/ || die |
348 |
+ fi |
349 |
+ rm -rf "${ED%/}"/usr/share/doc/${PF}/examples |
350 |
+ fi |
351 |
+} |
352 |
|
353 |
diff --git a/sys-apps/groff/metadata.xml b/sys-apps/groff/metadata.xml |
354 |
new file mode 100644 |
355 |
index 0000000..56c1244 |
356 |
--- /dev/null |
357 |
+++ b/sys-apps/groff/metadata.xml |
358 |
@@ -0,0 +1,8 @@ |
359 |
+<?xml version="1.0" encoding="UTF-8"?> |
360 |
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> |
361 |
+<pkgmetadata> |
362 |
+<maintainer type="project"> |
363 |
+ <email>base-system@g.o</email> |
364 |
+ <name>Gentoo Base System</name> |
365 |
+</maintainer> |
366 |
+</pkgmetadata> |