/[packages]/cauldron/zygrib/current/SPECS/zygrib.spec
ViewVC logotype

Contents of /cauldron/zygrib/current/SPECS/zygrib.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 89433 - (show annotations) (download)
Thu Apr 21 10:33:43 2011 UTC (10 years, 4 months ago) by grenoya
File size: 3188 byte(s)
imported package zygrib
1 %define oname zyGrib
2
3 Name: zygrib
4 Version: 3.9.2
5 Release: %mkrel 1
6 Summary: Weather data visualization, GRIB file viewer
7 License: GPLv3
8 Group: Sciences/Geosciences
9 Url: http://www.zygrib.org
10 # Sources downloaded at :
11 # http://www.zygrib.org/getfile.php?file=zyGrib-3.8.3.tgz
12 # http://www.zygrib.org/getfile.php?file=zyGrib_maps2.tgz
13 # Given the size, tarballs are extracted and recompressed using xz (tar -cJ)
14 Source0: %{oname}-%{version}.tar.xz
15 Source1: %{oname}_maps2.tar.xz
16 # From the Debian package
17 Source2: %{name}.png
18 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot
19
20 BuildRequires: qt4-devel
21 BuildRequires: proj-devel
22
23 Suggests: %{name}-maps-high
24
25 %description
26 ZyGrib is a GRIB file viewer. It enables :
27
28 o Visualisation of meteo data from files in GRIB Format 1
29 o Automatic GRIB data download
30 o Automatic Download from IAC (fleetcode) Data
31 o Roh or compressed GRIB Data (gzip *.gz; bzip2 *.bz2) can be used
32
33 %package maps-high
34 Summary: High resolution maps for %{oname}
35 Group: Sciences/Geosciences
36
37 Requires: %{name}
38
39 %description maps-high
40 This package contains maps for %{oname} in higher resolution than the ones
41 provided in the main package.
42
43 %prep
44 %setup -q -n %{oname}-%{version}
45 %setup -q -n %{oname}-%{version} -T -D -a 1
46
47 # fix paths so that the executable can be relocated in %{_bindir}
48 sed -i -e 's:"maps\/:"%{_datadir}\/%{name}\/maps\/:g' src/map/GisReader.cpp src/MainWindow.cpp
49 sed -i -e 's:"img\/:"%{_datadir}\/%{name}\/img\/:g' src/GribAnimator.cpp src/MenuBar.cpp
50 sed -i -e 's:"tr\/:"%{_datadir}\/%{name}\/tr\/:g' src/MenuBar.cpp src/main.cpp
51
52 %build
53 make QTBIN=%{qt4bin}
54
55 %install
56 rm -rf %{buildroot}
57
58 install -d -m755 %{buildroot}%{_bindir}
59 install -D -m755 src/%{oname} %{buildroot}%{_bindir}
60
61 install -d -m755 %{buildroot}%{_datadir}/%{name}/tr
62 cp -pr maps %{buildroot}%{_datadir}/%{name}
63 cp -pr img %{buildroot}%{_datadir}/%{name}
64 install -D -m644 tr/*.qm %{buildroot}%{_datadir}/%{name}/tr
65
66 # desktop file
67 install -d -m755 %{buildroot}%{_datadir}/applications
68 cat << EOF > %{buildroot}%{_datadir}/applications/%{name}.desktop
69 [Desktop Entry]
70 Name=%{oname}
71 GenericName=GRIB file viewer
72 Comment=Multi-protocol Messaging Client
73 Exec=%{_bindir}/%{oname}
74 Icon=%{name}
75 Terminal=false
76 Type=Application
77 StartupNotify=true
78 Categories=Science;Geoscience;
79 EOF
80
81 # icon
82 install -d -m755 %{buildroot}%{_datadir}/pixmaps
83 install -D -m644 %{SOURCE2} %{buildroot}%{_datadir}/pixmaps
84
85 %clean
86 rm -rf %{buildroot}
87
88 %files
89 %defattr(-,root,root,-)
90 %{_bindir}/%{oname}
91 %{_datadir}/%{name}
92 %exclude %{_datadir}/%{name}/maps/gshhs/gshhs_0.rim
93 %exclude %{_datadir}/%{name}/maps/gshhs/gshhs_1.rim
94 %exclude %{_datadir}/%{name}/maps/gshhs/rangs_0.*
95 %exclude %{_datadir}/%{name}/maps/gshhs/rangs_1.*
96 %exclude %{_datadir}/%{name}/maps/gshhs/wdb_*_f.b
97 %exclude %{_datadir}/%{name}/maps/gshhs/wdb_*_h.b
98 %{_datadir}/pixmaps/%{name}.png
99 %{_datadir}/applications/%{name}.desktop
100
101 %files maps-high
102 %defattr(-,root,root,-)
103 %{_datadir}/%{name}/maps/gshhs/gshhs_0.rim
104 %{_datadir}/%{name}/maps/gshhs/gshhs_1.rim
105 %{_datadir}/%{name}/maps/gshhs/rangs_0.*
106 %{_datadir}/%{name}/maps/gshhs/rangs_1.*
107 %{_datadir}/%{name}/maps/gshhs/wdb_*_f.b
108 %{_datadir}/%{name}/maps/gshhs/wdb_*_h.b
109
110

  ViewVC Help
Powered by ViewVC 1.1.28