2007-01-15 23:08:21 +00:00
|
|
|
#
|
2011-08-03 14:03:40 +00:00
|
|
|
# spec file for package curl
|
2007-01-15 23:08:21 +00:00
|
|
|
#
|
2015-02-15 17:07:47 +00:00
|
|
|
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
|
2007-01-15 23:08:21 +00:00
|
|
|
#
|
2008-09-05 20:26:25 +00:00
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2007-01-15 23:08:21 +00:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
2012-01-18 12:51:12 +00:00
|
|
|
|
2010-10-22 17:36:46 +00:00
|
|
|
%bcond_without openssl
|
|
|
|
%bcond_with mozilla_nss
|
|
|
|
%bcond_without testsuite
|
2007-01-15 23:08:21 +00:00
|
|
|
Name: curl
|
2015-02-26 10:52:00 +00:00
|
|
|
Version: 7.41.0
|
2012-05-14 08:01:48 +00:00
|
|
|
Release: 0
|
|
|
|
Summary: A Tool for Transferring Data from URLs
|
2012-11-06 08:40:05 +00:00
|
|
|
License: BSD-3-Clause and MIT
|
2012-05-14 08:01:48 +00:00
|
|
|
Group: Productivity/Networking/Web/Utilities
|
|
|
|
Url: http://curl.haxx.se/
|
|
|
|
Source: http://curl.haxx.se/download/%{name}-%{version}.tar.lzma
|
|
|
|
Source2: http://curl.haxx.se/download/%{name}-%{version}.tar.lzma.asc
|
|
|
|
Source3: baselibs.conf
|
2012-12-18 10:09:31 +00:00
|
|
|
Source4: %{name}.keyring
|
2014-11-15 16:38:21 +00:00
|
|
|
Patch0: libcurl-ocloexec.patch
|
2012-05-14 08:01:48 +00:00
|
|
|
Patch1: dont-mess-with-rpmoptflags.diff
|
2013-02-18 09:00:56 +00:00
|
|
|
Patch3: curl-secure-getenv.patch
|
2015-03-24 20:46:39 +00:00
|
|
|
# PATCH-FIX-OPENSUSE lnussel@suse.de -- use openssl's built in verify path as fallback
|
|
|
|
Patch4: curl-7.41.0-use-openssl-s-built-in-verify-path-as-fallback.diff
|
2014-11-15 16:38:21 +00:00
|
|
|
BuildRequires: krb5-mini-devel
|
2012-02-02 18:50:23 +00:00
|
|
|
BuildRequires: libtool
|
2012-01-18 12:50:45 +00:00
|
|
|
BuildRequires: lzma
|
|
|
|
BuildRequires: openldap2-devel
|
|
|
|
BuildRequires: pkg-config
|
2015-02-15 17:07:47 +00:00
|
|
|
BuildRequires: pkgconfig(libidn)
|
|
|
|
BuildRequires: pkgconfig(libmetalink)
|
|
|
|
BuildRequires: pkgconfig(libssh2)
|
|
|
|
BuildRequires: pkgconfig(zlib)
|
2014-11-15 16:38:21 +00:00
|
|
|
Requires: libcurl4 = %{version}
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2010-10-22 17:36:46 +00:00
|
|
|
%if %{with openssl}
|
2015-02-15 17:07:47 +00:00
|
|
|
BuildRequires: pkgconfig(libssl)
|
2010-10-22 17:36:46 +00:00
|
|
|
%endif
|
|
|
|
%if %{with mozilla_nss}
|
|
|
|
BuildRequires: mozilla-nss-devel
|
|
|
|
%endif
|
2014-03-13 13:18:58 +00:00
|
|
|
#BuildRequires: openssh
|
2008-09-15 10:13:37 +00:00
|
|
|
%if 0%{?_with_stunnel:1}
|
2007-11-19 09:19:29 +00:00
|
|
|
# used by the testsuite
|
|
|
|
BuildRequires: stunnel
|
2008-09-15 10:13:37 +00:00
|
|
|
%endif
|
2008-11-02 14:37:35 +00:00
|
|
|
# bug437293
|
|
|
|
%ifarch ppc64
|
|
|
|
Obsoletes: curl-64bit
|
|
|
|
%endif
|
2011-08-15 12:06:41 +00:00
|
|
|
|
2007-01-15 23:08:21 +00:00
|
|
|
%description
|
|
|
|
Curl is a client to get documents and files from or send documents to a
|
2008-09-05 20:26:25 +00:00
|
|
|
server using any of the supported protocols (HTTP, HTTPS, FTP, FTPS,
|
|
|
|
TFTP, DICT, TELNET, LDAP, or FILE). The command is designed to work
|
|
|
|
without user interaction or any kind of interactivity.
|
2007-01-15 23:08:21 +00:00
|
|
|
|
2007-04-12 15:12:15 +00:00
|
|
|
%package -n libcurl4
|
2011-11-29 08:10:06 +00:00
|
|
|
Summary: Version 4 of cURL shared library
|
2007-04-12 15:12:15 +00:00
|
|
|
Group: Productivity/Networking/Web/Utilities
|
|
|
|
|
|
|
|
%description -n libcurl4
|
2011-11-29 08:10:06 +00:00
|
|
|
The cURL shared library version 4 for accessing data using different
|
|
|
|
network protocols.
|
2007-04-12 15:12:15 +00:00
|
|
|
|
|
|
|
%package -n libcurl-devel
|
|
|
|
Summary: A Tool for Transferring Data from URLs
|
2007-10-09 14:57:38 +00:00
|
|
|
Group: Development/Libraries/C and C++
|
2012-05-14 08:01:48 +00:00
|
|
|
Requires: glibc-devel
|
|
|
|
Requires: libcurl4 = %{version}
|
2007-05-06 15:12:17 +00:00
|
|
|
# curl-devel (v 7.15.5) was last used in 10.2
|
2007-08-03 13:41:16 +00:00
|
|
|
Provides: curl-devel <= 7.15.5
|
2007-06-03 19:11:39 +00:00
|
|
|
Obsoletes: curl-devel < 7.16.2
|
2007-04-12 15:12:15 +00:00
|
|
|
|
|
|
|
%description -n libcurl-devel
|
|
|
|
Curl is a client to get documents and files from or send documents to a
|
|
|
|
server using any of the supported protocols (HTTP, HTTPS, FTP, GOPHER,
|
|
|
|
DICT, TELNET, LDAP, or FILE). The command is designed to work without
|
|
|
|
user interaction or any kind of interactivity.
|
2007-01-15 23:08:21 +00:00
|
|
|
|
|
|
|
%prep
|
2011-11-29 08:41:20 +00:00
|
|
|
%setup -q
|
2014-11-15 16:38:21 +00:00
|
|
|
%patch0
|
2012-01-18 12:50:45 +00:00
|
|
|
%patch1
|
2013-02-18 09:00:56 +00:00
|
|
|
%patch3
|
2015-03-24 20:46:39 +00:00
|
|
|
%patch4 -p1
|
2014-04-10 09:06:38 +00:00
|
|
|
|
2007-01-15 23:08:21 +00:00
|
|
|
%build
|
2013-04-13 15:46:54 +00:00
|
|
|
# curl complains if macro definition is contained in CFLAGS
|
|
|
|
# see m4/xc-val-flgs.m4
|
|
|
|
CPPFLAGS="-D_FORTIFY_SOURCE=2"
|
2015-02-26 10:52:00 +00:00
|
|
|
CFLAGS=$(echo "%{optflags}" | sed -e 's/-D_FORTIFY_SOURCE=2//')
|
2013-04-13 15:46:54 +00:00
|
|
|
export CPPFLAGS CFLAGS
|
2015-01-02 15:18:12 +00:00
|
|
|
export CFLAGS="$CFLAGS -fPIE"
|
|
|
|
export LDFLAGS="$LDFLAGS -pie"
|
2012-01-18 12:51:12 +00:00
|
|
|
autoreconf -fi
|
2008-01-30 17:04:20 +00:00
|
|
|
# local hack to make curl-config --libs stop printing libraries it depends on
|
|
|
|
# (currently, libtool sets link_all_deplibs=(yes|unknown) everywhere,
|
|
|
|
# will hopefully change in the future)
|
2015-02-26 10:52:00 +00:00
|
|
|
sed -i 's/\(link_all_deplibs=\)unknown/\1no/' configure
|
2012-07-30 07:42:51 +00:00
|
|
|
%configure \
|
2007-02-02 15:10:02 +00:00
|
|
|
--enable-ipv6 \
|
2010-10-22 17:36:46 +00:00
|
|
|
%if %{with openssl}
|
2007-02-02 15:10:02 +00:00
|
|
|
--with-ssl \
|
2015-03-24 20:46:39 +00:00
|
|
|
--without-ca-path \
|
|
|
|
--without-ca-bundle \
|
2010-10-22 17:36:46 +00:00
|
|
|
%else
|
|
|
|
--without-ssl \
|
|
|
|
%if %{with mozilla_nss}
|
|
|
|
--with-nss \
|
|
|
|
%endif
|
|
|
|
%endif
|
2014-11-15 16:38:21 +00:00
|
|
|
--with-gssapi=%{_libexecdir}/mit \
|
2010-03-26 15:17:01 +00:00
|
|
|
--with-libssh2\
|
2007-02-02 15:10:02 +00:00
|
|
|
--enable-hidden-symbols \
|
2011-04-09 21:16:06 +00:00
|
|
|
--disable-static \
|
2015-02-15 17:07:47 +00:00
|
|
|
--enable-threaded-resolver \
|
|
|
|
--with-libmetalink
|
2011-04-09 21:16:06 +00:00
|
|
|
|
2015-02-26 10:52:00 +00:00
|
|
|
# if this fails, the above sed hack did not work
|
2008-01-30 17:04:20 +00:00
|
|
|
./libtool --config | grep -q link_all_deplibs=no
|
2007-05-23 15:37:15 +00:00
|
|
|
# enable-hidden-symbols needs gcc4 and causes that curl exports only its API
|
2011-09-18 18:45:34 +00:00
|
|
|
make %{?_smp_mflags}
|
2010-10-22 17:36:46 +00:00
|
|
|
|
|
|
|
%if %{with testsuite}
|
|
|
|
%check
|
2015-02-26 10:52:00 +00:00
|
|
|
pushd tests
|
2014-11-15 16:38:21 +00:00
|
|
|
make %{?_smp_mflags}
|
2007-07-10 15:25:05 +00:00
|
|
|
# make sure the testsuite runs don't race on MP machines in autobuild
|
|
|
|
if test -z "$BUILD_INCARNATION" -a -r /.buildenv; then
|
|
|
|
. /.buildenv
|
|
|
|
fi
|
|
|
|
if test -z "$BUILD_INCARNATION"; then
|
|
|
|
BUILD_INCARNATION=0
|
|
|
|
fi
|
|
|
|
base=$((8990 + $BUILD_INCARNATION * 20))
|
2008-09-12 21:53:11 +00:00
|
|
|
perl ./runtests.pl -a -b$base || {
|
2009-05-19 21:14:51 +00:00
|
|
|
%if 0%{?curl_testsuite_fatal:1}
|
2008-02-25 16:03:38 +00:00
|
|
|
exit
|
2009-05-19 21:14:51 +00:00
|
|
|
%else
|
|
|
|
echo "WARNING: runtests.pl failed with code $?, continuing nevertheless"
|
2008-02-25 16:03:38 +00:00
|
|
|
%endif
|
|
|
|
}
|
2010-10-22 17:36:46 +00:00
|
|
|
%endif
|
2015-02-26 10:52:00 +00:00
|
|
|
popd
|
2007-01-15 23:08:21 +00:00
|
|
|
|
|
|
|
%install
|
2015-02-26 10:52:00 +00:00
|
|
|
%make_install
|
|
|
|
rm -f %{buildroot}%{_libdir}/libcurl.la
|
|
|
|
install -Dm 0644 docs/libcurl/libcurl.m4 %{buildroot}%{_datadir}/aclocal/libcurl.m4
|
2007-01-15 23:08:21 +00:00
|
|
|
|
2007-06-03 19:11:39 +00:00
|
|
|
%post -n libcurl4 -p /sbin/ldconfig
|
2007-01-15 23:08:21 +00:00
|
|
|
|
2007-06-03 19:11:39 +00:00
|
|
|
%postun -n libcurl4 -p /sbin/ldconfig
|
2007-01-15 23:08:21 +00:00
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
2007-10-09 14:57:38 +00:00
|
|
|
%doc README RELEASE-NOTES
|
|
|
|
%doc docs/{BUGS,FAQ,FEATURES,MANUAL,RESOURCES,TODO,TheArtOfHttpScripting}
|
2008-09-05 20:26:25 +00:00
|
|
|
%doc lib/README.curl_off_t
|
2014-11-15 16:38:21 +00:00
|
|
|
%{_bindir}/curl
|
2012-07-30 07:42:51 +00:00
|
|
|
%doc %{_mandir}/man1/curl.1%{ext_man}
|
2007-01-15 23:08:21 +00:00
|
|
|
|
2007-04-12 15:12:15 +00:00
|
|
|
%files -n libcurl4
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_libdir}/libcurl.so.4*
|
|
|
|
|
|
|
|
%files -n libcurl-devel
|
2007-01-15 23:08:21 +00:00
|
|
|
%defattr(-,root,root)
|
2014-11-15 16:38:21 +00:00
|
|
|
%{_bindir}/curl-config
|
|
|
|
%{_includedir}/curl
|
2015-02-26 10:52:00 +00:00
|
|
|
%dir %{_datadir}/aclocal/
|
2014-11-15 16:38:21 +00:00
|
|
|
%{_datadir}/aclocal/libcurl.m4
|
2007-01-15 23:08:21 +00:00
|
|
|
%{_libdir}/libcurl.so
|
|
|
|
%{_libdir}/pkgconfig/libcurl.pc
|
2012-07-30 07:42:51 +00:00
|
|
|
%{_mandir}/man1/curl-config.1%{ext_man}
|
|
|
|
%{_mandir}/man3/*
|
2009-03-03 21:12:52 +00:00
|
|
|
%doc docs/libcurl/symbols-in-versions
|
2007-12-12 17:05:45 +00:00
|
|
|
|
2007-02-16 17:20:49 +00:00
|
|
|
%changelog
|