Update from 5.3.1 to 5.5.2 to improve the chances of building.
(Leaf package, so ok during freeze.) Upstream changelog: 2009.08.14: Changes between NTL 5.5.1 and 5.5.2 New routines MulAddTo and MulSubFrom for computing x += a*b and x -= a*b, where x and a are ZZ's and b is a ZZ or a long. In the case where b is a long, this may be much faster than writing mul(t, a, b); add(x, x, t). See ZZ.txt for details. These new routines are used in a number of places in NTL to get faster algorithms (for example, the LLL routine). Fixed a relatively benign indexing bug in GF2EX discovered by Berend-Benjamin Tams using the valgrind tool. 2009.05.05: Changes between NTL 5.5 and 5.5.1 If using GMP (via either NTL_GMP_LIP or NTL_GMP_HACK), then the new version (4.3.0) of GMP implements the XGCD functionality differently, so that the coefficients do not always agree with those returned by the classical extended Euclidean algorithm. This version of NTL corrects the coefficients, so that the "classical" coefficients are always produced, regardless of GMP's implementation. This version of NTL also works around a bug in GMP 4.3.0's XGCD code (although that bug should be fixed in GMP 4.3.1). The configure script has been slightly modified: there is a new configuration variable DEF_PREFIX, whose value can be used to set PREFIX, GMP_PREFIX, and GF2X_PREFIX in one stroke. Also, the (somewhat esoteric) configure variables GMP_LIBDIR, GMP_INCDIR, GF2X_LIBDIR, and GF2X_INCDIR have slightly different meanings now. 2009.04.08: Changes between NTL 5.4.2 and 5.5 Added the ability to generate a shared library (with help from Tim Abbott). Details. Fixed some standardization issues (with help from Tim Abbot): default location of installed documentation files now conforms to standards; use of EOF now conforms to standards. Added a callback mechanism to NTL's error reporting function. See ErrorCallback in tools.txt. Added support for the gf2x library for speeding up arithmetic in GF2X (with help from Emmanuel Thom?). Details. In conjuction with the above, I also changed the GF2X so that it works better with very large polynomials: large blocks of memory are released, recursive HalfGCD algorithms are used for large polynomials. Fixed a bug in void TraceMod(zz_p& x, const zz_pX& a, const zz_pXModulus& F) (reported by Luca De Feo). Fixed a performance issue in various versions of SetCoeff (reported by Luca De Feo). Fixed the declaration of mat_zz_p transpose(const mat_zz_p& a) (reported by Benoit Lacelle). 2008.03.05: Changes between NTL 5.4.1 and 5.4.2 Fixed a bug in the sub(ZZ_pEX, ZZ_pE, ZZ_pEX) and sub(zz_pEX, zz_pE, zz_pEX) routines (reported by Charanjit Jutla). Under certain circumstances, these could outout wrong answers. 2007.05.09: Changes between NTL 5.4 and 5.4.1 Fixed rounding bug in expm1 (reported by Paul Zimmermann). Fixed memory leak in several LLL routines (reported by Friedrich Bahr). Fixed infinite loop in several LLL routines (this only occurred on machines, like x86, with double rounding). Improved GF2X timing tests (suggested by Paul Zimmermann). 2005.03.24: Changes between NTL 5.3.2 and 5.4 By default, NTL now compiles in ISO mode (using namespaces, etc.). You can always revert to traditional mode by unsetting the flag NTL_STD_CXX (either pass NTL_STD_CXX=off to the configure script, or manually edit the config.h file). Some bug fixes: The sqrt and log1p routines for the RR class would produce incorrectly rounded results in certain circumstances (although this only affected the relative error of the result very marginally). The SqrRootPrec routine for the RR class could not be called, because it was defined incorrectly. Thanks to Paul Zimmermann for finding (and fixing) these bugs! Paul has also validated NTL's RR class by cross-checking it with the MPFR library. Some performance enhancements: Added a new MulModPrecon inline function for computing (a * b) % n for single precision numbers, when b and n are fixed for several computations. On some platforms this can be twice as fast or more than the old MulMod2 routine. This indirectly affects a lot of computations that are done via homomorphic imaging (polynomial multiplication over zz_p, ZZ_p, and ZZ, matrix computations over zz_p and ZZ). Rewrote the small prime FFT to take advantage of the new MulModPrecon, and to be more cache friendly. Improved the performance of the GF2X multiplication routine. On some platforms, it can be twice as fast as the old one. Thanks (again) to Paul Zimmermann for suggesting some of these improvements and supplying some of the code. Miscellany: Rewrote several of the installation scripts in Perl (the old shell scripts were getting too messy to maintain). However, the syntax for all of the command-line interfaces remains identical. 2004.05.21: Changes between NTL 5.3.1 and 5.3.2 Some bug fixes. Re-wrote SqrRootMod to make it run faster.
This commit is contained in:
parent
967a4624f6
commit
eaf9b195af
6 changed files with 188 additions and 245 deletions
|
@ -1,7 +1,6 @@
|
|||
# $NetBSD: Makefile,v 1.24 2011/12/09 01:21:15 dholland Exp $
|
||||
# $NetBSD: Makefile,v 1.25 2012/01/02 23:42:27 dholland Exp $
|
||||
|
||||
DISTNAME= ntl-5.3.1
|
||||
PKGREVISION= 2
|
||||
DISTNAME= ntl-5.5.2
|
||||
CATEGORIES= math devel
|
||||
MASTER_SITES= http://www.shoup.net/ntl/
|
||||
|
||||
|
@ -16,6 +15,7 @@ MAKE_JOBS_SAFE= no
|
|||
WRKSRC= ${WRKDIR}/${DISTNAME}/src
|
||||
NO_CONFIGURE= yes
|
||||
USE_LANGUAGES= c c++
|
||||
USE_TOOLS+= perl
|
||||
USE_LIBTOOL= yes
|
||||
MAKE_FILE= makefile
|
||||
INSTALLATION_DIRS= lib
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
@comment $NetBSD: PLIST,v 1.4 2009/06/14 18:05:46 joerg Exp $
|
||||
@comment $NetBSD: PLIST,v 1.5 2012/01/02 23:42:28 dholland Exp $
|
||||
include/NTL/FFT.h
|
||||
include/NTL/FacVec.h
|
||||
include/NTL/GF2.h
|
||||
|
@ -11,6 +11,7 @@ include/NTL/GF2XVec.h
|
|||
include/NTL/HNF.h
|
||||
include/NTL/LLL.h
|
||||
include/NTL/RR.h
|
||||
include/NTL/SPMM_ASM.h
|
||||
include/NTL/WordVector.h
|
||||
include/NTL/ZZ.h
|
||||
include/NTL/ZZVec.h
|
||||
|
@ -109,6 +110,9 @@ share/doc/NTL/ZZ_pEX.txt
|
|||
share/doc/NTL/ZZ_pEXFactoring.txt
|
||||
share/doc/NTL/ZZ_pX.txt
|
||||
share/doc/NTL/ZZ_pXFactoring.txt
|
||||
share/doc/NTL/arrow1.gif
|
||||
share/doc/NTL/arrow2.gif
|
||||
share/doc/NTL/arrow3.gif
|
||||
share/doc/NTL/config.txt
|
||||
share/doc/NTL/conversions.txt
|
||||
share/doc/NTL/copying.txt
|
||||
|
@ -145,6 +149,7 @@ share/doc/NTL/tour-ex4.html
|
|||
share/doc/NTL/tour-ex5.html
|
||||
share/doc/NTL/tour-ex6.html
|
||||
share/doc/NTL/tour-examples.html
|
||||
share/doc/NTL/tour-gf2x.html
|
||||
share/doc/NTL/tour-gmp.html
|
||||
share/doc/NTL/tour-impl.html
|
||||
share/doc/NTL/tour-intro.html
|
||||
|
@ -153,6 +158,7 @@ share/doc/NTL/tour-roadmap.html
|
|||
share/doc/NTL/tour-stdcxx.html
|
||||
share/doc/NTL/tour-struct.html
|
||||
share/doc/NTL/tour-time.html
|
||||
share/doc/NTL/tour-tips.html
|
||||
share/doc/NTL/tour-unix.html
|
||||
share/doc/NTL/tour-win.html
|
||||
share/doc/NTL/tour.html
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
$NetBSD: distinfo,v 1.6 2009/12/03 17:48:58 joerg Exp $
|
||||
$NetBSD: distinfo,v 1.7 2012/01/02 23:42:28 dholland Exp $
|
||||
|
||||
SHA1 (ntl-5.3.1.tar.gz) = 22f9004d59595ddf931150e39805880cca67f8bc
|
||||
RMD160 (ntl-5.3.1.tar.gz) = 2eec6b8c72f342e74c81fca432434818ce3615eb
|
||||
Size (ntl-5.3.1.tar.gz) = 669649 bytes
|
||||
SHA1 (patch-aa) = c6e4211c55d9c1e038718e690d485e195db6727b
|
||||
SHA1 (patch-ab) = 726bb373a3dc31c33763282c5cc7c07110a33f23
|
||||
SHA1 (patch-ac) = f6a1e211379e713aee4fb575cc2d92563cbdd6fd
|
||||
SHA1 (ntl-5.5.2.tar.gz) = b45e3858f7f351afeb7fbb831b256befc4892b06
|
||||
RMD160 (ntl-5.5.2.tar.gz) = 3ba508219276b3922ec6def391100a23b79f6193
|
||||
Size (ntl-5.5.2.tar.gz) = 707247 bytes
|
||||
SHA1 (patch-aa) = e2900601cf350c8d93f7aa77969b3caca164c8fa
|
||||
SHA1 (patch-ab) = b91b052c88ea49a4138723259a312c43148737cc
|
||||
SHA1 (patch-ac) = 99c32692cd27ea63e966c3fe1df0b8a6373f5018
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
$NetBSD: patch-aa,v 1.6 2009/12/03 17:48:58 joerg Exp $
|
||||
$NetBSD: patch-aa,v 1.7 2012/01/02 23:42:28 dholland Exp $
|
||||
|
||||
--- makefile.orig Tue Dec 17 15:43:30 2002
|
||||
- configure for pkgsrc
|
||||
- libtoolize
|
||||
|
||||
--- makefile.orig 2009-08-14 12:53:13.000000000 +0000
|
||||
+++ makefile
|
||||
@@ -7,7 +7,7 @@
|
||||
###############################################################
|
||||
|
@ -25,7 +28,7 @@ $NetBSD: patch-aa,v 1.6 2009/12/03 17:48:58 joerg Exp $
|
|||
# Flags for the C compiler
|
||||
# Some useful flags:
|
||||
# -O2 -- recommended level of optimization
|
||||
@@ -31,7 +31,7 @@ CFLAGS=-O2
|
||||
@@ -32,7 +32,7 @@ CFLAGS=-O2
|
||||
|
||||
|
||||
|
||||
|
@ -34,7 +37,7 @@ $NetBSD: patch-aa,v 1.6 2009/12/03 17:48:58 joerg Exp $
|
|||
# Flags for the C++ compiler (usually the same as CFLAGS)
|
||||
# Some useful flags:
|
||||
# -+ -- needed with xlC to make it treat .c files as C++ files
|
||||
@@ -40,16 +40,16 @@ CXXFLAGS=$(CFLAGS)
|
||||
@@ -41,16 +41,16 @@ CXXFLAGS=$(CFLAGS)
|
||||
# The defaults should almost always be OK.
|
||||
|
||||
|
||||
|
@ -52,10 +55,10 @@ $NetBSD: patch-aa,v 1.6 2009/12/03 17:48:58 joerg Exp $
|
|||
|
||||
-LDFLAGS=
|
||||
+#LDFLAGS=
|
||||
# arguments for linker for C++ programs
|
||||
# arguments for linker for C programs
|
||||
|
||||
LDFLAGS_CXX=$(LDFLAGS)
|
||||
@@ -61,13 +61,13 @@ LDLIBS=-lm
|
||||
@@ -62,15 +62,15 @@ LDLIBS=-lm
|
||||
LDLIBS_CXX=$(LDLIBS)
|
||||
# libraries for linking C++ programs
|
||||
|
||||
|
@ -63,35 +66,61 @@ $NetBSD: patch-aa,v 1.6 2009/12/03 17:48:58 joerg Exp $
|
|||
+#CPPFLAGS=
|
||||
# arguments for the C preprocessor
|
||||
|
||||
-PREFIX=/usr/local
|
||||
+#PREFIX=/usr/local
|
||||
-LIBTOOL=libtool
|
||||
+#LIBTOOL=libtool
|
||||
# libtool command
|
||||
|
||||
-DEF_PREFIX=/usr/local
|
||||
+DEF_PREFIX=/nonexistent
|
||||
|
||||
-PREFIX=$(DEF_PREFIX)
|
||||
+#PREFIX=$(DEF_PREFIX)
|
||||
LIBDIR=$(PREFIX)/lib
|
||||
INCLUDEDIR=$(PREFIX)/include
|
||||
-DOCDIR=$(PREFIX)/doc
|
||||
+DOCDIR=$(PREFIX)/share/doc
|
||||
# where to install NTL
|
||||
|
||||
###############################################################
|
||||
@@ -87,15 +87,15 @@ DOCDIR=$(PREFIX)/doc
|
||||
DOCDIR=$(PREFIX)/share/doc
|
||||
@@ -92,17 +92,17 @@ DOCDIR=$(PREFIX)/share/doc
|
||||
###############################################################
|
||||
|
||||
|
||||
-GMP_INCDIR=
|
||||
+GMP_INCDIR= -I${BUILDLINK_PREFIX.gmp}/include
|
||||
# Set to -I<directory containing gmp.h> if using GMP and GMP
|
||||
# is not installed in a standard system directory, empty otherwise
|
||||
-GMP_PREFIX=$(DEF_PREFIX)
|
||||
+GMP_PREFIX=${BUILDLINK_PREFIX.gmp}
|
||||
|
||||
-GMP_LIBDIR=
|
||||
+GMP_LIBDIR= -Wl,-R${BUILDLINK_PREFIX.gmp}/lib -L${BUILDLINK_PREFIX.gmp}/lib
|
||||
# Set to -L<directory containing libgmp.a> if using GMP and GMP
|
||||
# is not installed in a standard system directory, empty otherwise
|
||||
-GMP_INCDIR=$(GMP_PREFIX)/include
|
||||
+GMP_INCDIR= ${GMP_PREFIX}/include
|
||||
# directory containing gmp.h if using GMP
|
||||
|
||||
-GMP_LIB=
|
||||
+GMP_LIB= -lgmp
|
||||
# Set to -lgmp if using GMP, empty otherwise
|
||||
-GMP_LIBDIR=$(GMP_PREFIX)/lib
|
||||
+GMP_LIBDIR= ${GMP_PREFIX}/lib
|
||||
# directory containing libgmp.a if using GMP
|
||||
|
||||
-GMP_OPT_INCDIR=# -I$(GMP_INCDIR) # GMP
|
||||
-GMP_OPT_LIBDIR=# -L$(GMP_LIBDIR) # GMP
|
||||
-GMP_OPT_LIB=# -lgmp # GMP
|
||||
+GMP_OPT_INCDIR= -I$(GMP_INCDIR) # GMP
|
||||
+GMP_OPT_LIBDIR= -Wl,-R$(GMP_LIBDIR) -L$(GMP_LIBDIR) # GMP
|
||||
+GMP_OPT_LIB= -lgmp # GMP
|
||||
# uncomment these if using GMP
|
||||
|
||||
|
||||
@@ -116,7 +116,7 @@ GMP_OPT_LIB=# -lgmp # GMP
|
||||
#
|
||||
###############################################################
|
||||
@@ -147,7 +147,7 @@ OBJ=$(O19)
|
||||
|
||||
-GF2X_PREFIX=$(DEF_PREFIX)
|
||||
+GF2X_PREFIX=/nonexistent
|
||||
|
||||
GF2X_INCDIR=$(GF2X_PREFIX)/include
|
||||
# directory containing gf2x.h if using gf2x
|
||||
@@ -125,7 +125,7 @@ GF2X_LIBDIR=$(GF2X_PREFIX)/lib
|
||||
# directory containing libgf2x.a
|
||||
|
||||
GF2X_OPT_INCDIR=# -I$(GF2X_INCDIR) # GF2X
|
||||
-GF2X_OPT_LIBDIR=# -L$(GF2X_LIBDIR) # GF2X
|
||||
+GF2X_OPT_LIBDIR=# -Wl,-R$(GF2X_LIBDIR) -L$(GF2X_LIBDIR) # GF2X
|
||||
GF2X_OPT_LIB=# -lgf2x # GF2X
|
||||
# uncomment these if using gf2x
|
||||
|
||||
@@ -179,7 +179,7 @@ OBJ=$(O19)
|
||||
S01=FFT.c FacVec.c GF2.c GF2E.c GF2EX.c GF2EXFactoring.c GF2X.c GF2X1.c
|
||||
S02=$(S01) GF2XFactoring.c GF2XVec.c HNF.c ctools.c LLL.c LLL_FP.c LLL_QP.c
|
||||
S03=$(S02) LLL_RR.c LLL_XD.c RR.c WordVector.c ZZ.c ZZVec.c ZZX.c ZZX1.c
|
||||
|
@ -100,7 +129,7 @@ $NetBSD: patch-aa,v 1.6 2009/12/03 17:48:58 joerg Exp $
|
|||
S05=$(S04) ZZ_pEXFactoring.c ZZ_pX.c ZZ_pX1.c ZZ_pXCharPoly.c
|
||||
S06=$(S05) ZZ_pXFactoring.c fileio.c lip.c lzz_p.c lzz_pE.c lzz_pEX.c
|
||||
S07=$(S06) lzz_pEXFactoring.c lzz_pX.c lzz_pX1.c
|
||||
@@ -162,8 +162,8 @@ S15=$(S14) vec_long.c vec_lzz_p.c vec_lz
|
||||
@@ -194,8 +194,8 @@ S15=$(S14) vec_long.c vec_lzz_p.c vec_lz
|
||||
S16=$(S15) vec_vec_GF2.c vec_vec_GF2E.c vec_vec_RR.c vec_vec_ZZ.c
|
||||
S17=$(S16) vec_vec_ZZ_p.c vec_vec_ZZ_pE.c vec_vec_long.c vec_vec_lzz_p.c
|
||||
S18=$(S17) vec_vec_lzz_pE.c vec_xdouble.c xdouble.c
|
||||
|
@ -111,16 +140,7 @@ $NetBSD: patch-aa,v 1.6 2009/12/03 17:48:58 joerg Exp $
|
|||
|
||||
SRC = $(S20)
|
||||
|
||||
@@ -178,7 +178,7 @@ SINC = c_lip_impl.h g_lip_impl.h
|
||||
# library header files
|
||||
|
||||
IN01= FFT.h FacVec.h GF2.h GF2E.h GF2EX.h GF2EXFactoring.h GF2X.h
|
||||
-IN02=$(IN01) GF2XFactoring.h GF2XVec.h HNF.h ctools.h LLL.h
|
||||
+IN02=$(IN01) GF2XFactoring.h GF2XVec.h HNF.h ctools.h LLL.h
|
||||
IN03=$(IN02) RR.h WordVector.h ZZ.h ZZVec.h ZZX.h ZZXFactoring.h ZZ_p.h
|
||||
IN04=$(IN03) ZZ_pE.h ZZ_pEX.h ZZ_pEXFactoring.h ZZ_pX.h ZZ_pXFactoring.h
|
||||
IN05=$(IN04) fileio.h lip.h lzz_p.h lzz_pE.h lzz_pEX.h lzz_pEXFactoring.h
|
||||
@@ -202,9 +202,9 @@ INCL=$(IN18)
|
||||
@@ -234,9 +234,9 @@ INCL=$(IN18)
|
||||
|
||||
# test data
|
||||
|
||||
|
@ -133,26 +153,7 @@ $NetBSD: patch-aa,v 1.6 2009/12/03 17:48:58 joerg Exp $
|
|||
TD4=$(TD3) CharPolyTestOut QuadTestIn QuadTestOut
|
||||
|
||||
TD = $(TD4)
|
||||
@@ -260,15 +260,15 @@ DOC = $(D18)
|
||||
# test program executables
|
||||
|
||||
PROG1=QuickTest BerlekampTest CanZassTest ZZXFacTest MoreFacTest LLLTest BitMatTest
|
||||
-PROG2=$(PROG1) MatrixTest CharPolyTest RRTest QuadTest
|
||||
+PROG2=$(PROG1) MatrixTest CharPolyTest RRTest QuadTest
|
||||
PROG3=$(PROG2) GF2EXTest subset ZZ_pEXTest lzz_pEXTest
|
||||
PROGS = $(PROG3)
|
||||
|
||||
# things to save to a tar file
|
||||
|
||||
-SFI1=makefile $(SRC) $(SINC) $(SCRIPTS) $(MD) $(GT) $(TS) $(TD) mach_desc.win
|
||||
+SFI1=makefile $(SRC) $(SINC) $(SCRIPTS) $(MD) $(GT) $(TS) $(TD) mach_desc.win
|
||||
SFI2=$(SFI1) MulTimeTest.c PolyTimeTest.c clr_AVOID_BRANCHING clr_AVOID_FLOAT
|
||||
-SFI3=$(SFI2) clr_FFT_PIPELINE clr_LONG_LONG clr_TBL_REM clr_WIZARD_HACK
|
||||
+SFI3=$(SFI2) clr_FFT_PIPELINE clr_LONG_LONG clr_TBL_REM clr_WIZARD_HACK
|
||||
SFI4=$(SFI3) InitSettings.c mul_banner poly_banner set_AVOID_BRANCHING set_AVOID_FLOAT
|
||||
SFI5=$(SFI4) set_FFT_PIPELINE set_LONG_LONG set_TBL_REM set_WIZARD_HACK
|
||||
SFI6=$(SFI5) WizComp.c DispSettings.c config_template WizardAux Wizard def_makefile
|
||||
@@ -285,11 +285,11 @@ SFILES=$(SFI6)
|
||||
@@ -314,11 +314,11 @@ SFILES=$(SFI3)
|
||||
NTL_INCLUDE = -I../include -I.
|
||||
# NTL needs this to find its include files
|
||||
|
||||
|
@ -168,15 +169,16 @@ $NetBSD: patch-aa,v 1.6 2009/12/03 17:48:58 joerg Exp $
|
|||
|
||||
|
||||
|
||||
@@ -298,14 +298,14 @@ all:
|
||||
@@ -332,7 +332,7 @@ all:
|
||||
make setup2
|
||||
make setup3
|
||||
make setup4
|
||||
- make ntl.a
|
||||
+ make libntl.la
|
||||
+ make libntl.a
|
||||
touch all
|
||||
|
||||
|
||||
# setup1 generates the file ../incluse/NTL/mach_desc.h
|
||||
@@ -340,7 +340,7 @@ all:
|
||||
|
||||
setup1:
|
||||
$(COMPILE) MakeDescAux.c
|
||||
|
@ -185,128 +187,131 @@ $NetBSD: patch-aa,v 1.6 2009/12/03 17:48:58 joerg Exp $
|
|||
./MakeDesc
|
||||
mv mach_desc.h ../include/NTL/mach_desc.h
|
||||
|
||||
@@ -332,9 +332,10 @@ setup4:
|
||||
@@ -367,10 +367,16 @@ setup4:
|
||||
sh Wizard $(WIZARD)
|
||||
|
||||
|
||||
-ntl.a: $(OBJ)
|
||||
- $(AR) $(ARFLAGS) ntl.a $(OBJ)
|
||||
- - $(RANLIB) ntl.a
|
||||
+libntl.la: $(OBJ)
|
||||
+ $(LIBTOOL) --mode=link $(CC) -o libntl.la $(OBJ:.o=.lo) \
|
||||
+ $(GMP_LIBDIR) $(GMP_LIB) -rpath $(LIBDIR) \
|
||||
+ -version-info 0:1
|
||||
- $(AR) $(ARFLAGS) ntl.a $(OBJ) #LSTAT
|
||||
- - $(RANLIB) ntl.a #LSTAT
|
||||
-# $(LIBTOOL) --mode=link $(LINK_CXX) -o libntl.la $(OBJ:.o=.lo) $(GMP_OPT_LIBDIR) $(GMP_OPT_LIB) $(GF2X_OPT_LIBDIR) $(GF2X_OPT_LIB) $(LDLIBS_CXX) -rpath $(LIBDIR) -version-info `cat VERSION_INFO` #LSHAR
|
||||
+libntl.a: $(OBJ)
|
||||
+ $(LIBTOOL) --mode=link $(CXX) -o libntl.la $(OBJ:.o=.lo) \
|
||||
+ $(GMP_OPT_LIBDIR) $(GMP_OPT_LIB) \
|
||||
+ $(GF2X_OPT_LIBDIR) $(GF2X_OPT_LIB) \
|
||||
+ $(LDLIBS_CXX) \
|
||||
+ -rpath $(LIBDIR) \
|
||||
+ -version-info `cat VERSION_INFO`
|
||||
+# $(AR) $(ARFLAGS) ntl.a $(OBJ) #LSTAT
|
||||
+# - $(RANLIB) ntl.a #LSTAT
|
||||
+## $(LIBTOOL) --mode=link $(LINK_CXX) -o libntl.la $(OBJ:.o=.lo) $(GMP_OPT_LIBDIR) $(GMP_OPT_LIB) $(GF2X_OPT_LIBDIR) $(GF2X_OPT_LIB) $(LDLIBS_CXX) -rpath $(LIBDIR) -version-info `cat VERSION_INFO` #LSHAR
|
||||
|
||||
lip.o: lip.c g_lip_impl.h c_lip_impl.h lip_gmp_aux_impl.h
|
||||
$(COMPILE) $(GMP_INCDIR) lip.c
|
||||
@@ -343,15 +344,15 @@ ctools.o: ctools.c
|
||||
$(COMPILE) ctools.c
|
||||
LCOMP= #LSTAT
|
||||
# LCOMP=$(LIBTOOL) --mode=compile #LSHAR
|
||||
@@ -391,7 +397,7 @@ GetTime.o: GetTime.c
|
||||
$(LCOMP) $(COMPILE_CXX) $(GF2X_OPT_INCDIR) $<
|
||||
|
||||
|
||||
-GetTime.o: GetTime.c
|
||||
+GetTime.o: GetTime.c
|
||||
$(COMPILE) GetTime.c
|
||||
|
||||
|
||||
-.c.o:
|
||||
+.c.o:
|
||||
$(COMPILE_CXX) $<
|
||||
|
||||
-.c:
|
||||
- $(LINK_CXX) -o $@ $< ntl.a $(GMP_LIBDIR) $(GMP_LIB) $(LDLIBS_CXX)
|
||||
+.c:
|
||||
+ $(LINK_CXX) -o $@ $< libntl.la $(GMP_LIBDIR) $(GMP_LIB) $(LDLIBS_CXX)
|
||||
.c:
|
||||
- $(LINK_CXX) -o $@ $< ntl.a $(GMP_OPT_LIBDIR) $(GMP_OPT_LIB) $(GF2X_OPT_LIBDIR) $(GF2X_OPT_LIB) $(LDLIBS_CXX) #LSTAT
|
||||
+ $(LINK_CXX) -o $@ $< libntl.la $(GMP_OPT_LIBDIR) $(GMP_OPT_LIB) $(GF2X_OPT_LIBDIR) $(GF2X_OPT_LIB) $(LDLIBS_CXX) #LSTAT
|
||||
# $(LIBTOOL) --mode=link $(LINK_CXX) -o $@ $< libntl.la #LSHAR
|
||||
|
||||
#################################################################
|
||||
#
|
||||
@@ -372,25 +373,20 @@ check:
|
||||
# make install just does a simple copy of the include file
|
||||
# and library
|
||||
# make uninstall removes these files
|
||||
-#
|
||||
+#
|
||||
#################################################################
|
||||
|
||||
|
||||
@@ -425,23 +431,29 @@ check:
|
||||
|
||||
|
||||
install:
|
||||
- mkdir -p $(LIBDIR)
|
||||
- cp ntl.a $(LIBDIR)/libntl.a
|
||||
- mkdir -p $(INCLUDEDIR)
|
||||
- - rm -r $(INCLUDEDIR)/NTL
|
||||
- mkdir $(INCLUDEDIR)/NTL
|
||||
- cp ../include/NTL/*.h $(INCLUDEDIR)/NTL
|
||||
- mkdir -p $(DOCDIR)
|
||||
- - rm -r $(DOCDIR)/NTL
|
||||
- mkdir $(DOCDIR)/NTL
|
||||
- cp ../doc/*.txt $(DOCDIR)/NTL
|
||||
- cp ../doc/*.html $(DOCDIR)/NTL
|
||||
- cp ../doc/*.gif $(DOCDIR)/NTL
|
||||
+ $(LIBTOOL) --mode=install $(BSD_INSTALL_DATA) libntl.la ${DESTDIR}$(LIBDIR)
|
||||
- mkdir -p -m 755 $(INCLUDEDIR)
|
||||
- rm -rf $(INCLUDEDIR)/NTL
|
||||
- mkdir -m 755 $(INCLUDEDIR)/NTL
|
||||
- cp -p ../include/NTL/*.h $(INCLUDEDIR)/NTL
|
||||
- - chmod -R a+r $(INCLUDEDIR)/NTL
|
||||
- mkdir -p -m 755 $(DOCDIR)
|
||||
- rm -rf $(DOCDIR)/NTL
|
||||
- mkdir -m 755 $(DOCDIR)/NTL
|
||||
- cp -p ../doc/*.txt $(DOCDIR)/NTL
|
||||
- cp -p ../doc/*.html $(DOCDIR)/NTL
|
||||
- cp -p ../doc/*.gif $(DOCDIR)/NTL
|
||||
- - chmod -R a+r $(DOCDIR)/NTL
|
||||
- mkdir -p -m 755 $(LIBDIR)
|
||||
- cp -p ntl.a $(LIBDIR)/libntl.a #LSTAT
|
||||
- - chmod a+r $(LIBDIR)/libntl.a #LSTAT
|
||||
-# $(LIBTOOL) --mode=install cp -p libntl.la $(LIBDIR) #LSHAR
|
||||
-
|
||||
+# mkdir -p -m 755 $(INCLUDEDIR)
|
||||
+# rm -rf $(INCLUDEDIR)/NTL
|
||||
+# mkdir -m 755 $(INCLUDEDIR)/NTL
|
||||
+# cp -p ../include/NTL/*.h $(INCLUDEDIR)/NTL
|
||||
+# - chmod -R a+r $(INCLUDEDIR)/NTL
|
||||
+# mkdir -p -m 755 $(DOCDIR)
|
||||
+# rm -rf $(DOCDIR)/NTL
|
||||
+# mkdir -m 755 $(DOCDIR)/NTL
|
||||
+# cp -p ../doc/*.txt $(DOCDIR)/NTL
|
||||
+# cp -p ../doc/*.html $(DOCDIR)/NTL
|
||||
+# cp -p ../doc/*.gif $(DOCDIR)/NTL
|
||||
+# - chmod -R a+r $(DOCDIR)/NTL
|
||||
+# mkdir -p -m 755 $(LIBDIR)
|
||||
+# cp -p ntl.a $(LIBDIR)/libntl.a #LSTAT
|
||||
+# - chmod a+r $(LIBDIR)/libntl.a #LSTAT
|
||||
+## $(LIBTOOL) --mode=install cp -p libntl.la $(LIBDIR) #LSHAR
|
||||
+ $(BSD_INSTALL_DATA_DIR) ${DESTDIR}$(INCLUDEDIR)/NTL
|
||||
+ $(BSD_INSTALL_DATA) ../include/NTL/*.h ${DESTDIR}$(INCLUDEDIR)/NTL
|
||||
+ $(BSD_INSTALL_DATA_DIR) ${DESTDIR}$(DOCDIR)/NTL
|
||||
+ $(BSD_INSTALL_DATA) ../doc/*.txt ${DESTDIR}$(DOCDIR)/NTL
|
||||
+ $(BSD_INSTALL_DATA) ../doc/*.html ${DESTDIR}$(DOCDIR)/NTL
|
||||
+
|
||||
|
||||
+ $(BSD_INSTALL_DATA) ../doc/*.gif ${DESTDIR}$(DOCDIR)/NTL
|
||||
+ $(LIBTOOL) --mode=install $(BSD_INSTALL_LIB) libntl.la ${DESTDIR}$(LIBDIR)
|
||||
|
||||
uninstall:
|
||||
@@ -409,17 +405,17 @@ uninstall:
|
||||
#
|
||||
rm -f $(LIBDIR)/libntl.a #LSTAT
|
||||
@@ -461,7 +473,7 @@ uninstall:
|
||||
#################################################################
|
||||
|
||||
-clobber:
|
||||
- - rm ntl.a mach_desc.h ../include/NTL/mach_desc.h GetTime.c
|
||||
- - rm lip_gmp_aux_impl.h ../include/NTL/gmp_aux.h
|
||||
+clobber:
|
||||
+ - rm -fr libntl.la .libs mach_desc.h ../include/NTL/mach_desc.h GetTime.c
|
||||
+ - rm -f lip_gmp_aux_impl.h ../include/NTL/gmp_aux.h
|
||||
- sh RemoveProg $(PROGS) MakeDesc TestGetTime gen_lip_gmp_aux gen_gmp_aux
|
||||
- - rm *.o
|
||||
- - rm -r small
|
||||
+ - rm -f *.o *.lo
|
||||
+ - rm -fr small
|
||||
clobber:
|
||||
- rm -f ntl.a mach_desc.h ../include/NTL/mach_desc.h GetTime.c
|
||||
+ rm -f mach_desc.h ../include/NTL/mach_desc.h GetTime.c
|
||||
rm -f lip_gmp_aux_impl.h ../include/NTL/gmp_aux.h
|
||||
sh RemoveProg $(PROGS) MakeDesc TestGetTime gen_lip_gmp_aux gen_gmp_aux
|
||||
rm -f *.o
|
||||
@@ -472,7 +484,7 @@ clobber:
|
||||
|
||||
clean:
|
||||
- - rm *.o
|
||||
+ - rm -f *.o *.lo
|
||||
- sh RemoveProg MakeDesc TestGetTime gen_lip_gmp_aux gen_gmp_aux
|
||||
- - rm -r small
|
||||
+ - rm -fr small
|
||||
|
||||
#################################################################
|
||||
#
|
||||
@@ -436,7 +432,7 @@ DIRNAME=ntl-5.3.1
|
||||
WINDIR=WinNTL-5_3_1
|
||||
|
||||
package:
|
||||
- sh unixify "$(SFILES)" "$(INCL)" "$(DOC)"
|
||||
+ sh unixify "$(SFILES)" "$(INCL)" "$(DOC)"
|
||||
-rm -r $(DIRNAME)
|
||||
mv unix $(DIRNAME)
|
||||
chmod -R a+rX $(DIRNAME)
|
||||
@@ -467,17 +463,17 @@ WO2 = $(WO1) ZZ_pX1.o lip.o tools.o vec_
|
||||
WOBJ = $(WO2)
|
||||
sh RemoveProg MakeDesc TestGetTime gen_lip_gmp_aux gen_gmp_aux
|
||||
- rm -f *.o
|
||||
+ rm -f *.o *.lo
|
||||
rm -rf small
|
||||
# - $(LIBTOOL) --mode=clean rm -f libntl.la *.lo #LSHAR
|
||||
|
||||
@@ -522,22 +534,25 @@ WO3 = $(WO2) GF2.o WordVector.o vec_GF2.
|
||||
WOBJ = $(WO3)
|
||||
|
||||
# wntl.a: LCOMP= #LSHAR
|
||||
-wntl.a: $(WOBJ)
|
||||
- $(AR) $(ARFLAGS) wntl.a $(WOBJ)
|
||||
- - $(RANLIB) wntl.a
|
||||
+libwntl.la: $(WOBJ)
|
||||
+ $(LIBTOOL) --mode=link $(CC) -o libwntl.la $(WOBJ:.o=.lo) -rpath $(LIBDIR) \
|
||||
+ -version-info 0:0
|
||||
|
||||
|
||||
+libwntl.la: $(WOBJ)
|
||||
+# $(AR) $(ARFLAGS) wntl.a $(WOBJ)
|
||||
+# - $(RANLIB) wntl.a
|
||||
+ $(LIBTOOL) --mode=link $(CC) -o libwntl.la $(WOBJ:.o=.lo) \
|
||||
+ -rpath $(LIBDIR) \
|
||||
+ -version-info 0:0
|
||||
|
||||
MulTimeTest:
|
||||
- $(LINK_CXX) -o MulTimeTest MulTimeTest.c wntl.a $(GMP_LIBDIR) $(GMP_LIB) $(LDLIBS_CXX)
|
||||
+ $(LINK_CXX) -o MulTimeTest MulTimeTest.c libwntl.la $(GMP_LIBDIR) $(GMP_LIB) $(LDLIBS_CXX)
|
||||
- $(LINK_CXX) -o MulTimeTest MulTimeTest.c wntl.a $(GMP_OPT_LIBDIR) $(GMP_OPT_LIB) $(LDLIBS_CXX)
|
||||
+ $(LINK_CXX) -o MulTimeTest MulTimeTest.c libwntl.la $(GMP_OPT_LIBDIR) $(GMP_OPT_LIB) $(LDLIBS_CXX)
|
||||
|
||||
PolyTimeTest:
|
||||
- $(LINK_CXX) -o PolyTimeTest PolyTimeTest.c wntl.a $(GMP_LIBDIR) $(GMP_LIB) $(LDLIBS_CXX)
|
||||
+ $(LINK_CXX) -o PolyTimeTest PolyTimeTest.c libwntl.la $(GMP_LIBDIR) $(GMP_LIB) $(LDLIBS_CXX)
|
||||
- $(LINK_CXX) -o PolyTimeTest PolyTimeTest.c wntl.a $(GMP_OPT_LIBDIR) $(GMP_OPT_LIB) $(LDLIBS_CXX)
|
||||
+ $(LINK_CXX) -o PolyTimeTest PolyTimeTest.c libwntl.la $(GMP_OPT_LIBDIR) $(GMP_OPT_LIB) $(LDLIBS_CXX)
|
||||
|
||||
Poly1TimeTest:
|
||||
- $(LINK_CXX) -o Poly1TimeTest Poly1TimeTest.c wntl.a $(GMP_OPT_LIBDIR) $(GMP_OPT_LIB) $(LDLIBS_CXX)
|
||||
+ $(LINK_CXX) -o Poly1TimeTest Poly1TimeTest.c libwntl.la $(GMP_OPT_LIBDIR) $(GMP_OPT_LIB) $(LDLIBS_CXX)
|
||||
|
||||
|
||||
GF2XTimeTest:
|
||||
- $(LINK_CXX) -o GF2XTimeTest GF2XTimeTest.c wntl.a $(GMP_OPT_LIBDIR) $(GMP_OPT_LIB) $(LDLIBS_CXX)
|
||||
+ $(LINK_CXX) -o GF2XTimeTest GF2XTimeTest.c libwntl.la $(GMP_OPT_LIBDIR) $(GMP_OPT_LIB) $(LDLIBS_CXX)
|
||||
|
||||
InitSettings:
|
||||
$(LINK_CXX) -o InitSettings InitSettings.c $(LDLIBS_CXX)
|
||||
|
|
|
@ -1,4 +1,6 @@
|
|||
$NetBSD: patch-ab,v 1.1 2001/01/29 06:53:28 jtb Exp $
|
||||
$NetBSD: patch-ab,v 1.2 2012/01/02 23:42:28 dholland Exp $
|
||||
|
||||
Configure for pkgsrc.
|
||||
|
||||
--- ../include/NTL/config.h.orig Mon Jan 29 06:50:11 2001
|
||||
+++ ../include/NTL/config.h
|
||||
|
|
|
@ -1,85 +1,15 @@
|
|||
$NetBSD: patch-ac,v 1.1 2001/06/20 10:19:28 jtb Exp $
|
||||
$NetBSD: patch-ac,v 1.2 2012/01/02 23:42:28 dholland Exp $
|
||||
|
||||
--- WizardAux.orig Fri Jun 8 14:23:16 2001
|
||||
- adjust to libtooling
|
||||
|
||||
--- WizardAux.orig 2009-08-14 12:53:12.000000000 +0000
|
||||
+++ WizardAux
|
||||
@@ -12,7 +12,7 @@
|
||||
cat clr_LONG_LONG clr_AVOID_FLOAT > best1
|
||||
cat clr_LONG_LONG clr_AVOID_FLOAT clr_TBL_REM clr_AVOID_BRANCHING clr_FFT_PIPELINE set_WIZARD_HACK isettings > isettings1
|
||||
sed -f isettings1 config_template > ../include/NTL/config.h
|
||||
-make wntl.a
|
||||
+make libwntl.la
|
||||
sh RemoveProg MulTimeTest
|
||||
@@ -47,7 +47,7 @@ sub RunProg {
|
||||
my $val;
|
||||
my $res;
|
||||
|
||||
- system("make wntl.a");
|
||||
+ system("make libwntl.la");
|
||||
RemoveProg($name);
|
||||
system("make $name");
|
||||
|
||||
if test -f NO_GMP_LIP
|
||||
@@ -33,7 +33,7 @@
|
||||
cat clr_LONG_LONG set_AVOID_FLOAT clr_TBL_REM clr_AVOID_BRANCHING clr_FFT_PIPELINE set_WIZARD_HACK isettings > isettings1
|
||||
sed -f isettings1 config_template > ../include/NTL/config.h
|
||||
rm lip.o
|
||||
- make wntl.a
|
||||
+ make libwntl.la
|
||||
sh RemoveProg MulTimeTest
|
||||
make MulTimeTest
|
||||
if test -f MulTimeTest
|
||||
@@ -55,7 +55,7 @@
|
||||
cat set_LONG_LONG clr_AVOID_FLOAT clr_TBL_REM clr_AVOID_BRANCHING clr_FFT_PIPELINE set_WIZARD_HACK isettings > isettings1
|
||||
sed -f isettings1 config_template > ../include/NTL/config.h
|
||||
rm lip.o
|
||||
- make wntl.a
|
||||
+ make libwntl.la
|
||||
sh RemoveProg MulTimeTest
|
||||
make MulTimeTest
|
||||
if test -f MulTimeTest
|
||||
@@ -79,7 +79,7 @@
|
||||
cat best1 clr_TBL_REM clr_AVOID_BRANCHING clr_FFT_PIPELINE set_WIZARD_HACK isettings > isettings1
|
||||
sed -f isettings1 config_template > ../include/NTL/config.h
|
||||
rm lip.o
|
||||
-make wntl.a
|
||||
+make libwntl.la
|
||||
sh RemoveProg PolyTimeTest
|
||||
make PolyTimeTest
|
||||
if test -f PolyTimeTest
|
||||
@@ -95,7 +95,7 @@
|
||||
cat best1 clr_TBL_REM clr_AVOID_BRANCHING set_FFT_PIPELINE set_WIZARD_HACK isettings > isettings1
|
||||
sed -f isettings1 config_template > ../include/NTL/config.h
|
||||
rm FFT.o
|
||||
-make wntl.a
|
||||
+make libwntl.la
|
||||
sh RemoveProg PolyTimeTest
|
||||
make PolyTimeTest
|
||||
if test -f PolyTimeTest
|
||||
@@ -123,7 +123,7 @@
|
||||
cat best1 set_TBL_REM clr_AVOID_BRANCHING best2 set_WIZARD_HACK isettings > isettings1
|
||||
sed -f isettings1 config_template > ../include/NTL/config.h
|
||||
rm lip.o
|
||||
- make wntl.a
|
||||
+ make libwntl.la
|
||||
sh RemoveProg PolyTimeTest
|
||||
make PolyTimeTest
|
||||
if test -f PolyTimeTest
|
||||
@@ -151,7 +151,7 @@
|
||||
cat best1 clr_TBL_REM set_AVOID_BRANCHING clr_FFT_PIPELINE set_WIZARD_HACK isettings > isettings1
|
||||
sed -f isettings1 config_template > ../include/NTL/config.h
|
||||
rm *.o
|
||||
-make wntl.a
|
||||
+make libwntl.la
|
||||
sh RemoveProg PolyTimeTest
|
||||
make PolyTimeTest
|
||||
if test -f PolyTimeTest
|
||||
@@ -167,7 +167,7 @@
|
||||
cat best1 clr_TBL_REM set_AVOID_BRANCHING set_FFT_PIPELINE set_WIZARD_HACK isettings > isettings1
|
||||
sed -f isettings1 config_template > ../include/NTL/config.h
|
||||
rm FFT.o
|
||||
-make wntl.a
|
||||
+make libwntl.la
|
||||
sh RemoveProg PolyTimeTest
|
||||
make PolyTimeTest
|
||||
if test -f PolyTimeTest
|
||||
@@ -196,7 +196,7 @@
|
||||
cat best1 set_TBL_REM set_AVOID_BRANCHING best2 set_WIZARD_HACK isettings > isettings1
|
||||
sed -f isettings1 config_template > ../include/NTL/config.h
|
||||
rm lip.o
|
||||
- make wntl.a
|
||||
+ make libwntl.la
|
||||
sh RemoveProg PolyTimeTest
|
||||
make PolyTimeTest
|
||||
if test -f PolyTimeTest
|
||||
|
|
Loading…
Reference in a new issue