# The naming scheme in non-Mandriva-based distros %if 0%{!?mklibname:1} %define mklibname(ds) lib%{1}%{?2:%{2}}%{-s:-static}%{-d:-devel} %endif %if 0%{!?mkrel:1} %define mkrel(c) %{1}%{?dist} %endif %define major 4 %define libname %mklibname %{name} %{major} %define develname %mklibname %{name} -d # Update this to match the date of this package's latest security patch # if this is not the latest released version of curl #define patchdate YYYY-MM-DD Summary: Gets a file from an FTP, GOPHER or HTTP server Name: curl Epoch: 1 Version: 8.11.1 Release: %mkrel 2 License: BSD-like Group: Networking/Other URL: https://curl.haxx.se Source0: https://curl.haxx.se/download/%{name}-%{version}.tar.xz Source1: https://curl.haxx.se/download/%{name}-%{version}.tar.xz.asc Patch0: curl-7.58.0-multilib.patch Patch1: curl-8.11.1-git-eventfd.patch BuildRequires: (groff-for-man or /usr/bin/groff) BuildRequires: pkgconfig(openssl) BuildRequires: pkgconfig(zlib) BuildRequires: pkgconfig(libbrotlidec) BuildRequires: pkgconfig(libidn2) BuildRequires: pkgconfig(libpsl) BuildRequires: pkgconfig(libssh) BuildRequires: pkgconfig(python3) BuildRequires: pkgconfig(ldap) BuildRequires: pkgconfig(krb5) #BuildRequires: c-ares-devel # (misc) required for testing BuildRequires: (locales-en or /usr/share/locale/en_US) BuildRequires: stunnel BuildRequires: pkgconfig(libnghttp2) >= 1.35.0 Provides: webfetch %description curl is a client to get documents/files from servers, using any of the supported protocols. The command is designed to work without user interaction or any kind of interactivity. curl offers a busload of useful tricks like proxy support, user authentication, ftp upload, HTTP post, file transfer resume and more. %package -n %{libname} Summary: A library of functions for file transfer Group: Networking/Other Provides: libcurl%{?_isa} = %{epoch}:%{version}-%{release} Requires: rootcerts >= 1:20070713.00 %description -n %{libname} libcurl is a library of functions for sending and receiving files through various protocols, including http and ftp. %package -n %{develname} Summary: Header files and libraries for libcurl Group: Development/C Requires: %{libname} = %{epoch}:%{version}-%{release} Provides: %{name}-devel = %{epoch}:%{version}-%{release} Provides: lib%{name}-devel = %{epoch}:%{version}-%{release} Provides: libcurl%{major}-devel = %{epoch}:%{version}-%{release} Provides: %mklibname %{name} 4 -d %description -n %{develname} libcurl is a library of functions for sending and receiving files through various protocols, including http and ftp. You should install this package if you wish to develop applications that use libcurl. %package examples Summary: Example files for %{name} development Group: Development/C BuildArch: noarch Requires: %{name}-devel >= %{epoch}:%{version}-%{release} %description examples Example files for %{name} development. %prep %autosetup -p1 # Remove ldflags from curl-config output sed -i -e 's/@LDFLAGS@\s\+//g' curl-config.in %build autoreconf -fiv %if %{defined patchdate} export CPPFLAGS="$CPPFLAGS -DCURL_PATCHSTAMP='\"%{patchdate}\"'" %endif %configure \ --disable-static \ --with-brotli \ --with-libidn2 \ --with-libpsl \ --with-ssl \ --without-gnutls \ --with-zlib \ --with-lber-lib=lber \ --with-libssh \ --with-random \ --with-ca-bundle=%{_sysconfdir}/pki/tls/certs/ca-bundle.crt \ --with-gssapi \ --with-nghttp2 \ --with-zsh-functions-dir \ --with-fish-functions-dir \ --enable-hidden-symbols \ --enable-optimize \ --enable-nonblocking \ --enable-thread \ --enable-crypto-auth \ --enable-libgcc \ --enable-ldaps \ --enable-ipv6 \ --disable-ares %make_build # Build zsh completions %make_build -C scripts %ifnarch %arm %check skip_tests='false' if ! $skip_tests ; then # %make_build sets -O which effectively hides the test output %__make %{?_smp_mflags} test V=0 TEST_Q='-a -p -n -j20 !flaky !timing-dependent' fi %endif %install %make_install %make_install -C scripts find "%{buildroot}" -name *.la -delete %files %{_bindir}/curl %{_mandir}/man1/curl.1* %{_datadir}/fish/vendor_completions.d/curl.fish %{_datadir}/zsh/site-functions/_curl %files -n %{libname} %{_libdir}/*.so.%{major}{,.*} %files -n %{develname} %doc docs/BUGS.md docs/KNOWN_BUGS docs/CONTRIBUTE.md docs/FAQ RELEASE-NOTES %doc docs/TODO docs/THANKS docs/INTERNALS.md %{_bindir}/curl-config %{_datadir}/aclocal/libcurl.m4 %{_libdir}/libcurl.so %{_includedir}/curl %{_libdir}/pkgconfig/*.pc %{_mandir}/man1/curl-config.1* %{_mandir}/man3/* %files examples %doc docs/examples