summaryrefslogtreecommitdiff
path: root/dev-php/pecl-geoip
diff options
context:
space:
mode:
Diffstat (limited to 'dev-php/pecl-geoip')
-rw-r--r--dev-php/pecl-geoip/Manifest4
-rw-r--r--dev-php/pecl-geoip/files/php8-support-1.1.1.patch93
-rw-r--r--dev-php/pecl-geoip/pecl-geoip-1.1.1-r4.ebuild4
-rw-r--r--dev-php/pecl-geoip/pecl-geoip-1.1.1-r5.ebuild25
4 files changed, 123 insertions, 3 deletions
diff --git a/dev-php/pecl-geoip/Manifest b/dev-php/pecl-geoip/Manifest
index 0b4cfb2af656..fe992ff8898a 100644
--- a/dev-php/pecl-geoip/Manifest
+++ b/dev-php/pecl-geoip/Manifest
@@ -1,4 +1,6 @@
AUX fix-failing-tests-1.1.1.patch 1250 BLAKE2B 587561ec400fe54b21333d09d2ad721b66c321de5a9c1823c0cb9706e63c41a24f81e53eb9fb92bc1f33bc867e141e8f29c26abc1452058dc387d29a53b0c7bc SHA512 9e3c93b337c38feaec29001a5a5b243f376bc7a32caaafa848b51daa3f0efbdecf407de6c8f304801ad106aa0e4906513588c42aa19bc6d5b261ccd6cb00b652
+AUX php8-support-1.1.1.patch 3017 BLAKE2B a3a200c6f9b081a1776a39a11cbcc1d547b5a1fa945e13436175e3e4834e5e83ad5980ed8b5d0e0b2f3c6fc31d8011a995cba98e3681ea2be22df55391767026 SHA512 80e234a37deb2a5ba075979aacb5f4a343ff2e938b42e398b1cb8fe98cc13cc70a2b9b1118e155a4ebc80783743e2f85ad09b1d48735112e807e902095d92035
DIST geoip-1.1.1.tgz 13004 BLAKE2B fe073b9459c434751ea0291ce6802041db47254f9d2d5b930db51751b3a66ce5cf925dc4bd07764920748b1735f26ba8bd136654e08ed9c24ac3b520e842f45d SHA512 395715297726aa8e7ed71297d403bea9cb08417a03adfca29dc6ea68bbc738c176f71ea621f9026109e07cd5a2adc647e2af8e140e18a6af1c8f0fe4ed1a9c6b
-EBUILD pecl-geoip-1.1.1-r4.ebuild 460 BLAKE2B f3e510fde3b552397efce311d83db0a2a78433408831f63778efbf01994baa2e45ce6f4e68424d5b775f21f0748476c67aa7957c6fe4ae4a98a86c462ded7b2d SHA512 9c32fc046bb9cf433894faee4ff537566df9c543a5af42ca0d3e422dba92789db9daf317a886cf81d25b5cd215898541860e5221ad495d5b4497b894cbcf8c06
+EBUILD pecl-geoip-1.1.1-r4.ebuild 439 BLAKE2B bc68853acc3e32b5a5e5f2b1c0485d346a93a7976735aaa8cbf0e9a94cacb7185083d89f670a8200167254d764d8255dceae1d5be14aaac593c2731f33f9a2f5 SHA512 2dfb9075f54995b439bf67642d2babb448d271c6cde649e8302e4ca7f51c1f5a029114a923131ec1c7c6699428db5128256fb382e6e911fd2e0ab87cc7748f6e
+EBUILD pecl-geoip-1.1.1-r5.ebuild 489 BLAKE2B 33b7073fe499d84d64df5dd07139a350e60bef86bd9f3bae5db8854faeb8a36c2c7286dabd3bcd9b3b53da63da3128aed44246631e70e26eb4efb8390b9c1472 SHA512 9cec410429e6ed5f24d55e71aa7b8a62cd722952acdfced25f0f97e006acc5d81a0b2d976bb67200709665b65a0f17770a7ba7d01ce3846a3a0914134ebb8974
MISC metadata.xml 239 BLAKE2B 9b7c5dcb74289073481cf07031b7a92f32496cc1097becb074d74a8fbb8133de429ce1baf284e446e44132943c8b32e6b824570f15828588e42ea49ef5661f00 SHA512 2181b874bfe8cd31e7730d8207e26cfd2f272eaf2d1b57ae0faff126347a5298fa1c506d9107e1da9736c8a0ed9c8c339e4d9509a8726b79dbe86e073c12dee0
diff --git a/dev-php/pecl-geoip/files/php8-support-1.1.1.patch b/dev-php/pecl-geoip/files/php8-support-1.1.1.patch
new file mode 100644
index 000000000000..50c53d1a94a7
--- /dev/null
+++ b/dev-php/pecl-geoip/files/php8-support-1.1.1.patch
@@ -0,0 +1,93 @@
+--- a/geoip.c 2020/10/30 12:04:28 351081
++++ b/geoip.c 2020/10/30 12:51:07 351082
+@@ -34,41 +34,72 @@
+ #include "ext/standard/info.h"
+ #include "php_geoip.h"
+
+-
++/* For PHP 8 */
++#ifndef TSRMLS_CC
++#define TSRMLS_CC
++#endif
+
+ ZEND_DECLARE_MODULE_GLOBALS(geoip)
+
++ZEND_BEGIN_ARG_INFO_EX(arginfo_geoip_void, 0, 0, 0)
++ZEND_END_ARG_INFO()
++
++ZEND_BEGIN_ARG_INFO_EX(arginfo_geoip_database_opt, 0, 0, 0)
++ ZEND_ARG_INFO(0, database)
++ZEND_END_ARG_INFO()
++
++ZEND_BEGIN_ARG_INFO_EX(arginfo_geoip_database, 0, 0, 1)
++ ZEND_ARG_INFO(0, database)
++ZEND_END_ARG_INFO()
++
++ZEND_BEGIN_ARG_INFO_EX(arginfo_geoip_host, 0, 0, 1)
++ ZEND_ARG_INFO(0, host)
++ZEND_END_ARG_INFO()
++
++ZEND_BEGIN_ARG_INFO_EX(arginfo_geoip_region, 0, 0, 2)
++ ZEND_ARG_INFO(0, country_code)
++ ZEND_ARG_INFO(0, region_code)
++ZEND_END_ARG_INFO()
++
++ZEND_BEGIN_ARG_INFO_EX(arginfo_geoip_directory, 0, 0, 1)
++ ZEND_ARG_INFO(0, directory)
++ZEND_END_ARG_INFO()
++
+ static int le_geoip;
+
+ /* {{{ */
+ zend_function_entry geoip_functions[] = {
+- PHP_FE(geoip_database_info, NULL)
++ PHP_FE(geoip_database_info, arginfo_geoip_database_opt)
+ #define GEOIPDEF(php_func, c_func, db_type) \
+- PHP_FE(php_func, NULL)
++ PHP_FE(php_func, arginfo_geoip_host)
+ #include "geoip.def"
+ #undef GEOIPDEF
+- PHP_FE(geoip_continent_code_by_name, NULL)
+- PHP_FE(geoip_org_by_name, NULL)
+- PHP_FE(geoip_record_by_name, NULL)
+- PHP_FE(geoip_id_by_name, NULL)
+- PHP_FE(geoip_region_by_name, NULL)
+- PHP_FE(geoip_isp_by_name, NULL)
+- PHP_FE(geoip_db_avail, NULL)
+- PHP_FE(geoip_db_get_all_info, NULL)
+- PHP_FE(geoip_db_filename, NULL)
++ PHP_FE(geoip_continent_code_by_name, arginfo_geoip_host)
++ PHP_FE(geoip_org_by_name, arginfo_geoip_host)
++ PHP_FE(geoip_record_by_name, arginfo_geoip_host)
++ PHP_FE(geoip_id_by_name, arginfo_geoip_host)
++ PHP_FE(geoip_region_by_name, arginfo_geoip_host)
++ PHP_FE(geoip_isp_by_name, arginfo_geoip_host)
++ PHP_FE(geoip_db_avail, arginfo_geoip_database)
++ PHP_FE(geoip_db_get_all_info, arginfo_geoip_void)
++ PHP_FE(geoip_db_filename, arginfo_geoip_database)
+ #if LIBGEOIP_VERSION >= 1004001
+- PHP_FE(geoip_region_name_by_code, NULL)
+- PHP_FE(geoip_time_zone_by_country_and_region, NULL)
++ PHP_FE(geoip_region_name_by_code, arginfo_geoip_region)
++ PHP_FE(geoip_time_zone_by_country_and_region, arginfo_geoip_region)
+ #endif
+ #ifdef HAVE_CUSTOM_DIRECTORY
+- PHP_FE(geoip_setup_custom_directory, NULL)
++ PHP_FE(geoip_setup_custom_directory, arginfo_geoip_directory)
+ #endif
+- PHP_FE(geoip_asnum_by_name, NULL)
+- PHP_FE(geoip_domain_by_name, NULL)
++ PHP_FE(geoip_asnum_by_name, arginfo_geoip_host)
++ PHP_FE(geoip_domain_by_name, arginfo_geoip_host)
+ #if LIBGEOIP_VERSION >= 1004008
+- PHP_FE(geoip_netspeedcell_by_name, NULL)
++ PHP_FE(geoip_netspeedcell_by_name, arginfo_geoip_host)
+ #endif
++#ifdef PHP_FE_END
++ PHP_FE_END
++#else
+ {NULL, NULL, NULL}
++#endif
+ };
+ /* }}} */
+
diff --git a/dev-php/pecl-geoip/pecl-geoip-1.1.1-r4.ebuild b/dev-php/pecl-geoip/pecl-geoip-1.1.1-r4.ebuild
index 956d2192df64..9b8d00516a8d 100644
--- a/dev-php/pecl-geoip/pecl-geoip-1.1.1-r4.ebuild
+++ b/dev-php/pecl-geoip/pecl-geoip-1.1.1-r4.ebuild
@@ -1,11 +1,11 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PHP_EXT_NAME="geoip"
DOCS="README ChangeLog"
-USE_PHP="php5-6 php7-0 php7-1 php7-2 php7-3 php7-4"
+USE_PHP="php7-2 php7-3 php7-4"
inherit php-ext-pecl-r3
diff --git a/dev-php/pecl-geoip/pecl-geoip-1.1.1-r5.ebuild b/dev-php/pecl-geoip/pecl-geoip-1.1.1-r5.ebuild
new file mode 100644
index 000000000000..f5bbf1f24038
--- /dev/null
+++ b/dev-php/pecl-geoip/pecl-geoip-1.1.1-r5.ebuild
@@ -0,0 +1,25 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+PHP_EXT_NAME="geoip"
+DOCS="README ChangeLog"
+USE_PHP="php7-2 php7-3 php7-4 php8-0"
+
+inherit php-ext-pecl-r3
+
+KEYWORDS="~amd64 ~x86"
+
+DESCRIPTION="PHP extension to map IP address to geographic places"
+LICENSE="PHP-3"
+SLOT="0"
+IUSE=""
+
+DEPEND="dev-libs/geoip"
+RDEPEND="${DEPEND}"
+
+PATCHES=(
+ "${FILESDIR}/fix-failing-tests-1.1.1.patch"
+ "${FILESDIR}/php8-support-1.1.1.patch"
+)