diff options
author | neeshy <neeshy@tfwno.gf> | 2020-06-02 14:09:23 +0300 |
---|---|---|
committer | Joonas Niilola <juippis@gentoo.org> | 2020-06-02 14:13:44 +0300 |
commit | 2758e2b15c592747ea4f65172aac35146b190aa7 (patch) | |
tree | 72c71448e160c6cf814d75b97ff25a51142ae231 /dev-util | |
parent | app-emulation/crun: fix extra spaces from patch file (diff) | |
download | gentoo-2758e2b15c592747ea4f65172aac35146b190aa7.tar.gz gentoo-2758e2b15c592747ea4f65172aac35146b190aa7.tar.bz2 gentoo-2758e2b15c592747ea4f65172aac35146b190aa7.zip |
dev-util/plan9port: bump version to 0_pre20200526
Signed-off-by: Nima Sadeghi <neeshy@tfwno.gf>
Signed-off-by: Joonas Niilola <juippis@gentoo.org>
Diffstat (limited to 'dev-util')
-rw-r--r-- | dev-util/plan9port/Manifest | 1 | ||||
-rw-r--r-- | dev-util/plan9port/files/plan9port-builderr.patch | 16 | ||||
-rw-r--r-- | dev-util/plan9port/files/plan9port-cflags.patch | 4 | ||||
-rw-r--r-- | dev-util/plan9port/files/plan9port-freebsd-10.patch | 11 | ||||
-rw-r--r-- | dev-util/plan9port/files/plan9port-noexecstack.patch | 6 | ||||
-rw-r--r-- | dev-util/plan9port/plan9port-0_pre20200526.ebuild | 132 |
6 files changed, 146 insertions, 24 deletions
diff --git a/dev-util/plan9port/Manifest b/dev-util/plan9port/Manifest index 30bb3ea66063..60d4aeb16d1b 100644 --- a/dev-util/plan9port/Manifest +++ b/dev-util/plan9port/Manifest @@ -1 +1,2 @@ +DIST plan9port-a6ad39aaaa36b8aadc5c35bfc803afbde32918c0.tar.gz 23445647 BLAKE2B 4cb0f08fc404c5618c4be0d7e5710e6a8a32fbe010d28a879b1f9575118256492a3ed2b9b744c35dbbb6c6deae405c05fd7b6606254fb94fc2b40b3a8d14fa71 SHA512 4d9f6ce66d3eebb311cbbb0ec27c01d99cc0e19c6ac8a1c511ff00070c085a349b637048cd0066240af975e90f527388dbeba58f4591bf7dcaa673ee5564430f DIST plan9port-e78ed7a67bbaa37dc57dfb37219f505c48755e14.tar.gz 23442851 BLAKE2B 89e2a8dcdf650cc3640ef0ba496f1c22e74831fda2e4a51cf8419c496da5a480a10324eb295369e9192defbd3c6411ea351bba1c6bdec5d72bc4ee397da58114 SHA512 3cb126eb0f8c58c76c4da5aaca6b3956b9cc30b1955c1b9db4727a01a46cae696f01b538a47f6f009e955f6ed8f308b60b6519d4184e10b255636ea32a1e9099 diff --git a/dev-util/plan9port/files/plan9port-builderr.patch b/dev-util/plan9port/files/plan9port-builderr.patch index 266f10c4b9d5..b1f3d1275ce8 100644 --- a/dev-util/plan9port/files/plan9port-builderr.patch +++ b/dev-util/plan9port/files/plan9port-builderr.patch @@ -4,15 +4,15 @@ By default, the plan9port INSTALL script doesn't report build error, which can result in a mostly broken build begin installed. --- a/INSTALL +++ b/INSTALL -@@ -41,7 +41,6 @@ echo " " - echo "* Resetting $PLAN9/config" - rm -f config +@@ -65,7 +65,6 @@ + ;; + esac -( - echo "* Compiler version:" - 9c -v 2>&1 | grep -v 'Configured with:' | grep -i version | sed 's/^/ /' - -@@ -134,7 +133,7 @@ if $dobuild; then + if [ `uname` = SunOS ]; then + # On Solaris x86, uname -p cannot be trusted. + echo "* Running on Solaris: checking architecture..." +@@ -159,7 +158,7 @@ echo "* Warning: not all binaries built successfully." fi echo "* Installing everything in $PLAN9/bin..." @@ -21,7 +21,7 @@ which can result in a mostly broken build begin installed. if [ ! -x $PLAN9/bin/cleanname -o ! -x $PLAN9/bin/acme -o ! -x $PLAN9/bin/sam ]; then echo " " echo "* Warning: not all binaries built successfully." -@@ -182,5 +181,4 @@ if $doinstall; then +@@ -211,5 +210,4 @@ echo " PLAN9=$PLAN9 export PLAN9" echo ' PATH=$PATH:$PLAN9/bin export PATH' fi diff --git a/dev-util/plan9port/files/plan9port-cflags.patch b/dev-util/plan9port/files/plan9port-cflags.patch index c2d2ed6defe5..74bd60518d08 100644 --- a/dev-util/plan9port/files/plan9port-cflags.patch +++ b/dev-util/plan9port/files/plan9port-cflags.patch @@ -5,10 +5,10 @@ This allows the plan9port build to inherit cflags from the environment. (This patch must be applied after plan9port-noexecstack.patch) --- a/src/mkhdr +++ b/src/mkhdr -@@ -28,8 +28,6 @@ LD=9l +@@ -11,8 +11,6 @@ + LD=9l AS=9a AR=9ar - INSTALL=install -CFLAGS= -LDFLAGS= AFLAGS=--noexecstack diff --git a/dev-util/plan9port/files/plan9port-freebsd-10.patch b/dev-util/plan9port/files/plan9port-freebsd-10.patch deleted file mode 100644 index cc46dc6f4509..000000000000 --- a/dev-util/plan9port/files/plan9port-freebsd-10.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/bin/9l 2015-12-09 19:12:50.000000000 +0000
-+++ b/bin/9l 2015-12-09 19:13:00.000000000 +0000
-@@ -19,7 +19,7 @@ case "$tag" in
- 5.2.*)
- extralibs="$extralibs -lkse"
- ;;
-- [5-9].*)
-+ [5-9].*|10.*)
- extralibs="$extralibs -lpthread"
- ;;
- esac
diff --git a/dev-util/plan9port/files/plan9port-noexecstack.patch b/dev-util/plan9port/files/plan9port-noexecstack.patch index fb4f19f21fc5..aff60d07a989 100644 --- a/dev-util/plan9port/files/plan9port-noexecstack.patch +++ b/dev-util/plan9port/files/plan9port-noexecstack.patch @@ -22,7 +22,7 @@ Patch by Andy Spencer test -f $PLAN9/config && . $PLAN9/config aflags="" -@@ -17,5 +12,16 @@ Darwin-*x86_64*) +@@ -17,5 +12,16 @@ ;; esac @@ -43,8 +43,8 @@ Patch by Andy Spencer +exec as $aflags $opts -o $dst $src --- a/src/mkhdr +++ b/src/mkhdr -@@ -30,7 +30,7 @@ AR=9ar - INSTALL=install +@@ -13,7 +13,7 @@ + AR=9ar CFLAGS= LDFLAGS= -AFLAGS= diff --git a/dev-util/plan9port/plan9port-0_pre20200526.ebuild b/dev-util/plan9port/plan9port-0_pre20200526.ebuild new file mode 100644 index 000000000000..dff9e3605a98 --- /dev/null +++ b/dev-util/plan9port/plan9port-0_pre20200526.ebuild @@ -0,0 +1,132 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit multiprocessing toolchain-funcs readme.gentoo-r1 + +MY_HASH="a6ad39aaaa36b8aadc5c35bfc803afbde32918c0" +MY_P="${PN}-${MY_HASH}" + +DESCRIPTION="Port of many Plan 9 programs and libraries" +HOMEPAGE="https://9fans.github.io/plan9port/ + https://github.com/9fans/plan9port" +SRC_URI="https://github.com/9fans/${PN}/archive/${MY_HASH}.tar.gz -> ${MY_P}.tar.gz" + +LICENSE="9base BSD-4 MIT LGPL-2.1 BigelowHolmes" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="X aqua truetype" +REQUIRED_USE="?? ( X aqua )" + +DEPEND=" + X? ( x11-apps/xauth ) + truetype? ( + media-libs/freetype + media-libs/fontconfig + ) +" +RDEPEND="${DEPEND}" + +PATCHES=( + "${FILESDIR}/${PN}-noexecstack.patch" + "${FILESDIR}/${PN}-cflags.patch" + "${FILESDIR}/${PN}-builderr.patch" +) + +S="${WORKDIR}/${MY_P}" + +PLAN9="/opt/plan9" +EPLAN9="${EPREFIX}${PLAN9}" +QA_MULTILIB_PATHS="${PLAN9}/.*/.*" + +DOC_CONTENTS="Plan 9 from User Space has been successfully installed into +${PLAN9}. Your PLAN9 and PATH environment variables have +also been appropriately set, please use env-update and +source /etc/profile to bring that into immediate effect. + +Please note that ${PLAN9}/bin has been appended to the +*end* or your PATH to prevent conflicts. To use the Plan9 +versions of common UNIX tools, use the absolute path: +${PLAN9}/bin or the 9 command (eg: 9 troff) + +Please report any bugs to bugs.gentoo.org, NOT Plan9Port." +DISABLE_AUTOFORMATTING="yes" + +src_prepare() { + default + + case "${CHOST}" in + *apple*) + sed -i 's/--noexecstack/-noexecstack/' src/mkhdr || + die "Failed to sed AFLAGS" ;; + esac + + # don't hardcode /bin and /usr/bin in PATH + sed -i '/PATH/s,/bin:/usr/bin:,,' INSTALL || die "sed on INSTALL failed" + + # don't hardcode /usr/{,local/}include and prefix /usr/include/* + sed -Ei -e 's,-I/usr(|/local)/include ,,g' \ + -e "s,-I/usr(|/local)/include,-I${EPREFIX}/usr\1/include,g" \ + src/cmd/fontsrv/freetyperules.sh INSTALL $(find -name makefile) || + die "sed failed" + + # Fix paths, done in place of ./INSTALL -c + einfo "Fixing hard-coded /usr/local/plan9 paths" + sed -i "s,/usr/local/plan9,${EPLAN9},g" $(grep -lr /usr/local/plan9) || + die "sed failed" +} + +src_configure() { + local -a myconf=( + CC9="$(tc-getCC)" + CC9FLAGS="'${CFLAGS} ${LDFLAGS}'" + ) + + if use X; then + myconf+=( WSYSTYPE=x11 ) + elif use aqua; then + local wsystype="$(awk '{if ($1 > 10.5) print "osx-cocoa"; else print "osx"}' \ + <<< "${MACOSX_DEPLOYMENT_TARGET}")" + myconf+=( WSYSTYPE="${wsystype}" ) + else + myconf+=( WSYSTYPE=nowsys ) + fi + + if use truetype; then + myconf+=( FONTSRV=fontsrv ) + else + myconf+=( FONTSRV= ) + fi + + printf '%s\n' "${myconf[@]}" >> LOCAL.config || + die "cannot create configuration" +} + +src_compile() { + # The INSTALL script builds mk then [re]builds everything using that + einfo "Compiling Plan 9 from User Space can take a very long time" + einfo "depending on the speed of your computer. Please be patient!" + NPROC="$(makeopts_jobs)" ./INSTALL -b || + die "Please report bugs to bugs.gentoo.org, NOT Plan9Port." +} + +src_install() { + readme.gentoo_create_doc + + # do* plays with the executable bit, and we should not modify them + dodir "${PLAN9}" + cp -a * "${ED}${PLAN9}" || die "cp failed" + + # build the environment variables and install them in env.d + newenvd - 60plan9 <<-EOF + PLAN9="${EPLAN9}" + PATH="${EPLAN9}/bin" + ROOTPATH="${EPLAN9}/bin" + MANPATH="${EPLAN9}/man" + EOF +} + +pkg_postinst() { + readme.gentoo_print_elog +} |