From 79c3a348e1db805b3c2c285e7c324d3743fe9bd5 Mon Sep 17 00:00:00 2001 From: Akinori Hattori Date: Sun, 10 Jun 2018 11:38:36 +0900 Subject: app-text/lv: update patches Package-Manager: Portage-2.3.40, Repoman-2.3.9 --- app-text/lv/files/lv-4.51-gentoo.patch | 40 ------------------------------- app-text/lv/files/lv-4.51-protos.patch | 29 ----------------------- app-text/lv/files/lv-4.51-tinfo.patch | 22 ----------------- app-text/lv/files/lv-4.51-xz.diff | 43 ---------------------------------- app-text/lv/files/lv-gentoo.patch | 39 ++++++++++++++++++++++++++++++ app-text/lv/files/lv-headers.patch | 26 ++++++++++++++++++++ app-text/lv/files/lv-tinfo.patch | 20 ++++++++++++++++ app-text/lv/files/lv-xz.patch | 43 ++++++++++++++++++++++++++++++++++ app-text/lv/lv-4.51-r3.ebuild | 8 +++---- app-text/lv/lv-4.51-r4.ebuild | 8 +++---- 10 files changed, 136 insertions(+), 142 deletions(-) delete mode 100644 app-text/lv/files/lv-4.51-gentoo.patch delete mode 100644 app-text/lv/files/lv-4.51-protos.patch delete mode 100644 app-text/lv/files/lv-4.51-tinfo.patch delete mode 100644 app-text/lv/files/lv-4.51-xz.diff create mode 100644 app-text/lv/files/lv-gentoo.patch create mode 100644 app-text/lv/files/lv-headers.patch create mode 100644 app-text/lv/files/lv-tinfo.patch create mode 100644 app-text/lv/files/lv-xz.patch (limited to 'app-text') diff --git a/app-text/lv/files/lv-4.51-gentoo.patch b/app-text/lv/files/lv-4.51-gentoo.patch deleted file mode 100644 index 90acab49fd16..000000000000 --- a/app-text/lv/files/lv-4.51-gentoo.patch +++ /dev/null @@ -1,40 +0,0 @@ -diff -Naur lv451.orig/src/Makefile.in lv451/src/Makefile.in ---- lv451.orig/src/Makefile.in 2004-01-06 16:22:17.000000000 +0900 -+++ lv451/src/Makefile.in 2008-10-08 00:20:13.000000000 +0900 -@@ -25,6 +25,7 @@ - LDFLAGS=@LDFLAGS@ - INSTALL=@INSTALL@ - PERL= @PERL@ -+DESTDIR= - - OBJS= itable.o ctable.o uty.o istr.o stream.o file.o guess.o decode.o \ - encode.o escape.o iso2022.o iso8859.o iso2cn.o iso2jp.o iso2kr.o \ -@@ -64,18 +65,19 @@ - # - - install:: -- $(INSTALL) -s -m 555 lv $(bindir) -- if test -f $(bindir)/lgrep; then \ -- /bin/rm -f $(bindir)/lgrep; \ -+ if test ! -d $(DESTDIR)$(bindir); then \ -+ mkdir -p $(DESTDIR)$(bindir); \ - fi -- (cd $(bindir); ln lv lgrep) -- if test ! -d $(lvlibdir); then \ -- mkdir -p $(lvlibdir); \ -+ $(INSTALL) -m 555 lv $(DESTDIR)$(bindir) -+ (cd $(DESTDIR)$(bindir); ln -s lv lgrep) -+ if test ! -d $(DESTDIR)$(lvlibdir); then \ -+ mkdir -p $(DESTDIR)$(lvlibdir); \ - fi -- $(INSTALL) -m 444 $(srcdir)/../lv.hlp $(lvlibdir) -- if test -d $(mandir) -a -d $(mandir)/man1; then \ -- $(INSTALL) -m 444 $(srcdir)/../lv.1 $(mandir)/man1; \ -+ $(INSTALL) -m 444 $(srcdir)/../lv.hlp $(DESTDIR)$(lvlibdir) -+ if test ! -d $(DESTDIR)$(mandir)/man1; then \ -+ mkdir -p $(DESTDIR)$(mandir)/man1; \ - fi -+ $(INSTALL) -m 444 $(srcdir)/../lv.1 $(DESTDIR)$(mandir)/man1; \ - - uninstall:: - for i in $(bindir)/lv $(bindir)/lgrep $(lvlibdir)/lv.hlp $(mandir)/man1/lv.1; do \ diff --git a/app-text/lv/files/lv-4.51-protos.patch b/app-text/lv/files/lv-4.51-protos.patch deleted file mode 100644 index 602ef5f6117f..000000000000 --- a/app-text/lv/files/lv-4.51-protos.patch +++ /dev/null @@ -1,29 +0,0 @@ -Add missing string protos. - - * src/guess.c:150:12: warning: implicit declaration of function ‘strncmp’ [-Wimplicit-function-declaration] - * src/guess.c:218:22: warning: implicit declaration of function ‘strcmp’ [-Wimplicit-function-declaration] - * src/guesslocale.c:42:9: warning: implicit declaration of function ‘toupper’ [-Wimplicit-function-declaration] -diff --git a/src/guess.c b/src/guess.c -index facd95e..555acd3 100644 ---- a/src/guess.c -+++ b/src/guess.c -@@ -21,6 +21,7 @@ - */ - - #include -+#include /* strcmp */ - - #include - #include -diff --git a/src/guesslocale.c b/src/guesslocale.c -index 7974c88..c259723 100644 ---- a/src/guesslocale.c -+++ b/src/guesslocale.c -@@ -29,6 +29,7 @@ - #include - #endif - -+#include /* toupper */ - #include - #include - #include diff --git a/app-text/lv/files/lv-4.51-tinfo.patch b/app-text/lv/files/lv-4.51-tinfo.patch deleted file mode 100644 index 9c17a92a65ef..000000000000 --- a/app-text/lv/files/lv-4.51-tinfo.patch +++ /dev/null @@ -1,22 +0,0 @@ -diff --git a/src/configure.in b/src/configure.in -index 7d118de..29833a7 100644 ---- a/src/configure.in -+++ b/src/configure.in -@@ -24,7 +24,16 @@ AC_ARG_ENABLE(purify, - dnl Checks for libraries. - AC_DEFINE(UNIX) - AC_DEFINE(TERMCAP) --AC_CHECK_LIB(terminfo, tgetstr,, [AC_CHECK_LIB(termcap, tgetstr,, [AC_CHECK_LIB(ncurses, tgetstr,, [AC_CHECK_LIB(curses, tgetstr)])])]) -+PKG_CHECK_MODULES( -+ CURSES, -+ ncurses, -+ [ -+ CPPFLAGS="$CURSES_CFLAGS $CPPFLAGS" -+ LIBS="$CURSES_LIBS $LIBS" -+ ], -+ [ -+ AC_CHECK_LIB(terminfo, tgetstr,, [AC_CHECK_LIB(termcap, tgetstr,, [AC_CHECK_LIB(ncurses, tgetstr,, [AC_CHECK_LIB(curses, tgetstr)])])]) -+ ]) - - dnl Checks for header files. - AC_HEADER_STDC diff --git a/app-text/lv/files/lv-4.51-xz.diff b/app-text/lv/files/lv-4.51-xz.diff deleted file mode 100644 index 058029b8be28..000000000000 --- a/app-text/lv/files/lv-4.51-xz.diff +++ /dev/null @@ -1,43 +0,0 @@ ---- lv451.orig/index.html -+++ lv451/index.html -@@ -301,8 +301,11 @@ -

- Compressed files that have suffix ``gz'', ``z'', or ``GZ'', ``Z'' are - extracted by lv using zcat (1), -- and ``bz2'' or ``BZ2'' with bzcat (1). -- Please install zcat and bzcat that can expand all of them. -+ ``bz2'' or ``BZ2'' with bzcat (1). -+ ``lzma'' or ``LZMA'' with lzcat (1). -+ and ``xz'' or ``XZ'' with xzcat (1). -+ Please install zcat, bzcat, lzcat and xzcat -+ that can expand all of them. -

- In case that standard output is not connected to an ordinal terminal - but to redirect or pipe-line, ---- lv451.orig/src/stream.c -+++ lv451/src/stream.c -@@ -43,6 +43,8 @@ - - private byte *gz_filter = "zcat"; - private byte *bz2_filter = "bzcat"; -+private byte *lzma_filter = "lzcat"; -+private byte *xz_filter = "xzcat"; - - private stream_t *StreamAlloc() - { -@@ -75,10 +77,14 @@ - filter = gz_filter; - else if( !strcmp( "bz2", exts ) || !strcmp( "BZ2", exts ) ) - filter = bz2_filter; -+ else if( !strcmp( "lzma", exts ) || !strcmp( "LZMA", exts ) ) -+ filter = lzma_filter; -+ else if( !strcmp( "xz", exts ) || !strcmp( "XZ", exts ) ) -+ filter = xz_filter; - } - if( NULL != filter ){ - /* -- * zcat or bzcat -+ * zcat or bzcat or lzcat or xzcat - */ - if( NULL == (st->fp = (FILE *)tmpfile()) ) - perror( "temporary file" ), exit( -1 ); diff --git a/app-text/lv/files/lv-gentoo.patch b/app-text/lv/files/lv-gentoo.patch new file mode 100644 index 000000000000..99724ef9c69e --- /dev/null +++ b/app-text/lv/files/lv-gentoo.patch @@ -0,0 +1,39 @@ +--- a/src/Makefile.in ++++ b/src/Makefile.in +@@ -25,6 +25,7 @@ + LDFLAGS=@LDFLAGS@ + INSTALL=@INSTALL@ + PERL= @PERL@ ++DESTDIR= + + OBJS= itable.o ctable.o uty.o istr.o stream.o file.o guess.o decode.o \ + encode.o escape.o iso2022.o iso8859.o iso2cn.o iso2jp.o iso2kr.o \ +@@ -64,18 +65,19 @@ + # + + install:: +- $(INSTALL) -s -m 555 lv $(bindir) +- if test -f $(bindir)/lgrep; then \ +- /bin/rm -f $(bindir)/lgrep; \ ++ if test ! -d $(DESTDIR)$(bindir); then \ ++ mkdir -p $(DESTDIR)$(bindir); \ + fi +- (cd $(bindir); ln lv lgrep) +- if test ! -d $(lvlibdir); then \ +- mkdir -p $(lvlibdir); \ ++ $(INSTALL) -m 555 lv $(DESTDIR)$(bindir) ++ (cd $(DESTDIR)$(bindir); ln -s lv lgrep) ++ if test ! -d $(DESTDIR)$(lvlibdir); then \ ++ mkdir -p $(DESTDIR)$(lvlibdir); \ + fi +- $(INSTALL) -m 444 $(srcdir)/../lv.hlp $(lvlibdir) +- if test -d $(mandir) -a -d $(mandir)/man1; then \ +- $(INSTALL) -m 444 $(srcdir)/../lv.1 $(mandir)/man1; \ ++ $(INSTALL) -m 444 $(srcdir)/../lv.hlp $(DESTDIR)$(lvlibdir) ++ if test ! -d $(DESTDIR)$(mandir)/man1; then \ ++ mkdir -p $(DESTDIR)$(mandir)/man1; \ + fi ++ $(INSTALL) -m 444 $(srcdir)/../lv.1 $(DESTDIR)$(mandir)/man1; \ + + uninstall:: + for i in $(bindir)/lv $(bindir)/lgrep $(lvlibdir)/lv.hlp $(mandir)/man1/lv.1; do \ diff --git a/app-text/lv/files/lv-headers.patch b/app-text/lv/files/lv-headers.patch new file mode 100644 index 000000000000..5207ec07cbee --- /dev/null +++ b/app-text/lv/files/lv-headers.patch @@ -0,0 +1,26 @@ +Add missing string protos. + + * src/guess.c:150:12: warning: implicit declaration of function ‘strncmp’ [-Wimplicit-function-declaration] + * src/guess.c:218:22: warning: implicit declaration of function ‘strcmp’ [-Wimplicit-function-declaration] + * src/guesslocale.c:42:9: warning: implicit declaration of function ‘toupper’ [-Wimplicit-function-declaration] + +--- a/src/guess.c ++++ b/src/guess.c +@@ -21,6 +21,7 @@ + */ + + #include ++#include /* strcmp */ + + #include + #include +--- a/src/guesslocale.c ++++ b/src/guesslocale.c +@@ -29,6 +29,7 @@ + #include + #endif + ++#include /* toupper */ + #include + #include + #include diff --git a/app-text/lv/files/lv-tinfo.patch b/app-text/lv/files/lv-tinfo.patch new file mode 100644 index 000000000000..7da23d474951 --- /dev/null +++ b/app-text/lv/files/lv-tinfo.patch @@ -0,0 +1,20 @@ +--- a/src/configure.in ++++ b/src/configure.in +@@ -24,7 +24,16 @@ AC_ARG_ENABLE(purify, + dnl Checks for libraries. + AC_DEFINE(UNIX) + AC_DEFINE(TERMCAP) +-AC_CHECK_LIB(terminfo, tgetstr,, [AC_CHECK_LIB(termcap, tgetstr,, [AC_CHECK_LIB(ncurses, tgetstr,, [AC_CHECK_LIB(curses, tgetstr)])])]) ++PKG_CHECK_MODULES( ++ CURSES, ++ ncurses, ++ [ ++ CPPFLAGS="$CURSES_CFLAGS $CPPFLAGS" ++ LIBS="$CURSES_LIBS $LIBS" ++ ], ++ [ ++ AC_CHECK_LIB(terminfo, tgetstr,, [AC_CHECK_LIB(termcap, tgetstr,, [AC_CHECK_LIB(ncurses, tgetstr,, [AC_CHECK_LIB(curses, tgetstr)])])]) ++ ]) + + dnl Checks for header files. + AC_HEADER_STDC diff --git a/app-text/lv/files/lv-xz.patch b/app-text/lv/files/lv-xz.patch new file mode 100644 index 000000000000..1b6ad8a91659 --- /dev/null +++ b/app-text/lv/files/lv-xz.patch @@ -0,0 +1,43 @@ +--- a/index.html ++++ b/index.html +@@ -301,8 +301,11 @@ +

+ Compressed files that have suffix ``gz'', ``z'', or ``GZ'', ``Z'' are + extracted by lv using zcat (1), +- and ``bz2'' or ``BZ2'' with bzcat (1). +- Please install zcat and bzcat that can expand all of them. ++ ``bz2'' or ``BZ2'' with bzcat (1). ++ ``lzma'' or ``LZMA'' with lzcat (1). ++ and ``xz'' or ``XZ'' with xzcat (1). ++ Please install zcat, bzcat, lzcat and xzcat ++ that can expand all of them. +

+ In case that standard output is not connected to an ordinal terminal + but to redirect or pipe-line, +--- a/src/stream.c ++++ b/src/stream.c +@@ -43,6 +43,8 @@ + + private byte *gz_filter = "zcat"; + private byte *bz2_filter = "bzcat"; ++private byte *lzma_filter = "lzcat"; ++private byte *xz_filter = "xzcat"; + + private stream_t *StreamAlloc() + { +@@ -75,10 +77,14 @@ + filter = gz_filter; + else if( !strcmp( "bz2", exts ) || !strcmp( "BZ2", exts ) ) + filter = bz2_filter; ++ else if( !strcmp( "lzma", exts ) || !strcmp( "LZMA", exts ) ) ++ filter = lzma_filter; ++ else if( !strcmp( "xz", exts ) || !strcmp( "XZ", exts ) ) ++ filter = xz_filter; + } + if( NULL != filter ){ + /* +- * zcat or bzcat ++ * zcat, bzcat, lzcat or xzcat + */ + if( NULL == (st->fp = (FILE *)tmpfile()) ) + perror( "temporary file" ), exit( -1 ); diff --git a/app-text/lv/lv-4.51-r3.ebuild b/app-text/lv/lv-4.51-r3.ebuild index ad9d48b78c38..d5c5de76eb5f 100644 --- a/app-text/lv/lv-4.51-r3.ebuild +++ b/app-text/lv/lv-4.51-r3.ebuild @@ -23,10 +23,10 @@ DEPEND="${RDEPEND} S="${WORKDIR}/${MY_P}" src_prepare() { - epatch "${FILESDIR}"/${P}-gentoo.patch - epatch "${FILESDIR}"/${P}-protos.patch - epatch "${FILESDIR}"/${P}-tinfo.patch - epatch "${FILESDIR}"/${P}-xz.diff + epatch "${FILESDIR}"/${PN}-gentoo.patch + epatch "${FILESDIR}"/${PN}-headers.patch + epatch "${FILESDIR}"/${PN}-tinfo.patch + epatch "${FILESDIR}"/${PN}-xz.patch cd "${S}"/src mv configure.{in,ac} diff --git a/app-text/lv/lv-4.51-r4.ebuild b/app-text/lv/lv-4.51-r4.ebuild index f85c10324f2b..e219f8f061c1 100644 --- a/app-text/lv/lv-4.51-r4.ebuild +++ b/app-text/lv/lv-4.51-r4.ebuild @@ -23,10 +23,10 @@ DEPEND="${RDEPEND} S="${WORKDIR}/${MY_P}" PATCHES=( - "${FILESDIR}"/${P}-gentoo.patch - "${FILESDIR}"/${P}-protos.patch - "${FILESDIR}"/${P}-tinfo.patch - "${FILESDIR}"/${P}-xz.diff + "${FILESDIR}"/${PN}-gentoo.patch + "${FILESDIR}"/${PN}-headers.patch + "${FILESDIR}"/${PN}-tinfo.patch + "${FILESDIR}"/${PN}-xz.patch ) DOCS=( README hello.sample ) HTML_DOCS=( index.html relnote.html hello.sample.gif ) -- cgit v1.2.3-65-gdbad