source: spec/trunk/SPECS/curl.spec@ 33

Last change on this file since 33 was 33, checked in by Yuri Dario, 15 years ago

spec: added curl build.

File size: 5.0 KB
Line 
1Summary: A utility for getting files from remote servers (FTP, HTTP, and others)
2Name: curl
3Version: 7.21.1
4Release: 1
5License: MIT
6Group: Applications/Internet
7Source: http://curl.haxx.se/download/%{name}-%{version}.tar.gz
8
9Patch0: curl-os2.diff
10
11Provides: webclient
12URL: http://curl.haxx.se/
13BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
14
15#BuildRequires: automake
16#BuildRequires: groff
17#BuildRequires: krb5-devel
18#BuildRequires: libidn-devel
19#BuildRequires: libssh2-devel >= 1.2
20#BuildRequires: nss-devel
21#BuildRequires: openldap-devel
22#BuildRequires: openssh-clients
23#BuildRequires: openssh-server
24BuildRequires: pkgconfig
25#BuildRequires: stunnel
26
27# valgrind is not available on s390(x)
28%ifnarch s390 s390x
29#BuildRequires: valgrind
30%endif
31
32BuildRequires: zlib-devel
33Requires: libcurl = %{version}-%{release}
34
35# TODO: mention also IMAP(S), POP3(S), SMTP(S) and RTSP protocols
36%description
37cURL is a tool for getting files from HTTP, FTP, FILE, LDAP, LDAPS,
38DICT, TELNET and TFTP servers, using any of the supported protocols.
39cURL is designed to work without user interaction or any kind of
40interactivity. cURL offers many useful capabilities, like proxy support,
41user authentication, FTP upload, HTTP post, and file transfer resume.
42
43%package -n libcurl
44Summary: A library for getting files from web servers
45Group: Development/Libraries
46
47# libssh2 ABI has been changed since libssh2-1.0
48# this forces update of libssh2 before update of libcurl
49#Requires: libssh2 >= 1.2
50
51%description -n libcurl
52This package provides a way for applications to use FTP, HTTP, Gopher and
53other servers for getting files.
54
55%package -n libcurl-devel
56Summary: Files needed for building applications with libcurl
57Group: Development/Libraries
58#Requires: automake
59Requires: libcurl = %{version}-%{release}
60#Requires: libidn-devel
61Requires: pkgconfig
62
63Provides: curl-devel = %{version}-%{release}
64Obsoletes: curl-devel < %{version}-%{release}
65
66%description -n libcurl-devel
67cURL is a tool for getting files from FTP, HTTP, Gopher, Telnet, and
68Dict servers, using any of the supported protocols. The libcurl-devel
69package includes files needed for developing applications which can
70use cURL's capabilities internally.
71
72%prep
73%setup -q
74
75# Convert docs to UTF-8
76# NOTE: we do this _before_ applying of all patches, which are already UTF-8
77#for f in CHANGES README; do
78# iconv -f iso-8859-1 -t utf8 < ${f} > ${f}.utf8
79# mv -f ${f}.utf8 ${f}
80#done
81
82%patch0 -p1 -b .os2~
83
84#autoreconf
85# replace hard wired port numbers in the test suite
86#sed -i s/899\\\([0-9]\\\)/%{?__isa_bits}9\\1/ tests/data/test*
87
88%build
89export CONFIG_SHELL="/bin/sh" ; \
90export LDFLAGS="-Zbin-files -Zhigh-mem -Zomf -Zargs-wild -Zargs-resp" ; \
91export LIBS="-lurpo -lmmap -lpthread" ; \
92%configure \
93 --disable-ipv6 \
94 --disable-ldaps \
95 --enable-manual \
96 --with-ca-bundle=%{_sysconfdir}/pki/tls/certs/ca-bundle.crt \
97 --with-gssapi=%{_prefix}/kerberos \
98 --without-libidn \
99 --without-libssh2 \
100 --without-ssl --without-nss \
101 --enable-shared --disable-static \
102 "--cache-file=%{_topdir}/cache/%{name}.cache"
103
104# uncomment to turn off optimizations
105# find -name Makefile | xargs sed -i 's/-O2/-O0/'
106# Remove bogus rpath
107#sed -i \
108# -e 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' \
109# -e 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
110
111make %{?_smp_mflags}
112
113#%check
114#LD_LIBRARY_PATH=$RPM_BUILD_ROOT%{_libdir}
115#export LD_LIBRARY_PATH
116#cd tests
117#make %{?_smp_mflags}
118# use different port range for 32bit and 64bit build, thus make it possible
119# to run both in parallel on the same machine
120#./runtests.pl -a -b%{?__isa_bits}90 -p -v
121
122%install
123rm -rf $RPM_BUILD_ROOT
124
125make DESTDIR=$RPM_BUILD_ROOT INSTALL="%{__install} -p" install
126
127rm -f ${RPM_BUILD_ROOT}%{_libdir}/libcurl.la
128
129install -d $RPM_BUILD_ROOT/%{_datadir}/aclocal
130install -m 644 docs/libcurl/libcurl.m4 $RPM_BUILD_ROOT/%{_datadir}/aclocal
131
132install -m 755 lib/curl7.dll $RPM_BUILD_ROOT/%{_libdir}
133install -m 755 lib/.libs/curl.lib $RPM_BUILD_ROOT/%{_libdir}
134install -m 755 lib/.libs/curl_s.a $RPM_BUILD_ROOT/%{_libdir}
135
136#%define _curlbuild_h curlbuild-32.h
137#mv $RPM_BUILD_ROOT%{_includedir}/curl/curlbuild.h \
138# $RPM_BUILD_ROOT%{_includedir}/curl/%{_curlbuild_h}
139#install -m 644 %{SOURCE2} $RPM_BUILD_ROOT%{_includedir}/curl/curlbuild.h
140
141%clean
142rm -rf $RPM_BUILD_ROOT
143
144#%post -n libcurl -p /sbin/ldconfig
145
146#%postun -n libcurl -p /sbin/ldconfig
147
148%files
149%defattr(-,root,root,-)
150%doc CHANGES README* COPYING
151%doc docs/BUGS docs/FAQ docs/FEATURES
152%doc docs/MANUAL docs/RESOURCES
153%doc docs/TheArtOfHttpScripting docs/TODO
154%{_bindir}/curl.exe
155%{_mandir}/man1/curl.1*
156
157%files -n libcurl
158%defattr(-,root,root,-)
159%{_libdir}/curl7.dll
160
161%files -n libcurl-devel
162%defattr(-,root,root,-)
163%doc docs/examples/*.c docs/examples/Makefile.example docs/INTERNALS
164%doc docs/CONTRIBUTE docs/libcurl/ABI
165%{_bindir}/curl-config*
166%{_includedir}/curl
167%{_libdir}/*.a
168%{_libdir}/*.lib
169%{_libdir}/pkgconfig/*.pc
170%{_mandir}/man1/curl-config.1*
171%{_mandir}/man3/*
172%{_datadir}/aclocal/libcurl.m4
173
174%changelog
Note: See TracBrowser for help on using the repository browser.