--- /dev/null
+--- sleuthkit-4.6.7/tsk/img/ewf.cpp~ 2020-05-01 04:05:39.000000000 +0200
++++ sleuthkit-4.6.7/tsk/img/ewf.cpp 2020-06-01 09:29:02.700329814 +0200
+@@ -67,8 +67,13 @@
+
+ tsk_take_lock(&(ewf_info->read_lock));
+ #if defined( HAVE_LIBEWF_V2_API )
++#if defined( HAVE_LIBEWF_HANDLE_READ_BUFFER_AT_OFFSET )
++ cnt = libewf_handle_read_buffer_at_offset(ewf_info->handle,
++ buf, len, offset, &ewf_error);
++#else
+ cnt = libewf_handle_read_random(ewf_info->handle,
+ buf, len, offset, &ewf_error);
++#endif
+ if (cnt < 0) {
+ char *errmsg = NULL;
+ tsk_error_reset();
+--- sleuthkit-4.6.7/configure.ac~ 2020-06-01 09:35:55.000000000 +0200
++++ sleuthkit-4.6.7/configure.ac 2020-06-01 09:38:05.671729514 +0200
+@@ -252,6 +250,7 @@
+ [AC_CHECK_HEADERS([libewf.h],
+ [AC_CHECK_LIB([ewf], [libewf_get_version], [], [NO_LIBEWF=true])]
+ )]
++ AC_CHECK_FUNCS([libewf_handle_read_buffer_at_offset libewf_handle_write_buffer_at_offset])
+ )
+ AS_IF([test "x$ac_cv_lib_ewf_libewf_get_version" = "xyes"], [ax_libewf=yes], [ax_libewf=no])
+
Summary: The Sleuth Kit - an forensic toolkit for analyzing file systems and disks
Summary(pl.UTF-8): The Sleuth Kit - zestaw narzędzi wspomagających analizę systemów plików
Name: sleuthkit
-Version: 4.6.7
+Version: 4.9.0
Release: 1
License: IBM Public License/Common Public License
Group: Applications
Source0: https://github.com/sleuthkit/sleuthkit/releases/download/%{name}-%{version}/%{name}-%{version}.tar.gz
-# Source0-md5: 173216be56d73c89a04631607068af80
+# Source0-md5: 01f04162de36cd23038a9d8f75b1c48a
+Patch0: libewf.patch
URL: http://www.sleuthkit.org/sleuthkit/
%{?with_aff:BuildRequires: afflib-devel}
#BuildRequires: autoconf
%prep
%setup -q
-sed -i -e 's/-static//' {samples,tests,tools/*tools}/Makefile.in
+%patch0 -p1
+
+%{__sed} -i -e 's/-static//' {samples,tests,tools/*tools}/Makefile.in
%build
+%{__aclocal}
+%{__autoconf}
+%{__autoheader}
+%{__automake}
%configure \
%{!?with_aff:--without-afflib}
-sed -i -e 's/^\(LIBS = -lewf\)/\1 -ldl -lpthread/' {tools/autotools,tsk}/Makefile
+%{__sed} -i -e 's/^\(LIBS = -lewf\)/\1 -ldl -lpthread/' {tools/autotools,tsk}/Makefile
+
%{__make}
%install
%defattr(644,root,root,755)
%attr(755,root,root) %{_libdir}/libtsk.so.*.*.*
%attr(755,root,root) %{_libdir}/libtsk_jni.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libtsk.so.13
+%attr(755,root,root) %ghost %{_libdir}/libtsk.so.19
%attr(755,root,root) %ghost %{_libdir}/libtsk_jni.so.0
%files devel