]> git.pld-linux.org Git - packages/hdf.git/blob - hdf.spec
202f8e1414b9ce542d5417560ca8c69f427edb93
[packages/hdf.git] / hdf.spec
1 #
2 # Conditional build:
3 %bcond_without  szip    # build without SZIP support
4 #
5 Summary:        Hierarchical Data Format library
6 Summary(pl.UTF-8):      Biblioteka HDF (Hierarchical Data Format)
7 Name:           hdf
8 Version:        4.2.6
9 Release:        1
10 Epoch:          1
11 Group:          Libraries
12 License:        Nearly BSD, but changed sources must be marked
13 Source0:        ftp://ftp.hdfgroup.org/HDF/HDF_Current/src/hdf-%{version}.tar.bz2
14 # Source0-md5:  eed281ded7f81f6ba1a3b1b1d5109bfe
15 Source1:        http://www.mif.pg.gda.pl/homepages/ankry/man-PLD/%{name}-man-pages.tar.bz2
16 # Source1-md5:  607df78cacc131b37dfdb443e61e789a
17 Patch0:         %{name}-shared.patch
18 Patch1:         %{name}-opt.patch
19 Patch2:         %{name}-morearchs.patch
20 Patch3:         %{name}-link.patch
21 URL:            http://hdf.ncsa.uiuc.edu/
22 BuildRequires:  autoconf >= 2.50
23 BuildRequires:  automake
24 BuildRequires:  bison
25 BuildRequires:  flex
26 BuildRequires:  gcc-fortran
27 BuildRequires:  groff
28 BuildRequires:  libjpeg-devel >= 6b
29 BuildRequires:  libtool >= 2:1.4d-3
30 BuildRequires:  netcdf-devel
31 %{?with_szip:BuildRequires:     szip-devel >= 2.0}
32 BuildRequires:  which
33 BuildRequires:  zlib-devel >= 1.1.3
34 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
36 %description
37 HDF is a multi-object file format that facilitates the transfer of
38 various types of scientific data between machines and operating
39 systems. Machines currently supported include the Cray, HP, Vax, Sun,
40 IBM RS/6000, Silicon Graphics, Macintosh, and IBM PC computers. HDF
41 allows self-definitions of data content and easy extensibility for
42 future enhancements or compatibility with other standard formats. HDF
43 includes Fortran and C calling interfaces,and utilities to prepare raw
44 image of data files or for use with other NCSA software. The HDF
45 library contains interfaces for storing and retrieving compressed or
46 uncompressed 8-bit and 24-bit raster images with palettes,
47 n-Dimensional scientific datasets and binary tables. An interface is
48 also included that allows arbitray grouping of other HDF objects.
49
50 %description -l pl.UTF-8
51 HDF jest wieloobiektowym formatem plików ułatwiającym przenoszenie
52 różnych danych naukowych pomiędzy różnymi komputerami i systemami
53 operacyjnymi. Aktualnie obsługiwane są m.in. Cray, HP, Vax, Sun, IBM
54 RS/6000, Silicon Graphics, Macintosh i IBM PC. HDF zawiera interfejsy
55 do Fortranu i C oraz narzędzia do przygotowywania plików z danymi.
56 Biblioteka pozwala na przechowywanie i odczytywanie skompresowanych
57 lub nie 8-bitowych i 24-bitowych obrazków z paletą, wielowymiarowych
58 zestawów danych itp.
59
60 %package devel
61 Summary:        HDF library development package
62 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki HDF
63 Group:          Development/Libraries
64 Requires:       %{name} = %{epoch}:%{version}-%{release}
65 Requires:       libjpeg-devel >= 6b
66 %{?with_szip:Requires:  szip-devel >= 2.0}
67 Requires:       zlib-devel >= 1.1.3
68
69 %description devel
70 Header files for HDF library.
71
72 %description devel -l pl.UTF-8
73 Pliki nagłówkowe biblioteki HDF.
74
75 %package static
76 Summary:        HDF static library
77 Summary(pl.UTF-8):      Statyczna biblioteka HDF
78 Group:          Development/Libraries
79 Requires:       %{name}-devel = %{epoch}:%{version}-%{release}
80
81 %description static
82 Static version of HDF library.
83
84 %description static -l pl.UTF-8
85 Statyczna wersja biblioteki HDF.
86
87 %package progs
88 Summary:        HDF utilities
89 Summary(pl.UTF-8):      Narzędzia do plików HDF
90 Group:          Applications/File
91 Requires:       %{name} = %{epoch}:%{version}-%{release}
92
93 %description progs
94 Utilities to convert from/to HDF format.
95
96 %description progs -l pl.UTF-8
97 Narzędzia do konwersji z i do formatu HDF.
98
99 %prep
100 %setup -q
101 %patch0 -p1
102 %patch1 -p1
103 %patch2 -p1
104 %patch3 -p1
105
106 # evil -R
107 sed -i '/^if HDF_BUILD_XDR/,/^endif/d;/^if HDF_BUILD_SHARED/,/^endif/d' config/commence.am
108
109 %build
110 %{__libtoolize}
111 %{__aclocal}
112 %{__autoconf}
113 %{__autoheader}
114 %{__automake}
115 # need to pass F77 to override F77=g77 in config/linux-gnu
116 %configure \
117         F77="%{_target_cpu}-pld-linux-gfortran" \
118         --enable-shared \
119         %{?with_szip:--with-szlib}
120
121 %{__make}
122
123 %install
124 rm -rf $RPM_BUILD_ROOT
125 install -d $RPM_BUILD_ROOT{%{_mandir}/man{3,7},%{_includedir}/hdf}
126
127 %{__make} install \
128         DESTDIR=$RPM_BUILD_ROOT
129
130 mv -f $RPM_BUILD_ROOT%{_includedir}/*.{h,inc,f90} $RPM_BUILD_ROOT%{_includedir}/hdf
131
132 install man/gr_chunk.3 $RPM_BUILD_ROOT%{_mandir}/man3
133 mv -f $RPM_BUILD_ROOT%{_mandir}/man1/hdf.1 $RPM_BUILD_ROOT%{_mandir}/man7/hdf.7
134
135 # resolve conflict with netcdf
136 for i in ncdump ncgen ; do
137         mv -f $RPM_BUILD_ROOT%{_bindir}/$i $RPM_BUILD_ROOT%{_bindir}/hdf$i
138         mv -f $RPM_BUILD_ROOT%{_mandir}/man1/$i.1 $RPM_BUILD_ROOT%{_mandir}/man1/hdf$i.1
139 done
140
141 bzip2 -dc %{SOURCE1} | tar xf - -C $RPM_BUILD_ROOT%{_mandir}
142 %{__rm} $RPM_BUILD_ROOT%{_mandir}/README.hdf-man-pages
143 %{__rm} $RPM_BUILD_ROOT%{_mandir}/diff.*
144
145 %clean
146 rm -rf $RPM_BUILD_ROOT
147
148 %post   -p /sbin/ldconfig
149 %postun -p /sbin/ldconfig
150
151 %files
152 %defattr(644,root,root,755)
153 %doc COPYING README.txt release_notes/{HISTORY,RELEASE,bugs_fixed,misc_docs}.txt
154 %attr(755,root,root) %{_libdir}/libdf.so.*.*.*
155 %attr(755,root,root) %ghost %{_libdir}/libdf.so.0
156 %attr(755,root,root) %{_libdir}/libmfhdf.so.*.*.*
157 %attr(755,root,root) %ghost %{_libdir}/libmfhdf.so.0
158 %{_libdir}/libhdf4.settings
159
160 %files devel
161 %defattr(644,root,root,755)
162 %attr(755,root,root) %{_libdir}/libdf.so
163 %attr(755,root,root) %{_libdir}/libmfhdf.so
164 %{_libdir}/libdf.la
165 %{_libdir}/libmfhdf.la
166 %{_includedir}/hdf
167 %{_mandir}/man3/gr_chunk.3*
168 %{_mandir}/man7/hdf.7*
169
170 %files static
171 %defattr(644,root,root,755)
172 %{_libdir}/libdf.a
173 %{_libdir}/libmfhdf.a
174
175 %files progs
176 %defattr(644,root,root,755)
177 %attr(755,root,root) %{_bindir}/gif2hdf
178 %attr(755,root,root) %{_bindir}/h4cc
179 %attr(755,root,root) %{_bindir}/h4fc
180 %attr(755,root,root) %{_bindir}/h4redeploy
181 %attr(755,root,root) %{_bindir}/hdf24to8
182 %attr(755,root,root) %{_bindir}/hdf2gif
183 %attr(755,root,root) %{_bindir}/hdf2jpeg
184 %attr(755,root,root) %{_bindir}/hdf8to24
185 %attr(755,root,root) %{_bindir}/hdfcomp
186 %attr(755,root,root) %{_bindir}/hdfed
187 %attr(755,root,root) %{_bindir}/hdfimport
188 %attr(755,root,root) %{_bindir}/hdfls
189 %attr(755,root,root) %{_bindir}/hdfncdump
190 %attr(755,root,root) %{_bindir}/hdfncgen
191 %attr(755,root,root) %{_bindir}/hdfpack
192 %attr(755,root,root) %{_bindir}/hdftopal
193 %attr(755,root,root) %{_bindir}/hdftor8
194 %attr(755,root,root) %{_bindir}/hdfunpac
195 %attr(755,root,root) %{_bindir}/hdiff
196 %attr(755,root,root) %{_bindir}/hdp
197 %attr(755,root,root) %{_bindir}/hrepack
198 %attr(755,root,root) %{_bindir}/jpeg2hdf
199 %attr(755,root,root) %{_bindir}/paltohdf
200 %attr(755,root,root) %{_bindir}/r8tohdf
201 %attr(755,root,root) %{_bindir}/ristosds
202 %attr(755,root,root) %{_bindir}/vmake
203 %attr(755,root,root) %{_bindir}/vshow
204 %{_mandir}/man1/fp2hdf.1*
205 %{_mandir}/man1/gif2hdf.1*
206 %{_mandir}/man1/hdf24to8.1*
207 %{_mandir}/man1/hdf2gif.1*
208 %{_mandir}/man1/hdf2jpeg.1*
209 %{_mandir}/man1/hdf8to24.1*
210 %{_mandir}/man1/hdfcomp.1*
211 %{_mandir}/man1/hdfed.1*
212 %{_mandir}/man1/hdfls.1*
213 %{_mandir}/man1/hdfncdump.1*
214 %{_mandir}/man1/hdfncgen.1*
215 %{_mandir}/man1/hdfpack.1*
216 %{_mandir}/man1/hdftopal.1*
217 %{_mandir}/man1/hdftor8.1*
218 %{_mandir}/man1/hdp.1*
219 %{_mandir}/man1/jpeg2hdf.1*
220 %{_mandir}/man1/paltohdf.1*
221 %{_mandir}/man1/r8tohdf.1*
222 %{_mandir}/man1/ristosds.1*
223 %{_mandir}/man1/vmake.1*
224 %{_mandir}/man1/vshow.1*
This page took 0.038021 seconds and 3 git commands to generate.