191 lines
6.6 KiB
RPMSpec
191 lines
6.6 KiB
RPMSpec
%global libname SharpZipLib
|
|
|
|
%global commit0 e01215507cf25a5978a0bd850c9e67dbabf515b7
|
|
%global date 20150714
|
|
|
|
# mono is without any packagable debuginfo
|
|
%global debug_package %{nil}
|
|
|
|
%bcond_with brokentests
|
|
|
|
Name: sharpziplib
|
|
# ReadMe.rtf says version 0.85.5 but version 0.86.0 (2010/05/25) is mentioned on homepage,
|
|
# latest upstream release as tarball is 0.86.0.518
|
|
Version: 0.86.0.518
|
|
Release: 7%{?dist}
|
|
Summary: Zip, GZip, Tar and BZip2 library
|
|
|
|
# - as stated on the homepage, license is aka GNU Classpath exception:
|
|
# As a special exception, the copyright holders of this library give you permission
|
|
# to link this library with independent modules to produce an executable, regardless
|
|
# of the license terms of these independent modules, and to copy and distribute the
|
|
# resulting executable under terms of your choice, provided that you also meet, for
|
|
# each linked independent module, the terms and conditions of the license of that module.
|
|
# - some files are licensed explicitly with BSD:
|
|
# + samples/cs/CreateZipFile/Main.cs
|
|
# + samples/cs/FastZip/Main.cs
|
|
# + samples/cs/minibzip2/Main.cs
|
|
# + samples/cs/minigzip/Main.cs
|
|
# + samples/cs/sz/sz.cs
|
|
# + samples/cs/tar/Main.cs
|
|
# + samples/cs/unzipfile/UnZipFile.cs
|
|
# + samples/cs/zipfiletest/ZipFileTest.cs
|
|
# + samples/vb/CreateZipFile/MainForm.vb
|
|
# + samples/vb/minibzip2/Main.vb
|
|
# + samples/vb/viewzipfile/Main.vb
|
|
# - samples/HttpCompressionModule is licensed as zlib/libpng (=zlib)
|
|
License: GPLv2+ with exceptions and BSD and zlib
|
|
URL: http://icsharpcode.github.io/%{libname}
|
|
Source0: https://github.com/icsharpcode/%{name}/archive/%{commit0}.tar.gz#/%{name}-%{commit0}.tar.gz
|
|
|
|
ExclusiveArch: %{mono_arches}
|
|
BuildRequires: nant
|
|
BuildRequires: mono-devel
|
|
BuildRequires: unrtf
|
|
# enforce nunit version cause of the versioned binary
|
|
BuildRequires: nunit2 = 2.6.4
|
|
|
|
# fix ownership of mono folders
|
|
Requires: mono-core
|
|
|
|
%description
|
|
SharpZipLib, formerly NZipLib is a Zip, GZip, Tar and BZip2 library
|
|
written entirely in C# . It is implemented as an assembly (installable
|
|
in the GAC), and thus can easily be incorporated into other projects.
|
|
|
|
%package devel
|
|
Summary: Development files for %{name}
|
|
Requires: %{name}%{?_isa} = %{version}-%{release}
|
|
|
|
%description devel
|
|
%{summary}.
|
|
|
|
%package doc
|
|
Summary: Documentation files for %{libname}
|
|
BuildArch: noarch
|
|
# need main package for samples and tests to work properly
|
|
Suggests: %{name}%{?_isa} = %{version}-%{release}
|
|
|
|
%description doc
|
|
Samples and %{summary}.
|
|
|
|
|
|
%prep
|
|
%setup -qn%{libname}-%{commit0}
|
|
# remove useless stuff
|
|
find samples -name Web\ References -print0 |xargs -0 rm -r
|
|
# W: wrong-file-end-of-line-encoding
|
|
#files=`find doc samples tests -regextype posix-extended -regex '.*(txt|build|csproj)'`
|
|
files=`find doc -name \*.txt ; find samples tests -exec file '{}' \; |grep text |sed -r 's,(.*):.*,\1,'`
|
|
sed -i 's,\r,,' $files
|
|
|
|
pushd tests
|
|
# tell where to find nunit
|
|
sed -i -e /ProgramFiles/d -e 's,${nunit.dir}/bin,%{_monodir}/nunit2,' tests.build
|
|
# disable sloppy tests (lazy or fail)
|
|
sed -i -r 's,.*Performance,[Category("Long Running")] \0,' BZip2/Bzip2Tests.cs
|
|
%if %{with brokentests}
|
|
%else
|
|
# FIXME https://github.com/icsharpcode/SharpZipLib/issues/90
|
|
sed -i -r 's,public void ZeroLengthInputStream\(,[Ignore("broken")] \0,' GZip/GZipTests.cs
|
|
sed -i -r 's,public void LongNames\(,[Ignore("broken")] \0,' Tar/TarTests.cs
|
|
sed -i -r 's,public void ReadingOfLockedDataFiles\(,[Ignore("broken")] \0,' Zip/ZipTests.cs
|
|
sed -i -r 's,public void BasicDirectories\(,[Ignore("broken")] \0,' Zip/ZipTests.cs
|
|
sed -i -r 's,public void BasicFiles\(,[Ignore("broken")] \0,' Zip/ZipTests.cs
|
|
sed -i -r 's,public void Replacement\(,[Ignore("broken")] \0,' Zip/ZipTests.cs
|
|
sed -i -r 's,public void ReplacementChecking\(,[Ignore("broken")] \0,' Zip/ZipTests.cs
|
|
sed -i -r 's,public void CreatedValues\(,[Ignore("broken")] \0,' Zip/ZipTests.cs
|
|
sed -i -r 's,public void FilenameCleaning\(,[Ignore("broken")] \0,' Zip/ZipTests.cs
|
|
%endif
|
|
|
|
|
|
%build
|
|
# FIXME adjust target when upstream moves to mono 4
|
|
nant -v+ build-mono-2.0
|
|
|
|
|
|
%install
|
|
mkdir -p %{buildroot}/%{_monogacdir} %{buildroot}/%{_libdir}/pkgconfig
|
|
gacutil -i bin/*.dll -f -package %{name} -root %{buildroot}/usr/lib
|
|
cp -p %{name}.pc %{buildroot}/%{_libdir}/pkgconfig
|
|
unrtf --text doc/ReadMe.rtf >doc/ReadMe.txt
|
|
|
|
|
|
%check
|
|
pushd tests
|
|
nant -v+ build
|
|
export TEMP=.
|
|
nunit-console26 -labels -exclude:"Long Running" \
|
|
%if %{without brokentests}
|
|
-stoponerror \
|
|
%endif
|
|
bin/debug/tests.dll
|
|
nant -v+ clean
|
|
rm -r bin
|
|
|
|
|
|
%files
|
|
%license doc/COPYING.txt
|
|
%doc README.md
|
|
# usage of wildcards cause of weird dll name
|
|
%{_monogacdir}/*%{libname}
|
|
%{_monodir}/%{name}/*%{libname}.dll
|
|
%dir %{_monodir}/%{name}
|
|
|
|
%files devel
|
|
%{_libdir}/pkgconfig/%{name}.pc
|
|
|
|
%files doc
|
|
%license doc/COPYING.txt
|
|
%doc doc/specification/
|
|
%doc doc/*.txt
|
|
%doc samples/ tests/
|
|
|
|
|
|
%changelog
|
|
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.86.0.518-7
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
|
|
|
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.86.0.518-6
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
|
|
|
|
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.86.0.518-5
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
|
|
|
|
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.86.0.518-4
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
|
|
|
* Thu Oct 13 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.86.0.518-3
|
|
- mono rebuild for aarch64 support
|
|
|
|
* Wed Aug 31 2016 Timotheus Pokorra <timotheus.pokorra@solidcharity.com> - 0.86.0.518-2
|
|
- build with nunit2
|
|
|
|
* Thu Apr 21 2016 Raphael Groner <projects.rg@smart.ms> - 0.86.0.518-1
|
|
- adjust version
|
|
|
|
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.86.0-0.6
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
|
|
|
* Thu Dec 17 2015 Raphael Groner <projects.rg@smart.ms> - 0.86.0-0.5
|
|
- split devel subpackage
|
|
|
|
* Fri Nov 13 2015 Raphael Groner <projects.rg@smart.ms> - 0.86.0-0.4
|
|
- improve licence breakdown
|
|
|
|
* Thu Nov 12 2015 Raphael Groner <projects.rg@smart.ms> - 0.86.0-0.3
|
|
- revert usage of gone nunit-runner
|
|
- fix folders ownership
|
|
|
|
* Mon Nov 09 2015 Raphael Groner <projects.rg@smart.ms> - 0.86.0-0.2
|
|
- improve License tag
|
|
- fix directory ownership
|
|
|
|
* Sun Nov 08 2015 Raphael Groner <projects.rg@smart.ms> - 0.86.0-0.1
|
|
- add Suggests to doc subpackage
|
|
- adjust Version tag
|
|
- shorten Summary text
|
|
- use nunit-runner cause now a separate package
|
|
|
|
* Thu Oct 08 2015 Raphael Groner <projects.rg@smart.ms> - 0.85.5-0.1
|
|
- initial
|