summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--php-Pimple.spec60
1 files changed, 27 insertions, 33 deletions
diff --git a/php-Pimple.spec b/php-Pimple.spec
index 028c4c2..b568b12 100644
--- a/php-Pimple.spec
+++ b/php-Pimple.spec
@@ -1,27 +1,28 @@
-%global libname Pimple
-%global php_min_ver 5.3.0
-
-Name: php-%{libname}
-Version: 1.0.1
+%global github_owner fabpot
+%global github_name Pimple
+%global github_version 1.0.2
+%global github_commit ae11e57e8c2bb414b2ff93396dbbfc0eb92feb94
+%global php_min_ver 5.3.0
+
+Name: php-%{github_name}
+Version: %{github_version}
Release: 1%{?dist}
Summary: A simple Dependency Injection Container for PHP
Group: Development/Libraries
License: MIT
URL: http://pimple.sensiolabs.org
-Source0: https://github.com/fabpot/%{libname}/archive/v%{version}.tar.gz
-
+Source0: https://github.com/%{github_owner}/%{github_name}/archive/%{github_commit}/%{name}-%{github_version}-%{github_commit}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
-BuildArch: noarch
-# Test requires
-BuildRequires: php-common >= %{php_min_ver}
+BuildArch: noarch
+BuildRequires: php(language) >= %{php_min_ver}
BuildRequires: php-pear(pear.phpunit.de/PHPUnit)
-# Test requires: phpci
+# phpci
BuildRequires: php-spl
-Requires: php-common >= %{php_min_ver}
-# phpci requires
+Requires: php(language) >= %{php_min_ver}
+# phpci
Requires: php-spl
%description
@@ -30,15 +31,7 @@ just one file and one class.
%prep
-%setup -q -n %{libname}-%{version}
-
-# Update and move tests' PHPUnit config
-sed 's#tests/##' -i phpunit.xml.dist
-mv phpunit.xml.dist tests/
-
-# Update tests' require
-sed "s#.*require.*Pimple.php.*#require_once '%{libname}/Pimple.php';#" \
- -i tests/bootstrap.php
+%setup -q -n %{github_name}-%{github_commit}
%build
@@ -46,28 +39,29 @@ sed "s#.*require.*Pimple.php.*#require_once '%{libname}/Pimple.php';#" \
%install
-mkdir -p -m 755 %{buildroot}%{_datadir}/php/%{libname}
-cp -pr lib/* %{buildroot}%{_datadir}/php/%{libname}/
-
-mkdir -p -m 755 %{buildroot}%{_datadir}/tests/%{name}
-cp -pr tests/* %{buildroot}%{_datadir}/tests/%{name}/
+mkdir -p -m 755 %{buildroot}%{_datadir}/php/%{github_name}
+cp -pr lib/* %{buildroot}%{_datadir}/php/%{github_name}/
%check
-%{_bindir}/phpunit \
- -d include_path=%{buildroot}%{_datadir}/php:.:%{pear_phpdir} \
- -c tests/phpunit.xml.dist
+%{_bindir}/phpunit -d include_path="./lib:./tests:%{pear_phpdir}"
%files
%defattr(-,root,root,-)
%doc LICENSE README.rst composer.json
-%{_datadir}/php/%{libname}
-%dir %{_datadir}/tests
- %{_datadir}/tests/%{name}
+%{_datadir}/php/%{github_name}
%changelog
+* Sat Mar 09 2013 Remi Collet <remi@fedoraproject.org> - 1.0.2-1
+- backport 1.0.2 for remi repo.
+
+* Fri Mar 08 2013 Shawn Iwinski <shawn.iwinski@gmail.com> 1.0.2-1
+- Updated to upstream version 1.0.2
+- Updates per new Fedora packaging guidelines for Git repos
+- Removed tests
+
* Mon Dec 17 2012 Remi Collet <remi@fedoraproject.org> - 1.0.1-1
- backport 1.0.1 for remi repo.