diff --git a/csmock.spec b/csmock.spec index 2ca1acb..7be0927 100644 --- a/csmock.spec +++ b/csmock.spec @@ -1,6 +1,6 @@ Name: csmock -Version: 1.5.1 -Release: 2%{?dist} +Version: 1.6.0 +Release: 1%{?dist} Summary: A mock wrapper for Static Analysis tools Group: Development/Tools @@ -8,6 +8,8 @@ License: GPLv3+ URL: https://git.fedorahosted.org/cgit/csmock.git Source0: https://git.fedorahosted.org/cgit/csmock.git/snapshot/csmock-%{version}.tar.xz +BuildRequires: GitPython +BuildRequires: cmake BuildRequires: help2man BuildRequires: python-devel %if !(0%{?fedora} >= 19 || 0%{?rhel} >= 7) @@ -23,6 +25,17 @@ BuildArch: noarch %description This is a metapackage pulling in csmock-common and basic csmock plug-ins. +%package -n csbuild +Summary: Tool for plugging static analyzers into the build process +Requires: GitPython +Requires: cscppc +Requires: csclng +Requires: csdiff +Requires: cswrap + +%description -n csbuild +Tool for plugging static analyzers into the build process, free of mock. + %package -n csmock-common Summary: Core of csmock (a mock wrapper for Static Analysis tools) Requires: csdiff @@ -71,60 +84,26 @@ This package contains the shellcheck plug-in for csmock. %setup -q %build -mkdir -p bin man - -# embed VERSION and PLUGIN_DIR version into the scripts -install -p -m0755 cov-{diff,mock}build bin/ -sed -e 's/rpm -qf .SELF/echo %{version}/' -i bin/cov-{diff,mock}build -sed -e 's/@VERSION@/%{name}-%{version}-%{release}/' \ - -e 's|@PLUGIN_DIR@|%{python2_sitelib}/csmock/plugins|' \ - -i py/csmock - -help2man --no-info --section 1 --name \ - "DEPRECATED - please use csmock instead!" \ - bin/cov-mockbuild > man/cov-mockbuild.1 - -help2man --no-info --section 1 --name \ - "DEPRECATED - please use 'csmock --diff-patches' instead!" \ - bin/cov-diffbuild > man/cov-diffbuild.1 - -help2man --no-info --section 1 --include doc/csmock.h2m \ - py/csmock > man/csmock.1 +mkdir csmock_build +cd csmock_build +%cmake '-DVERSION=%{name}-%{version}-%{release}' .. +make %{?_smp_mflags} VERBOSE=yes %install -install -m0755 -d \ - "$RPM_BUILD_ROOT%{_bindir}" \ - "$RPM_BUILD_ROOT%{_mandir}/man1" \ - "$RPM_BUILD_ROOT%{_datadir}/csmock" \ - "$RPM_BUILD_ROOT%{_datadir}/csmock/scripts" \ - "$RPM_BUILD_ROOT%{python2_sitelib}/" \ - "$RPM_BUILD_ROOT%{python2_sitelib}/csmock" \ - "$RPM_BUILD_ROOT%{python2_sitelib}/csmock/plugins" - -install -p -m0755 \ - cov-{diff,mock}build rpmbuild-rawbuild py/csmock \ - "$RPM_BUILD_ROOT%{_bindir}" - -install -p -m0644 man/{csmock,cov-{diff,mock}build}.1 "$RPM_BUILD_ROOT%{_mandir}/man1/" - -install -p -m0644 cwe-map.csv "$RPM_BUILD_ROOT%{_datadir}/csmock/" - -install -p -m0644 py/plugins/*.py \ - "$RPM_BUILD_ROOT%{python2_sitelib}/csmock/plugins" - -install -p -m0755 scripts/*.sh \ - "$RPM_BUILD_ROOT%{_datadir}/csmock/scripts" +cd csmock_build +make install DESTDIR="$RPM_BUILD_ROOT" # needed to create the csmock RPM %files +%files -n csbuild +%{_bindir}/csbuild +%{_mandir}/man1/csbuild.1* +%{_datadir}/csbuild/scripts/run-scan.sh +%doc COPYING + %files -n csmock-common -%{_bindir}/cov-diffbuild -%{_bindir}/cov-mockbuild %{_bindir}/csmock -%{_bindir}/rpmbuild-rawbuild -%{_mandir}/man1/cov-diffbuild.1* -%{_mandir}/man1/cov-mockbuild.1* %{_mandir}/man1/csmock.1* %{_datadir}/csmock/cwe-map.csv %{_datadir}/csmock/scripts/patch-rawbuild.sh @@ -146,6 +125,9 @@ install -p -m0755 scripts/*.sh \ %{python2_sitelib}/csmock/plugins/shellcheck* %changelog +* Wed Dec 17 2014 Kamil Dudka 1.6.0-1 +- update to latest upstream (introduces the csbuild subpackage) + * Thu Dec 11 2014 Michael Scherer 1.5.1-2 - fix the description of the csmock-plugin-shellcheck subpackage (#1173134) diff --git a/sources b/sources index fc98cb0..0366a92 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -2424459be48262530004e4defdb158c9 csmock-1.5.1.tar.xz +da4b817b5ff2bad184648bf46ae34c40 csmock-1.6.0.tar.xz