diff options
author | Adrian Dudau <adrian.dudau@enea.com> | 2014-06-26 14:36:22 +0200 |
---|---|---|
committer | Adrian Dudau <adrian.dudau@enea.com> | 2014-06-26 15:32:53 +0200 |
commit | f4cf9fe05bb3f32fabea4e54dd92d368967a80da (patch) | |
tree | 487180fa9866985ea7b28e625651765d86f515c3 /meta/recipes-support/beecrypt | |
download | poky-f4cf9fe05bb3f32fabea4e54dd92d368967a80da.tar.gz |
initial commit for Enea Linux 4.0
Migrated from the internal git server on the daisy-enea branch
Signed-off-by: Adrian Dudau <adrian.dudau@enea.com>
Diffstat (limited to 'meta/recipes-support/beecrypt')
6 files changed, 218 insertions, 0 deletions
diff --git a/meta/recipes-support/beecrypt/beecrypt/beecrypt-enable-ptest-support.patch b/meta/recipes-support/beecrypt/beecrypt/beecrypt-enable-ptest-support.patch new file mode 100644 index 0000000000..3e5513fce9 --- /dev/null +++ b/meta/recipes-support/beecrypt/beecrypt/beecrypt-enable-ptest-support.patch | |||
@@ -0,0 +1,37 @@ | |||
1 | beecrypt: enable ptest support | ||
2 | |||
3 | Upstream-Status: Inappropriate [embedded specific] | ||
4 | |||
5 | Add install-ptest rules. | ||
6 | |||
7 | Signed-off-by: Chong Lu <Chong.Lu@windriver.com> | ||
8 | --- | ||
9 | Makefile.am | 3 +++ | ||
10 | tests/Makefile.am | 3 +++ | ||
11 | 2 files changed, 6 insertions(+) | ||
12 | |||
13 | diff --git a/Makefile.am b/Makefile.am | ||
14 | index b7e7869..5076f59 100644 | ||
15 | --- a/Makefile.am | ||
16 | +++ b/Makefile.am | ||
17 | @@ -73,3 +73,6 @@ DISTCLEANFILES = mpopt.s blowfishopt.s sha1opt.s | ||
18 | |||
19 | bench: | ||
20 | (cd tests && $(MAKE) $(AM_MAKEFLAGS) bench) | ||
21 | + | ||
22 | +install-ptest: | ||
23 | + (cd tests && $(MAKE) $(AM_MAKEFLAGS) check_PROGRAMS) | ||
24 | diff --git a/tests/Makefile.am b/tests/Makefile.am | ||
25 | index 1604e5e..d8db8d8 100644 | ||
26 | --- a/tests/Makefile.am | ||
27 | +++ b/tests/Makefile.am | ||
28 | @@ -101,3 +101,6 @@ bench: benchme benchrsa benchhf benchbc | ||
29 | ./benchbc AES 128 | ||
30 | ./benchbc Blowfish 128 | ||
31 | ./benchbc Blowfish 128 | ||
32 | + | ||
33 | +check_PROGRAMS: | ||
34 | + $(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS) | ||
35 | -- | ||
36 | 1.8.1.2 | ||
37 | |||
diff --git a/meta/recipes-support/beecrypt/beecrypt/disable-icu-check.patch b/meta/recipes-support/beecrypt/beecrypt/disable-icu-check.patch new file mode 100644 index 0000000000..91b1fa6ef5 --- /dev/null +++ b/meta/recipes-support/beecrypt/beecrypt/disable-icu-check.patch | |||
@@ -0,0 +1,43 @@ | |||
1 | We are unable to run code at configure time in a cross environemnt, but as we | ||
2 | control the build we can be fairly certain this dependency is met. | ||
3 | |||
4 | Upstream-Status: Inappropriate [embedded specific] | ||
5 | |||
6 | JL 05/07/10 | ||
7 | Index: beecrypt-4.2.1/configure.ac | ||
8 | =================================================================== | ||
9 | --- beecrypt-4.2.1.orig/configure.ac 2010-11-26 17:12:25.000000000 +0800 | ||
10 | +++ beecrypt-4.2.1/configure.ac 2010-11-26 17:12:30.000000000 +0800 | ||
11 | @@ -292,32 +292,6 @@ | ||
12 | # Predefines and checks for C++ API support | ||
13 | AH_TEMPLATE([CPPGLUE],[Define to 1 if you want to include the C++ code]) | ||
14 | |||
15 | -if test "$ac_with_cplusplus" = yes; then | ||
16 | - AC_MSG_CHECKING([for IBM's ICU library version >= 2.8]) | ||
17 | - AC_LANG_PUSH(C) | ||
18 | - AC_RUN_IFELSE([ | ||
19 | - AC_LANG_PROGRAM([[#include <unicode/uversion.h>]],[[ | ||
20 | - #if U_ICU_VERSION_MAJOR_NUM < 2 | ||
21 | - exit(1); | ||
22 | - #elif U_ICU_VERSION_MAJOR_NUM == 2 | ||
23 | - # if U_ICU_VERSION_MINOR_NUM < 8 | ||
24 | - exit(1); | ||
25 | - # else | ||
26 | - exit(0); | ||
27 | - # endif | ||
28 | - #else | ||
29 | - exit(0); | ||
30 | - #endif | ||
31 | - ]])],[ | ||
32 | - AC_MSG_RESULT([yes]) | ||
33 | - ],[ | ||
34 | - AC_MSG_RESULT([no]) | ||
35 | - AC_MSG_WARN([disabling cplusplus]) | ||
36 | - ac_with_cplusplus=no | ||
37 | - ]) | ||
38 | - AC_LANG_POP(C) | ||
39 | -fi | ||
40 | - | ||
41 | AM_CONDITIONAL([WITH_CPLUSPLUS],[test "$ac_with_cplusplus" = yes]) | ||
42 | |||
43 | if test "$ac_with_cplusplus" = yes ; then | ||
diff --git a/meta/recipes-support/beecrypt/beecrypt/fix-for-gcc-4.7.patch b/meta/recipes-support/beecrypt/beecrypt/fix-for-gcc-4.7.patch new file mode 100644 index 0000000000..8144e39be0 --- /dev/null +++ b/meta/recipes-support/beecrypt/beecrypt/fix-for-gcc-4.7.patch | |||
@@ -0,0 +1,39 @@ | |||
1 | |||
2 | gcc-4.7 seems to be stricter about some things, so follow | ||
3 | the suggestion from the error/note information. | ||
4 | |||
5 | ../../x86_64-linux-libtool --tag=CXX --mode=compile g++ -DHAVE_CONFIG_H -I. -I../.. | ||
6 | x86_64-linux-libtool: compile: g++ -DHAVE_CONFIG_H -I. -I../.. -I../../include -isyst | ||
7 | In file included from ../../include/beecrypt/c++/util/Hashtable.h:42:0, | ||
8 | from ../../include/beecrypt/c++/util/Properties.h:36, | ||
9 | from Properties.cxx:25: | ||
10 | ../../include/beecrypt/c++/util/AbstractSet.h: In instantiation of 'bool beecrypt::uti | ||
11 | Properties.cxx:228:1: required from here | ||
12 | ../../include/beecrypt/c++/util/AbstractSet.h:59:27: error: 'containsAll' was not decl | ||
13 | ../../include/beecrypt/c++/util/AbstractSet.h:59:27: note: declarations in dependent b | ||
14 | ../../include/beecrypt/c++/util/AbstractSet.h:59:27: note: use 'this->containsAll' ins | ||
15 | ../../include/beecrypt/c++/util/AbstractSet.h: In instantiation of 'bool beecrypt::uti | ||
16 | Properties.cxx:228:1: required from here | ||
17 | ../../include/beecrypt/c++/util/AbstractSet.h:59:27: error: 'containsAll' was not decl | ||
18 | ../../include/beecrypt/c++/util/AbstractSet.h:59:27: note: declarations in dependent b | ||
19 | ../../include/beecrypt/c++/util/AbstractSet.h:59:27: note: use 'this->containsAll' ins | ||
20 | |||
21 | |||
22 | Upstream-Status: Pending | ||
23 | |||
24 | Signed-off-by: Saul Wold <sgw@linux.intel.com> | ||
25 | |||
26 | |||
27 | Index: beecrypt-4.2.1/include/beecrypt/c++/util/AbstractSet.h | ||
28 | =================================================================== | ||
29 | --- beecrypt-4.2.1.orig/include/beecrypt/c++/util/AbstractSet.h | ||
30 | +++ beecrypt-4.2.1/include/beecrypt/c++/util/AbstractSet.h | ||
31 | @@ -56,7 +56,7 @@ namespace beecrypt { | ||
32 | if (c->size() != size()) | ||
33 | return false; | ||
34 | |||
35 | - return containsAll(*c); | ||
36 | + return this->containsAll(*c); | ||
37 | } | ||
38 | return false; | ||
39 | } | ||
diff --git a/meta/recipes-support/beecrypt/beecrypt/fix-security.patch b/meta/recipes-support/beecrypt/beecrypt/fix-security.patch new file mode 100644 index 0000000000..6cb0c00205 --- /dev/null +++ b/meta/recipes-support/beecrypt/beecrypt/fix-security.patch | |||
@@ -0,0 +1,47 @@ | |||
1 | Fix visibility of various C++ functions, inspired by a similar patch in the Fink | ||
2 | project: | ||
3 | http://www.mail-archive.com/fink-commits@lists.sourceforge.net/msg75742.html | ||
4 | |||
5 | JL 05/07/10 | ||
6 | |||
7 | Upstream-Status: Pending | ||
8 | |||
9 | Index: beecrypt-4.2.1/include/beecrypt/c++/beeyond/BeeCertificate.h | ||
10 | =================================================================== | ||
11 | --- beecrypt-4.2.1.orig/include/beecrypt/c++/beeyond/BeeCertificate.h 2010-11-26 17:22:57.000000000 +0800 | ||
12 | +++ beecrypt-4.2.1/include/beecrypt/c++/beeyond/BeeCertificate.h 2010-11-26 17:23:01.000000000 +0800 | ||
13 | @@ -147,13 +147,13 @@ | ||
14 | mutable bytearray* enc; | ||
15 | |||
16 | BeeCertificate(); | ||
17 | - BeeCertificate(InputStream& in) throw (IOException); | ||
18 | |||
19 | void encodeTBS(DataOutputStream& out) const throw (IOException); | ||
20 | |||
21 | bytearray* encodeTBS() const throw (CertificateEncodingException); | ||
22 | |||
23 | public: | ||
24 | + BeeCertificate(InputStream& in) throw (IOException); | ||
25 | BeeCertificate(const BeeCertificate&) throw (CloneNotSupportedException); | ||
26 | virtual ~BeeCertificate(); | ||
27 | |||
28 | Index: beecrypt-4.2.1/include/beecrypt/c++/security/Security.h | ||
29 | =================================================================== | ||
30 | --- beecrypt-4.2.1.orig/include/beecrypt/c++/security/Security.h 2010-11-26 17:20:55.000000000 +0800 | ||
31 | +++ beecrypt-4.2.1/include/beecrypt/c++/security/Security.h 2010-11-26 17:21:36.000000000 +0800 | ||
32 | @@ -61,7 +61,6 @@ | ||
33 | friend class SecureRandom; | ||
34 | friend class Signature; | ||
35 | |||
36 | - private: | ||
37 | struct spi | ||
38 | { | ||
39 | Object* cspi; | ||
40 | @@ -76,6 +75,7 @@ | ||
41 | static spi* getSpi(const String& algo, const String& type, const Provider&) throw (NoSuchAlgorithmException); | ||
42 | static spi* getFirstSpi(const String& type); | ||
43 | |||
44 | + private: | ||
45 | static const String& getKeyStoreDefault(); | ||
46 | |||
47 | static bool _init; | ||
diff --git a/meta/recipes-support/beecrypt/beecrypt/run-ptest b/meta/recipes-support/beecrypt/beecrypt/run-ptest new file mode 100644 index 0000000000..5bc7460be9 --- /dev/null +++ b/meta/recipes-support/beecrypt/beecrypt/run-ptest | |||
@@ -0,0 +1,5 @@ | |||
1 | #!/bin/sh | ||
2 | |||
3 | cd tests | ||
4 | for i in `ls`; do ./$i; if [ $? == 0 ]; then echo "PASS: $i"; \ | ||
5 | else echo "FAIL: $i"; fi; done | ||
diff --git a/meta/recipes-support/beecrypt/beecrypt_4.2.1.bb b/meta/recipes-support/beecrypt/beecrypt_4.2.1.bb new file mode 100644 index 0000000000..209b92e653 --- /dev/null +++ b/meta/recipes-support/beecrypt/beecrypt_4.2.1.bb | |||
@@ -0,0 +1,47 @@ | |||
1 | # Beecrypt OE build file | ||
2 | # Copyright (C) 2004-2005, Advanced Micro Devices, Inc. All Rights Reserved | ||
3 | # Released under the MIT license (see packages/COPYING) | ||
4 | |||
5 | SUMMARY = "A general-purpose cryptography library" | ||
6 | HOMEPAGE = "http://sourceforge.net/projects/beecrypt" | ||
7 | |||
8 | SRC_URI = "${SOURCEFORGE_MIRROR}/beecrypt/beecrypt-${PV}.tar.gz \ | ||
9 | file://disable-icu-check.patch \ | ||
10 | file://fix-security.patch \ | ||
11 | file://fix-for-gcc-4.7.patch \ | ||
12 | file://run-ptest \ | ||
13 | file://beecrypt-enable-ptest-support.patch \ | ||
14 | " | ||
15 | |||
16 | SRC_URI[md5sum] = "8441c014170823f2dff97e33df55af1e" | ||
17 | SRC_URI[sha256sum] = "286f1f56080d1a6b1d024003a5fa2158f4ff82cae0c6829d3c476a4b5898c55d" | ||
18 | |||
19 | LICENSE = "GPLv2 & LGPLv2.1" | ||
20 | LIC_FILES_CHKSUM = "file://COPYING;md5=9894370afd5dfe7d02b8d14319e729a1 \ | ||
21 | file://COPYING.LIB;md5=dcf3c825659e82539645da41a7908589 \ | ||
22 | file://include/beecrypt/beecrypt.h;endline=20;md5=47a93eef539aac237eef86297a4d71c1" | ||
23 | |||
24 | PR = "r3" | ||
25 | |||
26 | inherit autotools multilib_header ptest | ||
27 | acpaths="" | ||
28 | |||
29 | do_install_append() { | ||
30 | oe_multilib_header beecrypt/gnu.h | ||
31 | } | ||
32 | |||
33 | EXTRA_OECONF = "--without-python --enable-shared --enable-static --disable-openmp --with-java=no" | ||
34 | |||
35 | PACKAGECONFIG ??= "" | ||
36 | PACKAGECONFIG[cplusplus] = "--with-cplusplus,--without-cplusplus,icu" | ||
37 | |||
38 | FILES_${PN} = "${sysconfdir} ${libdir}/*.so.* ${libdir}/${BPN}/*.so.*" | ||
39 | FILES_${PN}-dev += "${libdir}/${BPN}/*.so ${libdir}/${BPN}/*.la" | ||
40 | FILES_${PN}-staticdev += "${libdir}/${BPN}/*.a" | ||
41 | |||
42 | BBCLASSEXTEND = "native nativesdk" | ||
43 | |||
44 | do_install_ptest () { | ||
45 | mkdir ${D}${PTEST_PATH}/tests | ||
46 | cp -r ${B}/tests/.libs/test* ${D}${PTEST_PATH}/tests | ||
47 | } | ||