summaryrefslogtreecommitdiffstats
path: root/libraries/tlsh
diff options
context:
space:
mode:
author Matteo Bernardini <ponce@slackbuilds.org>2022-02-03 21:28:16 +0100
committer Willy Sudiarto Raharjo <willysr@slackbuilds.org>2022-02-04 17:53:42 +0700
commit1c12190b9d55f245eb8b287a057bddea0751ad85 (patch)
tree810e1bb38f275aab99e0dea115a3cf87c7aa967c /libraries/tlsh
parent091e57953d70bffa994f56f1080795f565f28101 (diff)
downloadslackbuilds-1c12190b9d55f245eb8b287a057bddea0751ad85.tar.gz
slackbuilds-1c12190b9d55f245eb8b287a057bddea0751ad85.tar.xz
libraries/tlsh: Updated for version 4.8.2.
Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'libraries/tlsh')
-rw-r--r--libraries/tlsh/README4
-rw-r--r--libraries/tlsh/install-libraries.patch23
-rw-r--r--libraries/tlsh/tlsh.SlackBuild17
-rw-r--r--libraries/tlsh/tlsh.info6
4 files changed, 12 insertions, 38 deletions
diff --git a/libraries/tlsh/README b/libraries/tlsh/README
index 57bee1f293..07a5364496 100644
--- a/libraries/tlsh/README
+++ b/libraries/tlsh/README
@@ -3,7 +3,3 @@ length of 256 bytes, TLSH generates a hash value which can be used for
similarity comparisons.
("TLSH" stands for Trend Micro Locality Sensitive Hash.)
-
-python3 is an optional dependency. You need to set PYTHON3=yes,
-for example:
- PYTHON3=yes ./python-libarchive-c.SlackBuild
diff --git a/libraries/tlsh/install-libraries.patch b/libraries/tlsh/install-libraries.patch
deleted file mode 100644
index 83f9c6cae5..0000000000
--- a/libraries/tlsh/install-libraries.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-From fb71fc45992a9adf73b3c8194bdd691391ca34d7 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Bobbio?= <lunar@debian.org>
-Date: Wed, 27 Jan 2016 17:44:06 +0100
-Subject: [PATCH] install the library in expected directories
-
-We add CMake install directives in order to see the library files installed in
-the expected multiarch compatible locations.
----
- src/CMakeLists.txt | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
-index b1c92fb..c8d3fd9 100644
---- a/src/CMakeLists.txt
-+++ b/src/CMakeLists.txt
-@@ -21,3 +21,7 @@ set_target_properties(tlsh_shared PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_SO
- set_target_properties(tlsh_shared PROPERTIES OUTPUT_NAME tlsh${BUILD_POSTFIX})
- set_target_properties(tlsh_shared PROPERTIES VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}"
- SOVERSION "0")
-+
-+include(GNUInstallDirs)
-+install(TARGETS tlsh_shared DESTINATION ${CMAKE_INSTALL_LIBDIR})
-+install(FILES ../include/tlsh.h DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
diff --git a/libraries/tlsh/tlsh.SlackBuild b/libraries/tlsh/tlsh.SlackBuild
index 3c5ccbbad9..ff1d5d968f 100644
--- a/libraries/tlsh/tlsh.SlackBuild
+++ b/libraries/tlsh/tlsh.SlackBuild
@@ -25,7 +25,7 @@
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=tlsh
-VERSION=${VERSION:-3.4.5}
+VERSION=${VERSION:-4.8.2}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
@@ -79,8 +79,10 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
-# From Arch Linux (thanks!), but tweaked to omit static lib
-patch -p1 < $CWD/install-libraries.patch
+sed '/set(CMAKE_EXE_LINKER_FLAGS/d' -i CMakeLists.txt
+sed '/set(CMAKE_CXX_FLAGS/d' -i CMakeLists.txt
+sed 's|TLSH_SHARED_LIBRARY 0|TLSH_SHARED_LIBRARY 1|' -i src/CMakeLists.txt
+sed "s|DESTINATION\ lib|DESTINATION lib$LIBDIRSUFFIX|" -i src/CMakeLists.txt
mkdir -p build
cd build
@@ -88,19 +90,18 @@ cd build
-DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
-DCMAKE_INSTALL_PREFIX=/usr \
- -DCMAKE_INSTALL_LIBDIR=/usr/lib${LIBDIRSUFFIX} \
-DCMAKE_BUILD_TYPE=Release ..
make
make install DESTDIR=$PKG
cd ..
-mkdir -p $PKG/usr/bin
-install -D -m755 bin/tlsh_unittest $PKG/usr/bin
-ln -s tlsh_unittest $PKG/usr/bin/tlsh
+#mkdir -p $PKG/usr/bin
+#install -D -m755 bin/tlsh_unittest $PKG/usr/bin
+#ln -s tlsh_unittest $PKG/usr/bin/tlsh
cd py_ext
python setup.py install --root=$PKG
- if [ "${PYTHON3:-no}" == "yes" ]; then
+ if [ "${PYTHON3:-yes}" == "yes" ]; then
rm -rf build
python3 setup.py install --root=$PKG
fi
diff --git a/libraries/tlsh/tlsh.info b/libraries/tlsh/tlsh.info
index fbc5fd9578..694e1d62fc 100644
--- a/libraries/tlsh/tlsh.info
+++ b/libraries/tlsh/tlsh.info
@@ -1,8 +1,8 @@
PRGNAM="tlsh"
-VERSION="3.4.5"
+VERSION="4.8.2"
HOMEPAGE="https://github.com/trendmicro/tlsh"
-DOWNLOAD="https://github.com/trendmicro/tlsh/archive/v3.4.5/tlsh-3.4.5.tar.gz"
-MD5SUM="9e23c525cf5a1b0b44d9c161b2a637f8"
+DOWNLOAD="https://github.com/trendmicro/tlsh/archive/4.8.2/tlsh-4.8.2.tar.gz"
+MD5SUM="27106dfc3f90954ba3831d357ed7335d"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES=""