avogadro-vl.spec 7.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236
  1. %define _qt4_version %(pkg-config --modversion --silence-errors Qt 2>/dev/null || echo 4.6.3)
  2. %define _qt4_prefix %(pkg-config --variable prefix --silence-errors Qt 2>/dev/null || echo %{_libdir}/qt-%{qt4_ver})
  3. %define ENABLE_TESTS -DENABLE_TESTS:BOOL=ON
  4. Name: avogadro
  5. Summary: An advanced molecular editor for chemical purposes
  6. Version: 1.0.1
  7. Release: 5%{?_dist_release}
  8. Group: Applications/Editors
  9. License: GPLv2
  10. URL: http://avogadro.openmolecules.net/
  11. Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.bz2
  12. BuildRequires: cmake >= 2.6.0
  13. BuildRequires: qt4-designer >= 4.5.1
  14. BuildRequires: qt4-devel >= 4.5.1
  15. BuildRequires: eigen2-devel >= 2.0.3
  16. BuildRequires: openbabel-devel >= 2.2.2
  17. BuildRequires: libboost-devel >= 1.35
  18. BuildRequires: glew-devel >= 1.5.0
  19. BuildRequires: desktop-file-utils
  20. BuildRequires: docbook-utils
  21. BuildRequires: sip-devel
  22. BuildRequires: numpy
  23. Requires: %{name}-libs = %{version}-%{release}
  24. %description
  25. An advanced molecular editor designed for
  26. cross-platform use in computational chemistry,
  27. molecular modeling, bioinformatics, materials science,
  28. and related areas, which offers flexible rendering and
  29. a powerful plugin architecture.
  30. %package libs
  31. Summary: Shared libraries for Avogadro
  32. Group: System Environment/Libraries
  33. Requires: sip
  34. %description libs
  35. This package contains the shared libraries for the
  36. molecular editor Avogadro.
  37. %package devel
  38. Summary: Development files for Avogadro
  39. Group: Development/Libraries
  40. Requires: %{name}-libs = %{version}-%{release}
  41. Requires: qt4-devel
  42. %description devel
  43. This package contains files to develop applications using
  44. Avogadros libraries.
  45. %prep
  46. %setup -q
  47. # nuke unpatched copy, use working version included in cmake instead -- Rex
  48. rm -f cmake/modules/FindPythonLibs.cmake
  49. %build
  50. mkdir -p %{_target_platform}
  51. pushd %{_target_platform}
  52. cmake -Wno-dev \
  53. -DCMAKE_INSTALL_PREFIX:PATH=%{_prefix} \
  54. -DBIN_INSTALL_DIR:PATH=bin \
  55. -DLIB_INSTALL_DIR:PATH=%{_lib} \
  56. -DENABLE_GLSL:BOOL=ON \
  57. -DENABLE_PYTHON:BOOL=ON \
  58. %{?ENABLE_TESTS} ..
  59. popd
  60. make %{?_smp_mflags} -C %{_target_platform}
  61. %install
  62. rm -rf $RPM_BUILD_ROOT
  63. make install/fast DESTDIR=$RPM_BUILD_ROOT -C %{_target_platform}
  64. %check
  65. desktop-file-validate $RPM_BUILD_ROOT%{_datadir}/applications/avogadro.desktop
  66. # all of these currently require an active X session, so will fail
  67. # in mock
  68. %{?ENABLE_TESTS:make test -C %{_target_platform} ||:}
  69. %post libs -p /sbin/ldconfig
  70. %postun libs -p /sbin/ldconfig
  71. %files
  72. %defattr(-,root,root,-)
  73. %doc AUTHORS ChangeLog COPYING
  74. %{_bindir}/avogadro
  75. %{_bindir}/avopkg
  76. # TODO: %lang'ify stuff under %%{_datadir}/avogadro/i18n/
  77. %{_datadir}/avogadro/
  78. %{_datadir}/pixmaps/avogadro-icon.png
  79. %{_datadir}/applications/avogadro.desktop
  80. %{_mandir}/man1/avogadro.1*
  81. %{_mandir}/man1/avopkg.1*
  82. %files devel
  83. %defattr(-,root,root,-)
  84. %{_includedir}/avogadro/
  85. %{_libdir}/libavogadro.so
  86. %{_libdir}/avogadro/*.cmake
  87. %{_libdir}/avogadro/1_0/*.cmake
  88. # these look like dups of system copies?, take a closer look and/or ask upstream -- Rex
  89. %{_libdir}/avogadro/1_0/cmake/
  90. %{_qt4_prefix}/mkspecs/features/avogadro.prf
  91. %files libs
  92. %defattr(-,root,root,-)
  93. %{python_sitelib}/Avogadro.so
  94. %{_datadir}/libavogadro/
  95. %{_libdir}/libavogadro.so.1*
  96. %dir %{_libdir}/avogadro/
  97. %dir %{_libdir}/avogadro/1_0/
  98. %{_libdir}/avogadro/1_0/colors/
  99. %{_libdir}/avogadro/1_0/extensions/
  100. %{_libdir}/avogadro/1_0/engines/
  101. %{_libdir}/avogadro/1_0/tools/
  102. %changelog
  103. * Tue Jan 18 2011 Shu KONNO <owa@bg.wakwak.com> - 1.0.1-5
  104. - rebuilt with libboost-1.45.0
  105. * Fri Aug 20 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 1.0.1-4
  106. - Initial build for Vine Linux
  107. * Wed Aug 04 2010 Rahul Sundaram <sundaram@fedoraproject.org> - 1.0.1-3
  108. - Rebuild for Boost soname bump
  109. - Update to match current guidelines
  110. * Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 1.0.1-2
  111. - Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
  112. * Mon May 24 2010 Rex Dieter <rdieter@fedoraproject.org> - 1.0.1-1
  113. - avogadro-1.0.1
  114. - -devel: move cmake-related files here
  115. - -devel: Req: qt4-devel
  116. - %%files: track lib sonames
  117. - %%check section
  118. * Wed Feb 10 2010 Kevin Kofler <Kevin@tigcc.ticalc.org> - 1.0.0-6
  119. - reenable plugin builds and libs subpackage
  120. - fix their build with sip 4.10
  121. * Fri Jan 08 2010 Sebastian Dziallas <sebastian@when.com> - 1.0.0-5
  122. - disable plugin builds and libs subpackage
  123. * Thu Jan 07 2010 Rex Dieter <rdieter@fedoraproject.org> - 1.0.0-4
  124. - rebuild (sip)
  125. * Mon Nov 23 2009 Rex Dieter <rdieter@fedoraproject.org> - 1.0.0-3
  126. - rebuild (for qt-4.6.0-rc1, f13+)
  127. * Mon Nov 16 2009 Rex Dieter <rdieter@fedoraproject.org> - 1.0.0-2
  128. - -libs: Requires: sip-api(%%_sip_api_major) >= %%_sip_api (#538124)
  129. - Requires: %%{name}-libs ...
  130. * Thu Oct 29 2009 Sebastian Dziallas <sebastian@when.com> 1.0.0-1
  131. - update to new upstream release
  132. * Tue Oct 20 2009 Rex Dieter <rdieter@fedoraproject.org> 0.9.8-3
  133. - rebuild (eigen2)
  134. * Sat Sep 26 2009 Sebastian Dziallas <sebastian@when.com> 0.9.8-2
  135. - fix typo in file list
  136. * Sat Sep 26 2009 Sebastian Dziallas <sebastian@when.com> 0.9.8-1
  137. - update to new upstream release
  138. - enable python and glsl support again
  139. * Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.6-2
  140. - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
  141. * Sat Jun 06 2009 Sebastian Dziallas <sebastian@when.com> 0.9.6-1
  142. - new upstream release to fix issue with qt 4.5.0 and earlier
  143. * Wed Jun 03 2009 Sebastian Dziallas <sebastian@when.com> 0.9.5-3
  144. - remove remaining python parts
  145. - fix files section finally
  146. * Wed Jun 03 2009 Sebastian Dziallas <sebastian@when.com> 0.9.5-2
  147. - disable python and glsl for now
  148. - fix files section
  149. * Wed Jun 03 2009 Sebastian Dziallas <sebastian@when.com> 0.9.5-1
  150. - update to new release
  151. * Tue May 12 2009 Sebastian Dziallas <sebastian@when.com> 0.9.4-1
  152. - update to new release
  153. * Fri Apr 10 2009 Sebastian Dziallas <sebastian@when.com> 0.9.3-1
  154. - update to new release
  155. * Sat Mar 21 2009 Sebastian Dziallas <sebastian@when.com> 0.9.2-2
  156. - get desktop file properly installed
  157. * Sat Mar 14 2009 Sebastian Dziallas <sebastian@when.com> 0.9.2-1
  158. - update to new release
  159. * Wed Feb 25 2009 Sebastian Dziallas <sebastian@when.com> 0.9.1-1
  160. - update to new release
  161. * Mon Feb 23 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.0-2
  162. - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
  163. * Thu Jan 22 2009 Sebastian Dziallas <sebastian@when.com> 0.9.0-1
  164. - update to new release
  165. * Sun Sep 14 2008 Sebastian Dziallas <sebastian@when.com> 0.8.1-6
  166. - add handbook to docs
  167. * Sun Sep 14 2008 Sebastian Dziallas <sebastian@when.com> 0.8.1-5
  168. - add build requirements and fix group names
  169. * Wed Aug 13 2008 Sebastian Dziallas <sebastian@when.com> 0.8.1-4
  170. - fix typos
  171. * Sat Aug 9 2008 Sebastian Dziallas <sebastian@when.com> 0.8.1-3
  172. - reorganize spec file
  173. * Sat Aug 9 2008 Sebastian Dziallas <sebastian@when.com> 0.8.1-2
  174. - rename shared library package and structure spec file
  175. * Sun Aug 3 2008 Sebastian Dziallas <sebastian@when.com> 0.8.1-1
  176. - initial pacakging release based on PackMan release