mirror of
https://github.com/freebsd/freebsd-src
synced 2024-09-06 17:18:32 +00:00
Integrate lib/libmp into the build/kyua
- Remove the .t wrapper - Fix -Wreturn-type warnings with clang This change has been tested on amd64/i386 Phabric: D530 Reviewed by: jmmv Approved by: jmmv (co-mentor) MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Division
This commit is contained in:
parent
5f9500c358
commit
dfed135e5c
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=269534
|
@ -85,6 +85,8 @@
|
|||
..
|
||||
libcrypt
|
||||
..
|
||||
libmp
|
||||
..
|
||||
..
|
||||
libexec
|
||||
atf
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
# $FreeBSD$
|
||||
|
||||
.include <src.opts.mk>
|
||||
|
||||
LIB= mp
|
||||
SHLIB_MAJOR= 7
|
||||
DPADD= ${LIBCRYPTO}
|
||||
|
@ -13,4 +15,8 @@ CFLAGS+= -I${.CURDIR}/../../crypto
|
|||
VERSION_DEF= ${.CURDIR}/../libc/Versions.def
|
||||
SYMBOL_MAPS= ${.CURDIR}/Symbol.map
|
||||
|
||||
.if ${MK_TESTS} != "no"
|
||||
SUBDIR+= tests
|
||||
.endif
|
||||
|
||||
.include <bsd.lib.mk>
|
||||
|
|
10
lib/libmp/tests/Makefile
Normal file
10
lib/libmp/tests/Makefile
Normal file
|
@ -0,0 +1,10 @@
|
|||
# $FreeBSD$
|
||||
|
||||
TESTSDIR= ${TESTSBASE}/lib/libmp
|
||||
|
||||
TAP_TESTS_C+= legacy_test
|
||||
|
||||
DPADD+= ${LIBCRYPTO} ${LIBMP}
|
||||
LDADD+= -lcrypto -lmp
|
||||
|
||||
.include <bsd.test.mk>
|
|
@ -46,7 +46,7 @@ testmcmp(const MINT *mp1, const MINT *mp2, const char *tname)
|
|||
printf("not ok - %d %s\n", ++tnr, tname);
|
||||
}
|
||||
|
||||
static int
|
||||
static void
|
||||
testsimpel(void)
|
||||
{
|
||||
const char str42[] = "2a";
|
||||
|
@ -74,7 +74,7 @@ testsimpel(void)
|
|||
mp_mfree(t2);
|
||||
}
|
||||
|
||||
static int
|
||||
static void
|
||||
testgcd(void)
|
||||
{
|
||||
|
||||
|
@ -82,7 +82,7 @@ testgcd(void)
|
|||
testmcmp(t0, c5, "gcd0");
|
||||
}
|
||||
|
||||
static int
|
||||
static void
|
||||
testmsqrt(void)
|
||||
{
|
||||
|
||||
|
@ -94,7 +94,7 @@ testmsqrt(void)
|
|||
testmcmp(t1, c6, "msqrt3");
|
||||
}
|
||||
|
||||
static int
|
||||
static void
|
||||
testdiv(void)
|
||||
{
|
||||
short ro;
|
||||
|
@ -121,7 +121,7 @@ testdiv(void)
|
|||
mp_mfree(t2);
|
||||
}
|
||||
|
||||
static int
|
||||
static void
|
||||
testmult(void)
|
||||
{
|
||||
|
||||
|
@ -131,7 +131,7 @@ testmult(void)
|
|||
testmcmp(t0, c42, "mmult1");
|
||||
}
|
||||
|
||||
static int
|
||||
static void
|
||||
testpow(void)
|
||||
{
|
||||
|
|
@ -1,12 +0,0 @@
|
|||
# $FreeBSD$
|
||||
|
||||
TESTS= test-libmp
|
||||
CFLAGS+= -g -Wall -lcrypto -lmp
|
||||
|
||||
.PHONY: tests
|
||||
tests: ${TESTS}
|
||||
for p in ${TESTS}; do ${.OBJDIR}/$$p; done
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
-rm -f ${TESTS}
|
|
@ -1,10 +0,0 @@
|
|||
#!/bin/sh
|
||||
# $FreeBSD$
|
||||
|
||||
cd `dirname $0`
|
||||
|
||||
executable=`basename $0 .t`
|
||||
|
||||
make $executable 2>&1 > /dev/null
|
||||
|
||||
exec ./$executable
|
Loading…
Reference in a new issue