blob: ee1aa89f275c5d5821daff481900334e0eca7ab2 [file] [log] [blame]
Andrew Geissler82c905d2020-04-13 13:39:40 -05001SUMMARY = "Command line tool and library for client-side URL transfers"
Andrew Geissler90fd73c2021-03-05 15:25:55 -06002DESCRIPTION = "It uses URL syntax to transfer data to and from servers. \
3curl is a widely used because of its ability to be flexible and complete \
4complex tasks. For example, you can use curl for things like user authentication, \
5HTTP post, SSL connections, proxy support, FTP uploads, and more!"
Andrew Geissler82c905d2020-04-13 13:39:40 -05006HOMEPAGE = "http://curl.haxx.se/"
7BUGTRACKER = "http://curl.haxx.se/mail/list.cgi?list=curl-tracker"
8SECTION = "console/network"
9LICENSE = "MIT"
Andrew Geissler9b4d8b02021-02-19 12:26:16 -060010LIC_FILES_CHKSUM = "file://COPYING;md5=425f6fdc767cc067518eef9bbdf4ab7b"
Andrew Geissler82c905d2020-04-13 13:39:40 -050011
Andrew Geisslerc3d88e42020-10-02 09:45:00 -050012SRC_URI = "https://curl.haxx.se/download/curl-${PV}.tar.bz2 \
Andrew Geissler82c905d2020-04-13 13:39:40 -050013 file://0001-replace-krb5-config-with-pkg-config.patch \
14"
15
William A. Kennington IIIac69b482021-06-02 12:28:27 -070016SRC_URI[sha256sum] = "6c0c28868cb82593859fc43b9c8fdb769314c855c05cf1b56b023acf855df8ea"
Andrew Geissler82c905d2020-04-13 13:39:40 -050017
Andrew Geisslerc9f78652020-09-18 14:11:35 -050018# Curl has used many names over the years...
19CVE_PRODUCT = "haxx:curl haxx:libcurl curl:curl curl:libcurl libcurl:libcurl daniel_stenberg:curl"
20
Andrew Geissler82c905d2020-04-13 13:39:40 -050021inherit autotools pkgconfig binconfig multilib_header
22
Andrew Geisslerc926e172021-05-07 16:11:35 -050023PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} ssl libidn proxy threaded-resolver verbose zlib"
Andrew Geissler82c905d2020-04-13 13:39:40 -050024PACKAGECONFIG_class-native = "ipv6 proxy ssl threaded-resolver verbose zlib"
25PACKAGECONFIG_class-nativesdk = "ipv6 proxy ssl threaded-resolver verbose zlib"
26
27# 'ares' and 'threaded-resolver' are mutually exclusive
28PACKAGECONFIG[ares] = "--enable-ares,--disable-ares,c-ares,,,threaded-resolver"
29PACKAGECONFIG[brotli] = "--with-brotli,--without-brotli,brotli"
30PACKAGECONFIG[builtinmanual] = "--enable-manual,--disable-manual"
31PACKAGECONFIG[dict] = "--enable-dict,--disable-dict,"
32PACKAGECONFIG[gnutls] = "--with-gnutls,--without-gnutls,gnutls"
33PACKAGECONFIG[gopher] = "--enable-gopher,--disable-gopher,"
34PACKAGECONFIG[imap] = "--enable-imap,--disable-imap,"
35PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
36PACKAGECONFIG[krb5] = "--with-gssapi,--without-gssapi,krb5"
37PACKAGECONFIG[ldap] = "--enable-ldap,--disable-ldap,"
38PACKAGECONFIG[ldaps] = "--enable-ldaps,--disable-ldaps,"
Andrew Geisslerc926e172021-05-07 16:11:35 -050039PACKAGECONFIG[libgsasl] = "--with-libgsasl,--without-libgsasl,libgsasl"
Andrew Geissler82c905d2020-04-13 13:39:40 -050040PACKAGECONFIG[libidn] = "--with-libidn2,--without-libidn2,libidn2"
41PACKAGECONFIG[libssh2] = "--with-libssh2,--without-libssh2,libssh2"
42PACKAGECONFIG[mbedtls] = "--with-mbedtls=${STAGING_DIR_TARGET},--without-mbedtls,mbedtls"
Andrew Geissler4b740dc2020-05-05 08:54:39 -050043PACKAGECONFIG[mqtt] = "--enable-mqtt,--disable-mqtt,"
Andrew Geissler82c905d2020-04-13 13:39:40 -050044PACKAGECONFIG[nghttp2] = "--with-nghttp2,--without-nghttp2,nghttp2"
45PACKAGECONFIG[pop3] = "--enable-pop3,--disable-pop3,"
46PACKAGECONFIG[proxy] = "--enable-proxy,--disable-proxy,"
47PACKAGECONFIG[rtmpdump] = "--with-librtmp,--without-librtmp,rtmpdump"
48PACKAGECONFIG[rtsp] = "--enable-rtsp,--disable-rtsp,"
49PACKAGECONFIG[smb] = "--enable-smb,--disable-smb,"
50PACKAGECONFIG[smtp] = "--enable-smtp,--disable-smtp,"
51PACKAGECONFIG[ssl] = "--with-ssl --with-random=/dev/urandom,--without-ssl,openssl"
52PACKAGECONFIG[nss] = "--with-nss,--without-nss,nss"
53PACKAGECONFIG[telnet] = "--enable-telnet,--disable-telnet,"
54PACKAGECONFIG[tftp] = "--enable-tftp,--disable-tftp,"
55PACKAGECONFIG[threaded-resolver] = "--enable-threaded-resolver,--disable-threaded-resolver,,,,ares"
56PACKAGECONFIG[verbose] = "--enable-verbose,--disable-verbose"
57PACKAGECONFIG[zlib] = "--with-zlib=${STAGING_LIBDIR}/../,--without-zlib,zlib"
58
59EXTRA_OECONF = " \
60 --disable-libcurl-option \
61 --disable-ntlm-wb \
62 --enable-crypto-auth \
63 --with-ca-bundle=${sysconfdir}/ssl/certs/ca-certificates.crt \
64 --without-libmetalink \
65 --without-libpsl \
Andrew Geisslerd25ed322020-06-27 00:28:28 -050066 --enable-debug \
67 --enable-optimize \
68 --disable-curldebug \
Andrew Geissler82c905d2020-04-13 13:39:40 -050069"
70
71do_install_append_class-target() {
72 # cleanup buildpaths from curl-config
73 sed -i \
74 -e 's,--sysroot=${STAGING_DIR_TARGET},,g' \
75 -e 's,--with-libtool-sysroot=${STAGING_DIR_TARGET},,g' \
76 -e 's|${DEBUG_PREFIX_MAP}||g' \
77 ${D}${bindir}/curl-config
78}
79
80PACKAGES =+ "lib${BPN}"
81
82FILES_lib${BPN} = "${libdir}/lib*.so.*"
83RRECOMMENDS_lib${BPN} += "ca-certificates"
84
85FILES_${PN} += "${datadir}/zsh"
86
87inherit multilib_script
88MULTILIB_SCRIPTS = "${PN}-dev:${bindir}/curl-config"
89
90BBCLASSEXTEND = "native nativesdk"