]>
Commit | Line | Data |
---|---|---|
d1b2e54c JB |
1 | # TODO: |
2 | # - any valid CMAKE_BUILD_TYPE causes overriding of our optflags | |
3 | # (and default non-verbose makefiles are hiding it!) | |
4 | # - rpmldflags/rpmcppflags are not passed through %%cmake macro at all | |
5 | # (is there any standard way???) | |
ccca321d KK |
6 | # |
7 | # Conditional build: | |
8 | %bcond_with bootstrap # use internal versions of some libraries | |
33042d59 | 9 | %bcond_without gui |
ccca321d | 10 | # |
efafbc62 | 11 | Summary: Cross-platform, open-source make system |
ac3ea35a | 12 | Summary(pl.UTF-8): Wieloplatformowy system make o otwartych źródłach |
72a696fa | 13 | Name: cmake |
3b68706f | 14 | Version: 2.6.1 |
6342daf8 | 15 | Release: 2 |
efafbc62 | 16 | License: BSD |
72a696fa | 17 | Group: Development/Building |
ccca321d | 18 | Source0: http://www.cmake.org/files/v2.6/%{name}-%{version}.tar.gz |
3b68706f | 19 | # Source0-md5: 6717f4bc3cfcced4172ad98660ce7599 |
6342daf8 | 20 | Patch0: %{name}-lib64.patch |
21 | Patch1: %{name}-ar.patch | |
22 | URL: http://www.cmake.org/HTML/ | |
33042d59 | 23 | %{?with_gui:BuildRequires: QtGui-devel} |
ece9e155 KK |
24 | BuildRequires: libstdc++-devel |
25 | BuildRequires: ncurses-devel | |
33042d59 KK |
26 | %{?with_gui:BuildRequires: qt4-build} |
27 | %{?with_gui:BuildRequires: qt4-qmake} | |
ece9e155 | 28 | BuildRequires: rpmbuild(macros) >= 1.167 |
c342f103 | 29 | %{!?with_bootstrap:BuildRequires: xmlrpc-c-devel} |
efafbc62 | 30 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
3fcbc09a AG |
31 | |
32 | %description | |
efafbc62 AG |
33 | CMake is used to control the software compilation process using simple |
34 | platform and compiler independent configuration files. CMake generates | |
35 | native makefiles and workspaces that can be used in the compiler | |
36 | environment of your choice. CMake is quite sophisticated: it is | |
37 | possible to support complex environments requiring system | |
38 | configuration, pre-processor generation, code generation, and template | |
39 | instantiation. | |
3fcbc09a | 40 | |
520c9eb8 JR |
41 | %description -l pl.UTF-8 |
42 | CMake służy do sterowania procesem kompilacji oprogramowania przy | |
485d9a7a KK |
43 | użyciu prostych plików konfiguracyjnych niezależnych od platformy |
44 | i kompilatora. CMake generuje natywne pliki makefile i workspace, | |
45 | których można używać w wybranym środowisku kompilatora. CMake jest | |
46 | dość przemyślany: może obsłużyć złożone środowiska wymagające | |
47 | konfiguracji systemu, generowanie preprocesora, generowanie kodu | |
48 | i dziedziczenie szablonów. | |
33042d59 KK |
49 | |
50 | %package gui | |
51 | Summary: Qt GUI for %{name} | |
52 | Group: Development/Tools | |
53 | Requires: %{name} = %{version}-%{release} | |
54 | ||
55 | %description gui | |
56 | The %{name}-gui package contains the Qt based GUI for CMake. | |
72a696fa | 57 | |
3fcbc09a | 58 | %prep |
923851a2 | 59 | %setup -q |
286b1479 | 60 | %if "%{_lib}" == "lib64" |
6342daf8 | 61 | %patch0 -p1 |
286b1479 | 62 | %endif |
6342daf8 | 63 | %patch1 -p0 |
3fcbc09a | 64 | |
ece9e155 | 65 | cat > "init.cmake" <<EOF |
286b1479 | 66 | SET (CURSES_INCLUDE_PATH "/usr/include/ncurses" CACHE PATH " " FORCE) |
ece9e155 KK |
67 | EOF |
68 | ||
3fcbc09a | 69 | %build |
ece9e155 KK |
70 | export CC="%{__cc}" |
71 | export CXX="%{__cxx}" | |
72 | export CFLAGS="%{rpmcflags}" | |
73 | export CXXFLAGS="%{rpmcxxflags}" | |
ccca321d | 74 | export LDFLAGS="%{rpmldflags}" |
923851a2 AG |
75 | ./bootstrap \ |
76 | --prefix=%{_prefix} \ | |
77 | --mandir=/share/man \ | |
78 | --datadir=/share/cmake \ | |
ece9e155 | 79 | --init=init.cmake \ |
c342f103 | 80 | %{!?with_bootstrap:--system-libs} \ |
33042d59 | 81 | %{?with_gui:--qt-gui} \ |
923851a2 AG |
82 | --verbose |
83 | ||
923851a2 | 84 | %{__make} |
3fcbc09a AG |
85 | |
86 | %install | |
efafbc62 | 87 | rm -rf $RPM_BUILD_ROOT |
72a696fa JB |
88 | |
89 | %{__make} install \ | |
90 | DESTDIR=$RPM_BUILD_ROOT | |
91 | ||
c4bbee29 | 92 | rm -rf $RPM_BUILD_ROOT%{_prefix}/doc |
3fcbc09a AG |
93 | |
94 | %clean | |
95 | rm -rf $RPM_BUILD_ROOT | |
96 | ||
97 | %files | |
efafbc62 | 98 | %defattr(644,root,root,755) |
51ed65c6 | 99 | %doc ChangeLog.* Copyright.txt *.gif Docs/{cmake,ctest}.{txt,html} |
72a696fa JB |
100 | %attr(755,root,root) %{_bindir}/ccmake |
101 | %attr(755,root,root) %{_bindir}/cmake | |
08b6790a | 102 | %attr(755,root,root) %{_bindir}/cpack |
72a696fa JB |
103 | %attr(755,root,root) %{_bindir}/ctest |
104 | %{_mandir}/man1/*.1* | |
923851a2 | 105 | %{_datadir}/cmake |
33042d59 KK |
106 | |
107 | %files gui | |
108 | %defattr(644,root,root,755) | |
109 | %attr(755,root,root) %{_bindir}/cmake-gui | |
110 | %{_datadir}/mime/packages/cmakecache.xml | |
111 | %{_desktopdir}/CMake.desktop | |
112 | %{_pixmapsdir}/CMakeSetup.png |