summaryrefslogtreecommitdiff
path: root/dev-libs/redland-bindings
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-04-25 11:37:10 +0100
committerV3n3RiX <venerix@redcorelinux.org>2020-04-25 11:37:10 +0100
commit38423c67c8a23f6a1bc42038193182e2da3116eb (patch)
tree04e2cf4bd43601b77daa79fe654e409187093c5e /dev-libs/redland-bindings
parent623ee73d661e5ed8475cb264511f683407d87365 (diff)
gentoo resync : 25.04.2020
Diffstat (limited to 'dev-libs/redland-bindings')
-rw-r--r--dev-libs/redland-bindings/Manifest5
-rw-r--r--dev-libs/redland-bindings/files/redland-bindings-1.0.17.1-add-PHP7-support.patch64
-rw-r--r--dev-libs/redland-bindings/files/redland-bindings-1.0.17.1-php-config-r1.patch77
-rw-r--r--dev-libs/redland-bindings/redland-bindings-1.0.14.1-r2.ebuild2
-rw-r--r--dev-libs/redland-bindings/redland-bindings-1.0.17.1-r1.ebuild126
5 files changed, 272 insertions, 2 deletions
diff --git a/dev-libs/redland-bindings/Manifest b/dev-libs/redland-bindings/Manifest
index ecfa86c81e4e..affbc78ee52a 100644
--- a/dev-libs/redland-bindings/Manifest
+++ b/dev-libs/redland-bindings/Manifest
@@ -1,7 +1,10 @@
+AUX redland-bindings-1.0.17.1-add-PHP7-support.patch 2359 BLAKE2B 04cc1122a8a22627ea49bd46b7600c9d289847a97f428abdc036c8647d23a5e70848d97db678c38872c841183dd871a00252c7949ca0c39920c15514d96e6eb1 SHA512 c18d8a4dbad433d96d396e1065c60fe85c1c0114adedb4f6151d1aeb65a3fedb5a2b94eb2e2a1e1b272c79e65ddd2d9128ee098d133e66452ae7fead62b73892
AUX redland-bindings-1.0.17.1-bool.patch 502 BLAKE2B 09ab5d8b5b3cf2edd046830bbc88a275c2df804dbb9e09a411bada838afd7f30c592dc48f02995752822a5d738af35c208f124c9d9d008cbff3395bbcfd7b404 SHA512 158e06e58ad66ca88ac8eb4646df0628f423de8d22638e78a737be3ea12fd123fd3bcf63b75478ff7f82ec3b444773a2e8d467fd737b8de0ae9143ef79e60a65
+AUX redland-bindings-1.0.17.1-php-config-r1.patch 2249 BLAKE2B 83d9a65d6db9411531b827d25aaaec721b6756c4a5503179a477fa3d452fff4deaa1fdcaa78c66f5cef0b4cb0d36e06a89050e520a2e0fd36694121eb8a71669 SHA512 406e0d0d97c7c181a16c2a72ec291582ada1c1dbec1cdb53ca62ec73f954a1116462b97f3cf85ada4adfc4ebff35081ac4ce0ce9e2b7155e61402dbb64f57c20
AUX redland-bindings-1.0.17.1-php-config.patch 1184 BLAKE2B f22aac3f4753f11c1473c2aef3291a311aa4313679e076a185b21e19735438ef9a3dd8cf4ddc4dab0cd691a17502a7a4d907935889755c2626720111246e532c SHA512 e9c9bdf5ed61b24afcb6bcf912be545525d5bdb0c77c304bc146c5fb645ddae2e7e90c6f71ae79d9624eaa2b0d498fddf149fd710524969b66c0f5c3ddabda65
DIST redland-bindings-1.0.14.1.tar.gz 792557 BLAKE2B fac20e9e2fbf9a4ea7299ef0b4a656ea3e5f1cbf436cd31c80e81be40dc95e074e557925b32ecf24091ce3cfe882d681318ae8402e14baf1e0966ec8a0a892ed SHA512 5e037a96f857c95bf4b9277d98c7de1fa41c4ba7e49e199eeb516458343587c796a10e857679c889406b22bca8617828a2bccd07c31b73f2366cdea39cefad15
DIST redland-bindings-1.0.17.1.tar.gz 933290 BLAKE2B f58524c30958200af1fb3ec0f63b8aa9f3fd2120297321299cdd225ff9eb331f385c4418ed25987b955857e5046b5c6f0589210b807aae0dc6abe0b758d48cfc SHA512 c105d1232555d226d98efdc1e4edc1b6c953fdd004804e40926452b8f91d30159319a50af68fc3cfe242cf180d85383ef3ff925cc65ed5d0652096cc51f4d7c0
-EBUILD redland-bindings-1.0.14.1-r2.ebuild 1333 BLAKE2B bb574159c67e7a4151cfdce1e970119cd50f8b87187b4ad4765a85f3ab25b72d1940da9da142d48c2b3a4bdc80e3bdfe0b2320d50ad9e476593edccfd4e5a921 SHA512 63592c3c641c4780c68d44989a59310ba1ac994830746e949627a682a32a7eeec83740da8d3c765972b41eb8bbd6c34268dd219d9d7f934870f6e08cf3a9a2a5
+EBUILD redland-bindings-1.0.14.1-r2.ebuild 1334 BLAKE2B 2a2da7b97e0061fcb33b6ca78a7f1adff1acdb0860b6bdf9787c8fdfc7d1006cd74beebd8bffe2a6d101deebcc21d40523ed5677a1f63cbe640d4bef9ad3e914 SHA512 47bf9ede3040c06353d5e1bef9d53ea06579270ae39e84882fce89e1e5a8ebe4708736a34096f872dda0bb766e687c581402bb9a5d2a0226ea35334d3e732f58
+EBUILD redland-bindings-1.0.17.1-r1.ebuild 2911 BLAKE2B d227d239347cacde4131411fc643b4c0326476c9713ed1bafe4d6065fda6fc1c955d10b3845cc86f7c293b08f11a13dee0439b2affc831a9f69625d5451386fc SHA512 a9cfe1c713dcba1cff830be8ad3e6d349d40d51cd84e946d9ac290d4c6d81ac24d8ad31a0ef1e7c976fadfe30a4f0fd95bd6e14eac79b19cd0ca7cb29b2f51df
EBUILD redland-bindings-1.0.17.1.ebuild 2654 BLAKE2B e2d9817c25e7830523064b5306b8cc286f4e78a417657cb01bffe754b2c61fc8e637c98ff2d345a3e9d570cdd6cf6116c2e7808261b9248237f63c15f55bad70 SHA512 f3d22574c9d826766c51b9964ad71b0a77d5fc0586061953de19d9cada5b81c270772a31a1db2cf8d7a08538844157cbd3cff60acc90852810dee654b3c70011
MISC metadata.xml 249 BLAKE2B f7f8f071ecba933f3d39b0b60983281d59299b92de9375a60ab4109d7202800cb790bce0c426227f04b3e2624b1adb20876145741355abc6a4938b8b9698d144 SHA512 9a100fb26586365eda99724330a03a512f4d0be18d39c3a195ba02c2fc841edeee99d22512acf5a058a3b978d3a74f4d963a5aff9aa343b6cb4086cdfefe6343
diff --git a/dev-libs/redland-bindings/files/redland-bindings-1.0.17.1-add-PHP7-support.patch b/dev-libs/redland-bindings/files/redland-bindings-1.0.17.1-add-PHP7-support.patch
new file mode 100644
index 000000000000..af8e3d560d7b
--- /dev/null
+++ b/dev-libs/redland-bindings/files/redland-bindings-1.0.17.1-add-PHP7-support.patch
@@ -0,0 +1,64 @@
+Origin: Based on patch from Petr Písař <ppisar@redhat.com>
+Date: Tue, 13 Jun 2017 15:29:15 +0200
+
+--- a/php/redland-post.i
++++ b/php/redland-post.i
+@@ -132,8 +132,11 @@ librdf_php_world_init(void)
+ exception_ce = zend_exception_get_default();
+ INIT_CLASS_ENTRY(ee_ce, "RedlandException", NULL);
+ redland_exception_ptr = zend_register_internal_class_ex(&ee_ce,
+- exception_ce,
+- NULL TSRMLS_CC);
++ exception_ce
++#if PHP_MAJOR_VERSION < 7
++ ,NULL TSRMLS_CC
++#endif
++ );
+ #endif
+
+ memset(&librdf_php_locator, '\0', sizeof(raptor_locator));
+--- a/php/redland-typemap.i
++++ b/php/redland-typemap.i
+@@ -1,17 +1,17 @@
+-%typemap(in) librdf_uri* %{
+- if(SWIG_ConvertPtr(*$input, (void **) &$1, SWIGTYPE_p_librdf_uri_s, 0) < 0) {
++%typemap(in) librdf_uri %{
++ if(SWIG_ConvertPtr($input, (void **) &$1, SWIGTYPE_p_librdf_uri_s, 0) < 0) {
+ /* Allow NULL from php for librdf_uri* */
+- if ((*$input)->type==IS_NULL)
++ if ($input->type==IS_NULL)
+ $1=NULL;
+ else
+ SWIG_PHP_Error(E_ERROR, "Type error in argument $argnum of $symname. Expected $1_descriptor");
+ }
+ %}
+
+-%typemap(in) librdf_node* %{
+- if(SWIG_ConvertPtr(*$input, (void **) &$1, SWIGTYPE_p_librdf_node_s, 0) < 0) {
++%typemap(in) librdf_node %{
++ if(SWIG_ConvertPtr($input, (void **) &$1, SWIGTYPE_p_librdf_node_s, 0) < 0) {
+ /* Allow NULL from php for librdf_node* */
+- if ((*$input)->type==IS_NULL)
++ if ($input->type==IS_NULL)
+ $1=NULL;
+ else
+ SWIG_PHP_Error(E_ERROR, "Type error in argument $argnum of $symname. Expected $1_descriptor");
+
+--- a/php/test.php
++++ b/php/test.php
+@@ -26,11 +26,9 @@
+ /* ------------------------------------------------------------------------ */
+
+ print "Testing Redland...\n";
+-$dlls = array("redland.so", "php_redland.dll", "redland.dylib", "redland.bundle");
+-foreach ($dlls as $dll) {
+- if(file_exists($dll)) {
+- dl($dll);
+- }
++if (extension_loaded('redland') !== true) {
++ print "Redland extension not loaded. Cannot run tests!" . PHP_EOL;
++ exit(1);
+ }
+
+ $world=librdf_php_get_world();
+
diff --git a/dev-libs/redland-bindings/files/redland-bindings-1.0.17.1-php-config-r1.patch b/dev-libs/redland-bindings/files/redland-bindings-1.0.17.1-php-config-r1.patch
new file mode 100644
index 000000000000..8f8dd409c0d3
--- /dev/null
+++ b/dev-libs/redland-bindings/files/redland-bindings-1.0.17.1-php-config-r1.patch
@@ -0,0 +1,77 @@
+--- a/configure.ac
++++ b/configure.ac
+@@ -58,7 +58,6 @@ AC_CHECK_PROGS(TAR, gnutar gtar tar)
+ AC_CHECK_PROGS(LUA, lua)
+ AC_CHECK_PROGS(PYTHON, python)
+ AC_CHECK_PROGS(PERL, perl)
+-AC_CHECK_PROGS(PHP, php)
+ AC_CHECK_PROGS(RUBY, ruby)
+ AC_CHECK_PROGS(SWIG, swig)
+ # Gnome
+@@ -153,15 +152,28 @@ if test "X$LUA_VERSION" != X; then
+ fi
+ fi
+
++dnl Find php-config script.
++AC_ARG_WITH([php-config],
++ [AS_HELP_STRING([--with-php-config=PATH], [Path to php-config [php-config]])],
++ [with_php_config=${withval}],
++ [with_php_config=php-config])
++
++if test "${with_php_config}" = "php-config"; then
++ AC_CHECK_PROG(PHP_CONFIG, php-config, php-config)
++elif test -x "${with_php_config}"; then
++ PHP_CONFIG=${with_php_config}
++ AC_SUBST(PHP_CONFIG)
++ AC_MSG_NOTICE([found ${PHP_CONFIG}])
++fi
+
+-AC_CHECK_PROG(PHP_CONFIG, php-config, php-config)
+ if test "X$PHP_CONFIG" != X ; then
++ PHP_VERSION=`${PHP_CONFIG} --version`
++ PHP_INCLUDES=`${PHP_CONFIG} --includes`
++ PHP_EXTENSION_DIR=`${PHP_CONFIG} --extension-dir`
+
+- PHP_VERSION=`$PHP_CONFIG --version`
+- PHP_INCLUDES=`$PHP_CONFIG --includes`
+- PHP_EXTENSION_DIR=`$PHP_CONFIG --extension-dir`
+-
+- if test $PHP_VERSION '>' 5.0.0; then
++ if test $PHP_VERSION '>' 7; then
++ PHP_SWIG="-php7"
++ elif test $PHP_VERSION '>' 5.0.0; then
+ PHP_SWIG="-php5"
+ else
+ PHP_SWIG="-php4"
+@@ -200,6 +212,8 @@ if test "X$PHP_CONFIG" != X ; then
+ AC_MSG_RESULT(compile '$PHP_CFLAGS' link '$PHP_LDFLAGS' suffix $PHP_SO_SUFFIX)
+
+ else
++ AC_MSG_WARN([php-config not found])
++
+ # This allows 'make clean' in the php directory to work when
+ # php isn't available
+ PHP=:
+@@ -445,13 +459,17 @@ if test "X$with_php" != Xno ; then
+ with_php=yes
+ fi
+
+-PHP_VERSION=`php-config --version 2>/dev/null`
+-if test "X$PHP_VERSION" != X; then
+- languages_available="$languages_available php($PHP_VERSION)"
+- if test $with_php = yes; then
+- languages="$languages php"
++if test "X${PHP_VERSION}" != "X"; then
++ languages_available="$languages_available php(${PHP_VERSION})"
++fi
++
++if test ${with_php} = yes; then
++ if test "X${PHP_VERSION}" = "X"; then
++ AC_MSG_ERROR([Failed to detect PHP version])
+ fi
++ languages="$languages php"
+ fi
++
+ AC_MSG_RESULT($with_php)
+ AC_SUBST(PHP_VERSION)
+
diff --git a/dev-libs/redland-bindings/redland-bindings-1.0.14.1-r2.ebuild b/dev-libs/redland-bindings/redland-bindings-1.0.14.1-r2.ebuild
index 863f1025123d..16af4f5f980b 100644
--- a/dev-libs/redland-bindings/redland-bindings-1.0.14.1-r2.ebuild
+++ b/dev-libs/redland-bindings/redland-bindings-1.0.14.1-r2.ebuild
@@ -13,7 +13,7 @@ SRC_URI="http://download.librdf.org/source/${P}.tar.gz"
LICENSE="Apache-2.0 GPL-2 LGPL-2.1"
SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ppc ppc64 sparc x86 ~x86-linux ~ppc-macos"
+KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ppc ppc64 sparc x86 ~x86-linux ~ppc-macos"
IUSE="lua perl python php ruby"
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
diff --git a/dev-libs/redland-bindings/redland-bindings-1.0.17.1-r1.ebuild b/dev-libs/redland-bindings/redland-bindings-1.0.17.1-r1.ebuild
new file mode 100644
index 000000000000..522be190cd48
--- /dev/null
+++ b/dev-libs/redland-bindings/redland-bindings-1.0.17.1-r1.ebuild
@@ -0,0 +1,126 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python2_7 python3_6 python3_7 python3_8 )
+
+USE_PHP="php7-2 php7-3 php7-4"
+PHP_EXT_ECONF_ARGS="--with-php=yes --without-lua --without-perl --without-python --without-ruby"
+PHP_EXT_NAME="redland"
+PHP_EXT_OPTIONAL_USE="php"
+PHP_EXT_SKIP_PATCHES="yes"
+PHP_EXT_SKIP_PHPIZE="yes"
+
+inherit php-ext-source-r3 python-single-r1 autotools
+
+DESCRIPTION="Language bindings for Redland"
+HOMEPAGE="http://librdf.org/bindings/"
+SRC_URI="http://download.librdf.org/source/${P}.tar.gz"
+
+LICENSE="Apache-2.0 GPL-2 LGPL-2.1"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-linux ~ppc-macos"
+IUSE="lua perl python php ruby"
+REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
+
+BDEPEND="sys-apps/sed
+ virtual/pkgconfig"
+
+RDEPEND=">=dev-libs/redland-1.0.14
+ lua? ( >=dev-lang/lua-5.1 )
+ perl? ( dev-lang/perl:= )
+ python? ( ${PYTHON_DEPS} )
+ ruby? ( dev-lang/ruby dev-ruby/log4r )
+ php? (
+ php_targets_php7-2? ( dev-lang/php:7.2[-threads] )
+ php_targets_php7-3? ( dev-lang/php:7.3[-threads] )
+ php_targets_php7-4? ( dev-lang/php:7.4[-threads] )
+ )"
+
+DEPEND="${RDEPEND}
+ >=dev-lang/swig-2"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-bool.patch
+ "${FILESDIR}"/${PN}-1.0.17.1-php-config-r1.patch
+ "${FILESDIR}"/${PN}-1.0.17.1-add-PHP7-support.patch
+)
+
+pkg_setup() {
+ use python && python-single-r1_pkg_setup
+}
+
+src_prepare() {
+ default
+
+ eautoreconf
+
+ use php && php-ext-source-r3_src_prepare
+}
+
+src_configure() {
+ if use lua || use perl || use python || use ruby ; then
+ econf \
+ $(use_with lua) \
+ $(use_with perl) \
+ $(use_with python) \
+ --without-php \
+ $(use_with ruby)
+ fi
+
+ use php && php-ext-source-r3_src_configure
+}
+
+src_compile() {
+ if use lua || use perl || use python || use ruby ; then
+ default
+ fi
+
+ use php && php-ext-source-r3_src_compile
+}
+
+src_test() {
+ if use lua || use perl || use python || use ruby ; then
+ default
+ fi
+
+ if use php ; then
+ local slot
+ for slot in $(php_get_slots) ; do
+ php_init_slot_env "${slot}"
+ cd php || die
+ ${PHPCLI} -v
+ ${PHPCLI} -d "extension=./${PHP_EXT_NAME}.so" -f test.php || die "PHP tests for ${slot} failed!"
+ cd "${S}" || die
+ done
+ fi
+}
+
+src_install() {
+ if use lua || use perl || use python || use ruby ; then
+ emake DESTDIR="${D}" INSTALLDIRS=vendor luadir=/usr/$(get_libdir)/lua/5.1 install
+ fi
+
+ if use perl; then
+ find "${ED}" -type f -name perllocal.pod -delete
+ find "${ED}" -depth -mindepth 1 -type d -empty -delete
+ fi
+
+ use python && python_optimize
+
+ if use php; then
+ local slot
+ for slot in $(php_get_slots); do
+ php_init_slot_env "${slot}"
+ exeinto "${EXT_DIR#$EPREFIX}"
+ doexe "php/${PHP_EXT_NAME}.so"
+ done
+
+ php-ext-source-r3_createinifiles
+ fi
+
+ local DOCS=( AUTHORS ChangeLog NEWS README TODO )
+ local HTML_DOCS=( {NEWS,README,RELEASE,TODO}.html )
+ einstalldocs
+}