opt/cmake/Pkgfile
2016-08-18 11:33:56 +02:00

37 lines
986 B
Plaintext

# Description: A cross-platform, open-source make system.
# URL: http://www.cmake.org/
# Maintainer: Jose V Beneyto, sepen at crux dot nu
# Packager: Mark Rosenstand, mark at borkware dot net
# Depends on: curl libarchive expat ncurses
name=cmake
version=3.6.1
release=2
source=(http://www.cmake.org/files/v${version%.*}/$name-$version.tar.gz)
build() {
cd $name-$version
# fix installation path
sed -i Source/CMakeInstallDestinations.cmake \
-e 's|share/cmake-${CMake_VERSION_MAJOR}.${CMake_VERSION_MINOR}|share/cmake|'
if pkginfo -i | grep -q ^qt5; then
export CMAKE_PREFIX_PATH=/usr/share/qt5
fi
./bootstrap \
--prefix=/usr \
--system-libs \
--system-libarchive \
--no-system-jsoncpp \
--parallel=$(sed -e 's/.*-j *\([0-9]\+\).*/\1/' <<< $MAKEFLAGS)
make
make DESTDIR=$PKG install
rm -r $PKG/usr/doc
# keep versioned dir for compatibility
ln -sf $name $PKG/usr/share/$name-${version%.*}
}