diff options
author | iTrooz | 2023-04-25 22:29:29 +0200 |
---|---|---|
committer | iTrooz | 2023-04-25 22:35:11 +0200 |
commit | db7f9575bfe32bda011ee7a0fdce434dc00b4148 (patch) | |
tree | a8eb2f88e2e6ab97a0534d38b25426d8bc645e42 | |
parent | d4b3039170cb9958af0c1020f060486681d4fef5 (diff) | |
download | aur-db7f9575bfe32bda011ee7a0fdce434dc00b4148.tar.gz |
updated build files
removed pl-0002 patch because it wasn't appling, and I'm just here to copy the files from the `imhex` package. Plz apply for maintainer.
-rw-r--r-- | .SRCINFO | 24 | ||||
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | 0001-makepkg-Fix-compiler-check.patch | 29 | ||||
-rw-r--r-- | 0002-fix-Deduplicate-resources-directories.patch | 64 | ||||
-rw-r--r-- | PKGBUILD | 36 | ||||
-rw-r--r-- | pl-0001-Use-C-23-standard.patch | 18 | ||||
-rw-r--r-- | pl-0002-makepkg-Remove-extraneous-compiler-flags.patch | 25 |
7 files changed, 51 insertions, 146 deletions
@@ -1,6 +1,6 @@ pkgbase = imhex-git pkgdesc = A Hex Editor for Reverse Engineers, Programmers and people that value their eye sight when working at 3 AM - pkgver = 1.25.0.r1.g91a4f52f + pkgver = 1.28.0.r73.gb0028b0e pkgrel = 1 url = https://imhex.werwolv.net arch = x86_64 @@ -23,38 +23,36 @@ pkgbase = imhex-git depends = fmt depends = yara optdepends = imhex-patterns-git: ImHex base patterns + provides = imhex + conflicts = imhex options = !lto options = !strip - source = imhex::git+https://github.com/WerWolv/ImHex.git + source = imhex-git::git+https://github.com/WerWolv/ImHex.git source = nativefiledialog::git+https://github.com/btzy/nativefiledialog-extended.git source = xdgpp::git+https://git.sr.ht/~danyspin97/xdgpp source = libromfs::git+https://github.com/WerWolv/libromfs source = capstone::git+https://github.com/capstone-engine/capstone#branch=next + source = libwolv::git+https://github.com/WerWolv/libwolv source = pattern_language::git+https://github.com/WerWolv/PatternLanguage source = 0001-makepkg-Fix-compiler-check.patch - source = 0002-fix-Deduplicate-resources-directories.patch source = pl-0001-Use-C-23-standard.patch - source = pl-0002-makepkg-Remove-extraneous-compiler-flags.patch sha256sums = SKIP sha256sums = SKIP sha256sums = SKIP sha256sums = SKIP sha256sums = SKIP sha256sums = SKIP - sha256sums = c13f47520affa06b3ab4687d528084ff1f7ecc2cd9600b2e43dae0513727eb5f - sha256sums = b004f268d18c03e2d225179fb52ca02877e93d81d87b4f08344f19ad4ab6fd31 - sha256sums = 2110b942bba25d6d0b0fe4f4ad2b47c9907ad329a0d064ff86bf54b83965f673 - sha256sums = 6bf93b82a254f79bdf92aefda4bcf413dcbe26b4b42444f1fd18793ee35cb402 + sha256sums = SKIP + sha256sums = 43bdbbb6edf567201fa52f1c695f77fea9a27dd5c62de615ef74d64a5e676a98 + sha256sums = 4c3e667d40eabe2a5ea724125c69f73bcb6774c01db9ad97bc6b633e1c284fc5 + b2sums = SKIP b2sums = SKIP b2sums = SKIP b2sums = SKIP b2sums = SKIP b2sums = SKIP b2sums = SKIP - b2sums = 75030d92294ff36642acbae000931ee6b8f03ba6e577b66b5c70a058ca9320f521368fbe225b642df1f4138172c24d966c9ec66fd4eb7f9de24ee896e91363cf - b2sums = ad679ef4fde42ebf9adefec9c3bffb9b640e79f2917141940050e285c79b13e1c7ad58f497db01dd22e56750372545ac544fb4b5400c5d5895461f931365a50e - b2sums = 3c10abfafeb8979924efff0b5d32e543f9ca2fa3eb4216f1c84d8cb5a6ba6c8af4c5b7e3012d4f535d132fe2492c6824473ed309e8ce09d012963de033bf37b5 - b2sums = 2c26d8b28212b98b9bb202f86c5ff84ac4bd44732ee3a30bdca91b576f5a64802c454314baff53621aafa08f761871ae95102b1727ba1f5a5d300103895e07a6 + b2sums = 99e8c5fb5dc0ad07039731c3245bec097de25e675be0f5c52c799738d794ee26df6506adf34fac42663dd39f1c84e7e1675aac5b2f47ef4f2d5ebb903ad4b3a3 + b2sums = ca3779e974709fa15e55255973eb2ff34fb21251c9f8b00c5b2efcfb175add34b503063984589c8d716b650a9543aa19dc2185b2f531ab8d4363635724114199 pkgname = imhex-git - diff --git a/.gitignore b/.gitignore index 8201748bcf12..35655bb03089 100644 --- a/.gitignore +++ b/.gitignore @@ -5,6 +5,7 @@ /pattern_language /xdgpp /yara +/libwolv # Package /imhex-git diff --git a/0001-makepkg-Fix-compiler-check.patch b/0001-makepkg-Fix-compiler-check.patch index d2c18b107ab6..6a870a396317 100644 --- a/0001-makepkg-Fix-compiler-check.patch +++ b/0001-makepkg-Fix-compiler-check.patch @@ -1,17 +1,17 @@ -From be07c244d139a918961e199cb6bccd42aad65e23 Mon Sep 17 00:00:00 2001 +From 935af505d61e4f7e2324cd34833d24e6f789e61a Mon Sep 17 00:00:00 2001 From: KokaKiwi <kokakiwi+git@kokakiwi.net> Date: Mon, 14 Nov 2022 11:58:59 +0100 -Subject: [PATCH 1/3] makepkg: Fix compiler check +Subject: [PATCH] makepkg: Fix compiler check --- - cmake/build_helpers.cmake | 25 ++++++++++++++----------- - 1 file changed, 14 insertions(+), 11 deletions(-) + cmake/build_helpers.cmake | 23 +++++++++++++---------- + 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/cmake/build_helpers.cmake b/cmake/build_helpers.cmake -index 511e7865..ec1b670d 100644 +index 0227511b..048e350c 100644 --- a/cmake/build_helpers.cmake +++ b/cmake/build_helpers.cmake -@@ -257,27 +257,27 @@ macro(createPackage) +@@ -238,27 +238,27 @@ macro(createPackage) elseif(UNIX AND NOT APPLE) set_target_properties(libimhex PROPERTIES SOVERSION ${IMHEX_VERSION}) @@ -45,7 +45,7 @@ index 511e7865..ec1b670d 100644 set_target_properties(libimhex PROPERTIES SOVERSION ${IMHEX_VERSION}) set_property(TARGET main PROPERTY MACOSX_BUNDLE_INFO_PLIST ${MACOSX_BUNDLE_INFO_PLIST}) -@@ -290,7 +290,7 @@ macro(createPackage) +@@ -271,7 +271,7 @@ macro(createPackage) add_custom_target(build-time-make-resources-directory ALL COMMAND ${CMAKE_COMMAND} -E make_directory "${IMHEX_BUNDLE_PATH}/Contents/Resources") downloadImHexPatternsFiles("${IMHEX_BUNDLE_PATH}/Contents/MacOS") @@ -54,21 +54,21 @@ index 511e7865..ec1b670d 100644 install(FILES ${IMHEX_ICON} DESTINATION "${IMHEX_BUNDLE_PATH}/Contents/Resources") install(TARGETS main BUNDLE DESTINATION ".") install(FILES $<TARGET_FILE:main> DESTINATION "${IMHEX_BUNDLE_PATH}") -@@ -407,8 +407,11 @@ function(downloadImHexPatternsFiles dest) +@@ -391,8 +391,11 @@ function(downloadImHexPatternsFiles dest) endfunction() macro(setupCompilerWarnings target) -- set(IMHEX_COMMON_FLAGS "-Wall -Wextra -Werror") -- set(IMHEX_C_FLAGS "${IMHEX_COMMON_FLAGS} -Wno-restrict -Wno-stringop-overread -Wno-stringop-overflow") +- set(IMHEX_COMMON_FLAGS "-Wall -Wextra -Wpedantic -Werror") +- set(IMHEX_C_FLAGS "${IMHEX_COMMON_FLAGS} -Wno-restrict -Wno-stringop-overread -Wno-stringop-overflow -Wno-array-bounds") + set(IMHEX_C_FLAGS "") + + if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU") -+ set(IMHEX_C_FLAGS "${IMHEX_C_FLAGS} -Wno-restrict -Wno-stringop-overread -Wno-stringop-overflow") ++ set(IMHEX_C_FLAGS "${IMHEX_C_FLAGS} -Wno-restrict -Wno-stringop-overread -Wno-stringop-overflow -Wno-array-bounds") + endif() set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${IMHEX_C_FLAGS}") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${IMHEX_C_FLAGS}") -@@ -422,8 +425,8 @@ macro(setUninstallTarget) +@@ -406,7 +409,7 @@ macro(setUninstallTarget) "${CMAKE_CURRENT_SOURCE_DIR}/cmake/cmake_uninstall.cmake.in" "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake" IMMEDIATE @ONLY) @@ -77,9 +77,6 @@ index 511e7865..ec1b670d 100644 add_custom_target(uninstall COMMAND ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake) endif() --endmacro() -\ No newline at end of file -+endmacro() -- -2.38.1 +2.40.0 diff --git a/0002-fix-Deduplicate-resources-directories.patch b/0002-fix-Deduplicate-resources-directories.patch deleted file mode 100644 index 8e795298464a..000000000000 --- a/0002-fix-Deduplicate-resources-directories.patch +++ /dev/null @@ -1,64 +0,0 @@ -From 684cca4d5dc6874842e0a505617abcad0f26472d Mon Sep 17 00:00:00 2001 -From: KokaKiwi <kokakiwi+git@kokakiwi.net> -Date: Sat, 11 Jun 2022 23:08:31 +0200 -Subject: [PATCH 2/3] fix: Deduplicate resources directories - -It seems to actually happens despite xdgpp already doing that... ---- - lib/libimhex/include/hex/helpers/utils.hpp | 11 +++++++++++ - lib/libimhex/source/helpers/fs.cpp | 5 +++++ - 2 files changed, 16 insertions(+) - -diff --git a/lib/libimhex/include/hex/helpers/utils.hpp b/lib/libimhex/include/hex/helpers/utils.hpp -index 3419043f..7d9d1e05 100644 ---- a/lib/libimhex/include/hex/helpers/utils.hpp -+++ b/lib/libimhex/include/hex/helpers/utils.hpp -@@ -199,6 +199,17 @@ namespace hex { - return result; - } - -+ template<typename T> -+ void deduplicateVector(std::vector<T> &items) { -+ auto end = items.end(); -+ -+ for (auto it = items.begin(); it != end; ++it) { -+ end = std::remove(it + 1, end, *it); -+ } -+ -+ items.erase(end, items.end()); -+ } -+ - std::vector<std::string> splitString(const std::string &string, const std::string &delimiter); - std::string combineStrings(const std::vector<std::string> &strings, const std::string &delimiter = ""); - std::string replaceStrings(std::string string, const std::string &search, const std::string &replace); -diff --git a/lib/libimhex/source/helpers/fs.cpp b/lib/libimhex/source/helpers/fs.cpp -index ab6e30d5..b4fce7b1 100644 ---- a/lib/libimhex/source/helpers/fs.cpp -+++ b/lib/libimhex/source/helpers/fs.cpp -@@ -1,4 +1,5 @@ - #include <hex/helpers/fs.hpp> -+#include <hex/helpers/utils.hpp> - - #include <hex/api/content_registry.hpp> - #include <hex/helpers/fs_macos.hpp> -@@ -166,6 +167,8 @@ namespace hex::fs { - auto additionalDirs = ImHexApi::System::getAdditionalFolderPaths(); - std::copy(additionalDirs.begin(), additionalDirs.end(), std::back_inserter(paths)); - -+ hex::deduplicateVector(paths); -+ - return paths; - } - -@@ -185,6 +188,8 @@ namespace hex::fs { - for (auto &path : paths) - path = path / "imhex"; - -+ hex::deduplicateVector(paths); -+ - return paths; - #endif - } --- -2.38.1 - @@ -8,7 +8,7 @@ # NOTE : This PKGBUILD is a copy of https://aur.archlinux.org/packages/imhex (maintained by KokaKiwi) with trivial modifications to fetch the latest commit. pkgname=imhex-git -pkgver=1.25.0.r1.g91a4f52f +pkgver=1.28.0.r73.gb0028b0e pkgrel=1 pkgdesc='A Hex Editor for Reverse Engineers, Programmers and people that value their eye sight when working at 3 AM' url='https://imhex.werwolv.net' @@ -28,31 +28,28 @@ source=("$pkgname::git+https://github.com/WerWolv/ImHex.git" "xdgpp::git+https://git.sr.ht/~danyspin97/xdgpp" "libromfs::git+https://github.com/WerWolv/libromfs" "capstone::git+https://github.com/capstone-engine/capstone#branch=next" + "libwolv::git+https://github.com/WerWolv/libwolv" "pattern_language::git+https://github.com/WerWolv/PatternLanguage" 0001-makepkg-Fix-compiler-check.patch - 0002-fix-Deduplicate-resources-directories.patch - pl-0001-Use-C-23-standard.patch - pl-0002-makepkg-Remove-extraneous-compiler-flags.patch) + pl-0001-Use-C-23-standard.patch) sha256sums=('SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP' - 'c13f47520affa06b3ab4687d528084ff1f7ecc2cd9600b2e43dae0513727eb5f' - 'b004f268d18c03e2d225179fb52ca02877e93d81d87b4f08344f19ad4ab6fd31' - '2110b942bba25d6d0b0fe4f4ad2b47c9907ad329a0d064ff86bf54b83965f673' - '6bf93b82a254f79bdf92aefda4bcf413dcbe26b4b42444f1fd18793ee35cb402') + 'SKIP' + '43bdbbb6edf567201fa52f1c695f77fea9a27dd5c62de615ef74d64a5e676a98' + '4c3e667d40eabe2a5ea724125c69f73bcb6774c01db9ad97bc6b633e1c284fc5') b2sums=('SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP' - '75030d92294ff36642acbae000931ee6b8f03ba6e577b66b5c70a058ca9320f521368fbe225b642df1f4138172c24d966c9ec66fd4eb7f9de24ee896e91363cf' - 'ad679ef4fde42ebf9adefec9c3bffb9b640e79f2917141940050e285c79b13e1c7ad58f497db01dd22e56750372545ac544fb4b5400c5d5895461f931365a50e' - '3c10abfafeb8979924efff0b5d32e543f9ca2fa3eb4216f1c84d8cb5a6ba6c8af4c5b7e3012d4f535d132fe2492c6824473ed309e8ce09d012963de033bf37b5' - '2c26d8b28212b98b9bb202f86c5ff84ac4bd44732ee3a30bdca91b576f5a64802c454314baff53621aafa08f761871ae95102b1727ba1f5a5d300103895e07a6') + 'SKIP' + '99e8c5fb5dc0ad07039731c3245bec097de25e675be0f5c52c799738d794ee26df6506adf34fac42663dd39f1c84e7e1675aac5b2f47ef4f2d5ebb903ad4b3a3' + 'ca3779e974709fa15e55255973eb2ff34fb21251c9f8b00c5b2efcfb175add34b503063984589c8d716b650a9543aa19dc2185b2f531ab8d4363635724114199') options=(!lto !strip) pkgver() { @@ -64,7 +61,7 @@ prepare() { cd "$pkgname" git submodule init - for name in nativefiledialog xdgpp libromfs capstone pattern_language; do + for name in nativefiledialog xdgpp libromfs capstone libwolv pattern_language; do git config submodule.lib/external/$name.url "$srcdir/$name" done for name in fmt curl yara/yara; do @@ -72,13 +69,18 @@ prepare() { done git -c protocol.file.allow=always submodule update + for name in libwolv; do + git -C lib/external/pattern_language \ + config submodule.external/$name.url "$srcdir/$name" + done + git -C lib/external/pattern_language -c protocol.file.allow=always \ + submodule update + git apply \ - "$srcdir/0001-makepkg-Fix-compiler-check.patch" \ - "$srcdir/0002-fix-Deduplicate-resources-directories.patch" + "$srcdir/0001-makepkg-Fix-compiler-check.patch" git -C lib/external/pattern_language apply \ - "$srcdir/pl-0001-Use-C-23-standard.patch" \ - "$srcdir/pl-0002-makepkg-Remove-extraneous-compiler-flags.patch" + "$srcdir/pl-0001-Use-C-23-standard.patch" } build() { diff --git a/pl-0001-Use-C-23-standard.patch b/pl-0001-Use-C-23-standard.patch index 09ef47ed64a6..225c1c0b8874 100644 --- a/pl-0001-Use-C-23-standard.patch +++ b/pl-0001-Use-C-23-standard.patch @@ -1,26 +1,22 @@ -From c61bb49f6dbd1adba1653a3cef242299cd34255a Mon Sep 17 00:00:00 2001 +From 5ca59e77063effc934988c16301dbc7ac821755e Mon Sep 17 00:00:00 2001 From: KokaKiwi <kokakiwi+git@kokakiwi.net> Date: Thu, 18 Aug 2022 00:57:02 +0200 Subject: [PATCH 1/2] Use C++23 standard --- - lib/CMakeLists.txt | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) + lib/CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt -index 404f7f6..4d593ff 100644 +index f7e8c68..e1a1384 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt -@@ -1,7 +1,7 @@ +@@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.16) +cmake_minimum_required(VERSION 3.20) project(libpl) --set(CMAKE_CXX_STANDARD 20) -+set(CMAKE_CXX_STANDARD 23) - - if (LIBPL_SHARED_LIBRARY) - set(LIBRARY_TYPE SHARED) + set(CMAKE_CXX_STANDARD 23) -- -2.38.1 +2.40.0 diff --git a/pl-0002-makepkg-Remove-extraneous-compiler-flags.patch b/pl-0002-makepkg-Remove-extraneous-compiler-flags.patch deleted file mode 100644 index 7c7cf0bce3b9..000000000000 --- a/pl-0002-makepkg-Remove-extraneous-compiler-flags.patch +++ /dev/null @@ -1,25 +0,0 @@ -From f05087e0d92d6312294b06f026ef8a19fac4eac2 Mon Sep 17 00:00:00 2001 -From: KokaKiwi <kokakiwi+git@kokakiwi.net> -Date: Sat, 17 Sep 2022 16:27:17 +0200 -Subject: [PATCH 2/2] makepkg: Remove extraneous compiler flags - ---- - lib/CMakeLists.txt | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt -index 4d593ff..585fdb2 100644 ---- a/lib/CMakeLists.txt -+++ b/lib/CMakeLists.txt -@@ -34,7 +34,7 @@ add_library(libpl ${LIBRARY_TYPE} - source/pl/lib/std/hash.cpp - ) - --target_compile_options(libpl PRIVATE -Wall -Wextra -Werror -Wno-unknown-pragmas) -+target_compile_options(libpl PRIVATE -Wno-unknown-pragmas) - target_include_directories(libpl PUBLIC include) - target_link_libraries(libpl PUBLIC fmt::fmt intervaltree) - set_property(TARGET libpl PROPERTY POSITION_INDEPENDENT_CODE ON) --- -2.38.1 - |