Update to 1.1.0
allow Symfony 2, 3 and 4
This commit is contained in:
parent
cec21ac805
commit
24eca06263
5 changed files with 35 additions and 27 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -6,3 +6,4 @@
|
|||
/php-composer-ca-bundle-1.0.7-b17e615.tgz
|
||||
/php-composer-ca-bundle-1.0.8-9dd73a0.tgz
|
||||
/php-composer-ca-bundle-1.0.9-36344ae.tgz
|
||||
/php-composer-ca-bundle-1.1.0-943b2c4.tgz
|
||||
|
|
|
|||
|
|
@ -1,9 +0,0 @@
|
|||
<?php
|
||||
/* Autoloader for composer/ca-bundle and its dependencies */
|
||||
|
||||
if (!class_exists('Fedora\\Autoloader\\Autoload', false)) {
|
||||
require_once '/usr/share/php/Fedora/Autoloader/autoload.php';
|
||||
}
|
||||
|
||||
\Fedora\Autoloader\Autoload::addPsr4('Composer\\CaBundle\\', __DIR__);
|
||||
|
||||
|
|
@ -1,12 +1,12 @@
|
|||
diff -up src/CaBundle.php.rpm src/CaBundle.php
|
||||
--- src/CaBundle.php.rpm 2016-04-30 09:44:06.624946839 +0200
|
||||
+++ src/CaBundle.php 2016-04-30 09:44:37.576088602 +0200
|
||||
@@ -129,7 +129,7 @@ class CaBundle
|
||||
--- src/CaBundle.php.rpm 2017-11-30 07:12:46.773928987 +0100
|
||||
+++ src/CaBundle.php 2017-11-30 07:15:28.549820032 +0100
|
||||
@@ -130,7 +130,7 @@ class CaBundle
|
||||
*/
|
||||
public static function getBundledCaBundlePath()
|
||||
{
|
||||
- return __DIR__.'/../res/cacert.pem';
|
||||
+ return '/etc/pki/tls/certs/ca-bundle.crt'; // System CA, always
|
||||
}
|
||||
- $caBundleFile = __DIR__.'/../res/cacert.pem';
|
||||
+ $caBundleFile = '/etc/pki/tls/certs/ca-bundle.crt'; // System CA, always
|
||||
|
||||
/**
|
||||
// cURL does not understand 'phar://' paths
|
||||
// see https://github.com/composer/ca-bundle/issues/10
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
#
|
||||
# Please, preserve the changelog entries
|
||||
#
|
||||
%global gh_commit 36344aeffdc37711335563e6108cda86566432a6
|
||||
%global gh_commit 943b2c4fcad1ef178d16a713c2468bf7e579c288
|
||||
%global gh_short %(c=%{gh_commit}; echo ${c:0:7})
|
||||
%global gh_owner composer
|
||||
%global gh_project ca-bundle
|
||||
|
|
@ -14,7 +14,7 @@
|
|||
%global with_tests 0%{!?_without_tests:1}
|
||||
|
||||
Name: php-composer-ca-bundle
|
||||
Version: 1.0.9
|
||||
Version: 1.1.0
|
||||
Release: 1%{?dist}
|
||||
Summary: Lets you find a path to the system CA
|
||||
|
||||
|
|
@ -24,7 +24,6 @@ URL: https://github.com/%{gh_owner}/%{gh_project}
|
|||
# git snapshot to get everything, despite .gitattributes
|
||||
Source0: %{name}-%{version}-%{gh_short}.tgz
|
||||
Source1: makesrc.sh
|
||||
Source2: %{name}-autoload.php
|
||||
|
||||
# Never bundle a CA file
|
||||
Patch0: %{name}-rpm.patch
|
||||
|
|
@ -36,13 +35,13 @@ BuildRequires: php-openssl
|
|||
BuildRequires: php-pcre
|
||||
BuildRequires: php-cli
|
||||
# From composer.json, "require": {
|
||||
# "phpunit/phpunit": "^4.5",
|
||||
# "phpunit/phpunit": "^4.8.35",
|
||||
# "psr/log": "^1.0",
|
||||
# "symfony/process": "^2.5 || ^3.0"
|
||||
# "symfony/process": "^2.5 || ^3.0 || ^4.0"
|
||||
BuildRequires: phpunit
|
||||
BuildRequires: php-composer(psr/log) < 2
|
||||
BuildRequires: php-composer(psr/log) >= 1.0
|
||||
BuildRequires: php-composer(symfony/process) < 3
|
||||
BuildRequires: php-composer(symfony/process) < 5
|
||||
BuildRequires: php-composer(symfony/process) >= 2.5
|
||||
# Autoloader
|
||||
BuildRequires: php-composer(fedora/autoloader)
|
||||
|
|
@ -76,11 +75,18 @@ Autoloader: %{php_home}/Composer/CaBundle/autoload.php
|
|||
%prep
|
||||
%setup -q -n %{gh_project}-%{gh_commit}
|
||||
|
||||
cp %{SOURCE2} src/autoload.php
|
||||
%patch0 -p0 -b .rpm
|
||||
|
||||
find src -name \*.rpm -exec rm {} \;
|
||||
|
||||
cat << 'EOF' | tee src/autoload.php
|
||||
<?php
|
||||
/* Autoloader for %{gh_owner}/%{gh_project} and its dependencies */
|
||||
|
||||
require_once '%{php_home}/Fedora/Autoloader/autoload.php';
|
||||
|
||||
\Fedora\Autoloader\Autoload::addPsr4('Composer\\CaBundle\\', __DIR__);
|
||||
EOF
|
||||
|
||||
|
||||
%build
|
||||
# Empty build section, most likely nothing required.
|
||||
|
|
@ -98,8 +104,14 @@ mkdir vendor
|
|||
cat << 'EOF' | tee vendor/autoload.php
|
||||
<?php
|
||||
require_once '%{buildroot}%{php_home}/Composer/CaBundle/autoload.php';
|
||||
require_once '%{php_home}/Psr/Log/autoload.php';
|
||||
require_once '%{php_home}/Symfony/Component/Process/autoload.php';
|
||||
\Fedora\Autoloader\Dependencies::required(array(
|
||||
array(
|
||||
'%{php_home}/Symfony4/Component/Process/autoload.php',
|
||||
'%{php_home}/Symfony3/Component/Process/autoload.php',
|
||||
'%{php_home}/Symfony/Component/Process/autoload.php',
|
||||
),
|
||||
'%{php_home}/Psr/Log/autoload.php',
|
||||
));
|
||||
EOF
|
||||
|
||||
ret=0
|
||||
|
|
@ -124,6 +136,10 @@ exit $ret
|
|||
|
||||
|
||||
%changelog
|
||||
* Thu Nov 30 2017 Remi Collet <remi@remirepo.net> - 1.1.0-1
|
||||
- Update to 1.1.0
|
||||
- allow Symfony 2, 3 and 4
|
||||
|
||||
* Tue Nov 14 2017 Remi Collet <remi@remirepo.net> - 1.0.9-1
|
||||
- Update to 1.0.9 (no change)
|
||||
|
||||
|
|
|
|||
2
sources
2
sources
|
|
@ -1 +1 @@
|
|||
SHA512 (php-composer-ca-bundle-1.0.9-36344ae.tgz) = 52a82556f25bc20824432a133ab2d1b239f4477f12bd0aa52d2f48c1563fa751beb97d5a0619d0f7e75d85eeb52362a9e8357be4e7864be57600b25ece55593a
|
||||
SHA512 (php-composer-ca-bundle-1.1.0-943b2c4.tgz) = bcda67bc0d83d1071a1957f69a19fe701da40ef885beb4a7df8e5742050c04d513edd53c8153d38c23b54fb4397ec8106a7d78963dd0aa5b85341c74c214be92
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue