mirror of
https://gitdl.cn/https://github.com/chakralinux/core.git
synced 2025-02-04 03:07:13 +08:00
51 lines
1.6 KiB
Bash
51 lines
1.6 KiB
Bash
pkgname=cmake
|
|
pkgver=3.5.1
|
|
pkgrel=2
|
|
pkgdesc="A cross-platform open-source make system"
|
|
arch=('x86_64')
|
|
license=('custom')
|
|
url="http://www.cmake.org"
|
|
depends=('curl' 'libarchive>=2.3.1' 'shared-mime-info' 'jsoncpp')
|
|
makedepends=('qt5-base' 'python3-sphinx')
|
|
install=${pkgname}.install
|
|
source=("http://www.cmake.org/files/v${pkgver%.*}/${pkgname}-${pkgver}.tar.gz"
|
|
"add_openblas.diff")
|
|
sha256sums=('93d651a754bcf6f0124669646391dd5774c0fc4d407c384e3ae76ef9a60477e8'
|
|
'9cd72e7c269d06dc2df9ed42f7e0658ffcb8fce64af94098364ac72dbf26e5dc')
|
|
|
|
prepare() {
|
|
cd "${srcdir}"/${pkgname}-${pkgver}
|
|
patch -Np1 < ${srcdir}/add_openblas.diff
|
|
}
|
|
|
|
build() {
|
|
cd "${srcdir}"/${pkgname}-${pkgver}
|
|
|
|
./bootstrap --prefix=/usr \
|
|
--mandir=/share/man \
|
|
--docdir=/share/doc/cmake \
|
|
--sphinx-man \
|
|
--system-libs \
|
|
--qt-gui \
|
|
--qt-qmake=/usr/lib/qt5/bin/qmake \
|
|
--parallel=$(/usr/bin/getconf _NPROCESSORS_ONLN)
|
|
make
|
|
}
|
|
|
|
package() {
|
|
cd ${pkgname}-${pkgver}
|
|
make DESTDIR="${pkgdir}" install
|
|
|
|
vimpath="${pkgdir}/usr/share/vim/vimfiles"
|
|
install -d "${vimpath}"/{help,indent,syntax}
|
|
ln -s /usr/share/${pkgname}-${_pkgver}/editors/vim/cmake-help.vim "${vimpath}"/help/
|
|
ln -s /usr/share/${pkgname}-${_pkgver}/editors/vim/cmake-indent.vim "${vimpath}"/indent/
|
|
ln -s /usr/share/${pkgname}-${_pkgver}/editors/vim/cmake-syntax.vim "${vimpath}"/syntax/
|
|
|
|
install -d "${pkgdir}"/usr/share/emacs/site-lisp/
|
|
ln -s /usr/share/${pkgname}-${_pkgver}/editors/emacs/cmake-mode.el "${pkgdir}"/usr/share/emacs/site-lisp/
|
|
|
|
install -Dm644 Copyright.txt \
|
|
"${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
|
|
}
|