File php-composer.spec of Package php-composer
#
# spec file for package php-composer
#
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
Name: php-composer
Version: 1.2.1
Release: 0
Summary: Dependency Management for PHP
License: MIT
Group: Development/Libraries/Other
Url: http://getcomposer.org/
Source0: https://getcomposer.org/download/%{version}/composer.phar
Source1: https://raw.githubusercontent.com/composer/composer/%{version}/LICENSE
Requires: php-json
Requires: php-openssl
Requires: php-pear-console >= 2.3
Requires: php-pear-finder >= 2.3
Requires: php-phar
Provides: php5-composer = %{version}
Obsoletes: php5-composer < %{version}
BuildRoot: %{_tmppath}/%{name}-%{version}-build
# Those dependencies are not yet available on the build service
#Requires: php-pear-symfony2-Process >= 2.3
#Requires: php-pear-jsonlint >= 1.0
#Requires: php-pear-json-schema >= 1.3
BuildArch: noarch
%if 0%{?sles_version} >= 10
BuildRequires: php53 >= 5.3.2
Requires: php53 >= 5.3.2
%else
BuildRequires: php >= 5.3.2
Requires: php >= 5.3.2
%endif
%description
Composer is a dependency manager tracking local dependencies of your projects
and libraries.
%prep
%setup -q -c -T
%build
%install
install -d -m 0750 %{buildroot}%{_bindir}
install -m 0755 %{SOURCE0} %{buildroot}%{_bindir}/composer
install -d -m 0750 %{buildroot}%{_docdir}/%{name}
install -m 0644 %{SOURCE1} %{buildroot}%{_docdir}/%{name}/LICENSE
%files
%defattr(-,root,root,0755)
%{_bindir}/composer
%{_docdir}/%{name}
%changelog