void-packages/srcpkgs/cmake/template

35 lines
1.2 KiB
Bash

# Template file for 'cmake'
pkgname=cmake
version=3.20.3
revision=1
build_style=configure
configure_args="--prefix=/usr --mandir=/share/man --docdir=/share/doc/cmake
--system-libs ${XBPS_MAKEJOBS:+--parallel=$XBPS_MAKEJOBS}"
make_check_target=test
hostmakedepends="gcc-fortran"
makedepends="expat-devel libarchive-devel libcurl-devel libuv-devel
ncurses-devel rhash-devel jsoncpp-devel"
checkdepends="pax pkg-config git"
short_desc="Cross-platform, open-source build system"
maintainer="Đoàn Trần Công Danh <congdanhqx@gmail.com>"
license="BSD-3-Clause, ICU"
homepage="https://www.cmake.org"
distfiles="https://www.cmake.org/files/v${version%.*}/${pkgname}-${version}.tar.gz"
checksum=4d008ac3461e271fcfac26a05936f77fc7ab64402156fb371d41284851a651b8
replaces="cmake-bootstrap>=0"
if [ "$CROSS_BUILD" ]; then
build_style=cmake
configure_args="-DCMAKE_DOC_DIR=/share/doc/cmake
-DCMAKE_USE_SYSTEM_LIBRARIES=ON -DKWSYS_LFS_WORKS=1"
fi
post_install() {
rm -rf ${DESTDIR}/usr/share/doc/cmake
sed -n -e '/Copyright/,/authorization[.]/p' \
Source/CursesDialog/form/fld_arg.c >fld.LICENSE
vlicense fld.LICENSE
vlicense Copyright.txt
vlicense Utilities/KWIML/Copyright.txt KWIML-Copyright.txt
}