%define oname sysdig Name: %{oname} # versioning taken from https://github.com/draios/sysdig/releases Version: 0.8.0 Release: %mkrel 1 Summary: sysdig Group: Monitoring License: GPLv2 URL: http://www.sysdig.org Source0: https://github.com/draios/%{oname}/archive/%{version}.tar.gz # bundled dependency for base64 encoder/decoder Source1: http://download.draios.com/dependencies/libb64-1.2.src.zip BuildRequires: cmake >= 2.8 BuildRequires: pkgconfig(zlib) BuildConflicts: pkgconfig(lua) BuildRequires: pkgconfig(luajit) BuildRequires: jsoncpp-devel BuildRequires: pkgconfig(ncurses) BuildRequires: pkgconfig(libcurl) BuildRequires: pkgconfig(openssl) # the kernel module is only required for live tracing, not for analysing traces Recommends: dkms-%{oname} %description Sysdig is open source, system-level exploration: capture system state and activity from a running Linux instance, then save, filter and analyze. Think of it as strace + tcpdump + lsof + awesome sauce. With a little Lua cherry on top. Sysdig instruments your physical and virtual machines at the OS level by installing into the Linux kernel and capturing system calls and other OS events. Then, using sysdig's command line interface, you can filter and decode these events in order to extract useful information. Sysdig can be used to inspect systems live in real-time, or to generate trace files that can be analyzed at a later stage. %package -n dkms-%{oname} Summary: Kernel module required for live tracing, built via dkms Group: System/Kernel and hardware Provides: kmod(%{oname}.ko) = %{version} Requires(pre): dkms Requires(post): dkms BuildArch: noarch %description -n dkms-%{oname} Sysdig is open source, system-level exploration: capture system state and activity from a running Linux instance, then save, filter and analyze. Think of it as strace + tcpdump + lsof + awesome sauce. With a little Lua cherry on top. Sysdig instruments your physical and virtual machines at the OS level by installing into the Linux kernel and capturing system calls and other OS events. Then, using sysdig's command line interface, you can filter and decode these events in order to extract useful information. Sysdig can be used to inspect systems live in real-time, or to generate trace files that can be analyzed at a later stage. This package uses DKMS to automatically build the %{oname} kernel module. %prep %setup -qn %{oname}-%{version} install -D %{SOURCE1} build/b64-prefix/src/libb64-1.2.src.zip %build # disable driver build, handled in -dkms subpackage, also disable build of bundled libraries %cmake -DBUILD_DRIVER=OFF \ -DUSE_BUNDLED_B64=ON \ -DUSE_BUNDLED_CURL=OFF \ -DUSE_BUNDLED_DEPS=OFF \ -DUSE_BUNDLED_JSONCPP=OFF \ -DUSE_BUNDLED_LUAJIT=OFF \ -DUSE_BUNDLED_NCURSES=OFF \ -DUSE_BUNDLED_ZLIB=OFF \ -DUSE_BUNDLED_OPENSSL=OFF \ -DCMAKE_BUILD_TYPE=Release %make %install cd build %makeinstall_std mv %{buildroot}/usr/%{_sysconfdir} %{buildroot}/%{_sysconfdir} rm -rf %{buildroot}/usr/share/zsh/ ## below is the dkms module mv %{buildroot}/usr/src/sysdig* %{buildroot}/%{_usrsrc}/%{oname}-%{version}-%{release} %post -n dkms-%{oname} dkms add -m %{oname} -v %{version}-%{release} --rpm_safe_upgrade && dkms build -m %{oname} -v %{version}-%{release} --rpm_safe_upgrade && dkms install -m %{oname} -v %{version}-%{release} --rpm_safe_upgrade --force true /sbin/modprobe %{oname}-probe %preun -n dkms-%{oname} dkms remove --binary -m %{oname} -v %{version}-%{release} --rpm_safe_upgrade --all true /sbin/rmmod %{oname}-probe %files %{_bindir}/*%{oname}* %{_datadir}/%{oname} %{_mandir}/man8/*sysdig* %{_sysconfdir}/bash_completion.d/%{oname} %files -n dkms-%{oname} %{_usrsrc}/%{oname}-%{version}-%{release} %changelog * Sat Mar 12 2016 doktor5000 <doktor5000> 0.8.0-1.mga5 + Revision: 989571 - new version 0.8.0 o fixes build of sysdig-probe module with 4.4 kernels - disabled build of more bundled dependencies, use system ones o openssl o curl - prevent download of required dependency b64 - added BuildRequires on ncurses-devel - add BuildRequires on ncurses-devel - new version 0.2.0 o enables build against kernel > 3.19 (mga#16911) o new ncurses user interface csysdig (added in 0.1.101) o new script sysdig-probe-loader (added in 0.1.98) - disabled usage of bundled ncurses and use system ncurses * Wed Oct 15 2014 umeabot <umeabot> 0.1.89-3.mga5 + Revision: 747848 - Second Mageia 5 Mass Rebuild * Tue Oct 07 2014 doktor5000 <doktor5000> 0.1.89-2.mga5 + Revision: 737417 - added BuildRequires on pkgconfig(luajit) o added BuildConflicts on pkgconfig(lua) - removed useless Recommends on luajit binary * Tue Oct 07 2014 doktor5000 <doktor5000> 0.1.89-1.mga5 + Revision: 737365 - switch cmake build type to Release to try to fix build - new version 0.1.89 o added chisel shellshock_detect: detects shellshock injections o added chisel spy_file: Intercepts all reads and writes to all files - initially imported for Mageia