From 79599515788b85b18aa655e7b7f8cc05c1bbddd8 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 16 Feb 2019 12:59:29 +0000 Subject: gentoo resync : 16.02.1018 --- sys-apps/toybox/toybox-0.8.0.ebuild | 57 +++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 sys-apps/toybox/toybox-0.8.0.ebuild (limited to 'sys-apps/toybox/toybox-0.8.0.ebuild') diff --git a/sys-apps/toybox/toybox-0.8.0.ebuild b/sys-apps/toybox/toybox-0.8.0.ebuild new file mode 100644 index 000000000000..564d2c54b23c --- /dev/null +++ b/sys-apps/toybox/toybox-0.8.0.ebuild @@ -0,0 +1,57 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="7" + +inherit multiprocessing savedconfig toolchain-funcs + +if [[ ${PV} == 9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/landley/toybox.git" +else + SRC_URI="https://landley.net/code/toybox/downloads/${P}.tar.gz" + KEYWORDS="~amd64 ~x86" +fi + +# makefile is stupid +RESTRICT="test" + +DESCRIPTION="Common linux commands in a multicall binary" +HOMEPAGE="https://landley.net/code/toybox/" + +# The source code does not explicitly say that it's BSD, but the author has repeatedly said it +LICENSE="BSD-2" +SLOT="0" +IUSE="" + +src_prepare() { + default + restore_config .config +} + +src_configure() { + if [ -f .config ]; then + yes "" | emake -j1 oldconfig > /dev/null + return 0 + else + einfo "Could not locate user configfile, so we will save a default one" + emake -j1 defconfig > /dev/null + fi +} + +src_compile() { + tc-export CC STRIP + export HOSTCC=$(tc-getBUILD_CC) + unset CROSS_COMPILE + export CPUS=$(makeopts_jobs) + emake V=1 +} + +src_test() { + emake test +} + +src_install() { + save_config .config + newbin generated/unstripped/toybox toybox +} -- cgit v1.2.3