]>
Commit | Line | Data |
---|---|---|
c0a97864 ER |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without tests # build without tests | |
4 | ||
d97eea3f | 5 | %define svnrev 795 |
235ee385 | 6 | %define rel 2 |
c0a97864 ER |
7 | Summary: Generate Your Projects |
8 | Name: gyp | |
2e583992 | 9 | Version: 1 |
7f23d1d9 | 10 | Release: %{svnrev}.%{rel} |
c0a97864 ER |
11 | License: New BSD |
12 | Group: Development/Building | |
d97eea3f | 13 | # revno=795 |
2e583992 ER |
14 | # svn co http://gyp.googlecode.com/svn/trunk${revno:+@$revno} gyp |
15 | # tar -cjf gyp-$(svnversion gyp).tar.bz2 --exclude=.svn gyp | |
16 | # ../dropin gyp-$(svnversion gyp).tar.bz2 | |
c0a97864 | 17 | Source0: %{name}-%{svnrev}.tar.bz2 |
d97eea3f | 18 | # Source0-md5: 7ff7a085e5e352c6d3188acce3661a89 |
c0a97864 ER |
19 | URL: http://code.google.com/p/gyp/ |
20 | BuildRequires: python-devel | |
21 | BuildRequires: rpm-pythonprov | |
22 | BuildRequires: rpmbuild(macros) >= 1.219 | |
593a2a50 | 23 | Requires: python-%{name} = %{version}-%{release} |
c0a97864 ER |
24 | BuildArch: noarch |
25 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
26 | ||
27 | %description | |
28 | GYP is a tool to generates native Visual Studio, Xcode and SCons | |
29 | and/or make build files from a platform-independent input format. It's | |
30 | syntax is a universal cross-platform build representation that still | |
31 | allows sufficient per-platform flexibility to accommodate | |
32 | irreconcilable differences. | |
33 | ||
593a2a50 ER |
34 | %package -n python-%{name} |
35 | Summary: Python module for GYP | |
36 | Group: Development/Languages/Python | |
37 | ||
38 | %description -n python-%{name} | |
39 | GYP is a tool to generates native Visual Studio, Xcode and SCons | |
40 | and/or make build files from a platform-independent input format. It's | |
41 | syntax is a universal cross-platform build representation that still | |
42 | allows sufficient per-platform flexibility to accommodate | |
43 | irreconcilable differences. | |
44 | ||
c0a97864 ER |
45 | %prep |
46 | %setup -q -n %{name} | |
47 | ||
48 | %build | |
49 | %{__python} setup.py build | |
50 | ||
51 | %install | |
52 | rm -rf $RPM_BUILD_ROOT | |
53 | %{__python} setup.py install \ | |
54 | --optimize=2 \ | |
55 | --root=$RPM_BUILD_ROOT | |
56 | ||
57 | %py_postclean | |
58 | ||
59 | %clean | |
60 | rm -rf $RPM_BUILD_ROOT | |
61 | ||
62 | %files | |
63 | %defattr(644,root,root,755) | |
64 | %attr(755,root,root) %{_bindir}/gyp | |
593a2a50 ER |
65 | |
66 | %files -n python-%{name} | |
7f23d1d9 | 67 | %defattr(644,root,root,755) |
c0a97864 ER |
68 | %dir %{py_sitescriptdir}/gyp |
69 | %dir %{py_sitescriptdir}/gyp/generator | |
70 | %{py_sitescriptdir}/gyp/*.py[co] | |
71 | %{py_sitescriptdir}/gyp/generator/*.py[co] | |
72 | ||
73 | %if "%{py_ver}" > "2.4" | |
74 | %{py_sitescriptdir}/gyp-*.egg-info | |
75 | %endif |