SRC_TARBALL=openssl-1.0.1e.tar.gz SRC_FETCH_PATH="http://www.openssl.org/source/$SRC_TARBALL" SRC_FETCH_METHOD="http" PATCH_LIST=" 0001-Aloha-5.5-1001-default_ciphers.patch.patch 0002-Aloha-5.5-1002-cryptodev-1.5.patch.patch 0003-Aloha-5.5-1003-warning-header.patch.patch 0004-Fix-for-SSL_get_certificate.patch 0005-evp-e_des3.c-fix-typo-with-potential-integer-overflo.patch 0006-Don-t-prefer-ECDHE-ECDSA-ciphers-when-the-client-app.patch 0007-Fix-verify-loop-with-CRL-checking.patch 0008-Fix-for-PEM_X509_INFO_read_bio.patch 0009-typo-CMS_decrypt-mismatch-out-with-NULL.patch 0010-Fix-memory-leak.patch 0011-Fix-for-TLS-record-tampering-bug-CVE-2013-4353.patch 0012-Typo-BUF_reverse-mismatch-in-with-out.patch 0013-Set-s-d1-to-NULL-after-freeing-it.patch 0014-e_aes_cbc_hmac_sha1.c-fix-rare-bad-record-mac-on-AES.patch 0015-Encode-INTEGER-correctly.patch 0016-Fix-bug-in-X509_V_FLAG_IGNORE_CRITICAL-CRL-handling.patch 0017-Typo-pkey_rsa_ctrl_str-mishmatch-oeap-with-oaep.patch " function do_config { # To find these options, try "./Configure LIST" then "./Configure TABLE". # The colons are just delimiters and all words are allowed on the line. # Please read the Configure script in openssl to fin the relevant keywords, # as most of them are already implied by the OS target definition and the # default compiler ! if [ "$FLXARCH" == "x86_64" ]; then os="linux-x86_64" opt=( $GCC_ARCH_CURRENT $GCC_CPU_CURRENT $GCC_OPT_FASTEST ) elif [ "$FLX_ARCH_SMALL" == "i386" ]; then os="linux-elf" opt=( $GCC_ARCH_CURRENT $GCC_CPU_CURRENT $GCC_OPT_FASTEST ) elif [ -n "$FLXARCH" -a -z "${FLXARCH##arm*}" ]; then os="linux-armv4" opt=( $GCC_ARCH_CURRENT $GCC_CPU_CURRENT $GCC_OPT_FASTEST ) elif [ "$FLXARCH" == "sparc" ]; then os="linux-sparcv9" opt="" elif [ "$FLXARCH" == "sparc64" ]; then os="linux64-sparcv9" opt="" else os="linux-elf" opt="" fi # Do not enable cryptodev digests (-DUSE_CRYPTODEV_DIGESTS), as indicated in # the README, they significantly lower performance due to the high latency of # the ioctl required for cryptodev. Only enable HAVE_CRYPTODEV. opt=( "${opt[@]}" -DHAVE_CRYPTODEV ) CC="$CC" ./Configure --prefix=/usr --openssldir=/usr/share/openssl threads shared "${opt[@]}" "$os" } function do_compile_only { $FLXMAKE CC=$CC AR='${FLXCROSS}ar r' RANLIB='${FLXCROSS}ranlib' || exit $? $FLXMAKE build-shared CC=$CC AR='${FLXCROSS}ar r' RANLIB='${FLXCROSS}ranlib' || exit $? $FLXMAKE -C apps CC=$CC DLIBCRYPTO=../libcrypto.so AR='${FLXCROSS}ar r' RANLIB='${FLXCROSS}ranlib' || exit $? } function do_prepack { $FLXMAKE install LIBDIR=/lib INSTALL_PREFIX=$ROOTDIR || exit $? set_default_perm $ROOTDIR }