2
1

libcurl.mk 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. #############################################################
  2. #
  3. # libcurl
  4. #
  5. #############################################################
  6. LIBCURL_VERSION = 7.21.2
  7. LIBCURL_SOURCE = curl-$(LIBCURL_VERSION).tar.bz2
  8. LIBCURL_SITE = http://curl.haxx.se/download/
  9. LIBCURL_INSTALL_STAGING = YES
  10. LIBCURL_CONF_OPT = --disable-verbose --disable-manual --enable-hidden-symbols
  11. ifeq ($(BR2_PACKAGE_OPENSSL),y)
  12. LIBCURL_DEPENDENCIES += openssl
  13. LIBCURL_CONF_ENV += ac_cv_lib_crypto_CRYPTO_lock=yes
  14. # configure adds the cross openssl dir to LD_LIBRARY_PATH which screws up
  15. # native stuff during the rest of configure when target == host.
  16. # Fix it by setting LD_LIBRARY_PATH to something sensible so those libs
  17. # are found first.
  18. LIBCURL_CONF_ENV += LD_LIBRARY_PATH=$$LD_LIBRARY_PATH:/lib:/usr/lib
  19. LIBCURL_CONF_OPT += --with-ssl=$(STAGING_DIR)/usr --with-random=/dev/urandom
  20. else
  21. LIBCURL_CONF_OPT += --without-ssl
  22. endif
  23. define LIBCURL_TARGET_CLEANUP
  24. rm -rf $(TARGET_DIR)/usr/bin/curl-config \
  25. $(if $(BR2_PACKAGE_CURL),,$(TARGET_DIR)/usr/bin/curl)
  26. endef
  27. LIBCURL_POST_INSTALL_TARGET_HOOKS += LIBCURL_TARGET_CLEANUP
  28. $(eval $(call AUTOTARGETS,package,libcurl))
  29. curl: libcurl
  30. curl-clean: libcurl-clean
  31. curl-dirclean: libcurl-dirclean
  32. curl-source: libcurl-source