From 8ba70a1c28a4e0ee73db5308b38abc923b0be44d Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Thu, 2 Mar 2017 12:24:31 +0000 Subject: Create meta-gplv2 from files from OE-Core Signed-off-by: Richard Purdie --- .../fix-narrowing-conversion-error.patch | 61 ++++++++++++++++++++++ .../groff-1.18.1.4/groff-1.18.1.4-fix-bindir.patch | 39 ++++++++++++++ .../groff-1.18.1.4/groff-1.18.1.4-remove-mom.patch | 39 ++++++++++++++ .../groff/groff-1.18.1.4/man-local.patch | 36 +++++++++++++ .../groff/groff-1.18.1.4/mdoc-local.patch | 36 +++++++++++++ recipes-extended/groff/groff_1.18.1.4.bb | 50 ++++++++++++++++++ 6 files changed, 261 insertions(+) create mode 100644 recipes-extended/groff/groff-1.18.1.4/fix-narrowing-conversion-error.patch create mode 100644 recipes-extended/groff/groff-1.18.1.4/groff-1.18.1.4-fix-bindir.patch create mode 100644 recipes-extended/groff/groff-1.18.1.4/groff-1.18.1.4-remove-mom.patch create mode 100644 recipes-extended/groff/groff-1.18.1.4/man-local.patch create mode 100644 recipes-extended/groff/groff-1.18.1.4/mdoc-local.patch create mode 100644 recipes-extended/groff/groff_1.18.1.4.bb (limited to 'recipes-extended/groff') diff --git a/recipes-extended/groff/groff-1.18.1.4/fix-narrowing-conversion-error.patch b/recipes-extended/groff/groff-1.18.1.4/fix-narrowing-conversion-error.patch new file mode 100644 index 0000000..4b0176f --- /dev/null +++ b/recipes-extended/groff/groff-1.18.1.4/fix-narrowing-conversion-error.patch @@ -0,0 +1,61 @@ +From fc289ab69c6d7e4ad489172509a85f68afec43ea Mon Sep 17 00:00:00 2001 +From: Hongxu Jia +Date: Fri, 29 Jul 2016 03:19:39 -0400 +Subject: [PATCH] fix narrowing conversion error + +While gcc6 used, build old groff (for anti-GPLv3 reasons) failed: +..... +|groff-1.18.1.4/src/devices/grolbp/charset.h:69:1: error: narrowing +conversion of '130' from 'int' to 'char' inside { } [-Wnarrowing] +...... + +In upstream git://git.savannah.gnu.org/groff.git, +the following commit fix the issue, but the license is GPLV3, +we could not backport it to the old groff which license is GPLV2. +... +commit d180038ae0da19655bc2760ae2043efa0550a76c +Author: Werner LEMBERG +Date: Wed Apr 16 21:11:07 2003 +0000 + * src/devices/grolbp/charset.h (symset): Use `unsigned char'. +... + +We use another different way to fix the issue. + +Upstream-Status: Pending + +Signed-off-by: Hongxu Jia +--- + src/devices/grolbp/charset.h | 2 +- + src/devices/grolbp/lbp.cc | 4 ++-- + 2 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/src/devices/grolbp/charset.h b/src/devices/grolbp/charset.h +index adc76f4..e9c6c5b 100644 +--- a/src/devices/grolbp/charset.h ++++ b/src/devices/grolbp/charset.h +@@ -1,6 +1,6 @@ + // Definition of the WP54 character set + +-char symset[] = { ++int symset[] = { + 0x57,0x50,0x35,0x34,0x00,0x41,0x76,0x61,0x6e,0x74,0x47,0x61, + 0x72,0x64,0x65,0x2d,0x42,0x6f,0x6f,0x6b,0x00,0x41,0x76, + 0x61,0x6e,0x74,0x47,0x61,0x72,0x64,0x65,0x2d,0x44,0x65, +diff --git a/src/devices/grolbp/lbp.cc b/src/devices/grolbp/lbp.cc +index 76db32a..00d4ca7 100644 +--- a/src/devices/grolbp/lbp.cc ++++ b/src/devices/grolbp/lbp.cc +@@ -152,8 +152,8 @@ static void wp54charset() + { + unsigned int i; + lbpputs("\033[714;100;29;0;32;120.}"); +- for (i = 0; i < sizeof(symset); i++) +- lbpputc(symset[i]); ++ for (i = 0; i < sizeof(symset)/sizeof(symset[0]); i++) ++ lbpputc((char)symset[i]&0xFF); + lbpputs("\033[100;0 D"); + return; + } +-- +2.8.1 + diff --git a/recipes-extended/groff/groff-1.18.1.4/groff-1.18.1.4-fix-bindir.patch b/recipes-extended/groff/groff-1.18.1.4/groff-1.18.1.4-fix-bindir.patch new file mode 100644 index 0000000..559ae72 --- /dev/null +++ b/recipes-extended/groff/groff-1.18.1.4/groff-1.18.1.4-fix-bindir.patch @@ -0,0 +1,39 @@ +Upstream-Status: Inappropriate [embedded] + +Signed-off-by: Ming Liu +--- + Makefile.sub | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +--- a/contrib/groffer/Makefile.sub ++++ b/contrib/groffer/Makefile.sub +@@ -38,16 +38,16 @@ groffer: groffer.sh groffer2.sh version. + $(RM) $@; + sed \ + -e "s|@g@|$(g)|g" \ +- -e "s|@BINDIR@|$(DESTDIR)$(bindir)|g" \ ++ -e "s|@BINDIR@|$(bindir)|g" \ + -e "s|@libdir@|$(DESTDIR)$(libdir)|g" \ + -e "s|@VERSION@|$(version)$(revision)|g" \ + $(srcdir)/groffer.sh >$@; + chmod +x $@ + + install_data: groffer +- -test -d $(DESTDIR)$(bindir) || $(mkinstalldirs) $(DESTDIR)$(bindir) +- -$(RM) $(DESTDIR)$(bindir)/groffer +- $(INSTALL_SCRIPT) groffer $(DESTDIR)$(bindir)/groffer ++ -test -d $(bindir) || $(mkinstalldirs) $(bindir) ++ -$(RM) $(bindir)/groffer ++ $(INSTALL_SCRIPT) groffer $(bindir)/groffer + -test -d $(DESTDIR)$(libdir)/groff/groffer || \ + $(mkinstalldirs) $(DESTDIR)$(libdir)/groff/groffer + -$(RM) $(DESTDIR)$(libdir)/groff/groffer/groffer2.sh +@@ -58,7 +58,7 @@ install_data: groffer + $(DESTDIR)$(libdir)/groff/groffer/version.sh + + uninstall_sub: +- -$(RM) $(DESTDIR)$(bindir)/groffer ++ -$(RM) $(bindir)/groffer + -$(RM) $(DESTDIR)$(libdir)/groff/groffer/groffer2.sh + -$(RM) $(DESTDIR)$(libdir)/groff/groffer/version.sh + -rmdir $(DESTDIR)$(libdir)/groff/groffer diff --git a/recipes-extended/groff/groff-1.18.1.4/groff-1.18.1.4-remove-mom.patch b/recipes-extended/groff/groff-1.18.1.4/groff-1.18.1.4-remove-mom.patch new file mode 100644 index 0000000..c24eff9 --- /dev/null +++ b/recipes-extended/groff/groff-1.18.1.4/groff-1.18.1.4-remove-mom.patch @@ -0,0 +1,39 @@ + +Upstream-Status: Inappropriate [embedded] + +Signed-off-by: Saul Wold +--- + groff-1.18.1.4/Makefile.in | 7 +------ + 1 file changed, 1 insertion(+), 6 deletions(-) + +--- a/Makefile.in ++++ b/Makefile.in +@@ -460,27 +460,22 @@ OTHERDIRS=\ + src/roff/grog \ + src/roff/nroff \ + contrib/mm \ + contrib/pic2graph \ + contrib/eqn2graph \ +- contrib/groffer \ +- contrib/mom \ +- doc ++ contrib/groffer + ALLDIRS=$(INCDIRS) $(LIBDIRS) $(PROGDIRS) \ + $(DEVDIRS) $(OTHERDEVDIRS) $(TTYDEVDIRS) $(OTHERDIRS) + EXTRADIRS=\ + font/devps/generate \ + font/devdvi/generate \ + font/devlj4/generate \ +- src/xditview \ + doc + NOMAKEDIRS=\ + arch/djgpp \ + contrib/mm/examples \ + contrib/mm/mm \ +- contrib/mom/examples \ +- contrib/mom/momdoc \ + src/libs/snprintf + DISTDIRS=\ + $(INCDIRS) $(LIBDIRS) $(PROGDIRS) $(DEVDIRS) $(OTHERDEVDIRS) \ + $(ALLTTYDEVDIRS) $(OTHERDIRS) $(EXTRADIRS) $(NOMAKEDIRS) + TARGETS=all install install_bin install_data clean distclean mostlyclean \ diff --git a/recipes-extended/groff/groff-1.18.1.4/man-local.patch b/recipes-extended/groff/groff-1.18.1.4/man-local.patch new file mode 100644 index 0000000..e3f1aa6 --- /dev/null +++ b/recipes-extended/groff/groff-1.18.1.4/man-local.patch @@ -0,0 +1,36 @@ +Upstream-Status: Inappropriate [embedded] + +Signed-off-by: Saul Wold + +Index: groff-1.18.1.4/tmac/man.local +=================================================================== +--- groff-1.18.1.4.orig/tmac/man.local 2000-10-26 22:15:17.000000000 +0800 ++++ groff-1.18.1.4/tmac/man.local 2010-08-24 14:17:52.070006664 +0800 +@@ -1,2 +1,27 @@ + .\" This file is loaded after an-old.tmac. + .\" Put any local modifications to an-old.tmac here. ++. ++.if n \{\ ++. \" Debian: Map \(oq to ' rather than ` in nroff mode for devices other ++. \" than utf8. ++. if !'\*[.T]'utf8' \ ++. tr \[oq]' ++. ++. \" Debian: Disable the use of SGR (ANSI colour) escape sequences by ++. \" grotty. ++. if '\V[GROFF_SGR]'' \ ++. output x X tty: sgr 0 ++. ++. \" Debian: Map \- to the Unicode HYPHEN-MINUS character, to make ++. \" searching in man pages easier. ++. if '\*[.T]'utf8' \ ++. char \- \N'45' ++. ++. \" Debian: Many UTF-8 man pages use "-" instead of "\-" for dashes such ++. \" as those in command-line options. This is a bug in those pages, but ++. \" too many fonts are missing the Unicode HYPHEN character, so we render ++. \" this as the ASCII-compatible HYPHEN-MINUS instead. ++. if '\*[.T]'utf8' \ ++. char - \N'45' ++.\} ++ diff --git a/recipes-extended/groff/groff-1.18.1.4/mdoc-local.patch b/recipes-extended/groff/groff-1.18.1.4/mdoc-local.patch new file mode 100644 index 0000000..409c1a5 --- /dev/null +++ b/recipes-extended/groff/groff-1.18.1.4/mdoc-local.patch @@ -0,0 +1,36 @@ + +Upstream-Status: Inappropriate [embedded] + +Signed-off-by: Saul Wold + +Index: groff-1.18.1.4/tmac/mdoc.local +=================================================================== +--- groff-1.18.1.4.orig/tmac/mdoc.local 2001-03-23 08:17:51.000000000 +0800 ++++ groff-1.18.1.4/tmac/mdoc.local 2010-08-24 14:20:22.014006846 +0800 +@@ -1,2 +1,26 @@ + .\" This file is loaded after doc.tmac. + .\" Put any local modifications to doc.tmac here. ++. ++.if n \{\ ++. \" Debian: Map \(oq to ' rather than ` in nroff mode for devices other ++. \" than utf8. ++. if !'\*[.T]'utf8' \ ++. tr \[oq]' ++. ++. \" Debian: Disable the use of SGR (ANSI colour) escape sequences by ++. \" grotty. ++. if '\V[GROFF_SGR]'' \ ++. output x X tty: sgr 0 ++. ++. \" Debian: Map \- to the Unicode HYPHEN-MINUS character, to make ++. \" searching in man pages easier. ++. if '\*[.T]'utf8' \ ++. char \- \N'45' ++. ++. \" Debian: Many UTF-8 man pages use "-" instead of "\-" for dashes such ++. \" as those in command-line options. This is a bug in those pages, but ++. \" too many fonts are missing the Unicode HYPHEN character, so we render ++. \" this as the ASCII-compatible HYPHEN-MINUS instead. ++. if '\*[.T]'utf8' \ ++. char - \N'45' ++.\} diff --git a/recipes-extended/groff/groff_1.18.1.4.bb b/recipes-extended/groff/groff_1.18.1.4.bb new file mode 100644 index 0000000..fc7eb44 --- /dev/null +++ b/recipes-extended/groff/groff_1.18.1.4.bb @@ -0,0 +1,50 @@ +SUMMARY = "GNU Troff software" +DESCRIPTION = "The groff (GNU troff) software is a typesetting package which reads plain text mixed with \ +formatting commands and produces formatted output." +SECTION = "console/utils" +HOMEPAGE = "http://www.gnu.org/software/groff/" +LICENSE = "GPLv2" +PR = "r1" + +LIC_FILES_CHKSUM = "file://COPYING;md5=e43fc16fccd8519fba405f0a0ff6e8a3" + +SRC_URI = "${GNU_MIRROR}/${BPN}/old/${BP}.tar.gz \ + file://groff-1.18.1.4-remove-mom.patch;striplevel=1 \ + file://man-local.patch \ + file://mdoc-local.patch \ + file://groff-1.18.1.4-fix-bindir.patch \ + file://fix-narrowing-conversion-error.patch \ +" + +inherit autotools texinfo + +EXTRA_OECONF="--without-x --prefix=${D} --exec-prefix=${D} --bindir=${D}${bindir} --datadir=${D}${datadir} --mandir=${D}${datadir}/man --infodir=${D}${datadir}info --with-appresdir=${D}${datadir}" + +SRC_URI[md5sum] = "ceecb81533936d251ed015f40e5f7287" +SRC_URI[sha256sum] = "ff3c7c3b6cae5e8cc5062a144de5eff0022e8e970e1774529cc2d5dde46ce50d" +PARALLEL_MAKE = "" + +do_configure (){ + oe_runconf +} + +do_install_append() { + # Some distros have both /bin/perl and /usr/bin/perl, but we set perl location + # for target as /usr/bin/perl, so fix it to /usr/bin/perl. + for i in afmtodit mmroff; do + if [ -f ${D}${bindir}/$i ]; then + sed -i -e '1s,#!.*perl,#! ${USRBINPATH}/env perl,' ${D}${bindir}/$i + fi + done + + mkdir -p ${D}${sysconfdir}/groff + cp -rf ${D}${datadir}/groff/site-tmac/* ${D}${sysconfdir}/groff/ + cp -rf ${D}${datadir}/groff/site-tmac/* ${D}${datadir}/groff/${PV}/tmac/ +} + +pkg_postinst_${PN}() { + ln -s tbl $D${bindir}/gtbl + echo "export GROFF_FONT_PATH=/usr/share/groff/${PV}/font" >> $D${sysconfdir}/profile + echo "export GROFF_TMAC_PATH=/usr/share/groff/${PV}/tmac" >> $D${sysconfdir}/profile +} + -- cgit v1.2.3-54-g00ecf