cfitsio-vl.spec 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321
  1. Name: cfitsio
  2. Version: 3.370
  3. Release: 1%{?_dist_release}
  4. Summary: Library for manipulating FITS data files
  5. Summary(ja): FITS データファイルを処理するためのライブラリ
  6. Group: System Environment/Libraries
  7. License: MIT
  8. URL: http://heasarc.gsfc.nasa.gov/docs/software/fitsio/fitsio.html
  9. Source0: ftp://heasarc.gsfc.nasa.gov/software/fitsio/c/cfitsio3370.tar.gz
  10. # Unbundles zlib
  11. Patch0: cfitsio-zlib.patch
  12. # Remove soname version check
  13. Patch1: cfitsio-noversioncheck.patch
  14. # Some rearrangements in pkg-config file
  15. Patch2: cfitsio-pkgconfig.patch
  16. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  17. BuildRequires: gcc-gfortran
  18. BuildRequires: bzip2-devel
  19. BuildRequires: zlib-devel
  20. Requires(post): /sbin/ldconfig
  21. Requires(postun): /sbin/ldconfig
  22. %description
  23. CFITSIO is a library of C and FORTRAN subroutines for reading and writing
  24. data files in FITS (Flexible Image Transport System) data format. CFITSIO
  25. simplifies the task of writing software that deals with FITS files by
  26. providing an easy to use set of high-level routines that insulate the
  27. programmer from the internal complexities of the FITS file format. At the
  28. same time, CFITSIO provides many advanced features that have made it the
  29. most widely used FITS file programming interface in the astronomical
  30. community.
  31. %package devel
  32. Summary: Headers required when building programs against cfitsio
  33. Summary(ja): cfitsio を用いるプログラムのビルドに必要なヘッダファイル
  34. Group: Development/Libraries
  35. Requires: %{name} = %{version}-%{release}
  36. Requires: pkgconfig
  37. %description devel
  38. Headers required when building a program against the cfitsio library.
  39. %package static
  40. Summary: Static cfitsio library
  41. Summary(ja): cfitsio の静的ライブラリ
  42. Group: Development/Libraries
  43. Requires: %{name}-devel = %{version}-%{release}
  44. %description static
  45. Static cfitsio library; avoid use if possible.
  46. %package docs
  47. Summary: Documentation for cfitsio
  48. Summary(ja): cfitsio のドキュメント
  49. Group: Documentation
  50. BuildArch: noarch
  51. %description docs
  52. Stand-alone documentation for cfitsio.
  53. %package -n fpack
  54. Summary: FITS image compression and decompression utilities
  55. Group: Applications/Engineering
  56. Requires: %{name} = %{version}-%{release}
  57. %description -n fpack
  58. fpack optimally compresses FITS format images and funpack restores them
  59. to the original state.
  60. * Integer format images are losslessly compressed using the Rice
  61. compression algorithm.
  62. * typically 30% better compression than GZIP
  63. * about 3 times faster compression speed than GZIP
  64. * about the same uncompression speed as GUNZIP
  65. * Floating-point format images are compressed with a lossy algorithm
  66. * truncates the image pixel noise by a user-specified amount to
  67. produce much higher compression than by lossless techniques
  68. * the precision of scientific measurements in the compressed image
  69. (relative to those in the original image) depends on the selected
  70. amount of compression
  71. %prep
  72. %setup -q -n cfitsio
  73. %patch0 -p1
  74. %patch1 -p1
  75. %patch2 -p1
  76. # remove bundled zlib
  77. # not all the files inside zlib belong to zlib
  78. pushd zlib
  79. rm adler32.c crc32.c deflate.c infback.c inffast.c inflate.c inflate.h \
  80. inftrees.c inftrees.h zlib.h deflate.h trees.c trees.h uncompr.c zconf.h \
  81. zutil.c zutil.h crc32.h inffast.h inffixed.h
  82. popd
  83. %build
  84. %configure \
  85. --enable-reentrant \
  86. %ifarch x86_64
  87. --enable-sse2 \
  88. %endif
  89. --with-bzip2
  90. make shared %{?_smp_mflags}
  91. make fpack %{?_smp_mflags}
  92. make funpack %{?_smp_mflags}
  93. %check
  94. make testprog
  95. LD_LIBRARY_PATH=. ./testprog > testprog.lis
  96. cmp -s testprog.lis testprog.out
  97. cmp -s testprog.fit testprog.std
  98. %install
  99. rm -rf %{buildroot}
  100. mkdir -p %{buildroot}
  101. mkdir -p %{buildroot}%{_bindir}
  102. mkdir -p %{buildroot}%{_libdir}
  103. mkdir -p %{buildroot}%{_includedir}/%{name}
  104. make LIBDIR=%{_lib} INCLUDEDIR=include/%{name} \
  105. CFITSIO_LIB=%{buildroot}%{_libdir} \
  106. CFITSIO_INCLUDE=%{buildroot}%{_includedir}/%{name} install
  107. cp -p f{,un}pack %{buildroot}%{_bindir}
  108. chmod 755 %{buildroot}%{_libdir}/libcfitsio.so.*
  109. chmod 755 %{buildroot}%{_bindir}/f{,un}pack
  110. %clean
  111. rm -rf %{buildroot}
  112. %post -p /sbin/ldconfig
  113. %postun -p /sbin/ldconfig
  114. %files
  115. %defattr(-,root,root,-)
  116. %doc README License.txt docs/changes.txt
  117. %{_libdir}/libcfitsio.so.*
  118. %files devel
  119. %defattr(-,root,root,-)
  120. %{_includedir}/%{name}
  121. %{_libdir}/libcfitsio.so
  122. %{_libdir}/pkgconfig/cfitsio.pc
  123. %files static
  124. %defattr(-,root,root,-)
  125. %{_libdir}/libcfitsio.a
  126. %files docs
  127. %defattr(-,root,root,-)
  128. %doc docs/fitsio.doc docs/fitsio.pdf docs/cfitsio.doc docs/cfitsio.pdf License.txt
  129. %files -n fpack
  130. %defattr(-,root,root,-)
  131. %doc docs/fpackguide.pdf License.txt
  132. %{_bindir}/fpack
  133. %{_bindir}/funpack
  134. %changelog
  135. * Tue Feb 24 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> - 3.370-1
  136. - new upstream release
  137. - moved docs subpackages to Documentation Group
  138. * Sat Sep 3 2011 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 3.280-1
  139. - new upstream release
  140. - added Patch1
  141. * Mon Sep 27 2010 Shu KONNO <owa@bg.wakwak.com> 3.240-2
  142. - rebuilt with rpm-4.8.1 for pkg-config
  143. * Thu Apr 15 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 3.240-1
  144. - new upstream release
  145. * Sun Aug 30 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 3.140-3
  146. - Initial build for Vine Linux
  147. * Fri Jul 24 2009 Matthew Truch <matt at truch.net> - 3.140-2
  148. - Bump to include proper tarball.
  149. * Tue Jul 21 2009 Matthew Truch <matt at truch.net> - 3.140-1
  150. - Update to upstream 3.140 release.
  151. - Bump for mass rebuild.
  152. * Wed Jun 17 2009 Matthew Truch <matt at truch.net> - 3.130-5
  153. - Separate -docs noarch subpackage as per BZ 492438.
  154. - Explicitly set file attributes correctly.
  155. * Tue Mar 10 2009 Matthew Truch <matt at truch.net> - 3.130-4
  156. - Set correct version in pkgconfig .pc file.
  157. * Sun Feb 22 2009 Matthew Truch <matt at truch.net> - 3.130-3
  158. - Re-check testprogram output.
  159. - Build for koji, rpm, gcc upgrade.
  160. * Thu Feb 5 2009 Matthew Truch <matt at truch.net> - 3.130-2
  161. - Fix source file naming typo.
  162. * Wed Feb 4 2009 Matthew Truch <matt at truch.net> - 3.130-1
  163. - Update to 3.130 upstream.
  164. * Sat Sep 20 2008 Matthew Truch <matt at truch.net> - 3.100-2
  165. - Test library with included test-suite.
  166. * Fri Sep 19 2008 Matthew Truch <matt at truch.net> - 3.100-1
  167. - Update to 3.100 upstream.
  168. Includes bugfixes and new compression scheme.
  169. * Fri Mar 7 2008 Matthew Truch <matt at truch.net> - 3.060-3
  170. - Properly indicated include and lib directories in .pc file
  171. (BZ 436539)
  172. - Fix typo in -static descrition.
  173. * Mon Feb 11 2008 Matthew Truch <matt at truch.net> - 3.060-2
  174. - Bump release for rebuild.
  175. * Fri Nov 9 2007 Matthew Truch <matt at truch.net> - 3.060-1
  176. - Update to 3.060 bugfix release.
  177. - Add static package (BZ 372801)
  178. * Tue Aug 21 2007 Matthew Truch <matt at truch.net> - 3.040-3
  179. - Bump release for rebuild (build-id etc.)
  180. * Thu Aug 2 2007 Matthew Truch <matt at truch.net> - 3.040-2
  181. - Update License tag
  182. * Mon Jul 9 2007 Matthew Truch <matt at truch.net> - 3.040-1
  183. - Upgrade to version 3.040 of cfitsio.
  184. * Fri Feb 16 2007 Matthew Truch <matt at truch.net> - 3.030-2
  185. - Require pkgconfig for -devel.
  186. - export CC=gcc so we don't clobber $RPM_OPT_FLAGS, thereby
  187. ruining any -debuginfo packages.
  188. See RedHat Bugzilla 229041.
  189. * Fri Jan 5 2007 Matthew Truch <matt at truch.net> - 3.030-1
  190. - Upgrade to version 3.020 of cfitsio.
  191. * Fri Dec 8 2006 Matthew Truch <matt at truch.net> - 3.020-3
  192. - Commit correct patch to configure and Makefiles.
  193. * Fri Dec 8 2006 Matthew Truch <matt at truch.net> - 3.020-2
  194. - Modify spec file to install to correct directories.
  195. - Package cfitsio.pc file in -devel package.
  196. * Wed Dec 6 2006 Matthew Truch <matt at truch.net> - 3.020-1
  197. - Upgrade to revision 3.020 of cfitsio.
  198. * Mon Aug 28 2006 Matthew Truch <matt at truch.net> - 3.006-6
  199. - Bump release for rebuild in prep. for FC6.
  200. * Thu Mar 30 2006 Matthew Truch <matt at truch.net> - 3.006-5
  201. - Include defattr() for devel package as well - bug 187366
  202. * Sun Mar 19 2006 Matthew Truch <matt at truch.net> - 3.006-4
  203. - Don't use macro {buildroot} in build, only in install as per
  204. appended comments to Bugzilla bug 172042
  205. * Fri Mar 10 2006 Matthew Truch <matt at truch.net> - 3.006-3
  206. - Point to f95 instead of g95 as per bugzilla bug 185107
  207. * Tue Feb 28 2006 Matthew Truch <matt at truch.net> - 3.006-2
  208. - Fix spelling typo in name of License.txt file.
  209. * Tue Feb 28 2006 Matthew Truch <matt at truch.net> - 3.006-1
  210. - Use new 3.006 fully official stable (non-beta) upstream package.
  211. * Tue Feb 28 2006 Matthew Truch <matt at truch.net> - 3.005-0.2.beta
  212. - Bump release for FC5 extras rebuild.
  213. * Fri Dec 23 2005 Matthew Truch <matt at truch.net> - 3.005-0.1.beta
  214. - Update to 3.005beta release.
  215. * Mon Nov 14 2005 Matthew Truch <matt at truch.net> - 3.004-0.12.b
  216. - Put in proper URL and Source addresses.
  217. - Sync up spec files.
  218. * Sun Nov 13 2005 Matthew Truch <matt at truch.net> - 3.004-0.11.b
  219. - Clean up unused code in spec file.
  220. * Sun Nov 13 2005 Matthew Truch <matt at truch.net> - 3.004-0.10.b
  221. - Set environment variables correctly.
  222. - Include patch so Makefile will put things where they belong.
  223. * Sun Nov 13 2005 Matthew Truch <matt at truch.net> - 3.004-0.9.b
  224. - Set libdir and includedir correctly for build process.
  225. * Sat Nov 12 2005 Matthew Truch <matt at truch.net> - 3.004-0.8.b
  226. - unset FC once we are done with the build
  227. * Sat Nov 12 2005 Ed Hill <ed@eh3.com> - 3.004-0.7.b
  228. - shared libs and small cleanups
  229. * Sun Nov 06 2005 Matthew Truch <matt at truch.net> - 3.004-0.6.b
  230. - Own include directory created by the devel package.
  231. * Sun Nov 06 2005 Matthew Truch <matt at truch.net> - 3.004-0.5.b
  232. - Shorten summary.
  233. - Improve specfile post and postun syntax.
  234. - Install headers in cfitsio include subdir.
  235. - Include more documentation provided in tarball.
  236. * Sun Nov 06 2005 Matthew Truch <matt at truch.net> - 3.004-0.4.b
  237. - Require cfitsio for cfitsio-devel
  238. * Sat Nov 05 2005 Matthew Truch <matt at truch.net> - 3.004-0.3.b
  239. - Use proper virgin tarball from upstream.
  240. * Sun Oct 30 2005 Matthew Truch <matt at truch.net> - 3.004-0.2.b
  241. - Include gcc-gfortran build requirment and make sure it gets used.
  242. - Use macros instead of hard coded paths.
  243. - Include home page in description
  244. * Sat Oct 29 2005 Matthew Truch <matt at truch.net> - 3.004-0.1.b
  245. - Initial spec file for Fedora Extras.