From 4f2d7949f03e1c198bc888f2d05f421d35c57e21 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Mon, 9 Oct 2017 18:53:29 +0100 Subject: reinit the tree, so we can have metadata --- sys-libs/suacomp/suacomp-9999.ebuild | 59 ++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 sys-libs/suacomp/suacomp-9999.ebuild (limited to 'sys-libs/suacomp/suacomp-9999.ebuild') diff --git a/sys-libs/suacomp/suacomp-9999.ebuild b/sys-libs/suacomp/suacomp-9999.ebuild new file mode 100644 index 000000000000..c40821304da1 --- /dev/null +++ b/sys-libs/suacomp/suacomp-9999.ebuild @@ -0,0 +1,59 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=4 + +inherit toolchain-funcs flag-o-matic git-2 + +DESCRIPTION="library wrapping the interix lib-c to make it less buggy" +HOMEPAGE="http://suacomp.sf.net" +EGIT_REPO_URI="https://git.code.sf.net/p/suacomp/git" + +LICENSE="BEER-WARE" +SLOT="0" +KEYWORDS="" +IUSE="debug" + +DEPEND="" +RDEPEND="" + +get_opts() { + local shlibc= + local stlibc= + + for dir in /usr/lib /usr/lib/x86; do + [[ -f ${dir}/libc.a ]] && stlibc=${dir}/libc.a + + for name in libc.so.5.2 libc.so.3.5; do + [[ -f ${dir}/${name} ]] && { shlibc=${dir}/${name}; break; } + done + + [[ -f ${shlibc} && -f ${stlibc} ]] && break + done + + echo "SHARED_LIBC=${shlibc} STATIC_LIBC=${stlibc}" +} + +pkg_setup() { + if use debug; then + append-flags -D_DEBUG -D_DEBUG_TRACE + fi +} + +src_compile() { + emake all CC=$(tc-getCC) $(get_opts) CFLAGS="${CFLAGS}" +} + +src_install() { + emake install PREFIX="${EPREFIX}/usr" DESTDIR="${D}" $(get_opts) \ + CFLAGS="${CFLAGS}" +} + +src_test() { + local v= + + use debug && v="TEST_VERBOSE=1" + use debug && export SUACOMP_DEBUG_OUT=stderr + + emake check $(get_opts) ${v} +} -- cgit v1.2.3