summaryrefslogtreecommitdiffstats
path: root/recipes-support/nettle/nettle.inc
diff options
context:
space:
mode:
Diffstat (limited to 'recipes-support/nettle/nettle.inc')
-rw-r--r--recipes-support/nettle/nettle.inc37
1 files changed, 37 insertions, 0 deletions
diff --git a/recipes-support/nettle/nettle.inc b/recipes-support/nettle/nettle.inc
new file mode 100644
index 0000000..af51fb6
--- /dev/null
+++ b/recipes-support/nettle/nettle.inc
@@ -0,0 +1,37 @@
+SUMMARY = "A low level cryptographic library"
+HOMEPAGE = "http://www.lysator.liu.se/~nisse/nettle/"
+SECTION = "libs"
+
+DEPENDS += "gmp"
+
+SRC_URI = "http://www.lysator.liu.se/~nisse/archive/${BP}.tar.gz \
+ file://Add-target-to-only-build-tests-not-run-them.patch \
+ file://run-ptest \
+ "
+
+UPSTREAM_CHECK_REGEX = "nettle-(?P<pver>\d+(\.\d+)+)\.tar"
+
+inherit autotools ptest
+
+EXTRA_OECONF = "--disable-openssl"
+
+do_configure_prepend() {
+ if [ ! -e ${S}/acinclude.m4 -a -e ${S}/aclocal.m4 ]; then
+ cp ${S}/aclocal.m4 ${S}/acinclude.m4
+ fi
+}
+
+do_compile_ptest() {
+ oe_runmake buildtest
+}
+
+do_install_ptest() {
+ install -d ${D}${PTEST_PATH}/testsuite/
+ install ${S}/testsuite/gold-bug.txt ${D}${PTEST_PATH}/testsuite/
+ install ${S}/testsuite/*-test ${D}${PTEST_PATH}/testsuite/
+ # tools can be found in PATH, not in ../tools/
+ sed -i -e 's|../tools/||' ${D}${PTEST_PATH}/testsuite/*-test
+ install ${B}/testsuite/*-test ${D}${PTEST_PATH}/testsuite/
+}
+
+BBCLASSEXTEND = "native nativesdk"