|
|
|
@ -16,7 +16,15 @@ Patch0: miniz-2.1.0-Examples-to-include-system-miniz.h.patch
|
|
|
|
|
BuildRequires: coreutils
|
|
|
|
|
# diffutils for cmp
|
|
|
|
|
BuildRequires: diffutils
|
|
|
|
|
%if "%{toolchain}" == "gcc"
|
|
|
|
|
BuildRequires: gcc
|
|
|
|
|
%else
|
|
|
|
|
%if "%{toolchain}" == "clang"
|
|
|
|
|
BuildRequires: clang
|
|
|
|
|
%else
|
|
|
|
|
%{error:Unknown toolchain.}
|
|
|
|
|
%endif
|
|
|
|
|
%endif
|
|
|
|
|
BuildRequires: sed
|
|
|
|
|
BuildRequires: unzip
|
|
|
|
|
|
|
|
|
@ -51,10 +59,12 @@ mv ChangeLog.md.new ChangeLog.md
|
|
|
|
|
%global soname lib%{name}.so.0.2
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
# Export CC environment variable
|
|
|
|
|
%{set_build_flags}
|
|
|
|
|
# Inject downstream SONAME, bug #1152653
|
|
|
|
|
%{__cc} %{optflags} -fPIC -DPIC -D_LARGEFILE64_SOURCE=1 -D_FILE_OFFSET_BITS=64 \
|
|
|
|
|
"$CC" %{optflags} -fPIC -DPIC -D_LARGEFILE64_SOURCE=1 -D_FILE_OFFSET_BITS=64 \
|
|
|
|
|
%{name}.c -c -o %{name}.o
|
|
|
|
|
%{__cc} %{?__global_ldflags} -fPIC -shared -Wl,-soname,%{soname} \
|
|
|
|
|
"$CC" %{?__global_ldflags} -fPIC -shared -Wl,-soname,%{soname} \
|
|
|
|
|
%{name}.o -o %{soname}
|
|
|
|
|
ln -s %{soname} lib%{name}.so
|
|
|
|
|
# Build examples against the library
|
|
|
|
@ -118,7 +128,7 @@ install -m 0644 %{name}.h '%{buildroot}/%{_includedir}'
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
|
* Mon Jan 25 2021 Tom Stellard <tstellar@redhat.com> - 2.1.0-6
|
|
|
|
|
- Use __cc macro instead of hard-coding gcc
|
|
|
|
|
- Use toolchain macro instead of hard-coding gcc
|
|
|
|
|
|
|
|
|
|
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.1.0-5
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
|
|
|
|