Commit Graph

1080 Commits

Author SHA1 Message Date
Martchus 4316dfd846 Fix formatting in README 2023-04-04 17:10:34 +02:00
Martchus 873cf513c3 Improve README
* Wrap long lines
* Improve wording
* Mention icon bundling
* Remove obsolete notes
* List requires MSYS2 and VCPKG packages for Windows builds using CMake
  preset
2023-03-30 21:37:51 +02:00
Martchus 48aa1f54e0 Add `FFMPEG_BIN` to Windows preset 2023-03-30 21:33:42 +02:00
Martchus b426443aaf Workaround issues with `win-x64-msvc-static` preset
* Set CXX flags manually to specify the `/MT` flag explicitly; this is
  needed as compilations of moc objects apparently don't pick-up the
  variable `CMAKE_MSVC_RUNTIME_LIBRARY` and instead use what the Qt build
  had used (which breaks the compilation when using a shared Qt build with
  this setup which otherwise prefers static libraries)
* Set build type explicitly to release as otherwise a debug build would be
  made (but we have `win-x64-msvc-static-debug` for that)
* Specify the VCPKG target triplet to prefer static libs
* Disable the Qt Quick GUI for now; otherwise passwordmanager is trying to
  pull-in kirigami
* Remove most hardcoded paths for dependencies; with the correct VCPKG
  target triplet those paths can be auto-detected (except for CppUnit)
2023-03-29 23:40:57 +02:00
Martchus 2a123df86d Avoid use of non-standard escape character to avoid MSVC warning about it 2023-03-26 21:49:54 +02:00
Martchus bcd5816d23 Apply clang-format and cmake-format 2023-03-25 18:52:13 +01:00
Martchus d94e49620d Add paths for Doxygen and clang-format to Windows preset 2023-03-23 21:51:57 +01:00
Martchus c3470d0378 Improve build instructions
* Move packaging info into its own section
* Link build instructions for Tag Editor as well as they differ
  slightly from Syncthing Tray
* Use consistent path separator for Windows-specific variables
2023-03-20 23:01:00 +01:00
Martchus 9bd7dbc41c Use Ninja in build example 2023-03-20 22:49:26 +01:00
Martchus 9b1a7b3bf4 Fix includes in `copy.h` when using `sendfile()` 2023-03-19 20:09:14 +01:00
Martchus ec891b48f6 Use `sendfile()` to speed up copying 2023-03-19 20:02:32 +01:00
Martchus 7a5a02976a Fix symbol visibility when building Android apps 2023-03-19 20:02:32 +01:00
Martchus 6e28bec4c5 Add REALPATH_BIN to Windows-preset for CMake bug workaround 2023-03-16 01:02:49 +01:00
Martchus 65b86d71f6 Set QT_ANDROID_VERSION_NAME for Android target 2023-03-11 19:59:09 +01:00
Martchus ab298b200f Apply clang-format 2023-03-11 17:05:08 +01:00
Martchus 2a9949ce77 Tweak app target creation for Android deployment via Qt 6 helpers 2023-03-11 17:04:41 +01:00
Martchus e2593cea2a Bump minor version 2023-03-11 17:00:04 +01:00
Martchus 6ec77a1d1c Add `extractNativePath()` as counterpart to `makeNativePath()` 2023-03-06 22:17:44 +01:00
Martchus 283c416a59 Add preset for building on Windows with MSVC 2023-03-06 22:17:37 +01:00
Martchus 4aea7f5a57 Set `KF_PACKAGE_PREFIX` as well when building against Qt 6 2023-03-05 12:26:33 +01:00
Martchus 169756fce4 Fix loop-condition in `iotests.cpp` 2023-02-28 21:18:15 +01:00
Martchus 30819d9e85 Improve condition for use of `pubsetbuf`
Using this function like this seems only be possible with `libstdc++`. The
standard lib of MSVC and Clang both don't support this (so it is not just
MSVC and thus not Windows-specific).
2023-02-28 21:17:33 +01:00
Martchus 78d57902a7 Workaround MSVC-specific issues in testsuite so tests pass with MSVC 2023-02-28 00:07:56 +01:00
Martchus 2b6f26895d Support multiple source directories in `srcdirref` file
* Locate test files in all source directories specified in `srcdirref`
* Allow overriding contents of `srcdirref` so the directory of another
  component (within the same repository) can be appended to share testfiles
2023-02-27 18:29:31 +01:00
Martchus a703813b4c Mark helper functions of `testutils.cpp` as static; they're not used elsewhere 2023-02-27 18:29:21 +01:00
Martchus 07e9546855 Avoid relying on compiler optimizations for binary conversions
* Add/update binary conversion functions to use `std::memcopy`
* Only GCC could actually optimize the custom code using bit operations
    * Clang could only optimize the `getBytes()` functions
    * MSVC could not optimize any of the functions
* The to…Int…() functions cannot be updated as they are `constexpr` (and
  thus `std::memcopy` and `reinterpret_cast` cannot be used). So they stay
  as-is and `toInt()` has been added instead
* The `BinaryReader` class has been updated to use the new `toInt()`
  function
2023-02-05 21:29:22 +01:00
Martchus 147d36a578 Improve messages of conversion tests 2023-02-05 21:21:26 +01:00
Martchus 31f369d051 Add signed versions of `swapOrder()` functions 2023-02-05 21:20:53 +01:00
Martchus 66621d757b Bump minor release 2023-02-05 20:40:24 +01:00
Martchus 3b2615fa62 Move `BE`/`LE` namespaces to the end so these functions can use previous helpers 2023-02-05 20:17:32 +01:00
Martchus b3fd365502 Use `std::byteswap()` when compiling in C++23 mode 2023-02-05 20:15:29 +01:00
Martchus 8588c17df3 Remove wrong includes in `binaryconversionprivate.h`
This header is not meant to be self-contained and must not include any
other headers.
2023-02-05 19:57:36 +01:00
Martchus 7d6fc9721a Apply clang-format/cmake-format 2023-02-03 13:31:18 +01:00
Martchus be6626f6a6 Fix using percentage operators of `stringbuilder.h` with MSVC 2023-02-01 00:43:53 +01:00
Martchus 024865cc44 Fix building conversion tests with MSVC 2023-02-01 00:42:44 +01:00
Martchus b9b8bfc62a Fix and improve code for finding CppUnit
* Remove `FORCE` in initialization of cache variables as this makes the
  library/include dir effectively *not* configurable
* Try using `find_package()` as the vcpkg package provides a CMake module
2023-01-31 22:37:06 +01:00
Martchus 25e4eebb64 Avoid MSVC warning about possible overflow 2023-01-31 22:37:06 +01:00
Martchus 4d96a82ed9 Workaround unfortunate macro definition in `windows.h` 2023-01-31 22:37:06 +01:00
Martchus a5a33bbcef Add missing include for `std::tuple` to `argumentparser.h` 2023-01-31 22:37:06 +01:00
Martchus da830dcef5 Apply clang-format and cmake-format 2023-01-28 20:20:47 +01:00
Martchus 3a4d71ef5c Avoid unqualified call to `std::move` 2023-01-28 20:20:30 +01:00
Martchus 53ce099bf9 Apply clang-format 2023-01-28 18:49:54 +01:00
Martchus d1eeae83c6 Fix includes for command-line utilities
Most importantly, import `io.h` under Windows as it is required for using
`_open_osfhandle`.
2023-01-26 22:26:42 +01:00
Martchus b6fa13f8dd Use C++ 20 when compiling with MSVC as it requires it for designated initializers 2023-01-26 22:23:46 +01:00
Martchus 38fa3512fd Disable assert for argument name for MSVC to avoid compilation error
Not sure what MSVC complains about here exactly so let's just disable this
code as it is only for debugging anyways.
2023-01-26 22:23:12 +01:00
Martchus d4fbe5f43d Use `std::` consistently in `convertMultiByteToWide()` 2023-01-26 22:20:59 +01:00
Martchus 16f17fb9de Make feature detection for thead local work with MSVC 2023-01-26 22:20:20 +01:00
Martchus e02fed2b57 Add directories of Visual Studio to `.gitignore` 2023-01-26 22:18:43 +01:00
Martchus 16782fc547 Improve formatting in `.gitignore` 2023-01-26 22:18:22 +01:00
Martchus 81618a3468 Expose package version via `use_package` function 2023-01-22 23:01:10 +01:00