~ubuntu-branches/ubuntu/wily/grass/wily

« back to all changes in this revision

Viewing changes to rpm/opensuse/grass.spec

Tags: 7.0.0~rc1+ds1-1~exp1
* New upstream release candidate.
* Repack upstream tarball, remove precompiled Python objects.
* Add upstream metadata.
* Update gbp.conf and Vcs-Git URL to use the experimental branch.
* Update watch file for GRASS 7.0.
* Drop build dependencies for Tcl/Tk, add build dependencies:
  python-numpy, libnetcdf-dev, netcdf-bin, libblas-dev, liblapack-dev
* Update Vcs-Browser URL to use cgit instead of gitweb.
* Update paths to use grass70.
* Add configure options: --with-netcdf, --with-blas, --with-lapack,
  remove --with-tcltk-includes.
* Update patches for GRASS 7.
* Update copyright file, changes:
  - Update copyright years
  - Group files by license
  - Remove unused license sections
* Add patches for various typos.
* Fix desktop file with patch instead of d/rules.
* Use minimal dh rules.
* Bump Standards-Version to 3.9.6, no changes.
* Use dpkg-maintscript-helper to replace directories with symlinks.
  (closes: #776349)
* Update my email to use @debian.org address.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
%define shortver 63
2
 
 
3
 
Summary:        GRASS - Geographic Resources Analysis Support System
4
 
Name:           grass
5
 
Version:        6.3.0
6
 
Release:        1
7
 
License:        GPL
8
 
Group:          Applications/GIS
9
 
URL:            http://grass.osgeo.org/
10
 
Source:         grass-%{version}.tar.gz
11
 
Patch:          grass-%{version}_wx-vdigit.patch
12
 
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
13
 
Packager:       Otto Dassau <otto.dassau@gmx.de>
14
 
Requires:       libgdal >= 1.5.0
15
 
Requires:       tcl >= 8.4
16
 
Requires:       tk >= 8.4
17
 
Requires:       proj4 >= 4.5.0
18
 
Requires:       sqlite >= 3
19
 
Requires:       xterm
20
 
Requires:       unixODBC
21
 
Requires:       fftw3
22
 
Requires:       netcdf
23
 
Requires:       libpng
24
 
Requires:       libtiff
25
 
Requires:       libjpeg
26
 
Requires:       readline
27
 
Requires:       wxPython2.8-gtk2-unicode
28
 
Requires:       python-numeric
29
 
BuildRequires:  bison
30
 
BuildRequires:  gcc-c++
31
 
BuildRequires:  flex
32
 
BuildRequires:  freetype2-devel
33
 
BuildRequires:  libjpeg-devel
34
 
BuildRequires:  libgdal-devel
35
 
BuildRequires:  libpng-devel >= 1.2.12
36
 
BuildRequires:  man
37
 
BuildRequires:  readline-devel
38
 
BuildRequires:  libpng-devel
39
 
BuildRequires:  libtiff-devel
40
 
%if 0%{?suse_version} >= 1030
41
 
BuildRequires:  libnetcdf-devel
42
 
%else
43
 
BuildRequires:  netcdf
44
 
%endif
45
 
BuildRequires:  libjpeg-devel
46
 
BuildRequires:  tcl-devel
47
 
BuildRequires:  tk-devel
48
 
BuildRequires:  libproj-devel proj4
49
 
BuildRequires:  ncurses-devel >= 5.5
50
 
BuildRequires:  zlib-devel
51
 
BuildRequires:  libtiff-devel
52
 
BuildRequires:  xorg-x11-Mesa-devel
53
 
BuildRequires:  sqlite-devel
54
 
BuildRequires:  unixODBC-devel
55
 
BuildRequires:  postgresql-devel
56
 
BuildRequires:  mysql mysql-devel
57
 
BuildRequires:  fftw3 fftw3-devel
58
 
BuildRequires:  fdupes perl
59
 
BuildRequires:  python-devel swig
60
 
BuildRequires:  wxPython2.8-devel-gtk2-unicode
61
 
 
62
 
%package docs
63
 
Summary:        Documentation for grass
64
 
Group:          Applications/GIS
65
 
Requires:       grass = %{version}
66
 
 
67
 
%package devel
68
 
Summary:        Development files for grass
69
 
Group:          Development/Libraries
70
 
Requires:       grass = %{version}
71
 
 
72
 
%debug_package
73
 
 
74
 
%description
75
 
GRASS (Geographic Resources Analysis Support System), commonly
76
 
referred to as GRASS, is a Geographic Information System
77
 
(GIS) used for geospatial data management and analysis, image
78
 
processing, graphics/maps production, spatial modeling, and
79
 
visualization. GRASS is currently used in academic and commercial
80
 
settings around the world, as well as by many governmental agencies
81
 
and environmental consulting companies.
82
 
 
83
 
%description devel
84
 
This package contains the development files for grass
85
 
 
86
 
%description docs
87
 
This package contains the HTML documentation files for grass
88
 
 
89
 
%prep
90
 
%setup -n grass-%{version}
91
 
%patch -p1
92
 
%define grasver -@GRASS_VERSION_MAJOR@.@GRASS_VERSION_MINOR@.@GRASS_VERSION_RELEASE@
93
 
%define grasver2 '-${GRASS_VERSION_MAJOR}.${GRASS_VERSION_MINOR}.${GRASS_VERSION_RELEASE}'
94
 
 
95
 
sed s/%{grasver}//g include/Make/Platform.make.in >_tmp
96
 
mv _tmp include/Make/Platform.make.in
97
 
 
98
 
sed s/%{grasver}//g grass.pc.in >_tmp
99
 
mv _tmp grass.pc.in
100
 
 
101
 
sed s/%{grasver2}//g configure >_tmp
102
 
mv _tmp configure
103
 
chmod +x configure
104
 
 
105
 
sed s/%{grasver2}//g Makefile >_tmp
106
 
mv _tmp Makefile
107
 
 
108
 
%define _prefix /opt
109
 
%define grassdir %{_prefix}/grass
110
 
%define grasslib %{_prefix}/grass/lib
111
 
 
112
 
#configure with shared libs:
113
 
CFLAGS="-O2" ./configure \
114
 
        --prefix=%{_prefix} \
115
 
        --enable-shared \
116
 
        --enable-largefile \
117
 
        --with-proj-share=/usr/share/proj \
118
 
        --with-cxx \
119
 
        --with-gdal=/usr/bin/gdal-config \
120
 
        --with-postgres --with-postgres-includes=/usr/include/pgsql \
121
 
        --with-mysql --with-mysql-includes=/usr/include/mysql \
122
 
        --with-fftw \
123
 
        --with-readline \
124
 
        --with-netcdf \
125
 
        --with-curses \
126
 
        --with-nls \
127
 
        --with-sqlite \
128
 
        --with-freetype \
129
 
        --with-freetype-includes=/usr/include/freetype2 \
130
 
        --with-odbc \
131
 
        --with-python \
132
 
        --with-wxwidgets=/usr/lib/wxPython-2.8.7.1-gtk2-unicode/bin/wx-config   
133
 
 
134
 
%build
135
 
make prefix=%{_prefix} BINDIR=%{_bindir} PREFIX=%{_prefix}
136
 
 
137
 
%install
138
 
make prefix=%{buildroot}%{_prefix} BINDIR=%{buildroot}%{_bindir} \
139
 
PREFIX=%{buildroot}%{_prefix} install
140
 
 
141
 
# changing GISBASE in startup script (deleting %{buildroot} from path)
142
 
mkdir %{buildroot}/usr/bin -p
143
 
cat %{buildroot}%{_prefix}/bin/grass%{shortver} |
144
 
        sed s:%{buildroot}::g > %{buildroot}/usr/bin/grass%{shortver}
145
 
rm %{buildroot}%{_prefix}/bin/grass%{shortver}
146
 
chmod +x %{buildroot}/usr/bin/grass%{shortver}
147
 
ln -s grass%{shortver} %{buildroot}/usr/bin/grass
148
 
 
149
 
# make grass libraries available on the system
150
 
install -d %{buildroot}/etc/ld.so.conf.d
151
 
echo %{grasslib} >> %{buildroot}/etc/ld.so.conf.d/grass-%{version}.conf
152
 
pushd %{buildroot}%{grassdir}/man
153
 
  gzip */*
154
 
popd
155
 
pushd %{buildroot}%{grassdir}/etc/gem/skeleton/
156
 
chmod +x uninstall
157
 
chmod +x post
158
 
popd
159
 
 
160
 
# this is possibly dangerous
161
 
# make sure that no changeable files are linked
162
 
fdupes -r %{buildroot}%{grassdir} | perl -ne \
163
 
'chomp;if(!$_){my $f=shift @a;while($_=shift @a){system "ln -f $f $_";}}else{push @a,$_;}'
164
 
 
165
 
%clean
166
 
rm -rf %{buildroot}
167
 
 
168
 
%files devel
169
 
%defattr(-,root,root)
170
 
%{grassdir}/include
171
 
%{grasslib}/*.a
172
 
 
173
 
%files docs
174
 
%defattr(-,root,root)
175
 
%{grassdir}/docs
176
 
%{grassdir}/man
177
 
 
178
 
%files
179
 
%defattr(-,root,root)
180
 
/etc/ld.so.conf.d/grass-%{version}.conf
181
 
%{grassdir}/bin/*
182
 
%{grassdir}/etc/*
183
 
%{grassdir}/scripts/*
184
 
%{grassdir}/bwidget/*
185
 
#%{grassdir}/locale/*
186
 
%lang(ar) %{grassdir}/locale/ar/
187
 
%lang(cs) %{grassdir}/locale/cs/
188
 
%lang(de) %{grassdir}/locale/de/
189
 
%lang(el) %{grassdir}/locale/el/
190
 
%lang(es) %{grassdir}/locale/es/
191
 
%lang(fr) %{grassdir}/locale/fr/
192
 
%lang(hi) %{grassdir}/locale/hi/
193
 
%lang(it) %{grassdir}/locale/it/
194
 
%lang(ja) %{grassdir}/locale/ja/
195
 
%lang(ko) %{grassdir}/locale/ko/
196
 
%lang(lv) %{grassdir}/locale/lv/
197
 
%lang(mr) %{grassdir}/locale/mr/
198
 
%lang(pl) %{grassdir}/locale/pl/
199
 
%lang(pt) %{grassdir}/locale/pt/
200
 
%lang(pt_br) %{grassdir}/locale/pt_br/
201
 
%lang(ru) %{grassdir}/locale/ru/
202
 
%lang(sl) %{grassdir}/locale/sl/
203
 
%lang(th) %{grassdir}/locale/th/
204
 
%lang(tr) %{grassdir}/locale/tr/
205
 
%lang(vi) %{grassdir}/locale/vi/
206
 
%lang(zh) %{grassdir}/locale/zh/
207
 
%{grassdir}/driver/*
208
 
%{grassdir}/fonts/*
209
 
%{grasslib}/*.so
210
 
/usr/bin/grass*
211
 
#%exclude %{grasslib}/*[a-zA-Z].so
212
 
#%doc AUTHORS COPYING GPL.TXT README REQUIREMENTS.html
213
 
%{grassdir}/AUTHORS
214
 
%{grassdir}/CHANGES
215
 
%{grassdir}/COPYING
216
 
%{grassdir}/GPL.TXT
217
 
%{grassdir}/REQUIREMENTS.html
218
 
%defattr(755,root,root)
219
 
%{_prefix}/bin/*
220
 
 
221
 
%post
222
 
/sbin/ldconfig
223
 
 
224
 
%postun
225
 
/sbin/ldconfig
226
 
 
227
 
%changelog
228
 
* Thu Apr 23 2008 Otto Dassau <otto.dassau@gmx.de> 6.3.0.1
229
 
- update to 6.3 with new wxpython as standard gui
230
 
- patch to comment wxgui vdigit in Makefile
231
 
* Thu Dec 20 2007 Otto Dassau 6.2.3
232
 
- added support for netcdf, readline and LFS
233
 
* Mon Aug 13 2007 Dirk Stöcker 6.2.2
234
 
- adapted for openSUSE build service
235
 
* Mon Jul 16 2007 Otto Dassau 6.2.2
236
 
- first build of grass 6.2.2 bugfix release
237
 
* Fri Jan 05 2007 Otto Dassau 6.2.1
238
 
- split into devel and docs packages
239
 
- removed ld.so.conf entry and added ld.so.conf.d/grass* 
240
 
* Tue Dec 19 2006 Otto Dassau 6.2.1
241
 
- updated to SuSE 10.2
242
 
* Wed Jan 25 2006 Otto Dassau 6.0.2RC4
243
 
- updated to SuSE 10.0
244
 
* Thu Nov 17 2005 Markus Neteler 6.1.cvs
245
 
- upgraded to Mandriva 2006, 6.1.cvs
246
 
* Fri Aug 05 2005 Otto Dassau 6.0.1RC2
247
 
- changed prefix 
248
 
* Fri Aug 05 2005 Markus Neteler 6.0.1RC1
249
 
- updated to GRASS 6.0.1
250
 
* Fri Mar 11 2005 Markus Neteler 6.0.0-1
251
 
- updated to GRASS 6.0.0
252
 
* Tue Nov 9 2004 Markus Neteler 5.7.0-2
253
 
- GRASS 5.3 no longer required as all code moved into this repository
254
 
* Wed Jun 17 2004 Markus Neteler 5.7.0-1
255
 
- removed unixODBC, added mysql
256
 
- specfile cleanup
257
 
* Tue May 24 2004 Markus Neteler 5.7.0-1beta4
258
 
- rewritten from 5.3 specs