diff options
-rw-r--r-- | composer.json | 29 | ||||
-rw-r--r-- | php-goutte.spec | 67 |
2 files changed, 61 insertions, 35 deletions
diff --git a/composer.json b/composer.json new file mode 100644 index 0000000..63d87e7 --- /dev/null +++ b/composer.json @@ -0,0 +1,29 @@ +{ + "name": "fabpot/goutte", + "type": "application", + "description": "A simple PHP Web Scraper", + "keywords": ["scraper"], + "homepage": "https://github.com/FriendsOfPHP/Goutte", + "license": "MIT", + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + } + ], + "require": { + "php": ">=5.4.0", + "symfony/browser-kit": "~2.1", + "symfony/css-selector": "~2.1", + "symfony/dom-crawler": "~2.1", + "guzzlehttp/guzzle": ">=4,<6" + }, + "autoload": { + "psr-4": { "Goutte\\": "Goutte" } + }, + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + } +} diff --git a/php-goutte.spec b/php-goutte.spec index 712e7a6..362d064 100644 --- a/php-goutte.spec +++ b/php-goutte.spec @@ -2,7 +2,7 @@ # # Fedora spec file for php-goutte # -# Copyright (c) 2014-2015 Shawn Iwinski <shawn@iwin.ski> +# Copyright (c) 2014-2016 Shawn Iwinski <shawn@iwin.ski> # # License: MIT # http://opensource.org/licenses/MIT @@ -12,24 +12,21 @@ %global github_owner FriendsOfPHP %global github_name Goutte -%global github_version 1.0.7 -%global github_commit 794b196e76bdd37b5155cdecbad311f0a3b07625 +%global github_version 2.0.4 +%global github_commit 0ad3ee6dc2d0aaa832a80041a1e09bf394e99802 %global composer_vendor fabpot %global composer_project goutte -# "php": ">=5.3.0" -%global php_min_ver 5.3.0 -# "guzzle/http": "~3.1" -# "guzzle/plugin-history": "~3.1" -# "guzzle/plugin-mock": "~3.1" -%global guzzle_min_ver 3.1 -%global guzzle_max_ver 4.0 +# "php": ">=5.4.0" +%global php_min_ver 5.4.0 +# "guzzlehttp/guzzle": ">=4,<6" +# NOTE: Min version not 4 because autoloader required +%global guzzle_min_ver 5.3.0 +%global guzzle_max_ver 6.0 # "symfony/browser-kit": "~2.1" # "symfony/css-selector": "~2.1" # "symfony/dom-crawler": "~2.1" -# "symfony/finder": "~2.1" -# "symfony/process": "~2.1" # NOTE: Min version not 2.1 because autoloader required %global symfony_min_ver 2.7.1 %global symfony_max_ver 3.0 @@ -37,7 +34,7 @@ # Build using "--without tests" to disable tests %global with_tests 0%{!?_without_tests:1} -%global phpdir %{_datadir}/php +%{!?phpdir: %global phpdir %{_datadir}/php} Name: php-goutte Version: %{github_version} @@ -55,17 +52,13 @@ BuildArch: noarch %if %{with_tests} BuildRequires: php-composer(phpunit/phpunit) ## composer.json -BuildRequires: php(language) >= %{php_min_ver} -BuildRequires: php-composer(guzzle/http) >= %{guzzle_min_ver} -BuildRequires: php-composer(guzzle/plugin-history) >= %{guzzle_min_ver} -BuildRequires: php-composer(guzzle/plugin-mock) >= %{guzzle_min_ver} -BuildRequires: php-composer(symfony/browser-kit) >= %{symfony_min_ver} -BuildRequires: php-composer(symfony/css-selector) >= %{symfony_min_ver} -BuildRequires: php-composer(symfony/dom-crawler) >= %{symfony_min_ver} -BuildRequires: php-composer(symfony/finder) >= %{symfony_min_ver} -BuildRequires: php-composer(symfony/process) >= %{symfony_min_ver} -BuildRequires: php-curl -## phpcompatinfo (computed from version 1.7.0) +BuildRequires: php(language) >= %{php_min_ver} +BuildRequires: php-composer(guzzlehttp/guzzle) >= %{guzzle_min_ver} +BuildRequires: php-composer(guzzlehttp/guzzle) < %{guzzle_max_ver} +BuildRequires: php-composer(symfony/browser-kit) >= %{symfony_min_ver} +BuildRequires: php-composer(symfony/css-selector) >= %{symfony_min_ver} +BuildRequires: php-composer(symfony/dom-crawler) >= %{symfony_min_ver} +## phpcompatinfo (computed from version 2.0.4) # <none> ## Autoloader BuildRequires: php-composer(symfony/class-loader) @@ -73,22 +66,19 @@ BuildRequires: php-composer(symfony/class-loader) # composer.json Requires: php(language) >= %{php_min_ver} -Requires: php-composer(guzzle/http) >= %{guzzle_min_ver} -Requires: php-composer(guzzle/http) < %{guzzle_max_ver} +Requires: php-composer(guzzlehttp/guzzle) >= %{guzzle_min_ver} +Requires: php-composer(guzzlehttp/guzzle) < %{guzzle_max_ver} Requires: php-composer(symfony/browser-kit) >= %{symfony_min_ver} Requires: php-composer(symfony/browser-kit) < %{symfony_max_ver} Requires: php-composer(symfony/css-selector) >= %{symfony_min_ver} Requires: php-composer(symfony/css-selector) < %{symfony_max_ver} Requires: php-composer(symfony/dom-crawler) >= %{symfony_min_ver} Requires: php-composer(symfony/dom-crawler) < %{symfony_max_ver} -Requires: php-composer(symfony/finder) >= %{symfony_min_ver} -Requires: php-composer(symfony/finder) < %{symfony_max_ver} -Requires: php-composer(symfony/process) >= %{symfony_min_ver} -Requires: php-composer(symfony/process) < %{symfony_max_ver} -Requires: php-curl -# phpcompatinfo (computed from version 1.7.0) +# phpcompatinfo (computed from version 2.0.4) # <none> +# Standard "php-{COMPOSER_VENDOR}-{COMPOSER_PROJECT}" naming +Provides: php-%{composer_vendor}-%{composer_project} = %{version}-%{release} # Composer Provides: php-composer(%{composer_vendor}/%{composer_project}) = %{version} @@ -125,12 +115,10 @@ if (!isset($fedoraClassLoader) || !($fedoraClassLoader instanceof \Symfony\Compo $fedoraClassLoader->addPrefix('Goutte\\', dirname(__DIR__)); -require_once '%{phpdir}/Guzzle/autoload.php'; +require_once '%{phpdir}/GuzzleHttp/autoload.php'; require_once '%{phpdir}/Symfony/Component/BrowserKit/autoload.php'; require_once '%{phpdir}/Symfony/Component/CssSelector/autoload.php'; require_once '%{phpdir}/Symfony/Component/DomCrawler/autoload.php'; -require_once '%{phpdir}/Symfony/Component/Finder/autoload.php'; -require_once '%{phpdir}/Symfony/Component/Process/autoload.php'; return $fedoraClassLoader; AUTOLOAD @@ -175,6 +163,15 @@ rm -rf %{buildroot} %changelog +* Sun Jun 12 2016 Shawn Iwinski <shawn@iwin.ski> - 2.0.4-1 +- Update to 2.0.4 + +* Mon Mar 28 2016 Shawn Iwinski <shawn@iwin.ski> - 1.0.7-3 +- Fixed Guzzle min version for autoloader +- Added "php-{COMPOSER_VENDOR}-{COMPOSER_PROJECT}" virtual provide +- Fixed \Goutte\Client::VERSION +- Added library version value and autoloader check + * Mon Nov 23 2015 Shawn Iwinski <shawn@iwin.ski> - 1.0.7-1 - Updated to 1.0.7 - Added spec file license header |