SHA256
3
0
forked from pool/cmake
cmake/cmake.spec

132 lines
3.4 KiB
RPMSpec
Raw Normal View History

#
# spec file for package cmake (Version 2.8.0+2.8.1rc3)
#
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
# norootforbuild
Name: cmake
Version: 2.8.0+2.8.1rc3
Release: 1
License: BSD3c
Group: Development/Tools/Building
%define tar_version 2.8.1-rc3
Url: http://www.cmake.org/
Source0: %{name}-%{tar_version}.tar.bz2
Patch4: cmake-disable-builtin-chrpath.diff
Patch5: fortify-buffer-overflows.diff
Summary: Cross-platform, open-source make system
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%if 0%{?suse_version} > 1020
BuildRequires: fdupes libexpat-devel libqt4-devel update-desktop-files
%endif
BuildRequires: curl-devel expat gcc-c++ ncurses-devel openssl-devel zlib-devel
Requires: make
%description
CMake is a cross-platform, open-source make system
Authors:
--------
Kitware, Inc., Insight Consortium
%if 0%{?suse_version} > 1020
%package gui
License: BSD3c
Summary: CMake Graphical User Interface
Group: Development/Tools/Building
%description gui
This is a Graphical User Interface for CMake, a cross-platform,
open-source make system.
Authors:
--------
Kitware, Inc., Insight Consortium
%endif
%prep
%setup -q -n %name-%tar_version
%patch4
%patch5
%build
EXTRA_FLAGS=""
%if 0%{?suse_version} > 1020
EXTRA_FLAGS="--qt-gui"
%endif
export CXXFLAGS="$RPM_OPT_FLAGS"
export CFLAGS="$CXXFLAGS"
./configure \
--prefix=%{_prefix} \
--datadir=/share/%{name} \
--docdir=/share/doc/packages/%{name} \
--mandir=/share/man \
--system-libs \
--parallel=0%jobs $EXTRA_FLAGS
make VERBOSE=1 %{?jobs:-j %jobs}
%install
make DESTDIR=%{buildroot} install
mkdir -p %{buildroot}%_libdir/cmake
find %{buildroot}/usr/share/cmake -type f -print0 | xargs -0 chmod 644
cp ChangeLog.manual %{buildroot}/usr/share/doc/packages/%{name}/Changelog
%if 0%{?suse_version} > 1020
%suse_update_desktop_file CMake Development IDE Tools Qt
%fdupes %buildroot/usr/share/cmake
%endif
%clean
rm -rf %{buildroot}
%files
%defattr(-,root,root)
/usr/bin/cpack
/usr/bin/cmake
/usr/bin/ctest
/usr/bin/ccmake
/usr/share/cmake
%_libdir/cmake
%doc /usr/share/doc/packages/%name
%doc %_mandir/man1/cmakepolicies.1.*
%doc %_mandir/man1/cmake.1.*
%doc %_mandir/man1/ctest.1.*
%doc %_mandir/man1/ccmake.1.*
%doc %_mandir/man1/cmakecommands.1.*
%doc %_mandir/man1/cmakecompat.1.*
%doc %_mandir/man1/cmakemodules.1.*
%doc %_mandir/man1/cmakeprops.1.*
%doc %_mandir/man1/cmakevars.1.*
%doc %_mandir/man1/cpack.1.*
%if 0%{?suse_version} > 1020
%doc %_mandir/man1/cmake-gui.1.*
%files gui
%defattr(-,root,root)
/usr/bin/cmake-gui
/usr/share/applications/CMake.desktop
/usr/share/mime/packages/cmakecache.xml
/usr/share/pixmaps/CMakeSetup32.png
%endif
%changelog