libgit2.mk 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. ################################################################################
  2. #
  3. # libgit2
  4. #
  5. ################################################################################
  6. LIBGIT2_VERSION = 1.3.0
  7. LIBGIT2_SITE = $(call github,libgit2,libgit2,v$(LIBGIT2_VERSION))
  8. LIBGIT2_LICENSE = GPL-2.0 with linking exception, MIT (sha1), wildmatch license (wildmatch)
  9. LIBGIT2_LICENSE_FILES = COPYING
  10. LIBGIT2_CPE_ID_VENDOR = libgit2_project
  11. LIBGIT2_INSTALL_STAGING = YES
  12. LIBGIT2_CONF_OPTS = \
  13. -DUSE_GSSAPI=OFF \
  14. -DBUILD_CLAR=OFF \
  15. -DUSE_ICONV=ON \
  16. -DREGEX_BACKEND=regcomp \
  17. -DUSE_HTTP_PARSER=system \
  18. -DUSE_NTLMCLIENT=OFF \
  19. -DTHREADSAFE=$(if $(BR2_TOOLCHAIN_HAS_THREADS),ON,OFF)
  20. LIBGIT2_DEPENDENCIES = zlib libhttpparser
  21. # If libiconv is available (for !locale toolchains), then we can use
  22. # it for iconv support. Note that USE_ICONV=ON is still correct even
  23. # without libiconv because (1) most toolchain have iconv support
  24. # without libiconv and (2) even if USE_ICONV=ON but iconv support is
  25. # not available, libgit2 simply avoids using iconv.
  26. ifeq ($(BR2_PACKAGE_LIBICONV),y)
  27. LIBGIT2_DEPENDENCIES += libiconv
  28. endif
  29. ifeq ($(BR2_PACKAGE_LIBSSH2),y)
  30. LIBGIT2_DEPENDENCIES += libssh2
  31. LIBGIT2_CONF_OPTS += -DUSE_SSH=ON
  32. else
  33. LIBGIT2_CONF_OPTS += -DUSE_SSH=OFF
  34. endif
  35. ifeq ($(BR2_PACKAGE_OPENSSL),y)
  36. LIBGIT2_DEPENDENCIES += openssl
  37. LIBGIT2_CONF_OPTS += -DUSE_HTTPS=OpenSSL
  38. else
  39. LIBGIT2_CONF_OPTS += -DUSE_HTTPS=OFF
  40. endif
  41. $(eval $(cmake-package))