]>
Commit | Line | Data |
---|---|---|
e2f85e20 JB |
1 | Summary: GridFields - convenient, algebraic manipulation of unstructured grids |
2 | Summary(pl.UTF-8): GridFields - wygodne operacje algebraiczne na tablicach bez struktury | |
3 | Name: gridfields | |
7ecd0771 JB |
4 | %define snap 20140423 |
5 | Version: 1.0.3 | |
6 | Release: 0.%{snap}.1 | |
7 | # project page says "MIT", but included spec and COPYING say LGPL v2+ | |
8 | License: LGPL v2+ | |
e2f85e20 JB |
9 | Group: Libraries |
10 | #Source0Download: https://code.google.com/p/gridfields/downloads/list | |
11 | Source0: https://gridfields.googlecode.com/files/tag.tgz | |
12 | # Source0-md5: 05e1aeb82fac693e57ed9e16c6a09556 | |
7ecd0771 JB |
13 | # released source is too old, so: |
14 | # svn checkout http://gridfields.googlecode.com/svn/trunk/ gridfields | |
15 | # diff -Nur -x .svn tag/gridfieldsclib-0.7 gridfields/clib | |
16 | Patch0: %{name}-clib-svn.patch | |
17 | # diff -Nur -x .svn tag/pygridfields-0.7 gridfields/pygridfields | |
18 | Patch1: %{name}-py-svn.patch | |
19 | Patch2: %{name}-python.patch | |
e2f85e20 | 20 | URL: https://code.google.com/p/gridfields/ |
7ecd0771 JB |
21 | BuildRequires: autoconf >= 2.68 |
22 | BuildRequires: automake | |
e2f85e20 | 23 | BuildRequires: libstdc++-devel |
7ecd0771 | 24 | BuildRequires: libtool >= 2:1.5 |
e2f85e20 JB |
25 | BuildRequires: netcdf-devel >= 4 |
26 | BuildRequires: netcdf-cxx-devel >= 4 | |
27 | BuildRequires: python-devel >= 1:2.4 | |
28 | BuildRequires: rpmbuild(macros) >= 1.219 | |
29 | BuildRequires: swig-python >= 1.3 | |
30 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
31 | ||
32 | %description | |
33 | GridFields library provides convenient, algebraic manipulation of | |
34 | unstructured grids in C++ and Python. | |
35 | ||
36 | %description -l pl.UTF-8 | |
37 | Biblioteka GridFields udostępnia wygodne operacje algebraiczne na | |
38 | tablicach bez struktury z poziomu C++ i Pythona. | |
39 | ||
40 | %package devel | |
41 | Summary: Header files for GridFields library | |
42 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki GridFields | |
43 | Group: Development/Libraries | |
44 | Requires: %{name} = %{version}-%{release} | |
45 | Requires: libstdc++-devel | |
46 | Requires: netcdf-devel >= 4 | |
47 | Requires: netcdf-cxx-devel >= 4 | |
48 | ||
49 | %description devel | |
50 | Header files for GridFields library. | |
51 | ||
52 | %description devel -l pl.UTF-8 | |
53 | Pliki nagłówkowe biblioteki GridFields. | |
54 | ||
55 | %package static | |
56 | Summary: Static GridFields library | |
57 | Summary(pl.UTF-8): Statyczna biblioteka GridFields | |
58 | Group: Development/Libraries | |
59 | Requires: %{name}-devel = %{version}-%{release} | |
60 | ||
61 | %description static | |
62 | Static GridFields library. | |
63 | ||
64 | %description static -l pl.UTF-8 | |
65 | Statyczna biblioteka GridFields. | |
66 | ||
67 | %package -n python-gridfield | |
68 | Summary: Python GridField library | |
69 | Summary(pl.UTF-8): Biblioteka GridField dla Pythona | |
70 | Group: Libraries/Python | |
71 | Requires: %{name} = %{version}-%{release} | |
72 | ||
73 | %description -n python-gridfield | |
74 | GridFields library provides convenient, algebraic manipulation of | |
75 | unstructured grids in C++ and Python. | |
76 | ||
77 | This package contains Python library. | |
78 | ||
79 | %description -n python-gridfield -l pl.UTF-8 | |
80 | Biblioteka GridFields udostępnia wygodne operacje algebraiczne na | |
81 | tablicach bez struktury z poziomu C++ i Pythona. | |
82 | ||
83 | Ten pakiet zawiera bibliotekę dla Pythona. | |
84 | ||
85 | %prep | |
7ecd0771 JB |
86 | %setup -q -c |
87 | cd tag | |
88 | %patch0 -p1 | |
89 | %patch1 -p1 | |
90 | %patch2 -p1 | |
e2f85e20 JB |
91 | |
92 | %build | |
7ecd0771 | 93 | cd tag/gridfieldsclib-0.7 |
e2f85e20 | 94 | %{__libtoolize} |
7ecd0771 | 95 | %{__aclocal} -I conf |
e2f85e20 JB |
96 | %{__autoconf} |
97 | %{__autoheader} | |
98 | %{__automake} | |
abcff9d2 JB |
99 | %configure \ |
100 | --with-netcdf-include=/usr/include \ | |
101 | --with-netcdf-libdir=%{_libdir} | |
e2f85e20 JB |
102 | %{__make} |
103 | ||
7ecd0771 | 104 | cd ../pygridfields-0.7 |
e2f85e20 JB |
105 | CC="%{__cc}" \ |
106 | CFLAGS="%{rpmcflags}" \ | |
107 | %{__python} setup.py build | |
108 | ||
109 | %install | |
110 | rm -rf $RPM_BUILD_ROOT | |
111 | ||
7ecd0771 | 112 | %{__make} -C tag/gridfieldsclib-0.7 install \ |
e2f85e20 JB |
113 | DESTDIR=$RPM_BUILD_ROOT |
114 | ||
7ecd0771 | 115 | cd tag/pygridfields-0.7 |
e2f85e20 JB |
116 | %{__python} setup.py install \ |
117 | --skip-build \ | |
118 | --optimize=2 \ | |
119 | --root=$RPM_BUILD_ROOT | |
120 | %py_postclean | |
121 | ||
122 | %clean | |
123 | rm -rf $RPM_BUILD_ROOT | |
124 | ||
125 | %post -p /sbin/ldconfig | |
126 | %postun -p /sbin/ldconfig | |
127 | ||
128 | %files | |
129 | %defattr(644,root,root,755) | |
7ecd0771 | 130 | %doc tag/gridfieldsclib-0.7/README |
e2f85e20 JB |
131 | %attr(755,root,root) %{_libdir}/libgridfields.so.*.*.* |
132 | %attr(755,root,root) %ghost %{_libdir}/libgridfields.so.1 | |
133 | ||
134 | %files devel | |
135 | %defattr(644,root,root,755) | |
7ecd0771 | 136 | %attr(755,root,root) %{_bindir}/gridfields-config |
e2f85e20 JB |
137 | %attr(755,root,root) %{_libdir}/libgridfields.so |
138 | %{_libdir}/libgridfields.la | |
139 | %{_includedir}/gridfields | |
140 | ||
141 | %files static | |
142 | %defattr(644,root,root,755) | |
143 | %{_libdir}/libgridfields.a | |
144 | ||
145 | %files -n python-gridfield | |
146 | %defattr(644,root,root,755) | |
147 | %attr(755,root,root) %{py_sitedir}/_core.so | |
148 | %attr(755,root,root) %{py_sitedir}/elio.so | |
149 | %{py_sitedir}/gridfield | |
150 | %{py_sitedir}/gridfield-0.5-py*.egg-info |