Makefile 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. # $Id$
  2. #-
  3. # This file is part of the OpenADK project. OpenADK is copyrighted
  4. # material, please see the LICENCE file in the top-level directory.
  5. include ${TOPDIR}/rules.mk
  6. PKG_NAME:= openssl
  7. PKG_VERSION:= 0.9.8k
  8. PKG_RELEASE:= 2
  9. CACERT_VER:= 12
  10. PKG_MD5SUM:= e555c6d58d276aec7fdc53363e338ab3
  11. MASTER_SITES:= http://www.openssl.org/source/ \
  12. ftp://ftp.funet.fi/pub/crypt/cryptography/libs/openssl/source/ \
  13. ftp://ftp.webmonster.de/pub/openssl/source/ \
  14. ftp://ftp.sunet.se/pub/security/tools/net/openssl/source/
  15. include ${TOPDIR}/mk/package.mk
  16. $(eval $(call PKG_template,LIBOPENSSL,libopenssl,${PKG_VERSION}-${PKG_RELEASE}))
  17. $(eval $(call PKG_template,OPENSSL_UTIL,openssl-util,${PKG_VERSION}-${PKG_RELEASE}))
  18. $(eval $(call PKG_template,CA_CERTS,ca-certificates,${PKG_VERSION}-${CACERT_VER}))
  19. BUILD_STYLE:= manual
  20. INSTALL_STYLE:= auto confprog
  21. INSTALL_TARGET:= install_sw
  22. FAKE_FLAGS+= INSTALL_PREFIX=${WRKINST}
  23. OPENSSL_OPTIONS = shared no-ec no-err no-hw no-krb5 no-threads zlib-dynamic no-engines no-camellia no-idea no-rc5 no-mdc2 no-sha0 no-smime no-aes192 no-ripemd no-cast no-bf
  24. do-configure:
  25. (cd $(WRKBUILD); \
  26. PATH=$(TARGET_PATH) \
  27. OPTIMIZATION_FLAGS="$(TARGET_CFLAGS) -fPIC" \
  28. ./Configure linux-embedded \
  29. --prefix=/usr \
  30. --openssldir=/etc/ssl \
  31. --with-cryptodev \
  32. -I$(STAGING_DIR)/usr/include \
  33. -L$(STAGING_DIR)/usr/lib -ldl \
  34. -DOPENSSL_SMALL_FOOTPRINT \
  35. $(OPENSSL_OPTIONS) \
  36. );
  37. do-build:
  38. $(MAKE) -C $(WRKBUILD) \
  39. MAKEDEPPROG="$(TARGET_CC)" \
  40. OPTIMIZATION_FLAGS="$(TARGET_CFLAGS) -fPIC" \
  41. depend
  42. $(MAKE) -C $(WRKBUILD) \
  43. CC="$(TARGET_CC)" \
  44. AR="$(TARGET_CROSS)ar r" \
  45. RANLIB="$(TARGET_CROSS)ranlib" \
  46. OPTIMIZATION_FLAGS="$(TARGET_CFLAGS) -fPIC" \
  47. all build-shared
  48. post-install:
  49. ${INSTALL_DIR} ${IDIR_LIBOPENSSL}/usr/lib
  50. ${CP} ${WRKINST}/usr/lib/lib*.so.* ${IDIR_LIBOPENSSL}/usr/lib
  51. chmod 644 ${IDIR_LIBOPENSSL}/usr/lib/lib*.so.*
  52. ${INSTALL_DIR} ${IDIR_OPENSSL_UTIL}/usr/bin
  53. ${CP} ${WRKINST}/usr/bin/openssl ${IDIR_OPENSSL_UTIL}/usr/bin
  54. ${INSTALL_DIR} ${IDIR_OPENSSL_UTIL}/etc/ssl/{,certs,private}
  55. ${CP} ${WRKSRC}/apps/openssl.cnf ${IDIR_OPENSSL_UTIL}/etc/ssl/
  56. chmod 0700 ${IDIR_OPENSSL_UTIL}/etc/ssl/private
  57. ${INSTALL_DIR} ${IDIR_CA_CERTS}/etc/ssl
  58. ${INSTALL_DATA} cert.pem ${IDIR_CA_CERTS}/etc/ssl/
  59. include ${TOPDIR}/mk/pkg-bottom.mk