# Could be part of http://fedoraproject.org/wiki/LukeMacken/SecurityLiveCD
Name: sleuthkit
Version: 3.0.1
Release: 2%{?dist}
Summary: The Sleuth Kit (TSK)
Group: Applications/System
License: CPL and IBM and GPLv2+
URL: http://www.sleuthkit.org
Source0: http://downloads.sourceforge.net/sleuthkit/sleuthkit-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
#BuildRequires: libtool
# afflib - BSD with advertising, GPL incompatible
BuildRequires: afflib-devel >= 3.3.4
# libewf - Newer versions are plain BSD (older are BSD with advertising)
BuildRequires: libewf-devel
Requires: %{name}-libs = %{version}-%{release}
Requires: file
Requires: mac-robber
%description
The Sleuth Kit (TSK) is a collection of UNIX-based command line tools that
allow you to investigate a computer. The current focus of the tools is the
file and volume systems and TSK supports FAT, Ext2/3, NTFS, UFS,
and ISO 9660 file systems
%package libs
Summary: Library for %{name}
Group: System Environment/Libraries
%description libs
The %{name}-libs package contains library for %{name}.
%package devel
Summary: Development files for %{name}
Group: Development/Libraries
Requires: %{name}-libs = %{version}-%{release}
%description devel
The %{name}-devel package contains libraries and header files for
developing applications that use %{name}.
%prep
%setup -q -n %{name}-%{version}
# re-run autotools
%if 0
libtoolize --force
aclocal
autoheader
autoconf
automake
%endif
%build
%configure --disable-static
# remove rpath from libtool
sed -i.rpath 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
sed -i.rpath 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
# clean unused-direct-shlib-dependencies
#sed -i -e 's! -shared ! -Wl,--as-needed\0!g' libtool
make %{?_smp_mflags}
%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p"
find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'
%clean
rm -rf $RPM_BUILD_ROOT
%post libs -p /sbin/ldconfig
%postun libs -p /sbin/ldconfig
%files
%defattr(-,root,root,-)
%doc CHANGES.txt README.txt licenses/*
%doc docs/other.txt docs/skins*.txt docs/ref*.txt
# License is CPL 1.0 exept for some files.
%{_bindir}/blkcalc
%{_bindir}/blkcat
%{_bindir}/blkls
%{_bindir}/blkstat
%{_bindir}/disk_sreset
%{_bindir}/disk_stat
%{_bindir}/ffind
%{_bindir}/fls
%{_bindir}/fsstat
%{_bindir}/hfind
%{_bindir}/icat
%{_bindir}/ifind
%{_bindir}/ils
%{_bindir}/img_cat
%{_bindir}/img_stat
%{_bindir}/istat
%{_bindir}/jcat
%{_bindir}/jls
# This file is described as GPL in the doc
# But the license remains CPL in the source.
%{_bindir}/mactime
##
%{_bindir}/mmcat
%{_bindir}/mmls
%{_bindir}/mmstat
%{_bindir}/sigfind
%{_bindir}/sorter
## This file is GPLv2+
%{_bindir}/srch_strings
#
%{_mandir}/man1/blkcalc.1*
%{_mandir}/man1/blkcat.1*
%{_mandir}/man1/blkls.1*
%{_mandir}/man1/blkstat.1*
%{_mandir}/man1/disk_sreset.1*
%{_mandir}/man1/disk_stat.1*
%{_mandir}/man1/ffind.1*
%{_mandir}/man1/fls.1*
%{_mandir}/man1/fsstat.1*
%{_mandir}/man1/hfind.1*
%{_mandir}/man1/icat.1*
%{_mandir}/man1/ifind.1*
%{_mandir}/man1/ils.1*
%{_mandir}/man1/img_cat.1*
%{_mandir}/man1/img_stat.1*
%{_mandir}/man1/istat.1*
%{_mandir}/man1/jcat.1*
%{_mandir}/man1/jls.1*
%{_mandir}/man1/mactime.1*
%{_mandir}/man1/mmcat.1*
%{_mandir}/man1/mmls.1*
%{_mandir}/man1/mmstat.1*
%{_mandir}/man1/sigfind.1*
%{_mandir}/man1/sorter.1*
%dir %{_datadir}/tsk3
%{_datadir}/tsk3/sorter/
%files libs
%defattr(-,root,root,-)
# CPL and IBM
%{_libdir}/*.so.*
%files devel
%defattr(-,root,root,-)
%doc docs/library-api.txt
# CPL and IBM
%{_includedir}/tsk3/
%{_libdir}/*.so
%changelog
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
* Tue Feb 10 2009 kwizart < kwizart at gmail.com > - 3.0.1-1
- Update to 3.0.1 (final)
* Tue Oct 28 2008 kwizart < kwizart at gmail.com > - 3.0.0-1
- Update to 3.0.0 (final)
* Fri Oct 3 2008 kwizart < kwizart at gmail.com > - 3.0.0-0.1.b4
- Update to 3.0.0b4
* Tue Jun 17 2008 kwizart < kwizart at gmail.com > - 2.52-1
- Update to 2.52
- Remove merged patches
- Remove clean unused-direct-shlib-dependencies
- Fix rpath at source.
- Sort license within the spec
- Move configure.ac to pkg-config detection
- Remove Perl-Date-Manip installation
* Tue Mar 18 2008 kwizart < kwizart at gmail.com > - 2.51-1
- Update to 2.51
- Add libewf/afflib BR
- Requires mac-robber external package.
- Remove internal perl-Date-Manip.
* Fri Dec 28 2007 kwizart < kwizart at gmail.com > - 2.10-1
- Update to 2.10
* Mon Oct 29 2007 kwizart < kwizart at gmail.com > - 2.09-1
- Initial package for Fedora
(inspired from Oden Eriksson mdk spec).