From fd9c94c7bbb223276a6dc53c46895237ea341695 Mon Sep 17 00:00:00 2001 From: Nolan Clark Date: Sat, 6 Dec 2014 19:00:44 -0600 Subject: [PATCH] Created libtommath recipe --- dev-libs/libtommath/libtommath-0.42.0.recipe | 54 +++++++++++++++++++ .../patches/libtommath-0.42.0.patchset | 50 +++++++++++++++++ 2 files changed, 104 insertions(+) create mode 100644 dev-libs/libtommath/libtommath-0.42.0.recipe create mode 100644 dev-libs/libtommath/patches/libtommath-0.42.0.patchset diff --git a/dev-libs/libtommath/libtommath-0.42.0.recipe b/dev-libs/libtommath/libtommath-0.42.0.recipe new file mode 100644 index 000000000..d1fcad3a9 --- /dev/null +++ b/dev-libs/libtommath/libtommath-0.42.0.recipe @@ -0,0 +1,54 @@ +SUMMARY="LibTomMath is a theoretic integer library written entirely in C." +DESCRIPTION="LibTomMath is a free open source portable number theoretic \ +multiple-precision integer library written entirely in C." +HOMEPAGE="http://libtommath.org" +SRC_URI="https://github.com/libtom/libtommath/archive/v0.42.0.tar.gz" +CHECKSUM_SHA256="5246356ba18c1b6edf4a7bc836a3d223842b86914cdba6dd8c112bfc59e227c8" +REVISION="1" +LICENSE="Public Domain" +COPYRIGHT="2010 Tom St. Denis" +PATCHES="libtommath-0.42.0.patchset" + +ARCHITECTURES="x86_gcc2 ?x86" +SECONDARY_ARCHITECTURES="x86" + +PROVIDES=" + libtommath$secondaryArchSuffix = $portVersion + " + +PROVIDES_devel=" + libtommath${secondaryArchSuffix}_devel = $portVersion + devel:libtommath$secondaryArchSuffix = $portVersion + " + +REQUIRES=" + haiku$secondaryArchSuffix >= $haikuVersion + " + +REQUIRES_devel=" + haiku${secondaryArchSuffix}_devel >= $haikuVersion + libtommath$secondaryArchSuffix == $portVersion base + " + +BUILD_REQUIRES=" + haiku${secondaryArchSuffix}_devel >= $haikuVersion + cmd:make + cmd:cc + cmd:ar + cmd:ranlib + cmd:install + " + +BUILD() +{ + make $jobArgs +} + +INSTALL() +{ + export LIBPATH=$libDir + export INCPATH=$includeDir + make install $jobArgs + prepareInstalledDevelLibs libtommath + packageEntries devel $developDir +} diff --git a/dev-libs/libtommath/patches/libtommath-0.42.0.patchset b/dev-libs/libtommath/patches/libtommath-0.42.0.patchset new file mode 100644 index 000000000..bc86a4b3b --- /dev/null +++ b/dev-libs/libtommath/patches/libtommath-0.42.0.patchset @@ -0,0 +1,50 @@ +From f2b4b4b4aa83b658ae9a23d5195e04487a102d88 Mon Sep 17 00:00:00 2001 +From: Nolan Clark +Date: Sat, 6 Dec 2014 16:01:50 -0600 +Subject: applying patch makefile.patch + + +diff --git a/makefile b/makefile +index 70de306..e3a0a04 100644 +--- a/makefile ++++ b/makefile +@@ -27,18 +27,9 @@ CFLAGS += -fomit-frame-pointer + + endif + +-#install as this user +-ifndef INSTALL_GROUP +- GROUP=wheel +-else +- GROUP=$(INSTALL_GROUP) +-endif +- +-ifndef INSTALL_USER +- USER=root +-else +- USER=$(INSTALL_USER) +-endif ++#install as this user and group ++USER=user ++GROUP=root + + #default files to install + ifndef LIBNAME +@@ -49,14 +40,6 @@ default: ${LIBNAME} + + HEADERS=tommath.h tommath_class.h tommath_superclass.h + +-#LIBPATH-The directory for libtommath to be installed to. +-#INCPATH-The directory to install the header files for libtommath. +-#DATAPATH-The directory to install the pdf docs. +-DESTDIR= +-LIBPATH=/usr/lib +-INCPATH=/usr/include +-DATAPATH=/usr/share/doc/libtommath/pdf +- + OBJECTS=bncore.o bn_mp_init.o bn_mp_clear.o bn_mp_exch.o bn_mp_grow.o bn_mp_shrink.o \ + bn_mp_clamp.o bn_mp_zero.o bn_mp_set.o bn_mp_set_int.o bn_mp_init_size.o bn_mp_copy.o \ + bn_mp_init_copy.o bn_mp_abs.o bn_mp_neg.o bn_mp_cmp_mag.o bn_mp_cmp.o bn_mp_cmp_d.o \ +-- +1.8.3.4 +