New package: 9base-6.0.20160912
This commit is contained in:
parent
58aeee65fa
commit
9ab76843d8
2 changed files with 56 additions and 0 deletions
2
srcpkgs/9base/files/plan9.sh
Normal file
2
srcpkgs/9base/files/plan9.sh
Normal file
|
@ -0,0 +1,2 @@
|
|||
export PLAN9=/usr/lib/plan9
|
||||
export PATH=$PATH:$PLAN9/bin
|
54
srcpkgs/9base/template
Normal file
54
srcpkgs/9base/template
Normal file
|
@ -0,0 +1,54 @@
|
|||
# Template file for '9base'
|
||||
pkgname=9base
|
||||
version=6.0.20160912
|
||||
revision=1
|
||||
_githash=de27e3fba58c3dd467c29ea9a1aea6f9e65a5299
|
||||
build_style=gnu-makefile
|
||||
# we use byacc instead of internal version
|
||||
hostmakedepends="byacc"
|
||||
short_desc="Revived minimalist port of Plan 9 userland to Unix"
|
||||
maintainer='Tai Chi Minh Ralph Eastwood <tcmreastwood@gmail.com>'
|
||||
license="custom"
|
||||
homepage="http://git.suckless.org/9base"
|
||||
distfiles="http://git.suckless.org/9base/snapshot/9base-${_githash}.tar.bz2"
|
||||
provides="plan9port-20160418_4"
|
||||
conflicts="plan9port"
|
||||
checksum=a6eda0673ee38fb9eb48921a7d6f0cfaa2012020dde81d10d7be5980e2af4e32
|
||||
wrksrc="9base-${_githash}"
|
||||
|
||||
pre_build() {
|
||||
# These are platform specific, but aarch64 and mips have their
|
||||
# program counter in the same place; we'll just use the ARM
|
||||
# implementation.
|
||||
cp lib9/getcallerpc-arm.c lib9/getcallerpc-aarch64.c
|
||||
cp lib9/getcallerpc-arm.c lib9/getcallerpc-mips.c
|
||||
|
||||
# config.mk has conflicting flags to the build-style; we enforce
|
||||
# specific ones in config.mk to make sure they don't get changed
|
||||
# in do_build.
|
||||
sed -i 's|^PREFIX \+= /usr/local/plan9|override PREFIX = /usr/lib/plan9|g' config.mk
|
||||
sed -i 's|^CFLAGS \++=|override CFLAGS += -D_DEFAULT_SOURCE |g' config.mk
|
||||
sed -i 's|^LDFLAGS.*||g' config.mk
|
||||
sed -i 's|^CC.*||g' config.mk
|
||||
# Add rc to the AR flag as the 9base build-scripts require AR to
|
||||
# be declared with the 'rc' argument. However, AR can be
|
||||
# different to 'ar' if declared differently within xbps e.g.
|
||||
# gcc-ar which is necessary for link-time optimisation builds.
|
||||
sed -i 's|^AR.*|override AR += rc|g' config.mk
|
||||
sed -i 's|^YACC \+=.*|YACC = byacc|g' config.mk
|
||||
|
||||
# This allows 9base's build-style know which getcallerpc
|
||||
# implementation to use.
|
||||
case "$XBPS_TARGET_MACHINE" in
|
||||
i686*) sed -i 's|^OBJTYPE \+=.*|OBJTYPE = 386|g' config.mk ;;
|
||||
x86_64*) sed -i 's|^OBJTYPE \+=.*|OBJTYPE = x86_64|g' config.mk ;;
|
||||
arm*) sed -i 's|^OBJTYPE \+=.*|OBJTYPE = arm|g' config.mk ;;
|
||||
aarch64*) sed -i 's|^OBJTYPE \+=.*|OBJTYPE = aarch64|g' config.mk ;;
|
||||
mips*) sed -i 's|^OBJTYPE \+=.*|OBJTYPE = mips|g' config.mk ;;
|
||||
esac
|
||||
}
|
||||
|
||||
post_install() {
|
||||
vinstall $FILESDIR/plan9.sh 644 etc/profile.d
|
||||
vlicense LICENSE
|
||||
}
|
Loading…
Reference in a new issue