1
0
mirror of synced 2024-12-18 10:35:53 +01:00
Commit Graph

242 Commits

Author SHA1 Message Date
WerWolv
9e1c2d5a2c build: Fix copy-paste bug 2024-07-10 20:50:20 +02:00
WerWolv
11498bd09b build: Properly look for boost and libimhex library in sdk again 2024-06-30 21:55:29 +02:00
WerWolv
91f6aae9ef impr: Make Win32 API properly use unicode support 2024-06-28 11:12:17 +02:00
WerWolv
80cb126200 build: Cleanup configure step logging 2024-06-18 22:09:38 +02:00
WerWolv
18e2b0eaa2 fix: Regex crashes with too long input strings 2024-06-07 23:12:18 +02:00
WerWolv
de8465a8f4 feat: Added limited support for the process memory provider to macOS 2024-06-07 19:17:14 +02:00
WerWolv
c217b1b100 build: Replace -WIP version suffix with .WIP 2024-06-05 20:59:48 +02:00
iTrooz
92b1234ddb
build: Reduce debug info produced (#1720) 2024-05-27 16:33:15 +02:00
iTrooz
0b0bf90e0b
build: Compress debug info (#1719)
This PR compress the debug info in the ELF files built.

This has no impact on the packages (e.g. .deb files) because they themselves have compression, but once installed in the filesystem, they this compression will be beneficial

The compression is opportunistic, happens automatically when possible

For some reason, the web version doesn't work with this (most compiler tests after this seem to fail ?) so it is disabled there

More information: https://github.com/WerWolv/ImHex/issues/1714#issuecomment-2131373826
2024-05-26 20:48:14 +02:00
iTrooz
e5b83d0ddf
chore: add comment about IMHEX_COMMON_FLAGS 2024-05-23 14:44:01 +02:00
David Mentler
bdaf1e4151
build: Xcode accomodating CMake setup (#1688)
### Problem description
This PR implements some rudimentary Xcode support for building and
editing ImHex.

### Implementation description

#### Problem 1: Xcode is a multi-configuration buildsystem
The project is already rather CMake generator independent, thus it did
not need to change much to support Xcode's multi-configuration paradigm:

By default, CMake generates a `.xcodeproj` in which targets build their
artifacts into the specified `<>_OUTPUT_DIRECTORY`, postfixed by the
currently active configuration. To better fit the existing paradigm, I
instead opted ot introduce `IMHEX_MAIN_OUTPUT_DIRECTORY`. This variable
is equal to the previously used `RUNTIME_OUTPUT_DIRECTORY` when using
other generators, and is changed to include a configuration specific
_prefix_ when used with Xcode.

The result is different output directories when using Xcode, and no
changes when using any other generator.

#### Problem 2: ImHex does not support AppleClang
To allow building the codebase with Xcode, I have introduced
`IMHEX_IDE_HELPERS_OVERRIDE_XCODE_COMPILER`. Specifying this option to
`ON` will force CMake to honor the user specified compiler settings,
even when using the Xcode generator.

In practice this can be used together with the new "xcode" CMakePreset
to build the project with mainline clang using `xcodebuild`, or Xcode
itself by generating a buildsystem like so:
```
cmake --preset xcode -DCMAKE_PREFIX_PATH=/opt/homebrew/opt/llvm@17
```

This solution is of course not without flaws. The inner workings are a
particularly ugly hack, and mainline clang does not implement the
necessary extensions to allow Xcode to index the code. Regardless this
option is useful to enable future work in terms of bundling/signing
macOS applications in the "intended" way using Xcode without additional
source modifications.

#### Problem 3: Vanilla CMake + Xcode = Bad developer UX 
By default, the CMake generated `.xcodeproj` is a mess. Tons of targets
are scattered about, and source files are not organized beyond grouping
them into a "Source Files" and "Header Files" group.

Even "Header Files" is missing, because the ImHex build system does not
regard private header files of libraries as sources of a target, and
Xcode does not try to guess this information.

The solution is twofold:
* Additional code has been added which organizes the targets into a neat
folder structure
* Additional code was added behind a configuration flag
`IMHEX_IDE_HELPERS_INTRUSIVE_IDE_TWEAKS` which automatically creates
source file trees in Xcode targets, and discovers the non-declared
header files via the folder convention.

### Screenshots
N/A

### Additional things

As a bonus: `IMHEX_OFFLINE_BUILD` assumes that ImHex-Patterns is cloned
into the source tree. I have added an additional fallback that tries to
locate it as a sibling folder of `${CMAKE_SOURCE_DIR}`, as this meshes
better with my filesystem setup.

The setup was tested with `CMake 3.29.2`, `Xcode 15.2`, and `llvm@17`
from homebrew.
2024-05-20 10:12:57 +00:00
WerWolv
1df0eea6c6 impr: Added support for SVG loading, improved texture loading API 2024-05-01 20:36:10 +02:00
WerWolv
5d0b474a7e build: Move renaming of the macOS bundle to the CI 2024-03-23 00:33:46 +01:00
WerWolv
d09f2c4f26 build: Fix creating the macOS bundle from within the M1 docker 2024-03-22 23:47:24 +01:00
WerWolv
28ea91e6c3 build: Move macOS rpath fixing to install step 2024-03-22 17:31:53 +01:00
WerWolv
0d58307e82 build: Fix bundling issues on macOS 2024-03-22 17:24:44 +01:00
WerWolv
4615dce0a9 build: Try fixing packaging issues with macOS bundles 2024-03-21 21:56:27 +01:00
Nobutaka Mantani
05ffcab911
build: Added support patches for FreeBSD (#1584)
This pull request fixes build on FreeBSD. The changes are conditioned
with `#if defined(__FreeBSD__)` preprocessor macro and they should not
affect build for other operating systems.

---------

Co-authored-by: Nik <werwolv98@gmail.com>
Co-authored-by: iTrooz <hey@itrooz.fr>
2024-03-21 21:31:17 +01:00
WerWolv
a1437658af impr: Generate more useful stack traces on Linux 2024-03-15 17:53:12 +01:00
WerWolv
c610d804b1 build: Added cimgui 2024-03-11 21:09:56 +01:00
WerWolv
deafb6fe08 build: Allow precompiled headers to be turned off 2024-03-02 11:51:33 +01:00
WerWolv
091be1440a build: Added option to disable precompiled headers 2024-03-02 11:28:24 +01:00
WerWolv
fdaa56fd86 build: Disable unknown pragmas warning 2024-02-29 21:49:36 +01:00
WerWolv
bb3de7d510 fix: Build with precompiled headers on Linux 2024-02-29 21:15:51 +01:00
WerWolv
dd62bee264 build: Added precompiled headers 2024-02-29 19:57:20 +01:00
WerWolv
3fa06cc7c0 build: Remove compression from sdk again 2024-02-25 01:57:42 +01:00
WerWolv
d551e39a1c build: Handle install prefix being absolute when installing sdk package 2024-02-25 01:27:48 +01:00
WerWolv
b57eaca365 build: Try to fix sdk packaging 2024-02-24 23:41:22 +01:00
WerWolv
8bf7aa9ceb build: Respect DISTDIR env var when packing SDK 2024-02-24 22:46:16 +01:00
WerWolv
0d4d8efe4e build: Compress SDK package 2024-02-24 16:09:48 +01:00
WerWolv
b2edb0441a build: Make external plugins build again 2024-02-24 15:06:10 +01:00
Nik
e475e763db
build: Hopefully fix macOS x86 build issues (#1556)
#1109
2024-02-17 21:01:57 +01:00
WerWolv
f113a2befe build: Only do dynamic linking of libpl on Windows 2024-02-15 16:10:16 +01:00
iTrooz
f332963c75
build: remove IMHEX_COMMIT_HASH_SHORT cmake flag (#1539) 2024-02-10 01:40:33 +00:00
WerWolv
24815c0370 fix: libpl not being installed correctly 2024-02-03 14:43:41 +01:00
WerWolv
ab842cbd73 build: Fix pattern language shared library ending up in the wrong folder on Linux 2024-02-03 10:41:11 +01:00
WerWolv
a80f9e9ca7 build: Don't re-sign macOS bundle unless requested 2024-02-01 23:56:14 +01:00
WerWolv
10f6aa3e4e fix: Default magic database not being bundled correctly 2024-01-30 21:19:43 +01:00
WerWolv
66d4034a4e build: Fix issues with large Windows builds 2024-01-30 21:19:04 +01:00
WerWolv
76e304c34e build: Fix various issues with linking, clang and unity builds 2024-01-29 22:57:39 +01:00
WerWolv
2e74a78f46 build: Improve unity builds 2024-01-29 21:18:32 +01:00
WerWolv
f5c529b2b3 build: Define DEBUG macro again only in debug builds 2024-01-26 21:11:42 +01:00
WerWolv
bde476dfb7 build: Make sure libraries are correctly linked in external plugins 2024-01-26 12:36:07 +01:00
Nik
6ae86ce906
build: Get rid of pkgconfig as much as possible (#1517) 2024-01-26 12:13:22 +01:00
WerWolv
920b403ee3 build: Fixed libimhex not finding nlohmann json on some platforms 2024-01-25 11:05:02 +01:00
WerWolv
390c1469b1 build: Fix rpath issues on macOS 2024-01-24 22:30:40 +01:00
Nik
a13b5bf8c0
feat: Implement Myers' diffing algorithm (#1508) 2024-01-21 18:39:13 +01:00
WerWolv
ad53a0bf4c build: Make PDB generation slightly better 2024-01-16 00:31:46 +01:00
WerWolv
2cc07f0e73 build: Add option to not generate PDB files in release builds 2024-01-15 23:33:31 +01:00
Nik
a82fdcca4b
build: Remove manual macOS code signing again 2024-01-05 12:39:19 +01:00