diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 062e6390a..4bd6beeba 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -627,11 +627,11 @@ jobs: - name: ✒️ Modify spec file run: | sed -i \ - -e 's/Version: [0-9]*\.[0-9]*\.[0-9]*$/Version: ${{env.IMHEX_VERSION}}/g' \ - -e 's/IMHEX_OFFLINE_BUILD=ON/IMHEX_OFFLINE_BUILD=OFF/g' \ - -e '/IMHEX_OFFLINE_BUILD=OFF/a -D IMHEX_PATTERNS_PULL_MASTER=ON \\' \ - -e '/BuildRequires: cmake/a BuildRequires: git-core' \ - -e '/%files/a %{_datadir}/%{name}/' \ + -e 's/Version: VERSION$/Version: ${{env.IMHEX_VERSION}}/g' \ + -e 's/IMHEX_OFFLINE_BUILD=ON/IMHEX_OFFLINE_BUILD=OFF/g' \ + -e '/IMHEX_OFFLINE_BUILD=OFF/a -D IMHEX_PATTERNS_PULL_MASTER=ON \\' \ + -e '/BuildRequires: cmake/a BuildRequires: git-core' \ + -e '/%files/a %{_datadir}/%{name}/' \ $GITHUB_WORKSPACE/ImHex/dist/rpm/imhex.spec - name: 📜 Fix ccache on EL9 diff --git a/CMakeLists.txt b/CMakeLists.txt index 5b7677f36..5abf82f00 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -60,8 +60,8 @@ setUninstallTarget() addBundledLibraries() add_subdirectory(lib/libimhex) -addPluginDirectories() add_subdirectory(main) +addPluginDirectories() # Add unit tests if (IMHEX_ENABLE_UNIT_TESTS) diff --git a/dist/compiling/docker.md b/dist/compiling/docker.md index f1a783281..484ab2e66 100644 --- a/dist/compiling/docker.md +++ b/dist/compiling/docker.md @@ -18,11 +18,11 @@ docker buildx build . -f --progress plain --build-arg 'JOBS=4' where `` should be replaced by the wanted Dockerfile base d on the build you want to do: -| Wanted build | Dockerfile path | -|--------------|-----------------------------| -| MacOS M1 | dist/macOS/arm64.Dockerfile | -| AppImage | dist/appimage/Dockerfile | -| Web version | dist/web/Dockerfile | +| Wanted build | Dockerfile path | Target | +|--------------|-----------------------------|--------| +| MacOS M1 | dist/macOS/arm64.Dockerfile | - | +| AppImage | dist/appimage/Dockerfile | - | +| Web version | dist/web/Dockerfile | raw | We'll explain this command in the next section @@ -43,6 +43,7 @@ In the command saw earlier: - `.` is the base folder that the Dockerfile will be allowed to see - `-f ` is to specify the Dockerfile path - `--progress plain` is to allow you to see the output of instructions -- `--build-arg =` is to allow to to specify arguments to the build (like -DKEY=VALUE in CMake) +- `--build-arg =` is to allow to specify arguments to the build (like -DKEY=VALUE in CMake) - `--build-context key=` is to specify folders other than the base folder that the Dockerfile is allowed to see - `--output ` is the path to write the output package to. If not specified, Docker will create an image as the output (probably not what you want) +- `--target ` specifies which docker target to build diff --git a/dist/rpm/imhex.spec b/dist/rpm/imhex.spec index d8d8c32b9..5a9da2221 100644 --- a/dist/rpm/imhex.spec +++ b/dist/rpm/imhex.spec @@ -1,5 +1,5 @@ Name: imhex -Version: 1.26.2 +Version: VERSION Release: 0%{?dist} Summary: A hex editor for reverse engineers and programmers diff --git a/lib/third_party/imgui/cimgui/CMakeLists.txt b/lib/third_party/imgui/cimgui/CMakeLists.txt index ba6cb3115..a89884ada 100644 --- a/lib/third_party/imgui/cimgui/CMakeLists.txt +++ b/lib/third_party/imgui/cimgui/CMakeLists.txt @@ -4,8 +4,12 @@ project(imgui_cimgui) set(CMAKE_CXX_STANDARD 17) +if (IMHEX_STATIC_LINK_PLUGINS) + return() +endif() + if (NOT IMHEX_EXTERNAL_PLUGIN_BUILD) - add_library(imgui_cimgui SHARED + add_library(imgui_cimgui ${LIBRARY_TYPE} source/cimgui.cpp ) @@ -18,7 +22,8 @@ if (NOT IMHEX_EXTERNAL_PLUGIN_BUILD) set_target_properties(imgui_cimgui PROPERTIES OUTPUT_NAME "cimgui") set_target_properties(imgui_cimgui PROPERTIES PREFIX "") add_dependencies(imhex_all imgui_cimgui) + + install(FILES "$" DESTINATION "${CMAKE_INSTALL_LIBDIR}" PERMISSIONS ${LIBRARY_PERMISSIONS}) + set_target_properties(imgui_cimgui PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}) endif() -install(FILES "$" DESTINATION "${CMAKE_INSTALL_LIBDIR}" PERMISSIONS ${LIBRARY_PERMISSIONS}) -set_target_properties(imgui_cimgui PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}) \ No newline at end of file