Changeset 933


Ignore:
Timestamp:
Jan 25, 2017, 10:59:57 AM (9 years ago)
Author:
Silvan Scherrer
Message:

spec: zlib: Release version 1.2.11-1.

Location:
spec/trunk/SPECS
Files:
2 added
1 edited

Legend:

Unmodified
Added
Removed
  • spec/trunk/SPECS/zlib.spec

    r661 r933  
    1 Summary: The zlib compression and decompression library.
     1#define svn_url     e:/trees/zlib/trunk
     2%define svn_url     http://svn.netlabs.org/repos/ports/zlib/trunk
     3%define svn_rev     1948
     4
     5Summary: The compression and decompression library
    26Name: zlib
    3 Version: 1.2.5
    4 Release: 6%{?dist}
    5 License: BSD
     7Version: 1.2.11
     8Release: 1%{?dist}
     9License: zlib and Boost
    610Group: System Environment/Libraries
    711URL: http://www.zlib.net
    8 Source: %url/zlib-%version.tar.bz2
    9 Patch0: zlib-os2.diff
    10 Prefix: %_prefix
    11 BuildRoot: /override/%name-%version
     12Vendor:  bww bitwise works GmbH
     13Source:  %{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip
     14
     15# DEF files to create forwarders for the legacy package
     16Source10:       z.def
     17
     18BuildRequires: automake, autoconf, libtool
    1219
    1320%description
    14 The zlib compression library provides in-memory compression and
    15 decompression functions, including integrity checks of the uncompressed
    16 data.  This version of the library supports only one compression method
    17 (deflation), but other algorithms may be added later, which will have
    18 the same stream interface.  The zlib library is used by many different
    19 system programs.
     21Zlib is a general-purpose, patent-free, lossless data compression
     22library which is used by many different programs.
    2023
    2124%package devel
    22 Summary: Header files and libraries for developing apps which will use zlib.
     25Summary: Header files and libraries for Zlib development
    2326Group: Development/Libraries
    24 Requires: %name = %version-%release
     27Requires: %{name} = %{version}-%{release}
    2528
    2629%description devel
    27 The zlib-devel package contains the header files and libraries needed to
    28 develop programs that use the zlib compression and decompression library.
     30The zlib-devel package contains the header files and libraries needed
     31to develop programs that use the zlib compression and decompression
     32library.
    2933
    30 %package debug
    31 Summary: HLL debug data for exception handling support.
     34%package static
     35Summary: Static libraries for Zlib development
     36Group: Development/Libraries
     37Requires: %{name}-devel = %{version}-%{release}
    3238
    33 %description debug
    34 HLL debug data for exception handling support.
     39%description static
     40The zlib-static package includes static libraries needed
     41to develop programs that use the zlib compression and
     42decompression library.
     43
     44%package -n minizip
     45Summary: Library for manipulation with .zip archives
     46Group: System Environment/Libraries
     47Requires: %{name} = %{version}-%{release}
     48
     49%description -n minizip
     50Minizip is a library for manipulation with files from .zip archives.
     51
     52%package -n minizip-devel
     53Summary: Development files for the minizip library
     54Group: Development/Libraries
     55Requires: minizip = %{version}-%{release}
     56Requires: %{name}-devel = %{version}-%{release}
     57Requires: pkgconfig
     58
     59%description -n minizip-devel
     60This package contains the libraries and header files needed for
     61developing applications which use minizip.
    3562
    3663%debug_package
    3764
    3865%prep
     66%if %{?svn_rev:%(sh -c 'if test -f "%{_sourcedir}/%{name}-%{version}-r%{svn_rev}.zip" ; then echo 1 ; else echo 0 ; fi')}%{!?svn_rev):0}
    3967%setup -q
    40 %patch0 -p0 -b .os2~
     68%else
     69%setup -n "%{name}-%{version}" -Tc
     70svn export %{?svn_rev:-r %{svn_rev}} %{svn_url} . --force
     71rm -f "%{_sourcedir}/%{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip"
     72(cd .. && zip -SrX9 "%{_sourcedir}/%{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip" "%{name}-%{version}")
     73%endif
    4174
    42 # Use optflags_lib for this package if defined.
    43 %{expand:%%define optflags %{?optflags_lib:%optflags_lib}%{!?optflags_lib:%optflags} -Wall}
     75# Prepare forwarder DLLs.
     76for m in %{SOURCE10}; do
     77  cp ${m} .
     78done
    4479
    4580%build
    46 # first build and test static zlib
    47 export TEST_LDFLAGS="-Zomf"
    48 CFLAGS="%optflags" \
    49 ./configure --prefix=/@unixroot/usr --static
     81export CFLAGS="$RPM_OPT_FLAGS"
     82export LDFLAGS="$LDFLAGS -Zomf -Zhigh-mem -lcx"
     83export VENDOR="%{vendor}"
     84./configure --libdir=%{_libdir} --includedir=%{_includedir} --prefix=%{_prefix}
     85make %{?_smp_mflags}
    5086
    51 ! grep -wE 'NO_vsnprintf|HAS_vsprintf_void|HAS_vsnprintf_void|NO_snprintf|HAS_sprintf_void|HAS_snprintf_void' Makefile
    52 %__make
    53 %__make z.dll
     87cd contrib/minizip
     88autoreconf -fvi
     89%configure --enable-static=no
     90make %{?_smp_mflags}
    5491
    55 %{!?_without_check:%{!?_without_test:%__make test}}
    56 rm -f *.s *.o
    57 
    58 # next build and test shared zlib
    59 #CFLAGS="%optflags -fPIC" ./configure --prefix=%_prefix --shared
    60 #! grep -wE 'NO_vsnprintf|HAS_vsprintf_void|HAS_vsnprintf_void|NO_snprintf|HAS_sprintf_void|HAS_snprintf_void' Makefile
    61 #%__make
    62 #%{!?_without_check:%{!?_without_test:%__make test}}
    63 
    64 #bzip2 -9fk ChangeLog FAQ algorithm.txt
     92%check
     93make test
    6594
    6695%install
    67 rm -rf %buildroot
    68 mkdir -p %buildroot%_libdir
    69 mkdir -p %buildroot%_libdir/pkgconfig
    70 mkdir -p %buildroot%_includedir
    71 mkdir -p %buildroot%_mandir/man3
     96make install DESTDIR=$RPM_BUILD_ROOT
    7297
    73 cp -a libz.a %buildroot%_libdir/
    74 cp -a libz_s.a %buildroot%_libdir/
    75 cp -a z.dll %buildroot%_libdir/
    76 cp -a zlib.pc %buildroot%_libdir/pkgconfig/
     98cd contrib/minizip
     99make install DESTDIR=$RPM_BUILD_ROOT
     100# we need to get back to root, as else the debugfile list is created at
     101# the wrong location
     102cd ..
     103cd ..
    77104
    78 install -p -m644 zlib.h zconf.h %buildroot%_includedir/
    79 install -p -m644 zlib.3 %buildroot%_mandir/man3/
     105rm -f $RPM_BUILD_ROOT%{_libdir}/*.la
    80106
    81 %define docdir %_docdir/%name-%version
    82 mkdir -p %buildroot%docdir
    83 install -p -m644 README \
    84         example.c minigzip.c %buildroot%docdir/
    85 # License {FAQ,ChangeLog,algorithm.txt}.bz2
     107# Generate & install forwarder DLLs.
     108gcc -Zomf -Zdll -nostdlib z.def -l$RPM_BUILD_ROOT/%{_libdir}/z1.dll -lend -o $RPM_BUILD_ROOT/%{_libdir}/z.dll
     109
     110#post -p /sbin/ldconfig
     111
     112#postun -p /sbin/ldconfig
     113
     114#post -n minizip -p /sbin/ldconfig
     115
     116#postun -n minizip -p /sbin/ldconfig
    86117
    87118%files
    88 %defattr(-,root,root)
    89 %_libdir/z.dll
    90 %dir %docdir
    91 #docdir/License
    92 %docdir/README
     119%{!?_licensedir:%global license %%doc}
     120%license README
     121%doc ChangeLog FAQ
     122%{_libdir}/z*.dll
    93123
    94124%files devel
    95 %defattr(-,root,root)
    96 %_libdir/*.a
    97 %_includedir/*
    98 %_mandir/man?/*
    99 %dir %docdir
    100 %docdir/*.c
    101 #docdir/*.bz2
    102 %{_libdir}/pkgconfig/*.pc
     125%{!?_licensedir:%global license %%doc}
     126%license README
     127%doc doc/algorithm.txt test/example.c
     128%{_libdir}/libz_dll.a
     129%{_libdir}/pkgconfig/zlib.pc
     130%{_includedir}/zlib.h
     131%{_includedir}/zconf.h
     132%{_mandir}/man3/zlib.3*
     133
     134%files static
     135%{!?_licensedir:%global license %%doc}
     136%license README
     137%{_libdir}/libz.a
     138
     139%files -n minizip
     140%doc contrib/minizip/MiniZip64_info.txt contrib/minizip/MiniZip64_Changes.txt
     141%{_libdir}/minizip*.dll
     142
     143%files -n minizip-devel
     144%dir %{_includedir}/minizip
     145%{_includedir}/minizip/*.h
     146%{_libdir}/minizip*_dll.a
     147%{_libdir}/pkgconfig/minizip.pc
    103148
    104149%changelog
     150* Tue Jan 24 2017 Silvan Scherrer <silvan.scherrer@aroa.ch> 1.2.11-1
     151- update to version 1.2.11
     152
    105153* Thu Feb 18 2016 yd <yd@os2power.com> 1.2.5-6
    106154- added .pc file to distribution.
Note: See TracChangeset for help on using the changeset viewer.