summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /sci-mathematics/calc
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'sci-mathematics/calc')
-rw-r--r--sci-mathematics/calc/Manifest5
-rw-r--r--sci-mathematics/calc/calc-2.12.1.5.ebuild40
-rw-r--r--sci-mathematics/calc/calc-2.12.2.2.ebuild52
-rw-r--r--sci-mathematics/calc/calc-2.12.4.13.ebuild57
-rw-r--r--sci-mathematics/calc/calc-2.12.4.3.ebuild53
-rw-r--r--sci-mathematics/calc/calc-2.12.4.4.ebuild57
-rw-r--r--sci-mathematics/calc/files/2.12.4.0-ldflags.patch101
-rw-r--r--sci-mathematics/calc/files/calc-2.12.2.2-libdir-fix.patch12
-rw-r--r--sci-mathematics/calc/files/calc-2.12.4.0-prefix.patch96
-rw-r--r--sci-mathematics/calc/files/calc-2.12.4.13-prefix.patch87
-rw-r--r--sci-mathematics/calc/metadata.xml12
11 files changed, 572 insertions, 0 deletions
diff --git a/sci-mathematics/calc/Manifest b/sci-mathematics/calc/Manifest
new file mode 100644
index 000000000000..3ac4498d354d
--- /dev/null
+++ b/sci-mathematics/calc/Manifest
@@ -0,0 +1,5 @@
+DIST calc-2.12.1.5.tar.gz 1020389 SHA256 3a8b6daa60de0b5aa7c33dcfdf0aeec9d4523f51638235468de32f843ce79171
+DIST calc-2.12.2.2.tar.bz2 864687 SHA256 0a334cd331a4953a86365becce9b9f401b264a580a1f2130d5de700fa093772a
+DIST calc-2.12.4.13.tar.bz2 970778 SHA256 1e6fd3256bd7bf738fcfe6e2d6a9d8a6bb0f37393aba6020b01d96274419a92c SHA512 7b7136c793917652ce2f2b3866b2db16a69dbead729d8a72b8c1359ebb8a4e1d4e7a3a8b214f8e85b9ccf41193ba6ffcb49926cc68f494e2b6cdff58559f2534 WHIRLPOOL 365700655f53eb5efb58ee6fbdf1d123943c2cc6a799318d9a48e2c5b8e0e2e871fd36e54b185442e0a0bc5380644edca1612bbfe7e2506247015743cdb556ee
+DIST calc-2.12.4.3.tar.bz2 865956 SHA256 a4e7d8a9313e7d28653e2c372fca9b0defdc02f965b833bb43479bbdfee51a92
+DIST calc-2.12.4.4.tar.bz2 867180 SHA256 106a0e5dc4da94ec8711a8631cd5d17b3979cde1d248ba9385cdcb862cb1390b SHA512 58be9d70a2c79adeb44d86da6f5f2d04dbf09aaec10ad4e8eed870a7b8de1d4a7cd35b1738ccb5cc64ef5f945e6cfbe1944e27f064541289abe1a4e7f4703690 WHIRLPOOL 1a106ba7b10463aca673329b625721d47a14721467e7847fdbe509b8bf16b4c5829b006240faf58f915abb0f0bf9cbc033289077f20f0c74c2704fb63ccaf340
diff --git a/sci-mathematics/calc/calc-2.12.1.5.ebuild b/sci-mathematics/calc/calc-2.12.1.5.ebuild
new file mode 100644
index 000000000000..2ddaa5a451b2
--- /dev/null
+++ b/sci-mathematics/calc/calc-2.12.1.5.ebuild
@@ -0,0 +1,40 @@
+# Copyright 1999-2008 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+DESCRIPTION="An arbitrary precision C-like arithmetic system"
+HOMEPAGE="http://www.isthe.com/chongo/tech/comp/calc/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
+
+SLOT="0"
+LICENSE="LGPL-2"
+KEYWORDS="alpha ~amd64 ~ppc x86"
+
+IUSE=""
+
+DEPEND=">=sys-libs/ncurses-5.2
+ >=sys-libs/readline-4.2"
+
+RDEPEND="${DEPEND}
+ >=sys-apps/less-348"
+
+src_compile() {
+ make \
+ T="${D}" \
+ DEBUG="${CFLAGS}" \
+ CALCPAGER=less \
+ USE_READLINE="-DUSE_READLINE" \
+ READLINE_LIB="-lreadline -lhistory -lncurses" \
+ all \
+ || die
+ if echo "${LD_PRELOAD}" | grep -q "sandbox"; then
+ ewarn "Can't run check when running in sandbox - see bug #59676"
+ else
+ make chk || die "Check failed"
+ fi
+}
+
+src_install() {
+ make T="${D}" install || die
+ dodoc BUGS CHANGES LIBRARY README
+}
diff --git a/sci-mathematics/calc/calc-2.12.2.2.ebuild b/sci-mathematics/calc/calc-2.12.2.2.ebuild
new file mode 100644
index 000000000000..c2e889b2aa59
--- /dev/null
+++ b/sci-mathematics/calc/calc-2.12.2.2.ebuild
@@ -0,0 +1,52 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+inherit eutils multilib
+
+DESCRIPTION="An arbitrary precision C-like arithmetic system"
+HOMEPAGE="http://www.isthe.com/chongo/tech/comp/calc/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2"
+
+SLOT="0"
+LICENSE="LGPL-2"
+KEYWORDS="~alpha amd64 ~ppc ~ppc64 ~x86"
+
+IUSE=""
+
+DEPEND=">=sys-libs/ncurses-5.2
+ >=sys-libs/readline-4.2"
+
+RDEPEND="${DEPEND}
+ >=sys-apps/less-348"
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ epatch "${FILESDIR}"/${P}-libdir-fix.patch
+
+ sed -e "s:LIBDIR= /usr/lib:LIBDIR= /usr/$(get_libdir):" \
+ -i Makefile || die "Failed to fix multilib in makefile"
+}
+
+src_compile() {
+ # bug #299224
+ emake -j1 \
+ T="${D}" \
+ DEBUG="${CFLAGS}" \
+ CALCPAGER=less \
+ USE_READLINE="-DUSE_READLINE" \
+ READLINE_LIB="-lreadline -lhistory -lncurses" \
+ all \
+ || die
+ if echo "${LD_PRELOAD}" | grep -q "sandbox"; then
+ ewarn "Can't run check when running in sandbox - see bug #59676"
+ else
+ make chk || die "Check failed"
+ fi
+}
+
+src_install() {
+ make T="${D}" install || die
+ dodoc BUGS CHANGES LIBRARY README
+}
diff --git a/sci-mathematics/calc/calc-2.12.4.13.ebuild b/sci-mathematics/calc/calc-2.12.4.13.ebuild
new file mode 100644
index 000000000000..66696e9940dc
--- /dev/null
+++ b/sci-mathematics/calc/calc-2.12.4.13.ebuild
@@ -0,0 +1,57 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit eutils multilib toolchain-funcs
+
+DESCRIPTION="Arbitrary precision C-like arithmetic system"
+HOMEPAGE="http://www.isthe.com/chongo/tech/comp/calc/"
+SRC_URI="http://www.isthe.com/chongo/src/calc/${P}.tar.bz2"
+
+SLOT="0"
+LICENSE="LGPL-2"
+KEYWORDS="~alpha ~amd64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux"
+
+IUSE=""
+
+DEPEND="
+ sys-libs/ncurses
+ sys-libs/readline"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${PN}-2.12.4.13-prefix.patch\
+ "${FILESDIR}"/2.12.4.0-ldflags.patch
+ ln -sf libcustcalc.so.${PV} custom/libcustcalc.so || die
+ sed -i -e "/DIR/s:/usr:${EPREFIX}/usr:g" Makefile || die
+}
+
+src_compile() {
+ # parallel compilation hard to fix. better to leave upstream.
+ emake -j1 \
+ CC="$(tc-getCC)" \
+ DEBUG="${CFLAGS}" \
+ LDFLAGS="${LDFLAGS}" \
+ CALCPAGER="${PAGER}" \
+ USE_READLINE="-DUSE_READLINE" \
+ READLINE_LIB="-lreadline -lhistory -lncurses -L${S}/custom -lcustcalc" \
+ all
+}
+
+src_test() {
+ if echo "${LD_PRELOAD}" | grep -q "sandbox"; then
+ ewarn "Can't run check when running in sandbox - see bug #59676"
+ else
+ emake chk
+ fi
+}
+
+src_install() {
+ emake \
+ T="${D}" \
+ LIBDIR="${EPREFIX}/usr/$(get_libdir)" \
+ install
+ dodoc BUGS CHANGES LIBRARY README
+}
diff --git a/sci-mathematics/calc/calc-2.12.4.3.ebuild b/sci-mathematics/calc/calc-2.12.4.3.ebuild
new file mode 100644
index 000000000000..4b011af490f1
--- /dev/null
+++ b/sci-mathematics/calc/calc-2.12.4.3.ebuild
@@ -0,0 +1,53 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="3"
+
+inherit eutils multilib toolchain-funcs
+
+DESCRIPTION="An arbitrary precision C-like arithmetic system"
+HOMEPAGE="http://www.isthe.com/chongo/tech/comp/calc/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2"
+
+SLOT="0"
+LICENSE="LGPL-2"
+KEYWORDS="~alpha ~amd64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux"
+
+IUSE=""
+
+DEPEND="
+ >=sys-libs/ncurses-5.2
+ >=sys-libs/readline-4.2"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${PN}-2.12.4.0-prefix.patch
+ epatch "${FILESDIR}"/2.12.4.0-ldflags.patch
+ ln -sf libcustcalc.so.${PV} custom/libcustcalc.so
+}
+
+src_compile() {
+ # parallel compilation hard to fix. better to leave upstream.
+ emake -j1 \
+ CC=$(tc-getCC) \
+ DEBUG="${CFLAGS}" \
+ LDFLAGS="${LDFLAGS}" \
+ CALCPAGER="${PAGER}" \
+ USE_READLINE="-DUSE_READLINE" \
+ READLINE_LIB="-lreadline -lhistory -lncurses -L${S}/custom -lcustcalc" \
+ all || die "emake failed"
+}
+
+src_test() {
+ if echo "${LD_PRELOAD}" | grep -q "sandbox"; then
+ ewarn "Can't run check when running in sandbox - see bug #59676"
+ else
+ make chk || die "Check failed"
+ fi
+}
+
+src_install() {
+ emake T="${D}" LIBDIR="${EPREFIX}/usr/$(get_libdir)" install || die "emake install failed"
+ dodoc BUGS CHANGES LIBRARY README
+}
diff --git a/sci-mathematics/calc/calc-2.12.4.4.ebuild b/sci-mathematics/calc/calc-2.12.4.4.ebuild
new file mode 100644
index 000000000000..9aca67e632bc
--- /dev/null
+++ b/sci-mathematics/calc/calc-2.12.4.4.ebuild
@@ -0,0 +1,57 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=4
+
+inherit eutils multilib toolchain-funcs
+
+DESCRIPTION="Arbitrary precision C-like arithmetic system"
+HOMEPAGE="http://www.isthe.com/chongo/tech/comp/calc/"
+SRC_URI="http://www.isthe.com/chongo/src/calc/${P}.tar.bz2"
+
+SLOT="0"
+LICENSE="LGPL-2"
+KEYWORDS="~alpha ~amd64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux"
+
+IUSE=""
+
+DEPEND="
+ sys-libs/ncurses
+ sys-libs/readline"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${PN}-2.12.4.0-prefix.patch
+ epatch "${FILESDIR}"/2.12.4.0-ldflags.patch
+ ln -sf libcustcalc.so.${PV} custom/libcustcalc.so
+ sed -i -e "/DIR/s:/usr:${EPREFIX}/usr:g" Makefile || die
+}
+
+src_compile() {
+ # parallel compilation hard to fix. better to leave upstream.
+ emake -j1 \
+ CC="$(tc-getCC)" \
+ DEBUG="${CFLAGS}" \
+ LDFLAGS="${LDFLAGS}" \
+ CALCPAGER="${PAGER}" \
+ USE_READLINE="-DUSE_READLINE" \
+ READLINE_LIB="-lreadline -lhistory -lncurses -L${S}/custom -lcustcalc" \
+ all
+}
+
+src_test() {
+ if echo "${LD_PRELOAD}" | grep -q "sandbox"; then
+ ewarn "Can't run check when running in sandbox - see bug #59676"
+ else
+ emake chk || die "Check failed"
+ fi
+}
+
+src_install() {
+ emake \
+ T="${D}" \
+ LIBDIR="${EPREFIX}/usr/$(get_libdir)" \
+ install
+ dodoc BUGS CHANGES LIBRARY README
+}
diff --git a/sci-mathematics/calc/files/2.12.4.0-ldflags.patch b/sci-mathematics/calc/files/2.12.4.0-ldflags.patch
new file mode 100644
index 000000000000..0f2b67d2c084
--- /dev/null
+++ b/sci-mathematics/calc/files/2.12.4.0-ldflags.patch
@@ -0,0 +1,101 @@
+diff --git a/Makefile b/Makefile
+index b526442..baa8273 100644
+--- a/Makefile
++++ b/Makefile
+@@ -1144,11 +1144,13 @@ BLD_TYPE= calc-dynamic-only
+ #
+ CC_SHARE= -fPIC
+ LD_SHARE=
+-LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+-LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
++LIBCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ else
+-LIBCUSTCALC_SHLIB=
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
++LIBCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ endif
+ #
+ CC_STATIC=
+@@ -1227,9 +1229,9 @@ BLD_TYPE= calc-dynamic-only
+ #
+ CC_SHARE= -fPIC
+ LD_SHARE=
+-LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+-LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+ else
+ LIBCUSTCALC_SHLIB=
+ endif
+@@ -1267,9 +1269,9 @@ BLD_TYPE= calc-dynamic-only
+ #
+ CC_SHARE= -fPIC
+ LD_SHARE=
+-LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+-LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+ else
+ LIBCUSTCALC_SHLIB=
+ endif
+@@ -1304,9 +1306,9 @@ CC_SHARE= -fPIC
+ DEFAULT_LIB_INSTALL_PATH= ${PWD}:/lib:/usr/lib:${LIBDIR}:/usr/local/lib
+ LD_SHARE= "-Wl,-rpath,${DEFAULT_LIB_INSTALL_PATH}" \
+ "-Wl,-rpath-link,${DEFAULT_LIB_INSTALL_PATH}"
+-LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+-LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+ else
+ LIBCUSTCALC_SHLIB=
+ endif
+@@ -1340,8 +1342,8 @@ BLD_TYPE= calc-static-only
+ #
+ CC_SHARE= -fPIC
+ LD_SHARE=
+-LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+-LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+ #
+ CC_STATIC=
+ LD_STATIC=
+@@ -1394,9 +1396,9 @@ BLD_TYPE= calc-static-only
+ #
+ CC_SHARE= -fPIC
+ LD_SHARE=
+-LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+-LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+ else
+ LIBCUSTCALC_SHLIB=
+ endif
+@@ -1431,9 +1433,9 @@ CC_SHARE= -fPIC
+ DEFAULT_LIB_INSTALL_PATH= ${PWD}:/lib:/usr/lib:${LIBDIR}:/usr/local/lib
+ LD_SHARE= "-Wl,-rpath,${DEFAULT_LIB_INSTALL_PATH}" \
+ "-Wl,-rpath-link,${DEFAULT_LIB_INSTALL_PATH}"
+-LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+-LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
++LIBCUSTCALC_SHLIB= -shared ${LDFLAGS} "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+ else
+ LIBCUSTCALC_SHLIB=
+ endif
+@@ -2002,7 +2004,7 @@ calc-static-only: ${STATIC_FIRST_TARGETS} ${EARLY_TARGETS} \
+
+ calc${EXT}: .hsrc ${CALCOBJS} ${CALC_DYNAMIC_LIBS} ${MAKE_FILE}
+ ${RM} -f $@
+- ${CC} ${CALCOBJS} ${LDFLAGS} ${LD_SHARE} ${CALC_DYNAMIC_LIBS} \
++ ${CC} ${LDFLAGS} ${CALCOBJS} ${LD_SHARE} ${CALC_DYNAMIC_LIBS} \
+ ${READLINE_LIB} ${READLINE_EXTRAS} -o $@
+
+ libcalc${LIB_EXT_VERSION}: ${LIBOBJS} ver_calc${EXT} ${MAKE_FILE}
diff --git a/sci-mathematics/calc/files/calc-2.12.2.2-libdir-fix.patch b/sci-mathematics/calc/files/calc-2.12.2.2-libdir-fix.patch
new file mode 100644
index 000000000000..f265793ab871
--- /dev/null
+++ b/sci-mathematics/calc/files/calc-2.12.2.2-libdir-fix.patch
@@ -0,0 +1,12 @@
+diff -Naur calc-2.12.2.2.old/Makefile calc-2.12.2.2/Makefile
+--- calc-2.12.2.2.old/Makefile 2007-09-29 12:58:19.000000000 -0400
++++ calc-2.12.2.2/Makefile 2007-10-24 06:40:10.000000000 -0400
+@@ -1131,7 +1131,7 @@
+ BLD_TYPE= calc-dynamic-only
+ #
+ CC_SHARE= -fPIC
+-DEFAULT_LIB_INSTALL_PATH= ${PWD}:/lib:/usr/lib:${LIBDIR}:/usr/local/lib
++DEFAULT_LIB_INSTALL_PATH= /lib:/usr/lib:${LIBDIR}:/usr/local/lib
+ LD_SHARE= "-Wl,-rpath,${DEFAULT_LIB_INSTALL_PATH}" \
+ "-Wl,-rpath-link,${DEFAULT_LIB_INSTALL_PATH}"
+ LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
diff --git a/sci-mathematics/calc/files/calc-2.12.4.0-prefix.patch b/sci-mathematics/calc/files/calc-2.12.4.0-prefix.patch
new file mode 100644
index 000000000000..68d057212c74
--- /dev/null
+++ b/sci-mathematics/calc/files/calc-2.12.4.0-prefix.patch
@@ -0,0 +1,96 @@
+diff --git a/Makefile b/Makefile
+index cc84386..b526442 100644
+--- a/Makefile
++++ b/Makefile
+@@ -959,7 +959,7 @@ LD_DEBUG=
+ #
+ # If in doubt, use CALC_ENV= CALCPATH=./cal LD_LIBRARY_PATH=.:./custom
+ #
+-CALC_ENV= CALCPATH=./cal LD_LIBRARY_PATH=.
++CALC_ENV= CALCPATH=./cal LD_LIBRARY_PATH=. DYLD_LIBRARY_PATH=.
+ #CALC_ENV= CALCPATH=./cal MALLOC_VERBOSE=1 MALLOC_TRACING=1 \
+ # MALLOC_FASTCHK=1 MALLOC_FULLWARN=1 LD_LIBRARY_PATH=.:./custom
+ #CALC_ENV= CALCPATH=./cal MALLOC_VERBOSE=1 MALLOC_TRACING=1 \
+@@ -1143,9 +1143,7 @@ ifeq ($(target),Linux)
+ BLD_TYPE= calc-dynamic-only
+ #
+ CC_SHARE= -fPIC
+-DEFAULT_LIB_INSTALL_PATH= ${PWD}:/lib:/usr/lib:${LIBDIR}:/usr/local/lib
+-LD_SHARE= "-Wl,-rpath,${DEFAULT_LIB_INSTALL_PATH}" \
+- "-Wl,-rpath-link,${DEFAULT_LIB_INSTALL_PATH}"
++LD_SHARE=
+ LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+ LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+@@ -1177,9 +1175,8 @@ ifeq ($(target),Darwin)
+ BLD_TYPE= calc-dynamic-only
+ #
+ CC_SHARE= -fPIC
+-DEFAULT_LIB_INSTALL_PATH= ${PWD}:${LIBDIR}:/usr/local/lib
+ LD_SHARE= ${DARWIN_ARCH}
+-LIBCALC_SHLIB= -single_module -undefined dynamic_lookup -dynamiclib
++LIBCALC_SHLIB= -single_module -undefined dynamic_lookup -dynamiclib -install_name ${LIBDIR}/libcalc${LIB_EXT_VERSION}
+ ifdef ALLOW_CUSTOM
+ LIBCUSTCALC_SHLIB= -single_module -undefined dynamic_lookup -dynamiclib
+ else
+@@ -1196,7 +1193,7 @@ CCWERR=
+ CCOPT= ${DEBUG}
+ CCMISC= ${DARWIN_ARCH}
+ #
+-LCC= MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET} gcc
++LCC= gcc
+ CC= ${PURIFY} ${LCC} ${CCWERR}
+ #
+ # Darmin dynamic shared lib filenames
+@@ -1211,7 +1208,6 @@ LDCONFIG:=
+ # DARWIN_ARCH= -arch i386 # Intel binary
+ # DARWIN_ARCH= -arch ppc # PPC binary
+ DARWIN_ARCH= # native binary
+-MACOSX_DEPLOYMENT_TARGET=10.4
+ #
+ endif
+
+@@ -1230,9 +1226,7 @@ ifeq ($(target),FreeBSD)
+ BLD_TYPE= calc-dynamic-only
+ #
+ CC_SHARE= -fPIC
+-DEFAULT_LIB_INSTALL_PATH= ${PWD}:/lib:/usr/lib:${LIBDIR}:/usr/local/lib
+-LD_SHARE= "-Wl,-rpath,${DEFAULT_LIB_INSTALL_PATH}" \
+- "-Wl,-rpath-link,${DEFAULT_LIB_INSTALL_PATH}"
++LD_SHARE=
+ LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+ LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+@@ -1272,9 +1266,7 @@ ifeq ($(target),OpenBSD)
+ BLD_TYPE= calc-dynamic-only
+ #
+ CC_SHARE= -fPIC
+-DEFAULT_LIB_INSTALL_PATH= ${PWD}:/lib:/usr/lib:${LIBDIR}:/usr/local/lib
+-LD_SHARE= "-Wl,-rpath,${DEFAULT_LIB_INSTALL_PATH}" \
+- "-Wl,-rpath-link,${DEFAULT_LIB_INSTALL_PATH}"
++LD_SHARE=
+ LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+ LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+@@ -1347,9 +1339,7 @@ ifeq ($(target),simple)
+ BLD_TYPE= calc-static-only
+ #
+ CC_SHARE= -fPIC
+-DEFAULT_LIB_INSTALL_PATH= ${PWD}:/lib:/usr/lib:${LIBDIR}:/usr/local/lib
+-LD_SHARE= "-Wl,-rpath,${DEFAULT_LIB_INSTALL_PATH}" \
+- "-Wl,-rpath-link,${DEFAULT_LIB_INSTALL_PATH}"
++LD_SHARE=
+ LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+ #
+@@ -1403,9 +1393,7 @@ CALCRC= ${CALC_SHAREDIR}/startup;~/.calcrc;./.calcinit
+ BLD_TYPE= calc-static-only
+ #
+ CC_SHARE= -fPIC
+-DEFAULT_LIB_INSTALL_PATH= ${PWD}:/lib:/usr/lib:${LIBDIR}:/usr/local/lib
+-LD_SHARE= "-Wl,-rpath,${DEFAULT_LIB_INSTALL_PATH}" \
+- "-Wl,-rpath-link,${DEFAULT_LIB_INSTALL_PATH}"
++LD_SHARE=
+ LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+ LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
diff --git a/sci-mathematics/calc/files/calc-2.12.4.13-prefix.patch b/sci-mathematics/calc/files/calc-2.12.4.13-prefix.patch
new file mode 100644
index 000000000000..727618c3fe71
--- /dev/null
+++ b/sci-mathematics/calc/files/calc-2.12.4.13-prefix.patch
@@ -0,0 +1,87 @@
+diff --git a/Makefile b/Makefile
+index cc84386..b526442 100644
+--- a/Makefile
++++ b/Makefile
+@@ -1143,9 +1143,7 @@ ifeq ($(target),Linux)
+ BLD_TYPE= calc-dynamic-only
+ #
+ CC_SHARE= -fPIC
+-DEFAULT_LIB_INSTALL_PATH= ${PWD}:/lib:/usr/lib:${LIBDIR}:/usr/local/lib
+-LD_SHARE= "-Wl,-rpath,${DEFAULT_LIB_INSTALL_PATH}" \
+- "-Wl,-rpath-link,${DEFAULT_LIB_INSTALL_PATH}"
++LD_SHARE=
+ LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+ LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+@@ -1177,9 +1175,8 @@ ifeq ($(target),Darwin)
+ BLD_TYPE= calc-dynamic-only
+ #
+ CC_SHARE= -fPIC
+-DEFAULT_LIB_INSTALL_PATH= ${PWD}:${LIBDIR}:/usr/local/lib
+ LD_SHARE= ${DARWIN_ARCH}
+-LIBCALC_SHLIB= -single_module -undefined dynamic_lookup -dynamiclib
++LIBCALC_SHLIB= -single_module -undefined dynamic_lookup -dynamiclib -install_name ${LIBDIR}/libcalc${LIB_EXT_VERSION}
+ ifdef ALLOW_CUSTOM
+ LIBCUSTCALC_SHLIB= -single_module -undefined dynamic_lookup -dynamiclib
+ else
+@@ -1196,7 +1193,7 @@ CCWERR=
+ CCOPT= ${DEBUG}
+ CCMISC= ${DARWIN_ARCH}
+ #
+-LCC= MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET} gcc
++LCC= gcc
+ CC= ${PURIFY} ${LCC} ${CCWERR}
+ #
+ # Darmin dynamic shared lib filenames
+@@ -1211,7 +1208,6 @@ LDCONFIG:=
+ # DARWIN_ARCH= -arch i386 # Intel binary
+ # DARWIN_ARCH= -arch ppc # PPC binary
+ DARWIN_ARCH= # native binary
+-MACOSX_DEPLOYMENT_TARGET=10.8
+ #
+ endif
+
+@@ -1230,9 +1226,7 @@ ifeq ($(target),FreeBSD)
+ BLD_TYPE= calc-dynamic-only
+ #
+ CC_SHARE= -fPIC
+-DEFAULT_LIB_INSTALL_PATH= ${PWD}:/lib:/usr/lib:${LIBDIR}:/usr/local/lib
+-LD_SHARE= "-Wl,-rpath,${DEFAULT_LIB_INSTALL_PATH}" \
+- "-Wl,-rpath-link,${DEFAULT_LIB_INSTALL_PATH}"
++LD_SHARE=
+ LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+ LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+@@ -1272,9 +1266,7 @@ ifeq ($(target),OpenBSD)
+ BLD_TYPE= calc-dynamic-only
+ #
+ CC_SHARE= -fPIC
+-DEFAULT_LIB_INSTALL_PATH= ${PWD}:/lib:/usr/lib:${LIBDIR}:/usr/local/lib
+-LD_SHARE= "-Wl,-rpath,${DEFAULT_LIB_INSTALL_PATH}" \
+- "-Wl,-rpath-link,${DEFAULT_LIB_INSTALL_PATH}"
++LD_SHARE=
+ LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+ LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+@@ -1347,9 +1339,7 @@ ifeq ($(target),simple)
+ BLD_TYPE= calc-static-only
+ #
+ CC_SHARE= -fPIC
+-DEFAULT_LIB_INSTALL_PATH= ${PWD}:/lib:/usr/lib:${LIBDIR}:/usr/local/lib
+-LD_SHARE= "-Wl,-rpath,${DEFAULT_LIB_INSTALL_PATH}" \
+- "-Wl,-rpath-link,${DEFAULT_LIB_INSTALL_PATH}"
++LD_SHARE=
+ LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
+ #
+@@ -1403,9 +1393,7 @@ CALCRC= ${CALC_SHAREDIR}/startup;~/.calcrc;./.calcinit
+ BLD_TYPE= calc-static-only
+ #
+ CC_SHARE= -fPIC
+-DEFAULT_LIB_INSTALL_PATH= ${PWD}:/lib:/usr/lib:${LIBDIR}:/usr/local/lib
+-LD_SHARE= "-Wl,-rpath,${DEFAULT_LIB_INSTALL_PATH}" \
+- "-Wl,-rpath-link,${DEFAULT_LIB_INSTALL_PATH}"
++LD_SHARE=
+ LIBCALC_SHLIB= -shared "-Wl,-soname,libcalc${LIB_EXT_VERSION}"
+ ifdef ALLOW_CUSTOM
+ LIBCUSTCALC_SHLIB= -shared "-Wl,-soname,libcustcalc${LIB_EXT_VERSION}"
diff --git a/sci-mathematics/calc/metadata.xml b/sci-mathematics/calc/metadata.xml
new file mode 100644
index 000000000000..4c7eb900a0cb
--- /dev/null
+++ b/sci-mathematics/calc/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>sci-mathematics</herd>
+<longdescription lang='en'>
+ Calc is an interactive calculator which provides for easy large
+ numeric calculations, but which also can be easily programmed for
+ difficult or long calculations. It can accept a command line argument,
+ in which case it executes that single command and exits. Otherwise, it
+ enters interactive mode.
+</longdescription>
+</pkgmetadata>