Makefile 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. # This file is part of the OpenADK project. OpenADK is copyrighted
  2. # material, please see the LICENCE file in the top-level directory.
  3. include ${TOPDIR}/rules.mk
  4. PKG_NAME:= curl
  5. PKG_VERSION:= 7.24.0
  6. PKG_RELEASE:= 1
  7. PKG_MD5SUM:= b93420f80a2baaa61a0f45214eddc2ba
  8. PKG_DESCR:= a client-side URL transfer tool
  9. PKG_SECTION:= www
  10. PKG_DEPENDS:= libcurl
  11. PKG_BUILDDEP:= zlib
  12. PKG_URL:= http://curl.haxx.se/
  13. PKG_SITES:= http://curl.haxx.se/download/
  14. PKG_SUBPKGS:= CURL LIBCURL LIBCURL_DEV
  15. PKGSD_LIBCURL:= a client-side URL transfer library
  16. PKGSC_LIBCURL:= libs
  17. PKGSS_LIBCURL:= zlib
  18. PKGSD_LIBCURL_DEV:= development files for libcurl
  19. PKGSC_LIBCURL_DEV:= devel
  20. PKG_FLAVOURS_CURL:= WITH_IPV6
  21. PKGFD_WITH_IPV6:= enable IPv6 support
  22. PKG_CHOICES_CURL:= WITHOUT_SSL WITH_OPENSSL WITH_GNUTLS
  23. PKGCD_WITHOUT_SSL:= use no SSL
  24. PKGCD_WITH_OPENSSL:= use OpenSSL for crypto
  25. PKGCS_WITH_OPENSSL:= libopenssl ca-certificates libgmp
  26. PKGCB_WITH_OPENSSL:= openssl
  27. PKGCD_WITH_GNUTLS:= use GnuTLS for crypto
  28. PKGCS_WITH_GNUTLS:= libgnutls ca-certificates libgmp
  29. PKGCB_WITH_GNUTLS:= gnutls
  30. include ${TOPDIR}/mk/package.mk
  31. $(eval $(call PKG_template,CURL,curl,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  32. $(eval $(call PKG_template,LIBCURL,libcurl,${PKG_VERSION}-${PKG_RELEASE},${PKGSS_LIBCURL},${PKGSD_LIBCURL},${PKGSC_LIBCURL}))
  33. $(eval $(call PKG_template,LIBCURL_DEV,libcurl-dev,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_LIBCURL_DEV},${PKGSC_LIBCURL_DEV}))
  34. ifeq (${ADK_PACKAGE_CURL_WITHOUT_SSL},y)
  35. CONFIGURE_ARGS+= --without-ssl \
  36. --without-gnutls
  37. endif
  38. ifeq (${ADK_PACKAGE_CURL_WITH_OPENSSL},y)
  39. CONFIGURE_ARGS+= --with-ssl="${STAGING_TARGET_DIR}/usr" \
  40. --without-gnutls
  41. endif
  42. ifeq (${ADK_PACKAGE_CURL_WITH_GNUTLS},y)
  43. CONFIGURE_ARGS+= --with-gnutls="${STAGING_TARGET_DIR}/usr" \
  44. --without-ssl
  45. endif
  46. TARGET_CFLAGS:= $(filter-out -flto,$(TARGET_CFLAGS))
  47. CONFIGURE_ENV+= curl_typeof_curl_socklen_t=socklen_t
  48. CONFIGURE_ARGS+= --disable-thread \
  49. --enable-cookies \
  50. --enable-crypto-auth \
  51. --enable-nonblocking \
  52. --enable-file \
  53. --enable-ftp \
  54. --enable-http \
  55. --disable-ares \
  56. --disable-dict \
  57. --disable-gopher \
  58. --disable-ldap \
  59. --disable-manual \
  60. --disable-sspi \
  61. --disable-telnet \
  62. --disable-verbose \
  63. --with-random="/dev/urandom" \
  64. --with-ca-bundle="/etc/ssl/cert.pem" \
  65. --without-libidn
  66. ifneq (${ADK_PACKAGE_CURL_WITH_IPV6},)
  67. CONFIGURE_ARGS+= --enable-ipv6
  68. else
  69. CONFIGURE_ARGS+= --disable-ipv6
  70. endif
  71. curl-install:
  72. ${INSTALL_DIR} ${IDIR_CURL}/usr/bin
  73. ${INSTALL_BIN} ${WRKINST}/usr/bin/curl ${IDIR_CURL}/usr/bin
  74. libcurl-install:
  75. ${INSTALL_DIR} ${IDIR_LIBCURL}/usr/lib
  76. ${CP} ${WRKINST}/usr/lib/libcurl.so* ${IDIR_LIBCURL}/usr/lib
  77. libcurl-dev-install:
  78. ${INSTALL_DIR} ${IDIR_LIBCURL_DEV}/usr/lib
  79. ${CP} ${WRKINST}/usr/lib/libcurl.a ${IDIR_LIBCURL_DEV}/usr/lib
  80. ${INSTALL_DIR} ${IDIR_LIBCURL_DEV}/usr/include/curl
  81. ${CP} ${WRKINST}/usr/include/curl/*.h \
  82. ${IDIR_LIBCURL_DEV}/usr/include/curl
  83. ${INSTALL_DIR} ${IDIR_LIBCURL_DEV}/usr/bin
  84. ${INSTALL_BIN} ${WRKINST}/usr/bin/curl-config \
  85. ${IDIR_LIBCURL_DEV}/usr/bin
  86. include ${TOPDIR}/mk/pkg-bottom.mk