cmake-vl.spec 6.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241
  1. # Set to bcond_without or use --with bootstrap if bootstrapping a new release
  2. # or architecture
  3. %bcond_with bootstrap
  4. # Set to bcond_with or use --without gui to disable qt4 gui build
  5. %bcond_without gui
  6. Name: cmake
  7. Summary: Cross-platform make system
  8. Summary(ja): クロスプラットフォームな Make システム
  9. Version: 2.8.12.2
  10. Release: 1%{?_dist_release}
  11. Group: Development/Tools
  12. License: BSD
  13. URL: http://www.cmake.org/
  14. Source0: http://www.cmake.org/files/v2.8/%{name}-%{version}.tar.gz
  15. Source1: macros.cmake
  16. # Patch to find DCMTK in Fedora (bug #720140)
  17. Patch0: cmake-dcmtk.patch
  18. Patch1: cmake-2.8.12.1-FindFreetype.patch
  19. # http://public.kitware.com/pipermail/cmake-developers/2014-December/024044.html
  20. Patch2: cmake-2.8.12.2-ruby-2.2.x.patch
  21. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  22. BuildRequires: curl-devel
  23. BuildRequires: expat-devel
  24. BuildRequires: gcc-gfortran
  25. BuildRequires: libarchive-devel
  26. BuildRequires: libidn-devel
  27. BuildRequires: ncurses-devel
  28. BuildRequires: openssl-devel
  29. BuildRequires: zlib-devel
  30. %if %{with gui}
  31. BuildRequires: qt4-devel, desktop-file-utils
  32. %define qt_gui --qt-gui
  33. %else
  34. %define qt_gui --no-qt-gui
  35. %endif
  36. Vendor: Project Vine
  37. Distribution: Vine Linux
  38. %description
  39. CMake is used to control the software compilation process using simple
  40. platform and compiler independent configuration files. CMake generates
  41. native makefiles and workspaces that can be used in the compiler
  42. environment of your choice. CMake is quite sophisticated: it is possible
  43. to support complex environments requiring system configuration, pre-processor
  44. generation, code generation, and template instantiation.
  45. %package gui
  46. Summary: Qt GUI for %{name}
  47. Group: Development/Tools
  48. Requires: %{name} = %{version}-%{release}
  49. Requires(post): desktop-file-utils, shared-mime-info
  50. Requires(postun): desktop-file-utils, shared-mime-info
  51. %description gui
  52. The %{name}-gui package contains the Qt based GUI for CMake.
  53. %prep
  54. %setup -q
  55. %patch0 -p1 -b .dcmtk
  56. %patch1 -p1 -b .freetype2
  57. %patch2 -p1 -b .ruby
  58. # Fixup permissions
  59. #find -name \*.h -o -name \*.cxx -print0 | xargs -0 chmod -x
  60. #fix desktop file warning
  61. sed -i 's:\(Icon=\)\(CMakeSetup32.png\):\1/usr/share/pixmaps/\2:' Source/QtDialog/CMake.desktop
  62. %build
  63. ./bootstrap \
  64. --prefix=%{_prefix} \
  65. --datadir=/share/%{name} \
  66. --mandir=/share/man \
  67. --%{?with_bootstrap:no-}system-libs \
  68. %{?qt_gui}
  69. sed -i 's/-lcurses/-lcurses -ltinfo/' Source/CMakeFiles/ccmake.dir/link.txt
  70. %if %{?_dist_release} == "vl5"
  71. sed -i 's/HAVE_SYS_WAIT_H:INTERNAL=/HAVE_SYS_WAIT_H:INTERNAL=1/' CMakeCache.txt
  72. %endif
  73. make VERBOSE=1 %{?_smp_mflags}
  74. %install
  75. rm -rf $RPM_BUILD_ROOT
  76. make install DESTDIR=$RPM_BUILD_ROOT
  77. find $RPM_BUILD_ROOT/%{_datadir}/%{name}/Modules -type f | xargs chmod -x
  78. rm -rf $RPM_BUILD_ROOT/usr/doc
  79. # RPM macros
  80. install -p -m0644 -D %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/rpm/macros.cmake
  81. sed -i -e "s|@@CMAKE_VERSION@@|%{version}|" $RPM_BUILD_ROOT%{_sysconfdir}/rpm/macros.cmake
  82. touch -r %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/rpm/macros.cmake
  83. %if %{with gui}
  84. # Desktop file
  85. desktop-file-install --delete-original \
  86. --dir=$RPM_BUILD_ROOT%{_datadir}/applications \
  87. $RPM_BUILD_ROOT/%{_datadir}/applications/CMake.desktop
  88. %endif
  89. %clean
  90. rm -rf $RPM_BUILD_ROOT
  91. %if %{with gui}
  92. %post gui
  93. update-desktop-database &> /dev/null || :
  94. update-mime-database %{_datadir}/mime &> /dev/null || :
  95. %postun gui
  96. update-desktop-database &> /dev/null || :
  97. update-mime-database %{_datadir}/mime &> /dev/null || :
  98. %endif
  99. %files
  100. %defattr(-,root,root)
  101. %doc CMakeLogo.gif ChangeLog.* Copyright.txt
  102. %doc Docs/*
  103. %doc Example/
  104. %config(noreplace) %{_sysconfdir}/rpm/macros.cmake
  105. %{_bindir}/ccmake
  106. %{_bindir}/cmake
  107. %{_bindir}/cpack
  108. %{_bindir}/ctest
  109. %{_datadir}/%{name}/
  110. %{_datadir}/aclocal/cmake.m4
  111. %{_mandir}/man1/*
  112. %if %{with gui}
  113. %files gui
  114. %defattr(-,root,root,-)
  115. %{_bindir}/cmake-gui
  116. %{_datadir}/applications/CMake.desktop
  117. %{_datadir}/mime/packages/cmakecache.xml
  118. %{_datadir}/pixmaps/CMakeSetup32.png
  119. %endif
  120. %changelog
  121. * Sat Sep 12 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.8.12.2-1
  122. - update to 2.8.12.2
  123. - add Patch2 (cmake-2.8.12.2-ruby-2.2.x.patch)
  124. * Sun Jul 06 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.8.12.1-2
  125. - rebuild with libarchive-3.1.2
  126. * Mon Dec 23 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.8.12.1-1
  127. - new upstream release
  128. - add Patch1 (cmake-2.8.12.1-FindFreetype.patch)
  129. * Sun Jul 07 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.8.11.2-1
  130. - new upstream release
  131. * Wed Jun 05 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.8.11-1
  132. - new upstream release
  133. * Mon Apr 29 2013 Toshiharu Kudoh <toshi.kd2@gmail.com> 2.8.10.2-1
  134. - new upstream release
  135. - fixed desktop file warning
  136. * Sun Jun 10 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.8.6-2
  137. - rebuild with libarchive-3.0.4
  138. * Sat Nov 19 2011 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.8.6-1
  139. - new upstream release
  140. - forced to link with libtinfo.so (ccmake)
  141. - used --system-libs again
  142. * Sat Jan 8 2011 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.8.3-1
  143. - new upstream release
  144. - used --no-system-libs, removed BR: curl-devel, expat-devel, zlib-devel
  145. * Sun Sep 5 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.8.2-4
  146. - fixed typo (not --with-system-libs, but --system-libs)
  147. - added BR: curl-devel, expat-devel, zlib-devel
  148. * Mon Aug 23 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.8.2-3
  149. - add BuildRequires: ncurses-devel
  150. * Sun Aug 22 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.8.2-2
  151. - generate gui package
  152. - renamed module directory
  153. * Sun Jul 25 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.8.2-1
  154. - new upstream release
  155. * Fri Feb 05 2010 Shu KONNO <owa@bg.wakwak.com> 2.6.4-3
  156. - rebuilt with new toolchain
  157. * Sun Aug 30 2009 NAKAMURA Kenta <kenta@vinelinux.org> 2.6.4-2
  158. - imported RPM macros from Fedora (cmake-2.6.4-3.fc12)
  159. * Tue Aug 25 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.6.4-1
  160. - new upstream release
  161. - added Vendor/Distribution tag
  162. * Wed Mar 25 2009 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 2.6.3-1
  163. - new upstream release
  164. * Tue Oct 21 2008 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 2.6.2-1
  165. - new upstream release
  166. * Sat Mar 29 2008 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 2.4.8-1
  167. - new upstream release
  168. * Wed Aug 15 2007 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 2.4.7-0vl1
  169. - new upstream release
  170. * Mon May 14 2007 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 2.4.6-0vl1
  171. - new upstream release
  172. - drop Patch100
  173. - use bootstrap script instead of configure
  174. - delete caches from %%doc
  175. * Sat May 12 2007 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 2.4.3-0vl2
  176. - rebuilt with new toolchain
  177. * Tue Oct 31 2006 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 2.4.3-0vl1
  178. - new upstream release
  179. - delete duped docs
  180. * Fri Oct 13 2006 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 2.2.3-0vl2
  181. - added Patch100 (especially for ppc to solve ppc/powerpc issue)
  182. * Mon Feb 06 2006 Seiya Nishizawa <seiya@kugi.kyoto-u.ac.jp> 2.2.3-0vl1
  183. - source version up
  184. * Sun Mar 20 2005 Seiya Nishizawa <seiya@kugi.kyoto-u.ac.jp> 2.0.5-0vl1
  185. - initial build for Vine Linux