Blame SPECS/gyp.spec

105b24
%{?scl:%scl_package gyp}
105b24
%{!?scl:%global pkg_name %{name}}
9f14a0
%global		revision	0bb6747
9f14a0
%{expand:	%%global	archivename	gyp-%{version}%{?revision:-git%{revision}}}
9f14a0
%if 0%{?rhel} && 0%{?rhel} <= 6
9f14a0
%{!?__python2: %global __python2 /usr/bin/python2}
9f14a0
%if 0%{?rhel} == 5
9f14a0
%global __python2 /usr/bin/python26
9f14a0
%global __os_install_post %__multiple_python_os_install_post
9f14a0
%endif
9f14a0
%{!?python2_sitelib: %global python2_sitelib %(%{__python2} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}
9f14a0
%{!?python2_sitearch: %global python2_sitearch %(%{__python2} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
105b24
%endif
105b24
105b24
Name:		%{?scl_prefix}gyp
105b24
Version:	0.1
9f14a0
Release:	0.20%{?revision:.%{revision}git}%{?dist}
105b24
Summary:	Generate Your Projects
105b24
105b24
Group:		Development/Tools
105b24
License:	BSD
105b24
URL:		http://code.google.com/p/gyp/
105b24
# No released tarball avaiable. so the tarball was generated
105b24
# from svn as following:
105b24
#
105b24
# 1. svn co http://gyp.googlecode.com/svn/trunk gyp
105b24
# 2. cd gyp
105b24
# 3. version=$(grep version= setup.py|cut -d\' -f2)
9f14a0
# 4. revision=$(git log --oneline|head -1|cut -d' ' -f1)
9f14a0
# 5. tar -a --exclude-vcs -cf /tmp/gyp-$version-git$revision.tar.bz2 *
105b24
Source0:	%{archivename}.tar.bz2
105b24
Patch0:		gyp-rpmoptflags.patch
105b24
9f14a0
%if 0%{?rhel} && 0%{?rhel} == 5
9f14a0
BuildRequires:	python26-devel
9f14a0
%else
9f14a0
BuildRequires:	python2-devel
9f14a0
%endif
9f14a0
BuildRequires:	python-setuptools
9f14a0
Requires:	python-setuptools
9f14a0
BuildArch:	noarch
105b24
BuildRequires:	python2-devel
105b24
BuildArch:	noarch
105b24
105b24
%{?scl:BuildRequires: %{scl}-runtime}
105b24
%{?scl:Requires: %{scl}-runtime}
105b24
%{?scl:Obsoletes: nodejs010-gyp}
105b24
105b24
%description
105b24
GYP is a tool to generates native Visual Studio, Xcode and SCons
105b24
and/or make build files from a platform-independent input format.
105b24
105b24
Its syntax is a universal cross-platform build representation
105b24
that still allows sufficient per-platform flexibility to accommodate
105b24
irreconcilable differences.
105b24
105b24
%prep
105b24
%setup -q -c -n %{archivename}
105b24
%patch0 -p1 -b .0-rpmoptflags
105b24
for i in $(find pylib -name '*.py'); do
105b24
	sed -e '\,#![ \t]*/.*python,{d}' $i > $i.new && touch -r $i $i.new && mv $i.new $i
105b24
done
105b24
105b24
%build
105b24
%{?scl:scl enable %{scl} "}
105b24
%{__python} setup.py build
105b24
%{?scl:"}
105b24
105b24
105b24
%install
105b24
rm -rf $RPM_BUILD_ROOT
105b24
105b24
%{?scl:scl enable %{scl} "}
105b24
%{__python} setup.py install --root $RPM_BUILD_ROOT --skip-build \
105b24
    --prefix %{_prefix}
105b24
%{?scl:"}
105b24
105b24
105b24
%clean
105b24
rm -rf $RPM_BUILD_ROOT
105b24
105b24
%files
105b24
%defattr(-,root,root,-)
105b24
%doc AUTHORS LICENSE
105b24
%{_bindir}/gyp
105b24
%{?scl:%_scl_root}%{python_sitelib}/*
105b24
105b24
%changelog
9f14a0
* Wed Jul 22 2015 Tomas Hrcka <thrcka@redhat.com> - 0.1-0.20.0bb6747git
9f14a0
- Rebase to latest upstream
9f14a0
9f14a0
* Fri May  1 2015 Akira TAGOH <tagoh@redhat.com> - 0.1-0.17.0bb6747git
9f14a0
- Rebase to 0bb6747.
9f14a0
- Add R: python-setuptools (#1217358)
9f14a0
9f14a0
* Mon Mar  2 2015 Akira TAGOH <tagoh@redhat.com> - 0.1-0.16.2037svn
9f14a0
- Rebase to r2037.
9f14a0
9f14a0
* Wed Jun 25 2014 Akira TAGOH <tagoh@redhat.com> - 0.1-0.15.1617svn
9f14a0
- Update rpm macros to the latest guidelines.
9f14a0
- Build against python26 for EPEL5.
9f14a0
9f14a0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
9f14a0
105b24
* Thu Mar 20 2014 Tomas Hrcka <thrcka@redhat.com> - 0.1-0.12.1617svn
105b24
- Obsolete nodejs010-gyp
105b24
105b24
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1-0.11.1617svn
105b24
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
105b24
105b24
* Tue Apr 23 2013 Akira TAGOH <tagoh@redhat.com> - 0.1-0.10.1617svn
105b24
- Rebase to r1617
105b24
105b24
* Mon Apr 08 2013 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.1-0.9.1010svn
105b24
- Add SCL runtime to Requires as well
105b24
105b24
* Mon Apr 08 2013 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.1-0.8.1010svn
105b24
- Add conditional BR on SCL runtime
105b24
105b24
* Fri Apr 05 2013 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.1-0.7.1010svn
105b24
- Add support for software collections
105b24
105b24
* Tue Feb 12 2013 Akira TAGOH <tagoh@redhat.com> - 0.1-0.9.1569svn
105b24
- Rebase to r1569 (#908983)
105b24
105b24
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1-0.8.1010svn
105b24
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
105b24
105b24
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1-0.7.1010svn
105b24
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
105b24
105b24
* Tue Aug 23 2011 Akira TAGOH <tagoh@redhat.com> - 0.1-0.6.1010svn
105b24
- Rebase to r1010.
105b24
105b24
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1-0.5.840svn
105b24
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
105b24
105b24
* Fri Aug 20 2010 Akira TAGOH <tagoh@redhat.com> - 0.1-0.4.840svn
105b24
- Rebase to r840.
105b24
- generate Makefile with RPM_OPT_FLAGS in CCFLAGS.
105b24
105b24
* Fri Aug  6 2010 Akira TAGOH <tagoh@redhat.com> - 0.1-0.3.839svn
105b24
- Drop the unnecessary macro.
105b24
105b24
* Thu Aug  5 2010 Akira TAGOH 
105b24
- Update the spec file according to the suggestion in rhbz#621242.
105b24
105b24
* Wed Aug  4 2010 Akira TAGOH <tagoh@redhat.com> - 0.1-0.1.839svn
105b24
- Initial packaging.
9f14a0