]> git.pld-linux.org Git - packages/cmake.git/blob - cmake.spec
39ab314b2b5e70d6d66cb120eba4a918e5a4899e
[packages/cmake.git] / cmake.spec
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???)
6 #
7 # Conditional build:
8 %bcond_with     bootstrap       # use internal versions of some libraries
9 %bcond_without  gui             # don't build gui package
10
11 Summary:        Cross-platform, open-source make system
12 Summary(pl.UTF-8):      Wieloplatformowy system make o otwartych źródłach
13 Name:           cmake
14 Version:        2.8.3
15 Release:        2
16 License:        BSD
17 Group:          Development/Building
18 Source0:        http://www.cmake.org/files/v2.8/%{name}-%{version}.tar.gz
19 # Source0-md5:  a76a44b93acf5e3badda9de111385921
20 Patch0:         %{name}-lib64.patch
21 Patch1:         %{name}-tinfo.patch
22 Patch2:         %{name}-parse.patch
23 URL:            http://www.cmake.org/
24 %{?with_gui:BuildRequires:      QtGui-devel}
25 BuildRequires:  libarchive-devel
26 BuildRequires:  libstdc++-devel
27 BuildRequires:  ncurses-devel
28 %{?with_gui:BuildRequires:      qt4-build}
29 %{?with_gui:BuildRequires:      qt4-qmake}
30 BuildRequires:  rpmbuild(macros) >= 1.167
31 %{!?with_bootstrap:BuildRequires:       xmlrpc-c-devel >= 1.4.12-2}
32 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33
34 %description
35 CMake is used to control the software compilation process using simple
36 platform and compiler independent configuration files. CMake generates
37 native makefiles and workspaces that can be used in the compiler
38 environment of your choice. CMake is quite sophisticated: it is
39 possible to support complex environments requiring system
40 configuration, pre-processor generation, code generation, and template
41 instantiation.
42
43 %description -l pl.UTF-8
44 CMake służy do sterowania procesem kompilacji oprogramowania przy
45 użyciu prostych plików konfiguracyjnych niezależnych od platformy i
46 kompilatora. CMake generuje natywne pliki makefile i workspace,
47 których można używać w wybranym środowisku kompilatora. CMake jest
48 dość wyrafinowany: może obsłużyć złożone środowiska wymagające
49 konfiguracji systemu, generowanie preprocesora, generowanie kodu i
50 dziedziczenie szablonów.
51
52 %package gui
53 Summary:        Qt GUI for CMake
54 Summary(pl.UTF-8):      Graficzny interfejs użytkownika Qt dla CMake
55 Group:          Development/Tools
56 Requires:       %{name} = %{version}-%{release}
57
58 %description gui
59 This package contains the Qt based GUI for CMake.
60
61 %description gui -l pl.UTF-8
62 Ten pakiet zawiera oparty na Qt graficzny interfejs użytkownika dla
63 CMake.
64
65 %prep
66 %setup -q
67 %if "%{_lib}" == "lib64"
68 %patch0 -p1
69 %endif
70 %patch1 -p0
71 %patch2 -p1
72
73 cat > "init.cmake" <<EOF
74 SET (CURSES_INCLUDE_PATH "/usr/include/ncurses" CACHE PATH " " FORCE)
75 EOF
76
77 %build
78 export CC="%{__cc}"
79 export CXX="%{__cxx}"
80 export CFLAGS="%{rpmcflags}"
81 export CXXFLAGS="%{rpmcxxflags}"
82 export LDFLAGS="%{rpmldflags}"
83 ./bootstrap \
84         --prefix=%{_prefix} \
85         --mandir=/share/man \
86         --datadir=/share/cmake \
87         --init=init.cmake \
88         %{!?with_bootstrap:--system-libs} \
89         %{?with_gui:--qt-gui} \
90         --qt-qmake=/usr/bin/qmake-qt4 \
91         --verbose
92
93 %{__make} VERBOSE=1
94
95 %install
96 rm -rf $RPM_BUILD_ROOT
97 install -d $RPM_BUILD_ROOT%{_libdir}/cmake
98 %{__make} install \
99         DESTDIR=$RPM_BUILD_ROOT
100
101 rm -r $RPM_BUILD_ROOT%{_prefix}/doc
102
103 %clean
104 rm -rf $RPM_BUILD_ROOT
105
106 %files
107 %defattr(644,root,root,755)
108 %doc ChangeLog.* Copyright.txt *.gif Docs/{cmake,ctest}.{txt,html}
109 %attr(755,root,root) %{_bindir}/ccmake
110 %attr(755,root,root) %{_bindir}/cmake
111 %attr(755,root,root) %{_bindir}/cpack
112 %attr(755,root,root) %{_bindir}/ctest
113 %{_mandir}/man1/ccmake.1*
114 %{_mandir}/man1/cmake.1*
115 %{_mandir}/man1/cmakecommands.1*
116 %{_mandir}/man1/cmakecompat.1*
117 %{_mandir}/man1/cmakemodules.1*
118 %{_mandir}/man1/cmakepolicies.1*
119 %{_mandir}/man1/cmakeprops.1*
120 %{_mandir}/man1/cmakevars.1*
121 %{_mandir}/man1/cpack.1*
122 %{_mandir}/man1/ctest.1*
123 %{_datadir}/cmake
124 %dir %{_libdir}/cmake
125
126 %if %{with gui}
127 %files gui
128 %defattr(644,root,root,755)
129 %attr(755,root,root) %{_bindir}/cmake-gui
130 %{_datadir}/mime/packages/cmakecache.xml
131 %{_desktopdir}/CMake.desktop
132 %{_pixmapsdir}/CMakeSetup32.png
133 %{_mandir}/man1/cmake-gui.1*
134 %endif
This page took 0.0295 seconds and 3 git commands to generate.