summaryrefslogtreecommitdiffstats
path: root/contrib/crossrpms/cygwin/i686/zlib.add
blob: c85a2e1f1ea60e02ec905b93541a0df340b1f224 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
%define zlib_version @ZLIB_VERS@
%define zlib_rpmvers %{expand:%(echo @ZLIB_VERS@ | tr - _)} 

Name:         @rpmprefix@@tool_target@-zlib
Release:      @ZLIB_RPMREL@
License:      GPL
Group:        Development/Tools

BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch:	noarch

Version:      	%zlib_rpmvers
Summary:      	Cygwin zlib Libraries

Source0:	ftp://cygwin.com/pub/cygwin/release/zlib/zlib-%{zlib_version}.tar.bz2
Source1:	ftp://cygwin.com/pub/cygwin/release/zlib/zlib-devel/zlib-devel-%{zlib_version}.tar.bz2
Source2:	ftp://cygwin.com/pub/cygwin/release/zlib/zlib0/zlib0-%{zlib_version}.tar.bz2

Provides:       @rpmprefix@@tool_target@-zlib-devel = %{version}-%{release}

%description
Cygwin zlib libraries.

%prep
%setup -c -q

%build
  rm -rf @tool_target@

  # Setup sys-root (Usable for gcc >= 3.4)
  mkdir -p @tool_target@/sys-root
  ( cd @tool_target@/sys-root ; %{__tar} xvjf %{SOURCE0})
  ( cd @tool_target@/sys-root ; %{__tar} xvjf %{SOURCE1})
  ( cd @tool_target@/sys-root ; %{__tar} xvjf %{SOURCE2})

%install
  rm -rf $RPM_BUILD_ROOT
  mkdir -p $RPM_BUILD_ROOT%{_prefix}
  cp -a @tool_target@ $RPM_BUILD_ROOT%{_prefix}