summaryrefslogtreecommitdiff
path: root/dev-php
diff options
context:
space:
mode:
authorBertrand Jacquin <bertrand@jacquin.bzh>2015-08-15 21:22:53 +0100
committerBertrand Jacquin <bertrand@jacquin.bzh>2015-08-18 21:48:40 +0100
commitabbdecce939e60fcdd152834afddfe3eaa7803aa (patch)
tree8f44279cee23232ddfc931e6c876f7ac1e99fa4d /dev-php
parentprofiles/common: Bump sys-kernel/longterm-sources (diff)
downloadportage-abbdecce939e60fcdd152834afddfe3eaa7803aa.tar.xz
dev-php/libphutil: Version bump
Package-Manager: portage-2.2.20.1
Diffstat (limited to 'dev-php')
-rw-r--r--dev-php/libphutil/ChangeLog7
-rw-r--r--dev-php/libphutil/Manifest4
-rw-r--r--dev-php/libphutil/files/20150815-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch48
-rw-r--r--dev-php/libphutil/libphutil-20150815.ebuild126
4 files changed, 184 insertions, 1 deletions
diff --git a/dev-php/libphutil/ChangeLog b/dev-php/libphutil/ChangeLog
index 8d7ba78d..90f70819 100644
--- a/dev-php/libphutil/ChangeLog
+++ b/dev-php/libphutil/ChangeLog
@@ -1,3 +1,10 @@
+*libphutil-20150815 (15 Aug 2015)
+
+ 15 Aug 2015; Bertrand Jacquin <bertrand@jacquin.bzh>
+ +files/20150815-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch,
+ +libphutil-20150815.ebuild:
+ dev-php/libphutil: Version bump
+
*libphutil-20150708 (08 Aug 2015)
08 Aug 2015; Bertrand Jacquin <bertrand@jacquin.bzh>
diff --git a/dev-php/libphutil/Manifest b/dev-php/libphutil/Manifest
index bbcbd12a..52bc059c 100644
--- a/dev-php/libphutil/Manifest
+++ b/dev-php/libphutil/Manifest
@@ -1,8 +1,10 @@
AUX 20150414-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch 2164 SHA256 80219b7e874cd1599ac2977949cf18dd0d09de4b7cf3ab10e5871d119c61bcf3 WHIRLPOOL 0af9d4a209f46f9e013988f86df69bd649e0f656fab8da9bc9ea9306e1d5b5f7477fb0d1e7b89de37871e8ac864c33a09ec2ad8a7ba5c3f43bd952d51b19ef64
AUX 20150708-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch 2164 SHA256 80219b7e874cd1599ac2977949cf18dd0d09de4b7cf3ab10e5871d119c61bcf3 WHIRLPOOL 0af9d4a209f46f9e013988f86df69bd649e0f656fab8da9bc9ea9306e1d5b5f7477fb0d1e7b89de37871e8ac864c33a09ec2ad8a7ba5c3f43bd952d51b19ef64
+AUX 20150815-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch 2164 SHA256 80219b7e874cd1599ac2977949cf18dd0d09de4b7cf3ab10e5871d119c61bcf3 WHIRLPOOL 0af9d4a209f46f9e013988f86df69bd649e0f656fab8da9bc9ea9306e1d5b5f7477fb0d1e7b89de37871e8ac864c33a09ec2ad8a7ba5c3f43bd952d51b19ef64
AUX 9999-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch 2164 SHA256 80219b7e874cd1599ac2977949cf18dd0d09de4b7cf3ab10e5871d119c61bcf3 WHIRLPOOL 0af9d4a209f46f9e013988f86df69bd649e0f656fab8da9bc9ea9306e1d5b5f7477fb0d1e7b89de37871e8ac864c33a09ec2ad8a7ba5c3f43bd952d51b19ef64
EBUILD libphutil-20150414.ebuild 3370 SHA256 c31b09b9728984948615c4b627f4461654a7b526f6e144c3309f533e85a4cc96 WHIRLPOOL 8ecf18fbb855679a3634a8c2a0254e880c8220d1d0c2369a90b6031642248cc99dc7382b91972ffd641b7ada864ea9ff5cc729bbbc5efadee64a3942d212ba0a
EBUILD libphutil-20150708.ebuild 3370 SHA256 8b2892ebb8f4cb711f0f029de74e6b87155513641c235ccee328fc393be5126d WHIRLPOOL e8afbdc230930c845ec2a6c5d8fbf7103ea3f81151c0aebde28ce0078a437190e912ee99f1bf871cf26229c3e989e246c4ed205bf0613a4411f5d8f1e7db0fec
+EBUILD libphutil-20150815.ebuild 3370 SHA256 fcfa9d4f7692165d00fd4c4de9d55798e504675b30bc45f68acd9c20a8e2e3bc WHIRLPOOL 4e6b4373785e23edb6dfbc7ff5d72d702a4a88f54a2e4c8308c9ff0c712b17c3a8d7ba7c314a006ab5834f869c9e9f1cd80f8db2ecb598e688d17b2156411d17
EBUILD libphutil-9999.ebuild 3285 SHA256 123c16d3947ccd47e6ae24a2dcd316f7cf29cd016f2e59f19d1f7c56ad03fbfa WHIRLPOOL f87d280edee48d1336fc86b66bac7f657097b2e199808cc30c0957708f2db9a79262f4e7e79cd044f3e45d8b0a2125c6dc593f7276f96d75471764e0a94428e5
-MISC ChangeLog 3347 SHA256 16a832ce0cec9be9f0bce886ea7f660741e7451d3a146d7035dbd0be692f1100 WHIRLPOOL b7a2240c95c8c3fd49e2918e6e9f07fd99c8e77fd4f93bc7e5539c4b59937c38638a62557b7877eca365f79ba818f879b446e77e254ae0263a77e7ca9874af22
+MISC ChangeLog 3580 SHA256 1278c1f2fb36cce539c032838771498eb3ad8738475395c1d0d06cb1a9219bd3 WHIRLPOOL 5406e4681589bef28bc00091cc4f2398fac7b90a517a2603e21a1826b84e6415b13b28555f7fc6e1bdbba0cd555e5f5a7501c5b8a1c363bc673527de243917dc
MISC metadata.xml 256 SHA256 6ca43960767ca28661abf97c85263db77fe7643902be2ce777c61aa688d8ea2d WHIRLPOOL cef8582829111be09e651eb819e6d1ea59c9c4386b842169ccd46a14c8e3ccb090486fecd61c5fd4aa47998cacc69cdc1fb5ca6bb6325a4da1ebfd0b6eebda7b
diff --git a/dev-php/libphutil/files/20150815-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch b/dev-php/libphutil/files/20150815-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch
new file mode 100644
index 00000000..c925f864
--- /dev/null
+++ b/dev-php/libphutil/files/20150815-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch
@@ -0,0 +1,48 @@
+From 76355d70f7b0418c12db64bc1407cc49f34618e7 Mon Sep 17 00:00:00 2001
+From: Bertrand Jacquin <beber@meleeweb.net>
+Date: Tue, 13 Aug 2013 16:07:58 +0200
+Subject: [PATCH] Remove the usage of local SSL certificates and use system
+ provided by ca-certificates.
+
+---
+ src/future/http/HTTPSFuture.php | 11 ++---------
+ 1 file changed, 2 insertions(+), 9 deletions(-)
+
+diff --git a/src/future/http/HTTPSFuture.php b/src/future/http/HTTPSFuture.php
+index 250a7e7..e8ea804 100644
+--- a/src/future/http/HTTPSFuture.php
++++ b/src/future/http/HTTPSFuture.php
+@@ -317,28 +317,21 @@ final class HTTPSFuture extends BaseHTTPFuture {
+ // `setCABundle()` or similar.
+ // - Then, check if a global bundle is set explicitly for all requests,
+ // via `setGlobalCABundle()` or similar.
+- // - Then, if a local custom.pem exists, use that, because it probably
+- // means that the user wants to override everything (also because the
+- // user might not have access to change the box's php.ini to add
+- // curl.cainfo).
+ // - Otherwise, try using curl.cainfo. If it's set explicitly, it's
+ // probably reasonable to try using it before we fall back to what
+ // libphutil ships with.
+- // - Lastly, try the default that libphutil ships with. If it doesn't
++ // - Lastly, try the default from ca-certificates. If it doesn't
+ // work, give up and yell at the user.
+
+ if (!$this->getCABundle()) {
+- $caroot = dirname(phutil_get_library_root('phutil')).'/resources/ssl/';
+ $ini_val = ini_get('curl.cainfo');
+ if (self::getGlobalCABundle()) {
+ $this->setCABundleFromPath(self::getGlobalCABundle());
+- } else if (Filesystem::pathExists($caroot.'custom.pem')) {
+- $this->setCABundleFromPath($caroot.'custom.pem');
+ } else if ($ini_val) {
+ // TODO: We can probably do a pathExists() here, even.
+ $this->setCABundleFromPath($ini_val);
+ } else {
+- $this->setCABundleFromPath($caroot.'default.pem');
++ $this->setCABundleFromPath('/etc/ssl/certs/ca-certificates.crt');
+ }
+ }
+
+--
+2.0.5
+
diff --git a/dev-php/libphutil/libphutil-20150815.ebuild b/dev-php/libphutil/libphutil-20150815.ebuild
new file mode 100644
index 00000000..4dec868a
--- /dev/null
+++ b/dev-php/libphutil/libphutil-20150815.ebuild
@@ -0,0 +1,126 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI=5
+inherit eutils toolchain-funcs git-r3
+
+DESCRIPTION="Collection of utility classes and functions for PHP used by phabricator"
+HOMEPAGE="http://www.phabricator.org"
+EGIT_REPO_URI="git://github.com/phacility/libphutil.git"
+EGIT_BRANCH="stable"
+EGIT_COMMIT="d266f8554c45dd670a16245a401da283bd6b3499"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="ssl test"
+
+DEPEND="virtual/awk:0
+ test? (
+ sys-devel/bison:0
+ >=sys-devel/flex-2.5.35:0
+ =www-client/arcanist-20150815:0
+ dev-lang/php[cli]
+ )"
+RDEPEND=">=dev-lang/php-5.2.3[curl,iconv,json,mysql,mysqli,pcntl,ssl?,unicode]"
+
+src_prepare() {
+ epatch "${FILESDIR}/${PV}-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch"
+
+ echo "${EGIT_VERSION}" > "${S}/VERSION"
+
+ if use test ; then
+ tc-export AR CXX
+ fi
+
+ find "${S}" -type f -name .gitignore -print0 \
+ | xargs -0 --no-run-if-empty -- \
+ rm
+
+ rm -r resources/ssl
+ rm -r scripts/daemon/torture
+ rm scripts/build_xhpast.sh
+ rm src/parser/xhpast/bin/xhpast.exe
+
+ # Replace 'env' shebang to files it point to
+ find "${S}" -type f \
+ | sort \
+ | xargs -n 1 --no-run-if-empty -- \
+ awk 'NR == 1 && /^#!\/usr\/bin\/env/ {print FILENAME}' \
+ | while read ; do
+ set -- $(sed -ne '1 s:^#!\([^ ]*\) ::p;q' ${REPLY})
+ cmd="$1" ; shift ; args="$@"
+
+ case "${cmd}" in
+ bash|php) ;;
+ *) continue ;;
+ esac
+
+ path="$(type -p ${cmd})" || continue
+ [[ -z "${path}" ]] && continue
+
+ einfo "Replace ${REPLY/#${S}\/} shebang to #!${path} ${args}"
+ sed -i \
+ -e "1 s:^#!.*:#!${path} ${args}:" \
+ "${REPLY}"
+ eend $?
+ done
+}
+
+src_compile() {
+ if use test ; then
+ cd support/xhpast
+
+ # Avoid sandbox violation for dev-lang/php[snmp]
+ # php -f generate_nodes.php'
+ #
+ # * ACCESS DENIED: open_wr: /var/lib/net-snmp/mib_indexes/0
+ # abs_path: /var/lib/net-snmp/mib_indexes/0
+ # res_path: /var/lib/net-snmp/mib_indexes/0
+ # /usr/lib64/libsandbox.so(+0xd9d1)[0x7f226c8899d1]
+ # /usr/lib64/libsandbox.so(+0xdaf8)[0x7f226c889af8]
+ # /usr/lib64/libsandbox.so(+0x59cf)[0x7f226c8819cf]
+ # /usr/lib64/libsandbox.so(fopen+0x7c)[0x7f226c8843ec]
+ # /usr/lib64/libnetsnmp.so.30(netsnmp_mibindex_new+0x48)[0x7f22695f55e8]
+ # /usr/lib64/libnetsnmp.so.30(add_mibdir+0x9c)[0x7f226960a00c]
+ # /usr/lib64/libnetsnmp.so.30(netsnmp_init_mib+0xca)[0x7f22695f4bea]
+ # /usr/lib64/libnetsnmp.so.30(init_snmp+0x32d)[0x7f226961c2dd]
+ # php(zm_startup_snmp+0x51)[0x7f226cf81e11]
+ # php(zend_startup_module_ex+0x11a)[0x7f226d0bccea]
+ # /proc/15834/cmdline: php -f generate_nodes.php
+ #
+ # See snmp_config(5)
+ export SNMP_PERSISTENT_DIR="${T}"
+
+ emake
+ emake install
+ fi
+}
+
+src_test() {
+ arc unit --everything --no-coverage || die "arc unit failed"
+}
+
+src_install() {
+ insinto "/usr/share/${PN}"
+ doins VERSION
+
+ insinto "/usr/share/php/${PN}"
+ doins -r externals resources scripts src
+
+ if use test ; then
+ fperms 755 "/usr/share/php/${PN}/src/parser/xhpast/bin/xhpast"
+ dosym "/usr/share/php/${PN}/src/parser/xhpast/bin/xhpast" /usr/bin/xhpast
+ fi
+
+ # Make executable all shebanged files
+ find "${ED}" -type f \
+ | xargs -n 1 --no-run-if-empty -- \
+ awk 'NR == 1 && /^#!/ {print FILENAME}' \
+ | sed -e "s:${ED}:/:" \
+ | xargs --no-run-if-empty -- \
+ fperms 755
+
+ dodoc NOTICE README.md
+}