sci-mathematics/abc: new package; add 0_p20230313 and live

Signed-off-by: Maciej Barć <xgqt@gentoo.org>
This commit is contained in:
Maciej Barć
2023-03-13 16:42:26 +01:00
parent c8e928d996
commit 0815664146
5 changed files with 148 additions and 0 deletions

View File

@@ -0,0 +1 @@
DIST abc-0_p20230313.tar.gz 6082725 BLAKE2B 3647e813d04545eba68faae58ce8f36747e0ebf13befbaaca646c783acdf9994209a5c58beadc20b1b18a2c77a64ac589e899595e3f1374df9e363a3416271a6 SHA512 a3512b280cbac747178c6e3decc785aff5eb4130a95eea2f3bab6d61a41c89758116b0d94cbbbb4d4060fbfbaa0fa1638a9e211f3f2677910bbfe8e8d629e7ee

View File

@@ -0,0 +1,58 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit toolchain-funcs
DESCRIPTION="System for sequential logic synthesis and formal verification"
HOMEPAGE="https://people.eecs.berkeley.edu/~alanmi/abc/
https://github.com/berkeley-abc/abc/"
if [[ ${PV} == *9999* ]] ; then
inherit git-r3
EGIT_REPO_URI="https://github.com/berkeley-abc/abc.git"
elif [[ ${PV} == *_p20230313 ]] ; then
COMMIT=a5f4841486d4a491913943c5b92167a9e988abac
SRC_URI="https://github.com/berkeley-abc/abc/archive/${COMMIT}.tar.gz
-> ${P}.tar.gz"
S="${WORKDIR}"/abc-${COMMIT}
KEYWORDS="~amd64 ~x86"
else
die "unsupported abc version, given: ${PV}"
fi
LICENSE="BSD"
SLOT="0"
IUSE="+readline +threads"
RDEPEND="readline? ( sys-libs/readline:= )"
DEPEND="${RDEPEND}"
PATCHES=( "${FILESDIR}"/abc-0_p20230313-libabc.patch )
src_compile() {
local -a mymakeargs=(
AR="$(tc-getAR)"
CC="$(tc-getCC)"
CXX="$(tc-getCXX)"
LD="$(tc-getCXX)"
ABC_MAKE_VERBOSE=1
ABC_USE_NO_CUDD=1
ABC_USE_PIC=1
$(usex readline "ABC_USE_READLINE=1" "ABC_USE_NO_READLINE=1")
$(usex threads "ABC_USE_PTHREADS=1" "ABC_USE_NO_PTHREADS=1")
)
emake "${mymakeargs[@]}" libabc.so
emake "${mymakeargs[@]}" abc
}
src_install() {
exeinto /usr/bin
doexe abc
newlib.so libabc.so libabc.so.0
dosym -r /usr/$(get_libdir)/libabc.so.0 /usr/$(get_libdir)/libabc.so
dodoc README.md readmeaig
}

View File

@@ -0,0 +1,58 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit toolchain-funcs
DESCRIPTION="System for sequential logic synthesis and formal verification"
HOMEPAGE="https://people.eecs.berkeley.edu/~alanmi/abc/
https://github.com/berkeley-abc/abc/"
if [[ ${PV} == *9999* ]] ; then
inherit git-r3
EGIT_REPO_URI="https://github.com/berkeley-abc/abc.git"
elif [[ ${PV} == *_p20230313 ]] ; then
COMMIT=a5f4841486d4a491913943c5b92167a9e988abac
SRC_URI="https://github.com/berkeley-abc/abc/archive/${COMMIT}.tar.gz
-> ${P}.tar.gz"
S="${WORKDIR}"/abc-${COMMIT}
KEYWORDS="~amd64 ~x86"
else
die "unsupported abc version, given: ${PV}"
fi
LICENSE="BSD"
SLOT="0"
IUSE="+readline +threads"
RDEPEND="readline? ( sys-libs/readline:= )"
DEPEND="${RDEPEND}"
PATCHES=( "${FILESDIR}"/abc-0_p20230313-libabc.patch )
src_compile() {
local -a mymakeargs=(
AR="$(tc-getAR)"
CC="$(tc-getCC)"
CXX="$(tc-getCXX)"
LD="$(tc-getCXX)"
ABC_MAKE_VERBOSE=1
ABC_USE_NO_CUDD=1
ABC_USE_PIC=1
$(usex readline "ABC_USE_READLINE=1" "ABC_USE_NO_READLINE=1")
$(usex threads "ABC_USE_PTHREADS=1" "ABC_USE_NO_PTHREADS=1")
)
emake "${mymakeargs[@]}" libabc.so
emake "${mymakeargs[@]}" abc
}
src_install() {
exeinto /usr/bin
doexe abc
newlib.so libabc.so libabc.so.0
dosym -r /usr/$(get_libdir)/libabc.so.0 /usr/$(get_libdir)/libabc.so
dodoc README.md readmeaig
}

View File

@@ -0,0 +1,11 @@
--- a/Makefile
+++ b/Makefile
@@ -221,7 +221,7 @@ lib$(PROG).a: $(LIBOBJ)
lib$(PROG).so: $(LIBOBJ)
@echo "$(MSG_PREFIX)\`\` Linking:" $(notdir $@)
- $(VERBOSE)$(CXX) -shared -o $@ $^ $(LIBS)
+ $(VERBOSE)$(CXX) -shared -o $@ $^ $(LDFLAGS) -Wl,-soname,lib$(PROG).so.0 $(LIBS)
docs:
@echo "$(MSG_PREFIX)\`\` Building documentation." $(notdir $@)

View File

@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="project">
<email>sci-mathematics@gentoo.org</email>
<name>Gentoo Mathematics Project</name>
</maintainer>
<longdescription>
ABC is a growing software system for synthesis and verification of binary
sequential logic circuits appearing in synchronous hardware designs. ABC
combines scalable logic optimization based on And-Inverter Graphs (AIGs),
optimal-delay DAG-based technology mapping for look-up tables and standard
cells, and innovative algorithms for sequential synthesis and verification.
</longdescription>
<upstream>
<bugs-to>https://github.com/berkeley-abc/abc/issues/</bugs-to>
<remote-id type="github">berkeley-abc/abc</remote-id>
</upstream>
</pkgmetadata>