Replace cmake commands with new cmake macros

Start using %cmake_build, %cmake_install and %ctest.
This commit is contained in:
Tulio Magno Quites Machado Filho 2020-07-09 21:40:18 -03:00 committed by Tulio Magno Quites Machado Filho
parent 306ed05227
commit 085886bf42

View File

@ -4,7 +4,7 @@
Name: zlib-ng Name: zlib-ng
Version: 1.9.9 Version: 1.9.9
Release: 0.1.%{commitdate}git%{shortcommit}%{?dist} Release: 0.2.%{commitdate}git%{shortcommit}%{?dist}
Summary: Zlib replacement with optimizations Summary: Zlib replacement with optimizations
License: zlib License: zlib
Url: https://github.com/zlib-ng/zlib-ng Url: https://github.com/zlib-ng/zlib-ng
@ -33,15 +33,16 @@ developing application that use %{name}.
%build %build
# zlib-ng uses a different macro for library directory. # zlib-ng uses a different macro for library directory.
%cmake . -DWITH_SANITIZERS=ON -DINSTALL_LIB_DIR=%{_libdir} %cmake -DWITH_SANITIZERS=ON -DINSTALL_LIB_DIR=%{_libdir}
%make_build %cmake_build
%check %check
# Tests fail when run in parallel. # Tests fail when run in parallel.
ctest -V %define _smp_mflags -j1
%ctest
%install %install
%make_install %cmake_install
%files %files
%{_libdir}/%{soname} %{_libdir}/%{soname}
@ -58,6 +59,9 @@ ctest -V
%{_mandir}/man3/%{name}.3.* %{_mandir}/man3/%{name}.3.*
%changelog %changelog
* Thu Jul 09 2020 Tulio Magno Quites Machado Filho <tuliom@ascii.art.br> - 1.9.9-0.2.20200609gitfe69810c2
- Replace cmake commands with new cmake macros
* Mon Jul 06 2020 Tulio Magno Quites Machado Filho <tuliom@ascii.art.br> - 1.9.9-0.1.20200609gitfe69810c2 * Mon Jul 06 2020 Tulio Magno Quites Machado Filho <tuliom@ascii.art.br> - 1.9.9-0.1.20200609gitfe69810c2
- Improve the archive name. - Improve the archive name.
- Starte release at 0.1 as required for prerelease. - Starte release at 0.1 as required for prerelease.