summaryrefslogtreecommitdiff
path: root/dev-php
diff options
context:
space:
mode:
Diffstat (limited to 'dev-php')
-rw-r--r--dev-php/libphutil/ChangeLog6
-rw-r--r--dev-php/libphutil/Manifest8
-rw-r--r--dev-php/libphutil/files/20150414-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch48
-rw-r--r--dev-php/libphutil/files/9999-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch9
-rw-r--r--dev-php/libphutil/libphutil-20150414.ebuild125
-rw-r--r--dev-php/libphutil/libphutil-9999.ebuild6
6 files changed, 193 insertions, 9 deletions
diff --git a/dev-php/libphutil/ChangeLog b/dev-php/libphutil/ChangeLog
index 55e39473..f8e28e12 100644
--- a/dev-php/libphutil/ChangeLog
+++ b/dev-php/libphutil/ChangeLog
@@ -1,3 +1,9 @@
+*libphutil-20150414 (19 Apr 2015)
+
+ 19 Apr 2015; Bertrand Jacquin <bertrand@jacquin.bzh>
+ +libphutil-20150414.ebuild, libphutil-9999.ebuild:
+ dev-php/libphutil: Add snapshot, sync with current repo, update git repo url
+
25 Jan 2015; Bertrand Jacquin <bertrand@jacquin.bzh> metadata.xml:
Update email address
diff --git a/dev-php/libphutil/Manifest b/dev-php/libphutil/Manifest
index 77d441dd..5faecc07 100644
--- a/dev-php/libphutil/Manifest
+++ b/dev-php/libphutil/Manifest
@@ -1,4 +1,6 @@
-AUX 9999-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch 2153 SHA256 408df8134bc33d011c023d64ccc980fe532fa1a9310545d3cb8439328a3ec8b4 WHIRLPOOL 19da9b0c880e8e7e7913e8018a15f1aa71d0c783ebdbe2878bce6f6f42b35fb8b374d2183c5a012bd9ef6fe5ab9da06d5bb921c5fa54a4b75f73cf7ab2c89b39
-EBUILD libphutil-9999.ebuild 3282 SHA256 67ede209e776289cf44782d5a1f9723ab8178d196211487255c1627c28d7ea8f WHIRLPOOL 4c544704c7ce119cbcfb80fe8f099c93a53bd5788d800a1e18221ca4b24b6ee045e7dcb1943d369bb7daced81bec42cf9f3f11b2bc00ea7dda9513b5cbda103d
-MISC ChangeLog 2864 SHA256 3f1240983ca9642e06874bbcfd7390d6c683db5c24b9485687a3ff7237103377 WHIRLPOOL 3a9ee7a68a2309a81d52220db01d62bb3009f88a8afd14c3264d47de02b4e071f6abf1a04f06741588bc8dde107226192a1dcce48d0382aa57e91943fffa626c
+AUX 20150414-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 3346 SHA256 0b8b97948570984ffb6c998e62b103ac94227a3735eaa1f72f254ab45f61ccea WHIRLPOOL 9dd62062154bff10ee80d8092ddfff1f6956e5d83db93fac5ffbe147ab08f3cdc25b5a0da68b5d16a69a953fe564ca55577f224739c985845d659cd8bf559410
+EBUILD libphutil-9999.ebuild 3285 SHA256 123c16d3947ccd47e6ae24a2dcd316f7cf29cd016f2e59f19d1f7c56ad03fbfa WHIRLPOOL f87d280edee48d1336fc86b66bac7f657097b2e199808cc30c0957708f2db9a79262f4e7e79cd044f3e45d8b0a2125c6dc593f7276f96d75471764e0a94428e5
+MISC ChangeLog 3087 SHA256 7ab3fc2bf37ed4af727e022c1c5023085f0c52e7c408c17f9c53a86bca679462 WHIRLPOOL ae32f890382b4e7bc3d92b662710680e94f3e6e8d022399ab6fb1b5d543e792ef9655bdda28a324d54f172d6616e970764bef830017c6ce4e5b66b6f458a8334
MISC metadata.xml 256 SHA256 6ca43960767ca28661abf97c85263db77fe7643902be2ce777c61aa688d8ea2d WHIRLPOOL cef8582829111be09e651eb819e6d1ea59c9c4386b842169ccd46a14c8e3ccb090486fecd61c5fd4aa47998cacc69cdc1fb5ca6bb6325a4da1ebfd0b6eebda7b
diff --git a/dev-php/libphutil/files/20150414-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch b/dev-php/libphutil/files/20150414-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/20150414-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/files/9999-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch b/dev-php/libphutil/files/9999-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch
index e1f5cfbb..c925f864 100644
--- a/dev-php/libphutil/files/9999-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch
+++ b/dev-php/libphutil/files/9999-Remove-the-usage-of-local-SSL-certificates-and-use-s.patch
@@ -1,4 +1,4 @@
-From bce789b826bcadb35e4fdae54781f41295d7cf5f Mon Sep 17 00:00:00 2001
+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
@@ -9,10 +9,10 @@ Subject: [PATCH] Remove the usage of local SSL certificates and use system
1 file changed, 2 insertions(+), 9 deletions(-)
diff --git a/src/future/http/HTTPSFuture.php b/src/future/http/HTTPSFuture.php
-index 98cd154..57b415d 100644
+index 250a7e7..e8ea804 100644
--- a/src/future/http/HTTPSFuture.php
+++ b/src/future/http/HTTPSFuture.php
-@@ -285,28 +285,21 @@ final class HTTPSFuture extends BaseHTTPFuture {
+@@ -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.
@@ -43,3 +43,6 @@ index 98cd154..57b415d 100644
}
}
+--
+2.0.5
+
diff --git a/dev-php/libphutil/libphutil-20150414.ebuild b/dev-php/libphutil/libphutil-20150414.ebuild
new file mode 100644
index 00000000..5a6fb2af
--- /dev/null
+++ b/dev-php/libphutil/libphutil-20150414.ebuild
@@ -0,0 +1,125 @@
+# 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_COMMIT="aaee4009e20db8eea94591117788be57c133eae5"
+
+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-${PV}: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
+}
diff --git a/dev-php/libphutil/libphutil-9999.ebuild b/dev-php/libphutil/libphutil-9999.ebuild
index 0150f72e..06a9f47d 100644
--- a/dev-php/libphutil/libphutil-9999.ebuild
+++ b/dev-php/libphutil/libphutil-9999.ebuild
@@ -7,7 +7,7 @@ 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/facebook/libphutil.git"
+EGIT_REPO_URI="git://github.com/phacility/libphutil.git"
LICENSE="Apache-2.0"
SLOT="0"
@@ -58,7 +58,7 @@ src_prepare() {
path="$(type -p ${cmd})" || continue
[[ -z "${path}" ]] && continue
- einfo "Changing ${REPLY/#${S}\/} shebang to #!${path} ${args}"
+ einfo "Replace ${REPLY/#${S}\/} shebang to #!${path} ${args}"
sed -i \
-e "1 s:^#!.*:#!${path} ${args}:" \
"${REPLY}"
@@ -120,5 +120,5 @@ src_install() {
| xargs --no-run-if-empty -- \
fperms 755
- dodoc NOTICE README
+ dodoc NOTICE README.md
}