summaryrefslogtreecommitdiff
path: root/app-admin
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2019-06-22 11:40:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2019-06-22 11:40:06 +0100
commit7a86906b67693cc65671d3e1476835d3a7e13092 (patch)
tree9de1b9e2cf77833183d4e5ffab2e94d0403ef725 /app-admin
parentd56d144655e3785864da43c9acb6c228ef9360ae (diff)
gentoo resync : 22.06.2019
Diffstat (limited to 'app-admin')
-rw-r--r--app-admin/chrpath/chrpath-0.16.ebuild41
-rw-r--r--app-admin/chrpath/files/chrpath-0.16-multilib.patch155
-rw-r--r--app-admin/chrpath/files/chrpath-0.16-solaris.patch19
-rw-r--r--app-admin/chrpath/files/chrpath-0.16-testsuite-1.patch19
-rw-r--r--app-admin/mongo-tools/mongo-tools-3.6.13.ebuild71
5 files changed, 305 insertions, 0 deletions
diff --git a/app-admin/chrpath/chrpath-0.16.ebuild b/app-admin/chrpath/chrpath-0.16.ebuild
new file mode 100644
index 000000000000..323e49a75d97
--- /dev/null
+++ b/app-admin/chrpath/chrpath-0.16.ebuild
@@ -0,0 +1,41 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools
+
+DESCRIPTION="Chrpath can modify the rpath and runpath of ELF executables"
+HOMEPAGE="https://directory.fsf.org/wiki/Chrpath"
+SRC_URI="https://alioth-archive.debian.org/releases/${PN}/${PN}/${PV}/${P}.tar.gz"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~mips ~ppc ~ppc64 ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+IUSE="static-libs"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-multilib.patch
+ "${FILESDIR}"/${P}-testsuite-1.patch
+ "${FILESDIR}"/${P}-solaris.patch
+)
+
+src_prepare() {
+ default
+ # disable installing redundant docs in the wrong dir
+ sed -i -e '/doc_DATA/d' Makefile.am || die
+ # fix for automake-1.13, #467538
+ sed -i -e 's/AM_CONFIG_HEADER/AC_CONFIG_HEADERS/' configure.ac || die
+ eautoreconf
+}
+
+src_configure() {
+ econf $(use_enable static-libs static)
+}
+
+src_install() {
+ default
+ if ! use static-libs; then
+ find "${D}" -name "*.la" -delete || die
+ fi
+}
diff --git a/app-admin/chrpath/files/chrpath-0.16-multilib.patch b/app-admin/chrpath/files/chrpath-0.16-multilib.patch
new file mode 100644
index 000000000000..075266d5cd95
--- /dev/null
+++ b/app-admin/chrpath/files/chrpath-0.16-multilib.patch
@@ -0,0 +1,155 @@
+--- chrpath-0.16/Makefile.am 2014-01-12 08:52:21.000000000 +0100
++++ chrpath-0.16-ng/Makefile.am 2019-05-19 11:23:48.352936406 +0200
+@@ -12,11 +12,18 @@
+ fakeroot debian/rules binary
+
+ chrpath_SOURCES = \
+- chrpath.c \
+- killrpath.c \
+ main.c \
+- elf.c \
+ protos.h
++
++chrpath_LDADD = $(LDLIBS)
++
++lib_LTLIBRARIES = libchrpath32.la libchrpath64.la
++libchrpath32_la_SOURCES = chrpath.c killrpath.c elf.c protos.h
++libchrpath32_la_CFLAGS = -DSIZEOF_VOID_P=4
++libchrpath32_la_LDFLAGS = -avoid-version
++libchrpath64_la_SOURCES = chrpath.c killrpath.c elf.c protos.h
++libchrpath64_la_CFLAGS = -DSIZEOF_VOID_P=8
++libchrpath64_la_LDFLAGS = -avoid-version
+
+ EXTRA_DIST = $(man_MANS)
+
+--- chrpath-0.16/configure.ac 2014-01-12 09:01:52.000000000 +0100
++++ chrpath-0.16-ng/configure.ac 2019-05-19 11:25:07.158665075 +0200
+@@ -16,6 +16,7 @@
+ dnl Checks for programs.
+ AC_PROG_CC
+ AC_PROG_INSTALL
++AC_PROG_LIBTOOL
+
+ dnl Checks for libraries.
+
+@@ -26,11 +27,19 @@
+ dnl Checks for typedefs, structures, and compiler characteristics.
+ AC_C_CONST
+ AC_C_BIGENDIAN
+-AC_CHECK_SIZEOF(void *)
+
+ dnl Checks for library functions.
+ AC_CHECK_FUNCS(getopt_long)
+
++dnl See if we need -ldl on this platform for dlopen
++LDLIBS=
++save_LIBS="$LIBS"
++LIBS=
++AC_SEARCH_LIBS([dlopen], [dl])
++LDLIBS=${LIBS}
++LIBS="${save_LIBS}"
++AC_SUBST([LDLIBS])
++
+ if eval "test x$GCC = xyes"; then
+ for flag in \
+ -W \
+--- chrpath-0.16/main.c 2014-01-14 10:15:59.000000000 +0100
++++ chrpath-0.16-ng/main.c 2019-05-19 11:29:34.648390032 +0200
+@@ -12,13 +12,19 @@
+ # include "config.h"
+ #endif
+
++#include <dlfcn.h>
++#include <elf.h>
++#include <fcntl.h>
+ #include <stdio.h>
+ #include <stdlib.h>
++#include <string.h>
+ #include <unistd.h>
+ #ifdef HAVE_GETOPT_H
+ #include <getopt.h>
+ #endif
+-#include "protos.h"
++
++typedef int (*killrpath_t)(const char *filename);
++typedef int (*chrpath_t)(const char *filename, const char *newpath, int convert);
+
+ #ifdef HAVE_GETOPT_LONG
+ # define GETOPT_LONG getopt_long
+@@ -63,6 +69,30 @@
+ printf("\n");
+ }
+
++static unsigned
++elf_class(const char *filename)
++{
++ Elf32_Ehdr ehdr;
++ int fd;
++
++ fd = open(filename, O_RDONLY);
++ if (fd == -1)
++ return 0;
++ if (read(fd, &ehdr, sizeof(ehdr)) != sizeof(ehdr))
++ {
++ close(fd);
++ return 0;
++ }
++ close(fd);
++ if ((memcmp(ehdr.e_ident, ELFMAG, SELFMAG) != 0)
++ || (ehdr.e_ident[EI_VERSION] != EV_CURRENT))
++ {
++ fprintf(stderr, "`%s' probably isn't an ELF file.\n", filename);
++ return 0;
++ }
++ return ehdr.e_ident[EI_CLASS];
++}
++
+ int
+ main(int argc, char * const argv[])
+ {
+@@ -75,6 +105,10 @@
+ #ifdef HAVE_GETOPT_LONG
+ int option_index = 0;
+ #endif /* HAVE_GETOPT_LONG */
++
++ void* dll[2];
++ killrpath_t killrpath[2];
++ chrpath_t chrpath[2];
+
+ if (argc < 2)
+ {
+@@ -118,15 +152,32 @@
+ break;
+ }
+ } while (-1 != opt);
++
++ dll[0] = dlopen("libchrpath32.so", RTLD_LAZY);
++ killrpath[0] = (killrpath_t)dlsym(dll[0], "killrpath");
++ chrpath[0] = (chrpath_t)dlsym(dll[0], "chrpath");
++
++ dll[1] = dlopen("libchrpath64.so", RTLD_LAZY);
++ killrpath[1] = (killrpath_t)dlsym(dll[1], "killrpath");
++ chrpath[1] = (chrpath_t)dlsym(dll[1], "chrpath");
+
+ while (optind < argc && (!retval || keep_going))
+ {
++ const char* program = argv[optind++];
++ unsigned eclass = elf_class(program);
++ if (!eclass)
++ {
++ retval = 1;
++ continue;
++ }
+ if (remove)
+- retval |= killrpath(argv[optind++]);
++ retval |= killrpath[eclass - ELFCLASS32](program);
+ else
+ /* list by default, replace if path is set */
+- retval |= chrpath(argv[optind++], newpath, convert);
++ retval |= chrpath[eclass - ELFCLASS32](program, newpath, convert);
+ }
+
++ dlclose(dll[0]);
++ dlclose(dll[1]);
+ return retval;
+ }
diff --git a/app-admin/chrpath/files/chrpath-0.16-solaris.patch b/app-admin/chrpath/files/chrpath-0.16-solaris.patch
new file mode 100644
index 000000000000..5e1dd1957e8f
--- /dev/null
+++ b/app-admin/chrpath/files/chrpath-0.16-solaris.patch
@@ -0,0 +1,19 @@
+protos: add bswap macros for Solaris
+
+--- a/protos.h
++++ b/protos.h
+@@ -1,7 +1,14 @@
+ #ifndef PROTOS_H
+ #define PROTOS_H
+
++#if defined(__sun)
++#include <sys/byteorder.h>
++#define bswap_16(x) BSWAP_16(x)
++#define bswap_32(x) BSWAP_32(x)
++#define bswap_64(x) BSWAP_64(x)
++#else
+ #include <byteswap.h>
++#endif
+ #include <elf.h>
+ #include "config.h"
+
diff --git a/app-admin/chrpath/files/chrpath-0.16-testsuite-1.patch b/app-admin/chrpath/files/chrpath-0.16-testsuite-1.patch
new file mode 100644
index 000000000000..04b682dc3b33
--- /dev/null
+++ b/app-admin/chrpath/files/chrpath-0.16-testsuite-1.patch
@@ -0,0 +1,19 @@
+Submitted By: Mario Fetka (geos_one) (mario dot fetka at gmail dot com)
+Date: 2010-04-04
+Initial Package Version: 0.16
+Origin: me
+Upstream Status: unknown
+Description: make the testsuite run with the new mltilib design
+
+diff -Naur a/chrpath-0.16/testsuite/runtest.sh b/chrpath-0.16/testsuite/runtest.sh
+--- a/testsuite/runtest.sh 2010-04-04 09:02:21.859114159 +0000
++++ b/testsuite/runtest.sh 2010-04-04 09:42:08.762112560 +0000
+@@ -2,6 +2,8 @@
+
+ set -x
+
++export LD_LIBRARY_PATH=$PWD/../.libs:$LD_LIBRARY_PATH
++
+ CHRPATH=../chrpath
+
+ retval=0
diff --git a/app-admin/mongo-tools/mongo-tools-3.6.13.ebuild b/app-admin/mongo-tools/mongo-tools-3.6.13.ebuild
new file mode 100644
index 000000000000..092d770686fb
--- /dev/null
+++ b/app-admin/mongo-tools/mongo-tools-3.6.13.ebuild
@@ -0,0 +1,71 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+MY_PV=${PV/_rc/-rc}
+MY_P=${PN}-r${MY_PV}
+
+DESCRIPTION="A high-performance, open source, schema-free document-oriented database"
+HOMEPAGE="https://www.mongodb.com"
+SRC_URI="https://github.com/mongodb/mongo-tools/archive/r${MY_PV}.tar.gz -> mongo-tools-${MY_PV}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="sasl ssl"
+
+DEPEND="dev-lang/go:=
+ net-libs/libpcap
+ sasl? ( dev-libs/cyrus-sasl )
+ ssl? ( dev-libs/openssl:0= )"
+
+# Do not complain about CFLAGS etc since go projects do not use them.
+QA_FLAGS_IGNORED='.*'
+
+EGO_PN="github.com/mongodb/mongo-tools"
+S="${WORKDIR}/src/${EGO_PN}"
+
+src_unpack() {
+ mkdir -p "${S%/*}" || die
+ default
+ mv ${MY_P} "${S}" || die
+}
+
+src_prepare() {
+ default
+
+ # allow building with go 1.12 #678924
+ sed -i 's/_Ctype_struct_/C.struct_/' vendor/github.com/google/gopacket/pcap/pcap.go || die
+}
+
+src_compile() {
+ local myconf=()
+
+ if use sasl; then
+ myconf+=(sasl)
+ fi
+
+ if use ssl; then
+ myconf+=(ssl)
+ fi
+
+ # build pie to avoid text relocations wrt #582854
+ local buildmode="pie"
+
+ # skip on ppc64 wrt #610984
+ if use ppc64; then
+ buildmode="default"
+ fi
+
+ mkdir -p bin || die
+ for i in bsondump mongostat mongofiles mongoexport mongoimport mongorestore mongodump mongotop mongoreplay; do
+ echo "Building $i"
+ GOROOT="$(go env GOROOT)" GOPATH="${WORKDIR}" go build -buildmode="${buildmode}" -o "bin/$i" \
+ -ldflags "-X ${EGO_PN}/common/options.VersionStr=${PV}" --tags "${myconf[*]}" "$i/main/$i.go" || die
+ done
+}
+
+src_install() {
+ dobin bin/*
+}