[gentoo-commits] repo/gentoo:master commit in: app-misc/getopt/, app-misc/getopt/files/

2019-06-17 Thread Fabian Groffen
commit: 6f08eef5b16ac1157305f07540fc59484a409d65
Author: Michael Mair-Keimberger  gmail  com>
AuthorDate: Sat May 18 16:40:40 2019 +
Commit: Fabian Groffen  gentoo  org>
CommitDate: Mon Jun 17 18:48:07 2019 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6f08eef5

app-misc/getopt: EAPI=7 bump

Closes: https://bugs.gentoo.org/686236
Signed-off-by: Michael Mair-Keimberger  gmail.com>
Signed-off-by: Fabian Groffen  gentoo.org>

 app-misc/getopt/files/getopt-1.1.4-irix.patch|  4 +-
 app-misc/getopt/files/getopt-1.1.5-libintl.patch |  4 +-
 app-misc/getopt/getopt-1.1.6-r1.ebuild   | 62 
 3 files changed, 66 insertions(+), 4 deletions(-)

diff --git a/app-misc/getopt/files/getopt-1.1.4-irix.patch 
b/app-misc/getopt/files/getopt-1.1.4-irix.patch
index 0c344a80131..1fd38c3b0a2 100644
--- a/app-misc/getopt/files/getopt-1.1.4-irix.patch
+++ b/app-misc/getopt/files/getopt-1.1.4-irix.patch
@@ -1,7 +1,7 @@
 http://bugs.gentoo.org/show_bug.cgi?id=211499
 
 gnu/getopt.c.dist
-+++ gnu/getopt.c
+--- a/gnu/getopt.c
 b/gnu/getopt.c
 @@ -69,12 +69,7 @@
  #include 
  #endif/* GNU C library.  */

diff --git a/app-misc/getopt/files/getopt-1.1.5-libintl.patch 
b/app-misc/getopt/files/getopt-1.1.5-libintl.patch
index b40367105ed..0b39b4ecbdc 100644
--- a/app-misc/getopt/files/getopt-1.1.5-libintl.patch
+++ b/app-misc/getopt/files/getopt-1.1.5-libintl.patch
@@ -1,5 +1,5 @@
 Makefile.orig  2012-12-28 11:40:09.524686698 +0100
-+++ Makefile   2012-12-28 11:41:20.646157275 +0100
+--- a/Makefile 2012-12-28 11:40:09.524686698 +0100
 b/Makefile 2012-12-28 11:41:20.646157275 +0100
 @@ -61,7 +61,7 @@
-$(RM) $(objects) $(binaries) 
  

diff --git a/app-misc/getopt/getopt-1.1.6-r1.ebuild 
b/app-misc/getopt/getopt-1.1.6-r1.ebuild
new file mode 100644
index 000..0acad8e5540
--- /dev/null
+++ b/app-misc/getopt/getopt-1.1.6-r1.ebuild
@@ -0,0 +1,62 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit toolchain-funcs eutils
+
+DESCRIPTION="getopt(1) replacement supporting GNU-style long options"
+HOMEPAGE="http://frodo.looijaard.name/project/getopt/";
+SRC_URI="http://frodo.looijaard.name/system/files/software/getopt/${P}.tar.gz";
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64-fbsd ~m68k-mint ~ppc-aix ~ppc-macos ~sparc-solaris 
~sparc64-solaris ~x64-cygwin ~x64-macos ~x64-solaris ~x86-fbsd ~x86-macos 
~x86-solaris"
+IUSE="nls"
+
+RDEPEND="nls? ( virtual/libintl )"
+DEPEND="${RDEPEND}
+   nls? ( sys-devel/gettext )"
+
+PATCHES=(
+   "${FILESDIR}"/${PN}-1.1.5-libintl.patch
+   "${FILESDIR}"/${PN}-1.1.5-setlocale.patch
+   "${FILESDIR}"/${PN}-1.1.6-longrename.patch
+   "${FILESDIR}"/${PN}-1.1.4-irix.patch
+)
+
+src_compile() {
+   local nogettext="1"
+   local libintl=""
+   local libcgetopt=1
+
+   if use nls; then
+   nogettext=0
+   has_version sys-libs/glibc || libintl="-lintl"
+   fi
+
+   [[ ${CHOST} == *-aix* ]] && libcgetopt=0
+   [[ ${CHOST} == *-irix* ]] && libcgetopt=0
+   [[ ${CHOST} == *-interix* ]] && libcgetopt=0
+
+   emake CC="$(tc-getCC)" prefix="${EPREFIX}/usr" \
+   LIBCGETOPT=${libcgetopt} \
+   WITHOUT_GETTEXT=${nogettext} LIBINTL=${libintl} \
+   CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}"
+}
+
+src_install() {
+   use nls && emake prefix="${EPREFIX}/usr" DESTDIR="${D}" install_po
+
+   newbin getopt getopt-long
+
+   # at least on interix, the system getopt is ... broken...
+   # util-linux, which would provide the getopt binary, does not build &
+   # install on interix/prefix, so, this has to provide it.
+   [[ ${CHOST} == *-interix* || ${CHOST} == *-mint* ]] && \
+   dosym getopt-long /usr/bin/getopt
+
+   newman getopt.1 getopt-long.1
+
+   dodoc getopt-*sh
+}



[gentoo-commits] repo/gentoo:master commit in: app-misc/getopt/, app-misc/getopt/files/

2015-08-27 Thread Manuel Rüger
commit: 123285736eada0ef5cb1cdc7b45edaa7787b7829
Author: Manuel Rüger  gentoo  org>
AuthorDate: Fri Aug 28 03:35:15 2015 +
Commit: Manuel Rüger  gentoo  org>
CommitDate: Fri Aug 28 03:35:15 2015 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=12328573

app-misc/getopt: Remove old

Package-Manager: portage-2.2.20.1

 app-misc/getopt/Manifest   |   2 -
 app-misc/getopt/files/getopt-1.1.4-libintl.patch   |  34 --
 .../getopt/files/getopt-1.1.4-longrename.patch | 118 -
 .../getopt/files/getopt-1.1.5-longrename.patch |  79 --
 app-misc/getopt/getopt-1.1.4.ebuild|  64 ---
 app-misc/getopt/getopt-1.1.5.ebuild|  65 
 6 files changed, 362 deletions(-)

diff --git a/app-misc/getopt/Manifest b/app-misc/getopt/Manifest
index b7d7a89..a3c5f80 100644
--- a/app-misc/getopt/Manifest
+++ b/app-misc/getopt/Manifest
@@ -1,3 +1 @@
-DIST getopt-1.1.4.tar.gz 37163 SHA256 
41083d9993c26792851e79b81a0991996a3f61e14998fdd607615cc3bf933bab SHA512 
9ec9b5ca50a02b6ae772b133408e61fb9fcb5840c00f23d1c836a9c7ee86778211dcb1ecf5cdcaf9e2488b2db0671e29bc8be55f1a7ca4f1d48cc3921dfe04ad
 WHIRLPOOL 
64e4942064930303ecc8cd6ea22f93ccd0c34415815f1e4fc43d2786b1e3bd511fac6d0aa6ef470b0a026a7776c4e0b345b1beada0c972203808232d0c331727
-DIST getopt-1.1.5.tar.gz 51794 SHA256 
11893276b94b1629606ab75772143918a5713259950fbf4216288e246f19fbb6 SHA512 
43597a1a8dd1dc188b6b4f0a8f8d438456013276aa1c719889e242ba2b526dccbca2fccd3d82d1541f4e0920fd277c101a436ed0c208124227481f792cb1cf75
 WHIRLPOOL 
c5de1797b0c294a404ef8e801d86677d0b84fd6974e5d5ad8d234ae28db5446d0b13766362ecac459b3f8ce07d56282a3f0274b460d5d95118000762d9374815
 DIST getopt-1.1.6.tar.gz 58926 SHA256 
d0bf1dc642a993e7388a1cddfb9409bed375c21d5278056ccca3a0acd09dc5fe SHA512 
aa5476e729f33ddd3f32f38b2565da319fdfe034f11549218d5d9953e70dad764e0d9a82bb10efe4043c86ae87f944619b8a2f29a197f592bd855699961d8e10
 WHIRLPOOL 
0fa96415fa5d9b001313b1491a0f260922dbb52ac72d6242e6ff332ac802e3d6cac2401c8e8a8f9cc09376d3c51f4b1cc3bd0f976dc857cd72c1ffc7b1d770da

diff --git a/app-misc/getopt/files/getopt-1.1.4-libintl.patch 
b/app-misc/getopt/files/getopt-1.1.4-libintl.patch
deleted file mode 100644
index 232e487..000
--- a/app-misc/getopt/files/getopt-1.1.4-libintl.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-Index: getopt-1.1.4/Makefile
-===
 getopt-1.1.4.orig/Makefile
-+++ getopt-1.1.4/Makefile
-@@ -33,7 +33,10 @@ MSGFMT=msgfmt
- LANGUAGES = cs de es fr it ja nl pt_BR
- MOFILES:=$(patsubst %,po/%.mo,$(LANGUAGES))
- 
--CPPFLAGS=-DLIBCGETOPT=$(LIBCGETOPT) -DWITH_GETTEXT=$(WITH_GETTEXT) 
-DLOCALEDIR=\"$(localedir)\" -DNOT_UTIL_LINUX
-+CPPFLAGS=-DLIBCGETOPT=$(LIBCGETOPT) -DLOCALEDIR=\"$(localedir)\" 
-DNOT_UTIL_LINUX
-+ifeq ($(WITHOUT_GETTEXT),1)
-+CPPFLAGS+=-DWITHOUT_GETTEXT
-+endif
- ifeq ($(LIBCGETOPT),0)
- CPPFLAGS+=-I./gnu 
- endif
-@@ -62,7 +65,7 @@ clean: clean_po
-   -$(RM) $(objects) $(binaries) 
- 
- getopt: $(objects)
--  $(CC) $(LDFLAGS) -o $@ $(objects)
-+  $(CC) $(LDFLAGS) -o $@ $(objects) $(LIBINTL)
- 
- install: getopt install_po
-   $(INSTALL) -m 755 -d $(DESTDIR)$(bindir) $(DESTDIR)$(man1dir)
-@@ -75,7 +78,7 @@ install_doc:
- getopt-test.bash getopt-test.tcsh \
-  $(DESTDIR)$(getoptdir)
- 
--ifeq ($(WITH_GETTEXT),1)
-+ifeq ($(WITHOUT_GETTEXT),0)
- all_po: $(MOFILES)
- install_po: all_po
-   $(INSTALL) -m 755 -d $(DESTDIR)$(localedir)

diff --git a/app-misc/getopt/files/getopt-1.1.4-longrename.patch 
b/app-misc/getopt/files/getopt-1.1.4-longrename.patch
deleted file mode 100644
index dc3ecb0..000
--- a/app-misc/getopt/files/getopt-1.1.4-longrename.patch
+++ /dev/null
@@ -1,118 +0,0 @@
-Index: getopt-1.1.4/getopt.c
-===
 getopt-1.1.4.orig/getopt.c
-+++ getopt-1.1.4/getopt.c
-@@ -88,7 +88,7 @@ void *our_malloc(size_t size)
- {
-   void *ret=malloc(size);
-   if (! ret) {
--  fprintf(stderr,_("%s: Out of memory!\n"),"getopt");
-+  fprintf(stderr,_("%s: Out of memory!\n"),"getopt-long");
-   exit(3);
-   }
-   return(ret);
-@@ -98,7 +98,7 @@ void *our_realloc(void *ptr, size_t size
- {
-   void *ret=realloc(ptr,size);
-   if (! ret && size) {
--  fprintf(stderr,_("%s: Out of memory!\n"),"getopt");
-+  fprintf(stderr,_("%s: Out of memory!\n"),"getopt-long");
-   exit(3);
-   }
-   return(ret);
-@@ -231,8 +231,8 @@ int generate_output(char * argv[],int ar
- void parse_error(const char *message)
- {
-   if (message)
--  fprintf(stderr,"getopt: %s\n",message);
--  fputs(_("Try `getopt --help' for more information.\n"),stderr);
-+  fprintf(stderr,"getopt-long: %s\n",message);
-+  fputs(_("Try `getopt-long --help' for more information.\n"