2022-06-08 19:02:48 +00:00
|
|
|
# Maintainer: Evangelos Foutras <evangelos@foutrelis.com>
|
|
|
|
|
|
|
|
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
|
|
|
|
# - strip -fstack-clash-protection from CFLAGS
|
|
|
|
|
|
|
|
pkgname=gn
|
2023-08-29 20:16:54 +00:00
|
|
|
pkgver=0.2119.cc56a0f9
|
|
|
|
_commit=cc56a0f98bb34accd5323316e0292575ff17a5d4
|
2022-07-12 00:45:29 +00:00
|
|
|
pkgrel=1
|
2022-06-08 19:02:48 +00:00
|
|
|
pkgdesc="Meta-build system that generates build files for Ninja"
|
|
|
|
arch=('x86_64')
|
|
|
|
url="https://gn.googlesource.com/gn/"
|
|
|
|
license=('BSD')
|
|
|
|
depends=('gcc-libs')
|
|
|
|
makedepends=('clang' 'ninja' 'python' 'git')
|
2022-07-12 00:45:29 +00:00
|
|
|
source=(git+https://gn.googlesource.com/gn#commit=$_commit)
|
|
|
|
sha256sums=('SKIP')
|
2022-06-08 19:02:48 +00:00
|
|
|
|
|
|
|
pkgver() {
|
|
|
|
cd $pkgname
|
|
|
|
echo 0.$(git rev-list --count initial-commit..).$(git rev-parse --short=8 HEAD)
|
|
|
|
}
|
|
|
|
|
|
|
|
build() {
|
|
|
|
cd $pkgname
|
|
|
|
# clang-13: error: argument unused during compilation: '-fstack-clash-protection' [-Werror,-Wunused-command-line-argument]
|
|
|
|
CFLAGS=${CFLAGS/-fstack-clash-protection/}
|
|
|
|
CXXFLAGS=${CXXFLAGS/-fstack-clash-protection/}
|
|
|
|
./build/gen.py
|
|
|
|
ninja -C out
|
|
|
|
}
|
|
|
|
|
|
|
|
check() {
|
|
|
|
cd $pkgname
|
|
|
|
./out/gn_unittests
|
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
|
|
|
cd $pkgname
|
|
|
|
install -D out/gn "$pkgdir/usr/bin/gn"
|
|
|
|
install -Dm644 -t "$pkgdir/usr/share/doc/$pkgname" docs/*
|
|
|
|
install -Dm644 -t "$pkgdir/usr/share/licenses/$pkgname" LICENSE
|
|
|
|
|
|
|
|
mkdir -p "$pkgdir/usr/share/vim/vimfiles"
|
|
|
|
cp -r misc/vim/{autoload,ftdetect,ftplugin,syntax} \
|
|
|
|
"$pkgdir/usr/share/vim/vimfiles/"
|
|
|
|
install -Dm644 -t "$pkgdir/usr/share/emacs/site-lisp" misc/emacs/gn-mode.el
|
|
|
|
}
|
|
|
|
|
|
|
|
# vim:set ts=2 sw=2 et:
|