Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 15 Oct 2022 20:53:45 GMT
From:      MANTANI Nobutaka <nobutaka@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: e1d94b436d6a - main - editors/imhex: Update to 1.24.3
Message-ID:  <202210152053.29FKrjSn010649@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by nobutaka:

URL: https://cgit.FreeBSD.org/ports/commit/?id=e1d94b436d6a192d50d3dd44c5f1a71b0a55aebc

commit e1d94b436d6a192d50d3dd44c5f1a71b0a55aebc
Author:     MANTANI Nobutaka <nobutaka@FreeBSD.org>
AuthorDate: 2022-10-15 20:51:37 +0000
Commit:     MANTANI Nobutaka <nobutaka@FreeBSD.org>
CommitDate: 2022-10-15 20:53:22 +0000

    editors/imhex: Update to 1.24.3
---
 editors/imhex/Makefile                             |  20 ++--
 editors/imhex/distinfo                             |  32 +++---
 editors/imhex/files/patch-CMakeLists.txt           |   4 +-
 .../imhex/files/patch-cmake_build__helpers.cmake   |   4 +-
 ...lib_include_pl_core_ast_ast__node__bitfield.hpp |  11 --
 ...pattern__language_lib_include_pl_core_token.hpp |   4 +-
 .../imhex/files/patch-lib_libimhex_CMakeLists.txt  |   4 +-
 .../patch-lib_libimhex_include_hex_api_task.hpp    |  18 +++
 ...b_libimhex_include_hex_data__processor_node.hpp |   4 +-
 .../patch-lib_libimhex_source_api_imhex__api.cpp   |   4 +-
 .../patch-lib_libimhex_source_helpers_file.cpp     |  14 +--
 .../files/patch-lib_libimhex_source_helpers_fs.cpp |   4 +-
 ...ltin_source_content_helpers_math__evaluator.cpp |  15 +++
 ...tin_source_content_providers_disk__provider.cpp |  14 +--
 ...ns_builtin_source_content_settings__entries.cpp |   4 +-
 ...ins_builtin_source_content_views_view__find.cpp | 125 ++++++++++++++++++++-
 ...ltin_source_content_views_view__hex__editor.cpp |   4 +-
 ...ns_windows_include_views_view__tty__console.hpp |  10 ++
 editors/imhex/pkg-plist                            |   9 +-
 19 files changed, 232 insertions(+), 72 deletions(-)

diff --git a/editors/imhex/Makefile b/editors/imhex/Makefile
index 395c44c03bf3..41e96e621458 100644
--- a/editors/imhex/Makefile
+++ b/editors/imhex/Makefile
@@ -1,5 +1,5 @@
 PORTNAME=	imhex
-PORTVERSION=	1.23.1
+PORTVERSION=	1.24.3
 DISTVERSIONPREFIX=	v
 CATEGORIES=	editors
 MASTER_SITES=	https://git.sr.ht/~danyspin97/xdgpp/blob/f01f810714443d0f10c333d4d1d9c0383be41375/:xdg
@@ -20,6 +20,7 @@ EXTRACT_ONLY=	${DISTNAME}${EXTRACT_SUFX} \
 		capstone-engine-capstone-${GH_TAG_CAPSTONE}_GH0${EXTRACT_SUFX} \
 		CLIUtils-CLI11-${GH_TAG_CLI11}_GH0${EXTRACT_SUFX} \
 		fmtlib-fmt-${GH_TAG_FMT}_GH0${EXTRACT_SUFX} \
+		josuttis-jthread-${GH_TAG_JTHREAD}_GH0${EXTRACT_SUFX} \
 		VirusTotal-yara-${GH_TAG_YARA}_GH0${EXTRACT_SUFX} \
 		WerWolv-libromfs-${GH_TAG_LIBROMFS}_GH0${EXTRACT_SUFX} \
 		WerWolv-ImHex-Patterns-${GH_TAG_IMHEX_PATTERNS}_GH0${EXTRACT_SUFX} \
@@ -29,8 +30,8 @@ BUILD_DEPENDS=	glm>0:math/glm \
 		nlohmann-json>0:devel/nlohmann-json \
 		${LOCALBASE}/include/range/v3/range.hpp:devel/range-v3
 LIB_DEPENDS=	libcurl.so:ftp/curl \
-		libfreetype.so:print/freetype2 \
 		libglfw.so:graphics/glfw \
+		libfreetype.so:print/freetype2 \
 		libharfbuzz.so:print/harfbuzz \
 		libmbedtls.so:security/mbedtls \
 		libtre.so:textproc/libtre
@@ -47,6 +48,7 @@ GH_TUPLE=	btzy:nativefiledialog-extended:${GH_TAG_NATIVEFILEDIALOG}:nativefiledi
 		capstone-engine:capstone:${GH_TAG_CAPSTONE}:capstone \
 		CLIUtils:CLI11:${GH_TAG_CLI11}:cli11 \
 		fmtlib:fmt:${GH_TAG_FMT}:fmt \
+		josuttis:jthread:${GH_TAG_JTHREAD}:jthread \
 		VirusTotal:yara:${GH_TAG_YARA}:yara \
 		WerWolv:ImHex-Patterns:${GH_TAG_IMHEX_PATTERNS}:imhex_patterns \
 		WerWolv:PatternLanguage:${GH_TAG_PATTERN_LANGUAGE}:pattern_language \
@@ -54,12 +56,13 @@ GH_TUPLE=	btzy:nativefiledialog-extended:${GH_TAG_NATIVEFILEDIALOG}:nativefiledi
 
 GH_TAG_CAPSTONE=	d5141c0
 GH_TAG_CLI11=	faea921
-GH_TAG_FMT=	c4ee726
-GH_TAG_IMHEX_PATTERNS=	5481c2f
-GH_TAG_LIBROMFS=	8c8556d
-GH_TAG_NATIVEFILEDIALOG=	6967d28
-GH_TAG_PATTERN_LANGUAGE=	143628a
-GH_TAG_YARA=	d5a7565
+GH_TAG_FMT=	a337011
+GH_TAG_IMHEX_PATTERNS=	8e70a55
+GH_TAG_JTHREAD=	0fa8d39
+GH_TAG_LIBROMFS=	8efe4c4
+GH_TAG_NATIVEFILEDIALOG=	d4df2b6
+GH_TAG_PATTERN_LANGUAGE=	ab7d738
+GH_TAG_YARA=	ba94b4f
 
 CMAKE_ARGS=	-DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON \
 		-DIMHEX_STRIP_RELEASE=OFF -DIMHEX_PLUGINS_IN_SHARE=ON \
@@ -84,6 +87,7 @@ post-extract:
 	${CP} ${DISTDIR}/${DIST_SUBDIR}/xdg.hpp ${WRKSRC}/lib/external/xdgpp
 	${CP} -R ${WRKSRC_capstone}/* ${WRKSRC}/lib/external/capstone
 	${CP} -R ${WRKSRC_fmt}/* ${WRKSRC}/lib/external/fmt
+	${CP} -R ${WRKSRC_jthread}/source/*.hpp ${WRKSRC}/lib/libimhex/include
 	${CP} -R ${WRKSRC_libromfs}/* ${WRKSRC}/lib/external/libromfs
 	${CP} -R ${WRKSRC_nativefiledialog}/* ${WRKSRC}/lib/external/nativefiledialog
 	${CP} -R ${WRKSRC_pattern_language}/* ${WRKSRC}/lib/external/pattern_language
diff --git a/editors/imhex/distinfo b/editors/imhex/distinfo
index 7a9b808d2e73..58cfaee19cbf 100644
--- a/editors/imhex/distinfo
+++ b/editors/imhex/distinfo
@@ -1,21 +1,23 @@
-TIMESTAMP = 1663402501
+TIMESTAMP = 1665857378
 SHA256 (imhex/xdg.hpp) = 2e08ce74adb71ff9b9aa9e1c999733fccd4b00967b9cf0c0e51dbf049392a9ec
 SIZE (imhex/xdg.hpp) = 7674
-SHA256 (imhex/WerWolv-ImHex-v1.23.1_GH0.tar.gz) = 37bd49d0a8f9b7785106b15f829965affb6235199ea0763397af4fe97b3a1682
-SIZE (imhex/WerWolv-ImHex-v1.23.1_GH0.tar.gz) = 10927633
-SHA256 (imhex/btzy-nativefiledialog-extended-6967d28_GH0.tar.gz) = 67575871aca25f6b448831183851656d95cee5af773ac7b2a1f7f887f6d874d6
-SIZE (imhex/btzy-nativefiledialog-extended-6967d28_GH0.tar.gz) = 412145
+SHA256 (imhex/WerWolv-ImHex-v1.24.3_GH0.tar.gz) = 5d6780b2d4c3b92bbe7619dcae34138072a8ed9c540523d25760da237f01d279
+SIZE (imhex/WerWolv-ImHex-v1.24.3_GH0.tar.gz) = 11126282
+SHA256 (imhex/btzy-nativefiledialog-extended-d4df2b6_GH0.tar.gz) = a0440e52bd25b8f85cb25ef68fe19ca39b4b0fad39358d5a501b317cad9d0f69
+SIZE (imhex/btzy-nativefiledialog-extended-d4df2b6_GH0.tar.gz) = 412249
 SHA256 (imhex/capstone-engine-capstone-d5141c0_GH0.tar.gz) = 435d40757928fa73dec19c6d0fbf171bd76341391c8525ce1286927dab44c3e7
 SIZE (imhex/capstone-engine-capstone-d5141c0_GH0.tar.gz) = 5761632
 SHA256 (imhex/CLIUtils-CLI11-faea921_GH0.tar.gz) = 84773ee9577e6b719e5a84ad62cc381cf3027756690e1db839eaa50bcafc6c78
 SIZE (imhex/CLIUtils-CLI11-faea921_GH0.tar.gz) = 299718
-SHA256 (imhex/fmtlib-fmt-c4ee726_GH0.tar.gz) = 05ba66b0a9ed040e5cfb07e845a0aa61fdbbb9a0cbd22a1860a303e8cbf343e4
-SIZE (imhex/fmtlib-fmt-c4ee726_GH0.tar.gz) = 833672
-SHA256 (imhex/VirusTotal-yara-d5a7565_GH0.tar.gz) = 1c908b160f2432a25aefc1e94147949d24bcb79c1412a2be840f767531f3ff7e
-SIZE (imhex/VirusTotal-yara-d5a7565_GH0.tar.gz) = 1287317
-SHA256 (imhex/WerWolv-ImHex-Patterns-5481c2f_GH0.tar.gz) = cfa2c76fb0986e406a3541202df4b7e2e5b8cf6bcf5fb14d6605efb1ca32f6bc
-SIZE (imhex/WerWolv-ImHex-Patterns-5481c2f_GH0.tar.gz) = 5171762
-SHA256 (imhex/WerWolv-PatternLanguage-143628a_GH0.tar.gz) = 4d284923d1fec8bb942145365cd57e0b33e786c5db2cd7d3d133be417a516070
-SIZE (imhex/WerWolv-PatternLanguage-143628a_GH0.tar.gz) = 288257
-SHA256 (imhex/WerWolv-libromfs-8c8556d_GH0.tar.gz) = 46364edcf21a4cbe7c48094e755751aa03704a9c1efe3be5add5f52a15690474
-SIZE (imhex/WerWolv-libromfs-8c8556d_GH0.tar.gz) = 3868
+SHA256 (imhex/fmtlib-fmt-a337011_GH0.tar.gz) = ba190d69d8b7994ef2ceb533c56bc34feec296fef2f87efab4cfb981a04601cf
+SIZE (imhex/fmtlib-fmt-a337011_GH0.tar.gz) = 837936
+SHA256 (imhex/josuttis-jthread-0fa8d39_GH0.tar.gz) = ccd9c871dc2da9611e6d0cba5fc859cec9b233541be7501e5cef9eaa367e1280
+SIZE (imhex/josuttis-jthread-0fa8d39_GH0.tar.gz) = 4450456
+SHA256 (imhex/VirusTotal-yara-ba94b4f_GH0.tar.gz) = 4c81120bff451a55deaa23b48155d3eb35955ce11a1d76fbfcbbe2c2e33770b9
+SIZE (imhex/VirusTotal-yara-ba94b4f_GH0.tar.gz) = 1288534
+SHA256 (imhex/WerWolv-ImHex-Patterns-8e70a55_GH0.tar.gz) = 8d283e8806412d4083f9da9c7b1ff499bc7374394397bd7f270ba11277cd6df2
+SIZE (imhex/WerWolv-ImHex-Patterns-8e70a55_GH0.tar.gz) = 5176390
+SHA256 (imhex/WerWolv-PatternLanguage-ab7d738_GH0.tar.gz) = d7b5844a21622265a1ecd5184650177595cfa40a7bb17cb44f2104f29dc38ac5
+SIZE (imhex/WerWolv-PatternLanguage-ab7d738_GH0.tar.gz) = 415301
+SHA256 (imhex/WerWolv-libromfs-8efe4c4_GH0.tar.gz) = cc538b4add2a451c7c9be4237717b3231171cce56db51a956eaffd85d7f5af5b
+SIZE (imhex/WerWolv-libromfs-8efe4c4_GH0.tar.gz) = 4078
diff --git a/editors/imhex/files/patch-CMakeLists.txt b/editors/imhex/files/patch-CMakeLists.txt
index 9ad03de1dafd..290002b6d217 100644
--- a/editors/imhex/files/patch-CMakeLists.txt
+++ b/editors/imhex/files/patch-CMakeLists.txt
@@ -1,6 +1,6 @@
---- CMakeLists.txt.orig	2022-09-03 22:05:27 UTC
+--- CMakeLists.txt.orig	2022-10-08 08:03:47 UTC
 +++ CMakeLists.txt
-@@ -22,8 +22,6 @@ project(imhex VERSION ${IMHEX_VERSION})
+@@ -23,8 +23,6 @@ project(imhex VERSION ${IMHEX_VERSION})
  
  # Make sure project is configured correctly
  setDefaultBuiltTypeIfUnset()
diff --git a/editors/imhex/files/patch-cmake_build__helpers.cmake b/editors/imhex/files/patch-cmake_build__helpers.cmake
index 0ebdb118cf2a..818003a32010 100644
--- a/editors/imhex/files/patch-cmake_build__helpers.cmake
+++ b/editors/imhex/files/patch-cmake_build__helpers.cmake
@@ -1,4 +1,4 @@
---- cmake/build_helpers.cmake.orig	2022-09-15 12:40:14 UTC
+--- cmake/build_helpers.cmake.orig	2022-10-08 08:03:47 UTC
 +++ cmake/build_helpers.cmake
 @@ -383,24 +383,15 @@ function(downloadImHexPatternsFiles dest)
          else ()
@@ -31,7 +31,7 @@
  
  macro(setupCompilerWarnings target)
      set(IMHEX_COMMON_FLAGS "-Wall -Wextra -Werror")
--    set(IMHEX_C_FLAGS "${IMHEX_COMMON_FLAGS} -Wno-restrict -Wno-stringop-overread")
+-    set(IMHEX_C_FLAGS "${IMHEX_COMMON_FLAGS} -Wno-restrict -Wno-stringop-overread -Wno-stringop-overflow")
  
      set(CMAKE_C_FLAGS    "${CMAKE_C_FLAGS}    ${IMHEX_C_FLAGS}")
      set(CMAKE_CXX_FLAGS  "${CMAKE_CXX_FLAGS}  ${IMHEX_C_FLAGS}")
diff --git a/editors/imhex/files/patch-lib_external_pattern__language_lib_include_pl_core_ast_ast__node__bitfield.hpp b/editors/imhex/files/patch-lib_external_pattern__language_lib_include_pl_core_ast_ast__node__bitfield.hpp
deleted file mode 100644
index cc4198d9685b..000000000000
--- a/editors/imhex/files/patch-lib_external_pattern__language_lib_include_pl_core_ast_ast__node__bitfield.hpp
+++ /dev/null
@@ -1,11 +0,0 @@
---- lib/external/pattern_language/lib/include/pl/core/ast/ast_node_bitfield.hpp.orig	2022-08-18 14:31:33 UTC
-+++ lib/external/pattern_language/lib/include/pl/core/ast/ast_node_bitfield.hpp
-@@ -86,7 +86,6 @@ namespace pl::core::ast {
- 
-     private:
-         std::vector<std::unique_ptr<ASTNode>> m_entries;
--        mutable size_t m_bitOffset = 0x00;
-     };
- 
- }
-\ No newline at end of file
diff --git a/editors/imhex/files/patch-lib_external_pattern__language_lib_include_pl_core_token.hpp b/editors/imhex/files/patch-lib_external_pattern__language_lib_include_pl_core_token.hpp
index 674688dd1b86..6f6e219eae3d 100644
--- a/editors/imhex/files/patch-lib_external_pattern__language_lib_include_pl_core_token.hpp
+++ b/editors/imhex/files/patch-lib_external_pattern__language_lib_include_pl_core_token.hpp
@@ -1,4 +1,4 @@
---- lib/external/pattern_language/lib/include/pl/core/token.hpp.orig	2022-09-16 15:30:16 UTC
+--- lib/external/pattern_language/lib/include/pl/core/token.hpp.orig	2022-10-15 20:26:43 UTC
 +++ lib/external/pattern_language/lib/include/pl/core/token.hpp
 @@ -148,9 +148,9 @@ namespace pl::core {
  
@@ -12,7 +12,7 @@
          [[nodiscard]] constexpr static inline bool isInteger(const ValueType &type) {
              return isUnsigned(type) || isSigned(type);
          }
-@@ -194,133 +194,133 @@ namespace pl::core {
+@@ -206,133 +206,133 @@ namespace pl::core {
  
      namespace tkn {
  
diff --git a/editors/imhex/files/patch-lib_libimhex_CMakeLists.txt b/editors/imhex/files/patch-lib_libimhex_CMakeLists.txt
index cc5d449b4c4b..d91be6ec76a6 100644
--- a/editors/imhex/files/patch-lib_libimhex_CMakeLists.txt
+++ b/editors/imhex/files/patch-lib_libimhex_CMakeLists.txt
@@ -1,6 +1,6 @@
---- lib/libimhex/CMakeLists.txt.orig	2022-08-14 12:54:20 UTC
+--- lib/libimhex/CMakeLists.txt.orig	2022-10-08 08:03:47 UTC
 +++ lib/libimhex/CMakeLists.txt
-@@ -26,7 +26,6 @@ set(FPHSA_NAME_MISMATCHED ON CACHE BOOL "")
+@@ -27,7 +27,6 @@ set(FPHSA_NAME_MISMATCHED ON CACHE BOOL "")
  find_package(PkgConfig REQUIRED)
  
  if (NOT USE_SYSTEM_NFD)
diff --git a/editors/imhex/files/patch-lib_libimhex_include_hex_api_task.hpp b/editors/imhex/files/patch-lib_libimhex_include_hex_api_task.hpp
new file mode 100644
index 000000000000..d5fef1616abe
--- /dev/null
+++ b/editors/imhex/files/patch-lib_libimhex_include_hex_api_task.hpp
@@ -0,0 +1,18 @@
+--- lib/libimhex/include/hex/api/task.hpp.orig	2022-10-08 08:03:47 UTC
++++ lib/libimhex/include/hex/api/task.hpp
+@@ -1,6 +1,7 @@
+ #pragma once
+ 
+ #include <hex.hpp>
++#include <jthread.hpp>
+ 
+ #include <cstdio>
+ #include <thread>
+@@ -11,6 +12,7 @@
+ #include <memory>
+ #include <list>
+ #include <condition_variable>
++#include <vector>
+ 
+ namespace hex {
+ 
diff --git a/editors/imhex/files/patch-lib_libimhex_include_hex_data__processor_node.hpp b/editors/imhex/files/patch-lib_libimhex_include_hex_data__processor_node.hpp
index a42bdab95f2b..b0388d966bd2 100644
--- a/editors/imhex/files/patch-lib_libimhex_include_hex_data__processor_node.hpp
+++ b/editors/imhex/files/patch-lib_libimhex_include_hex_data__processor_node.hpp
@@ -1,6 +1,6 @@
---- lib/libimhex/include/hex/data_processor/node.hpp.orig	2022-08-14 15:02:06 UTC
+--- lib/libimhex/include/hex/data_processor/node.hpp.orig	2022-10-08 08:03:47 UTC
 +++ lib/libimhex/include/hex/data_processor/node.hpp
-@@ -45,6 +45,7 @@ namespace hex::dp {
+@@ -46,6 +46,7 @@ namespace hex::dp {
          struct NodeError {
              Node *node;
              std::string message;
diff --git a/editors/imhex/files/patch-lib_libimhex_source_api_imhex__api.cpp b/editors/imhex/files/patch-lib_libimhex_source_api_imhex__api.cpp
index a38d2f10790f..24945986719f 100644
--- a/editors/imhex/files/patch-lib_libimhex_source_api_imhex__api.cpp
+++ b/editors/imhex/files/patch-lib_libimhex_source_api_imhex__api.cpp
@@ -1,4 +1,4 @@
---- lib/libimhex/source/api/imhex_api.cpp.orig	2022-08-17 21:25:52 UTC
+--- lib/libimhex/source/api/imhex_api.cpp.orig	2022-10-08 08:03:47 UTC
 +++ lib/libimhex/source/api/imhex_api.cpp
 @@ -4,6 +4,7 @@
  #include <hex/api/event.hpp>
@@ -8,7 +8,7 @@
  #include <utility>
  #include <unistd.h>
  
-@@ -260,7 +261,7 @@ namespace hex {
+@@ -266,7 +267,7 @@ namespace hex {
          }
  
          bool isDirty() {
diff --git a/editors/imhex/files/patch-lib_libimhex_source_helpers_file.cpp b/editors/imhex/files/patch-lib_libimhex_source_helpers_file.cpp
index f0d74435b58e..c3e38e800446 100644
--- a/editors/imhex/files/patch-lib_libimhex_source_helpers_file.cpp
+++ b/editors/imhex/files/patch-lib_libimhex_source_helpers_file.cpp
@@ -1,18 +1,18 @@
---- lib/libimhex/source/helpers/file.cpp.orig	2022-08-17 21:25:52 UTC
+--- lib/libimhex/source/helpers/file.cpp.orig	2022-10-08 08:03:47 UTC
 +++ lib/libimhex/source/helpers/file.cpp
 @@ -17,12 +17,12 @@ namespace hex::fs {
                  this->m_file = _wfopen(path.c_str(), L"w+b");
          #else
              if (mode == File::Mode::Read)
--                this->m_file = fopen64(path.string().c_str(), "rb");
-+                this->m_file = fopen(path.string().c_str(), "rb");
+-                this->m_file = fopen64(hex::toUTF8String(path).c_str(), "rb");
++                this->m_file = fopen(hex::toUTF8String(path).c_str(), "rb");
              else if (mode == File::Mode::Write)
--                this->m_file = fopen64(path.string().c_str(), "r+b");
-+                this->m_file = fopen(path.string().c_str(), "r+b");
+-                this->m_file = fopen64(hex::toUTF8String(path).c_str(), "r+b");
++                this->m_file = fopen(hex::toUTF8String(path).c_str(), "r+b");
  
              if (mode == File::Mode::Create || (mode == File::Mode::Write && this->m_file == nullptr))
--                this->m_file = fopen64(path.string().c_str(), "w+b");
-+                this->m_file = fopen(path.string().c_str(), "w+b");
+-                this->m_file = fopen64(hex::toUTF8String(path).c_str(), "w+b");
++                this->m_file = fopen(hex::toUTF8String(path).c_str(), "w+b");
          #endif
      }
  
diff --git a/editors/imhex/files/patch-lib_libimhex_source_helpers_fs.cpp b/editors/imhex/files/patch-lib_libimhex_source_helpers_fs.cpp
index 9a0b4d5bab60..a36b83e2d2ff 100644
--- a/editors/imhex/files/patch-lib_libimhex_source_helpers_fs.cpp
+++ b/editors/imhex/files/patch-lib_libimhex_source_helpers_fs.cpp
@@ -1,4 +1,4 @@
---- lib/libimhex/source/helpers/fs.cpp.orig	2022-08-05 10:52:34 UTC
+--- lib/libimhex/source/helpers/fs.cpp.orig	2022-10-08 08:03:47 UTC
 +++ lib/libimhex/source/helpers/fs.cpp
 @@ -14,10 +14,15 @@
      #include <shlobj.h>
@@ -16,7 +16,7 @@
  #include <filesystem>
  
  namespace hex::fs {
-@@ -179,7 +184,7 @@ namespace hex::fs {
+@@ -189,7 +194,7 @@ namespace hex::fs {
          #endif
      }
  
diff --git a/editors/imhex/files/patch-plugins_builtin_source_content_helpers_math__evaluator.cpp b/editors/imhex/files/patch-plugins_builtin_source_content_helpers_math__evaluator.cpp
new file mode 100644
index 000000000000..44d28a094316
--- /dev/null
+++ b/editors/imhex/files/patch-plugins_builtin_source_content_helpers_math__evaluator.cpp
@@ -0,0 +1,15 @@
+--- plugins/builtin/source/content/helpers/math_evaluator.cpp.orig	2022-10-12 10:48:50 UTC
++++ plugins/builtin/source/content/helpers/math_evaluator.cpp
+@@ -434,9 +434,9 @@ namespace hex {
+     template<typename T>
+     void MathEvaluator<T>::registerStandardVariables() {
+         this->setVariable("ans", 0);
+-        this->setVariable("pi", std::numbers::pi, true);
+-        this->setVariable("e", std::numbers::e, true);
+-        this->setVariable("phi", std::numbers::phi, true);
++        this->setVariable("pi", 3.141592653589793238462643383279502884L, true);
++        this->setVariable("e", 2.718281828459045235360287471352662498L, true);
++        this->setVariable("phi", 1.618033988749894848204586834365638117L, true);
+     }
+ 
+     template<typename T>
diff --git a/editors/imhex/files/patch-plugins_builtin_source_content_providers_disk__provider.cpp b/editors/imhex/files/patch-plugins_builtin_source_content_providers_disk__provider.cpp
index 2269f67780d5..6f842aea0d2a 100644
--- a/editors/imhex/files/patch-plugins_builtin_source_content_providers_disk__provider.cpp
+++ b/editors/imhex/files/patch-plugins_builtin_source_content_providers_disk__provider.cpp
@@ -1,13 +1,11 @@
---- plugins/builtin/source/content/providers/disk_provider.cpp.orig	2022-08-14 12:54:20 UTC
+--- plugins/builtin/source/content/providers/disk_provider.cpp.orig	2022-10-08 08:03:47 UTC
 +++ plugins/builtin/source/content/providers/disk_provider.cpp
-@@ -18,8 +18,9 @@
-     #include <sys/stat.h>
+@@ -20,7 +20,7 @@
      #include <sys/types.h>
+ #endif
  
-+# if !defined(__FreeBSD__)
+-#if defined(OS_LINUX)
++#if !defined(__FreeBSD__)
      #define lseek lseek64
--
-+# endif
- #elif defined(OS_MACOS)
+ #endif
  
-     #include <fcntl.h>
diff --git a/editors/imhex/files/patch-plugins_builtin_source_content_settings__entries.cpp b/editors/imhex/files/patch-plugins_builtin_source_content_settings__entries.cpp
index 75bacccf8a5e..2df3722bff2f 100644
--- a/editors/imhex/files/patch-plugins_builtin_source_content_settings__entries.cpp
+++ b/editors/imhex/files/patch-plugins_builtin_source_content_settings__entries.cpp
@@ -1,6 +1,6 @@
---- plugins/builtin/source/content/settings_entries.cpp.orig	2022-07-16 11:41:37 UTC
+--- plugins/builtin/source/content/settings_entries.cpp.orig	2022-10-08 08:03:47 UTC
 +++ plugins/builtin/source/content/settings_entries.cpp
-@@ -19,8 +19,7 @@ namespace {
+@@ -21,8 +21,7 @@ namespace {
          userFolders.clear();
          std::vector<std::string> paths = setting;
          for (const auto &path : paths) {
diff --git a/editors/imhex/files/patch-plugins_builtin_source_content_views_view__find.cpp b/editors/imhex/files/patch-plugins_builtin_source_content_views_view__find.cpp
index 1bdd6465fdb3..a3f5987cf764 100644
--- a/editors/imhex/files/patch-plugins_builtin_source_content_views_view__find.cpp
+++ b/editors/imhex/files/patch-plugins_builtin_source_content_views_view__find.cpp
@@ -1,11 +1,128 @@
---- plugins/builtin/source/content/views/view_find.cpp.orig	2022-09-15 12:40:14 UTC
+--- plugins/builtin/source/content/views/view_find.cpp.orig	2022-10-08 08:03:47 UTC
 +++ plugins/builtin/source/content/views/view_find.cpp
-@@ -239,7 +239,7 @@ namespace hex::plugin::builtin {
+@@ -153,34 +153,87 @@ namespace hex::plugin::builtin {
+     }
+ 
+     template<typename Type, typename StorageType>
+-    static std::tuple<bool, std::variant<u64, i64, float, double>, size_t> parseNumericValue(const std::string &string) {
++    static std::tuple<bool, u64, size_t> parseNumericValue_u(const std::string &string) {
+         static_assert(sizeof(StorageType) >= sizeof(Type));
+ 
+         StorageType value = 0x00;
+-        auto result = std::from_chars(string.data(), string.data() + string.size(), value);
+-        if (result.ec != std::errc() || result.ptr != string.data() + string.size())
++        try {
++            value = std::stoull(string.data());
++        } catch (...) {
+             return { false, { }, 0 };
++        }
+ 
+-        if (value < std::numeric_limits<Type>::min() || value > std::numeric_limits<Type>::max())
++        if (value < std::numeric_limits<Type>::lowest() || value > std::numeric_limits<Type>::max())
+             return { false, { }, 0 };
+ 
+         return { true, value, sizeof(Type) };
+     }
+ 
++    template<typename Type, typename StorageType>
++    static std::tuple<bool, i64, size_t> parseNumericValue_i(const std::string &string) {
++        static_assert(sizeof(StorageType) >= sizeof(Type));
++
++        StorageType value = 0x00;
++        try {
++            value = std::stoll(string.data());
++        } catch (...) {
++            return { false, { }, 0 };
++        }
++
++        if (value < std::numeric_limits<Type>::lowest() || value > std::numeric_limits<Type>::max())
++            return { false, { }, 0 };
++
++        return { true, value, sizeof(Type) };
++    }
++
++    template<typename Type, typename StorageType>
++    static std::tuple<bool, float, size_t> parseNumericValue_f(const std::string &string) {
++        static_assert(sizeof(StorageType) >= sizeof(Type));
++
++        StorageType value = 0x00;
++        try {
++            value = std::stof(string.data());
++        } catch (...) {
++            return { false, { }, 0 };
++        }
++
++        if (value < std::numeric_limits<Type>::lowest() || value > std::numeric_limits<Type>::max())
++            return { false, { }, 0 };
++
++        return { true, value, sizeof(float) };
++    }
++
++    template<typename Type, typename StorageType>
++    static std::tuple<bool, double, size_t> parseNumericValue_d(const std::string &string) {
++        static_assert(sizeof(StorageType) >= sizeof(Type));
++
++        StorageType value = 0x00;
++        try {
++            value = std::stod(string.data());
++        } catch (...) {
++            return { false, { }, 0 };
++        }
++
++        if (value < std::numeric_limits<Type>::lowest() || value > std::numeric_limits<Type>::max())
++            return { false, { }, 0 };
++
++        return { true, value, sizeof(Type) };
++    }
++
+     std::tuple<bool, std::variant<u64, i64, float, double>, size_t> ViewFind::parseNumericValueInput(const std::string &input, SearchSettings::Value::Type type) {
+         switch (type) {
+             using enum SearchSettings::Value::Type;
+ 
+-            case U8:    return parseNumericValue<u8,  u64>(input);
+-            case U16:   return parseNumericValue<u16, u64>(input);
+-            case U32:   return parseNumericValue<u32, u64>(input);
+-            case U64:   return parseNumericValue<u64, u64>(input);
+-            case I8:    return parseNumericValue<i8,  i64>(input);
+-            case I16:   return parseNumericValue<i16, i64>(input);
+-            case I32:   return parseNumericValue<i32, i64>(input);
+-            case I64:   return parseNumericValue<i64, i64>(input);
+-            case F32:   return parseNumericValue<float, float>(input);
+-            case F64:   return parseNumericValue<double, double>(input);
++            case U8:    return parseNumericValue_u<u8,  u64>(input);
++            case U16:   return parseNumericValue_u<u16, u64>(input);
++            case U32:   return parseNumericValue_u<u32, u64>(input);
++            case U64:   return parseNumericValue_u<u64, u64>(input);
++            case I8:    return parseNumericValue_i<i8,  i64>(input);
++            case I16:   return parseNumericValue_i<i16, i64>(input);
++            case I32:   return parseNumericValue_i<i32, i64>(input);
++            case I64:   return parseNumericValue_i<i64, i64>(input);
++            case F32:   return parseNumericValue_f<float, float>(input);
++            case F64:   return parseNumericValue_d<double, double>(input);
+             default:    return { false, { }, 0 };
+         }
+     }
+@@ -293,7 +346,7 @@ namespace hex::plugin::builtin {
  
          auto occurrence = reader.begin();
          while (true) {
--            occurrence = std::search(reader.begin(), reader.end(), std::boyer_moore_horspool_searcher(sequence.begin(), sequence.end()));
-+            occurrence = std::search(reader.begin(), reader.end(), sequence.begin(), sequence.end());
+-            occurrence = std::search(reader.begin(), reader.end(), std::boyer_moore_horspool_searcher(bytes.begin(), bytes.end()));
++            occurrence = std::search(reader.begin(), reader.end(), bytes.begin(), bytes.end());
              if (occurrence == reader.end())
                  break;
  
+@@ -377,8 +430,12 @@ namespace hex::plugin::builtin {
+         reader.seek(searchRegion.getStartAddress());
+         reader.setEndAddress(searchRegion.getEndAddress());
+ 
+-        const auto [validMin, min, sizeMin] = parseNumericValueInput(settings.inputMin, settings.type);
+-        const auto [validMax, max, sizeMax] = parseNumericValueInput(settings.inputMax, settings.type);
++        const auto validMin = std::get<0>(parseNumericValueInput(settings.inputMin, settings.type));
++        const auto min = std::get<1>(parseNumericValueInput(settings.inputMin, settings.type));
++        const auto sizeMin = std::get<2>(parseNumericValueInput(settings.inputMin, settings.type));
++        const auto validMax = std::get<0>(parseNumericValueInput(settings.inputMax, settings.type));
++        const auto max = std::get<1>(parseNumericValueInput(settings.inputMax, settings.type));
++        const auto sizeMax = std::get<2>(parseNumericValueInput(settings.inputMax, settings.type));
+ 
+         if (!validMin || !validMax || sizeMin != sizeMax)
+             return { };
diff --git a/editors/imhex/files/patch-plugins_builtin_source_content_views_view__hex__editor.cpp b/editors/imhex/files/patch-plugins_builtin_source_content_views_view__hex__editor.cpp
index 46ef7fe6c59b..bea962f71143 100644
--- a/editors/imhex/files/patch-plugins_builtin_source_content_views_view__hex__editor.cpp
+++ b/editors/imhex/files/patch-plugins_builtin_source_content_views_view__hex__editor.cpp
@@ -1,6 +1,6 @@
---- plugins/builtin/source/content/views/view_hex_editor.cpp.orig	2022-09-03 22:05:27 UTC
+--- plugins/builtin/source/content/views/view_hex_editor.cpp.orig	2022-10-12 10:48:50 UTC
 +++ plugins/builtin/source/content/views/view_hex_editor.cpp
-@@ -288,7 +288,7 @@ namespace hex::plugin::builtin {
+@@ -290,7 +290,7 @@ namespace hex::plugin::builtin {
              reader.seek(this->m_searchPosition.value_or(0x00));
  
              constexpr static auto searchFunction = [](const auto &haystackBegin, const auto &haystackEnd, const auto &needleBegin, const auto &needleEnd) {
diff --git a/editors/imhex/files/patch-plugins_windows_include_views_view__tty__console.hpp b/editors/imhex/files/patch-plugins_windows_include_views_view__tty__console.hpp
new file mode 100644
index 000000000000..8044d81e7896
--- /dev/null
+++ b/editors/imhex/files/patch-plugins_windows_include_views_view__tty__console.hpp
@@ -0,0 +1,10 @@
+--- plugins/windows/include/views/view_tty_console.hpp.orig	2022-10-15 14:50:11 UTC
++++ plugins/windows/include/views/view_tty_console.hpp
+@@ -1,6 +1,7 @@
+ #pragma once
+ 
+ #include <hex/ui/view.hpp>
++#include <jthread.hpp>
+ 
+ #include <windows.h>
+ 
diff --git a/editors/imhex/pkg-plist b/editors/imhex/pkg-plist
index f5a17e71071f..bcd5457bc959 100644
--- a/editors/imhex/pkg-plist
+++ b/editors/imhex/pkg-plist
@@ -1,5 +1,5 @@
 bin/imhex
-lib/libimhex.so.1.23.1
+lib/libimhex.so.1.24.3
 share/applications/imhex.desktop
 %%DATADIR%%/constants/_schema.json
 %%DATADIR%%/constants/crc16.json
@@ -7,17 +7,24 @@ share/applications/imhex.desktop
 %%DATADIR%%/constants/http_status.json
 %%DATADIR%%/constants/linux_errors.json
 %%DATADIR%%/includes/hex/core.pat
+%%DATADIR%%/includes/hex/dec.pat
 %%DATADIR%%/includes/hex/http.pat
 %%DATADIR%%/includes/hex/impl/imhex_check.pat
+%%DATADIR%%/includes/hex/type/mangled.pat
+%%DATADIR%%/includes/std/array.pat
 %%DATADIR%%/includes/type/types/010.pat
 %%DATADIR%%/includes/type/types/c.pat
 %%DATADIR%%/includes/type/types/linux.pat
 %%DATADIR%%/includes/type/types/rust.pat
 %%DATADIR%%/includes/type/types/win32.pat
+%%DATADIR%%/includes/type/base.pat
+%%DATADIR%%/includes/type/color.pat
 %%DATADIR%%/patterns/bson.hexpat
 %%DATADIR%%/patterns/flac.hexpat
+%%DATADIR%%/patterns/id3.hexpat
 %%DATADIR%%/patterns/minidump.hexpat
 %%DATADIR%%/patterns/msgpack.hexpat
+%%DATADIR%%/patterns/usb.hexpat
 %%DATADIR%%/patterns/xilinx_bit.hexpat
 %%DATADIR%%/encodings/arabic_iso.tbl
 %%DATADIR%%/encodings/arabic_windows.tbl



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202210152053.29FKrjSn010649>