Commit Graph

42 Commits

Author SHA1 Message Date
Laurent Trinques 42d2c824d2 Merge pull request #513 from ispyisail/feature/edz-import
Import EPLAN Data Portal parts (.edz) into element collections
2026-07-23 13:58:56 +02:00
scorpio810 629bd7cdef Add SQLite3::SQLite3 compat alias, use modern target name
CMake's bundled FindSQLite3 module only creates the SQLite3::SQLite3
target since CMake 4.3; earlier versions (still used by most current
Linux distros) only provide SQLite::SQLite3, which CMake >= 4.3 now
flags as deprecated.

Add the missing alias ourselves right after find_package(SQLite3)
when it isn't already provided, so the project can link against the
modern SQLite3::SQLite3 name on every supported CMake version without
triggering the deprecation warning on newer ones.
2026-07-19 12:30:19 +02:00
Dieter Mayer 683eefdac1 Request the GuiPrivate component only on Qt6
Listing GuiPrivate unconditionally in QET_COMPONENTS breaks the whole
Qt5 configure: find_package(Qt5 COMPONENTS GuiPrivate) looks for a
Qt5GuiPrivateConfig.cmake that has never existed - Qt5 creates the
Qt5::GuiPrivate target implicitly together with Gui. Only Qt6 requires
(and provides) the explicit component.

Move the request into a QT_VERSION_MAJOR-guarded find_package after the
main one, both for the application and for tests/catch (whose targets
link Qt::GuiPrivate via QET_PRIVATE_LIBRARIES). Fixes the msys2/Qt5
Windows CI configure failure:
"Could not find a package configuration file provided by Qt5GuiPrivate".

Verified: Qt 6.11 configure passes and the Qt6::GuiPrivate target is
created (the private-module warning now fires from the guarded call).
The Qt5 path simply no longer requests the component, restoring the
pre-existing implicit behaviour.
2026-07-17 19:25:26 +02:00
Laurent Trinques 424a1c945e Try to fix compile with cmake .. -G Ninja -DQT_VERSION_MAJOR=6 -DBUILD_WITH_KF5=OFF -DPACKAGE_TESTS=OFF 2026-07-17 10:25:30 +02:00
Dieter Mayer 46f479240e Run lupdate only via an explicit update_translations target
The default build ran both lupdate (qt5_create_translation, which
rewrites the tracked .ts files in the source tree) and lrelease
(qt5_add_translation, which reads the same .ts files). Under high
parallelism lrelease could read a .ts while lupdate was rewriting it,
failing the build with "Premature end of document"; every build also
modified tracked files as a side effect, and each .qm was generated
twice (once into the build dir, once into lang/).

Keep only lrelease in the default build and move lupdate behind an
explicit developer target (cmake --build . --target update_translations).
The target scans sources/ instead of the whole source tree, which also
stops lupdate from parsing unrelated third-party .js files.
2026-07-14 19:29:19 +02:00
Gerhard Schwanzer d0cea474a6 Fix Qt-only build without KF5
The BUILD_WITH_KF5 option was checked with DEFINED, so passing -DBUILD_WITH_KF5=OFF still entered the KF5 setup path.

Skip the KF5 setup when disabled and provide small Qt-only replacements for the KDE color widgets used by .ui files in that build mode.

Assisted-by: pi coding agent / Mika (OpenAI GPT-5.5)
2026-07-05 11:10:44 +02:00
Shane Ringrose 734391eabf Merge master: add cli_export, pdf_links; EDZ: 10-slot grid, group headers, ToS notice
- Resolve cmake/qet_compilation_vars.cmake conflict: keep both upstream's
  cli_export.cpp/h and pdf_links.cpp/h and the EDZ source additions.

- 10-position grid alignment: pin_y values are multiples of 10 so terminals
  snap cleanly to QET's default grid.  group_gap raised to 10 (one full slot).

- Named connector groups get a header label (group name) placed in the gap
  above the first pin, so the electrician sees block names (XDI, XPOW, …)
  without reading individual terminal designations.

- Device-tag dynamic_text now uses 9pt LABEL_FONT and y = min_y - 9 so it
  clears the element body and is legible at normal zoom.

- Add EPLAN Data Portal Terms of Use disclaimer to sources/import/edz/README.md.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-21 21:00:49 +12:00
Shane Ringrose e4b4ba875b Bundle LZMA SDK for .edz extraction; drop 7z CLI dependency (M3)
Replaces the QProcess->7z shim with the public-domain LZMA SDK (23.01) 7-Zip
reader, vendored under sources/import/edz/lzma/ (decode-only subset). New
edzsevenzip.cpp wraps SzArEx_Open/SzArEx_Extract and writes entries via Qt, so
EdzArchive no longer needs an external 7-Zip at runtime. Enables the C language
in CMake for the vendored sources.

Verified: the bundled decoder extracts all three ifm sample .edz and the
generated elements still match the Python oracle exactly (byte-correct decode),
with no 7z on the path.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-20 07:49:14 +12:00
Laurent Trinques 5574b4d3e9 CMake: guard Linux-only install rules with UNIX AND NOT APPLE
The .desktop, MIME package, and appdata install rules are
freedesktop.org conventions and only apply on Linux. Wrapping
them in if(UNIX AND NOT APPLE) prevents a configure failure on
macOS and Windows where QET_APPDATA_PATH and QET_MIME_PACKAGE_PATH
are not defined.

Also replace the hardcoded share/mime/packages path with
${QET_MIME_PACKAGE_PATH} for consistency with
paths_compilation_installation.cmake.

No change to Linux build behaviour.
2026-06-14 13:58:37 +02:00
Laurent Trinques 8a8a338a2e Update CMakeLists.txt 2026-06-07 15:06:23 +02:00
Laurent Trinques 407cc7a4c2 Update CMakeLists.txt 2026-06-07 14:59:36 +02:00
Laurent Trinques d85aff0c0f Update CMakeLists.txt 2026-05-21 03:40:14 +02:00
Laurent Trinques ae3e01e564 Update windows CI/CD pipeline
Windows Build / build-windows (push) Has been cancelled
2026-05-10 09:56:02 +02:00
Laurent Trinques a140c5ad39 Update CMakeLists.txt
Publish Edge Snap / publish_amd64 (push) Failing after 15s
2024-12-15 15:05:23 +01:00
Laurent Trinques 29ebc6000b Fix Cmake files 2023-11-08 13:38:55 +01:00
luz paz a76e5446aa Fix various typos in source documentation and comments
Found via `codespell`
2022-12-04 13:30:01 +01:00
Pino Toscano cf479bc113 Drop old mimelnk MIME types
Those desktop MIME types were needed only with KDE up to 3.x, as it
used to have its own desktop-based MIME type system. KDE 3 is EOL for
many years now, and there are already XDG MIME types.
2022-07-05 18:16:51 +02:00
Pino Toscano 08e206deeb Drop XML files autogenerated from qelectrotech.xml
These files are the bare XML definitions, and they are automatically
generated by update-mime-database (part of shared-mime-info) on update
(e.g. by distro hooks) or manually. Keeping them in the sources, and
installing them, is definitely not correct, as qelectrotech.xml is
their canonical definition.

Hence, drop them from the sources, together with references to them.
2022-07-05 18:16:51 +02:00
Laurent Trinques 1a3656f7be Add MINGW flag for cmake 2021-03-22 08:15:37 +01:00
Gleb Popov 9300130aaf Add installation phase to CMake build system 2021-03-18 13:44:26 +01:00
Simon De Backer 170d856007 Fix Cmake
did not compile
2021-03-02 22:15:44 +01:00
Simon De Backer 2e543dd1f7 Add create translation .ts file on Cmake 2020-12-18 17:05:41 +01:00
Simon De Backer 404ae4fffc Add Cmake ui files in sdk 2020-12-17 21:43:23 +01:00
Simon De Backer cb37c1c2fe Add switch for KF5 (QT6) and Mod Cmake
if we want to test QET on QT6, KF5 must be removed from the code,
this switch is for that,

this is for testing only
2020-12-16 23:06:08 +01:00
Simon De Backer 7fc9d06eef Fix Cmake translation files dir 2020-12-14 21:30:40 +01:00
Simon De Backer 842b39d68b Fix som Cmake PATH 2020-12-13 20:57:10 +01:00
Simon De Backer 2fc7f594cc Add Cmake files 2020-12-13 15:44:01 +01:00
Simon De Backer c88d1ef6bb Refactoring Cmake
cleaning up the Cmake code
2020-12-13 00:40:43 +01:00
Simon De Backer ce5cc25186 Fix stop the run autotests of kcoreaddons
see
https://invent.kde.org/frameworks/kcoreaddons/-/blob/master/CMakeLists.txt#L98

issue:
CMake Error at /usr/share/ECM/modules/ECMAddTests.cmake:89 (add_executable):
  Cannot find source file:
see
https://qelectrotech.org/forum/viewtopic.php?pid=13929#p13929
2020-12-11 22:41:30 +01:00
Simon De Backer 74b112a4bb Mod KF5 v5.76.0 => v5.70.0
see https://qelectrotech.org/forum/viewtopic.php?pid=13924#p13924
2020-12-11 18:05:21 +01:00
Simon De Backer 6ec9a04fda Fix translation in Cmake 2020-12-11 17:29:05 +01:00
Simon De Backer 35ad994471 Mod more Cmake 2020-12-11 16:17:15 +01:00
Simon De Backer 83d802adf7 Mod Cmake first working build 2020-12-11 14:55:11 +01:00
Simon De Backer 62b71c0ba5 Fix more Cmake + Mod pragma message 2020-12-11 00:45:43 +01:00
Simon De Backer eb49977c75 Fix som Cmake (add_definitions)
add_definitions(-DGIT_COMMIT_SHA=${GIT_COMMIT_SHA})
-DGIT_COMMIT_SHA=GIT_COMMIT_SHA
2020-12-11 00:16:49 +01:00
Simon De Backer 234f468f15 Fix GIT_COMMIT_SHA in Cmake 2020-12-10 21:18:42 +01:00
Simon De Backer ed938c82cd Mod Cmake 2020-12-10 19:03:36 +01:00
Simon De Backer d0c129478e Mod Cmake en preprocessor 2020-12-10 00:08:26 +01:00
Simon De Backer d89d1088a3 Cmake for UI files auto link
this is one of the errors:
the ui files must be linked and changed to h files
so the h files found in the code by preprocessor
2020-12-09 10:40:12 +01:00
Simon De Backer 10c4c3d528 Wip Fix preprocessor on Cmake 2020-12-08 19:57:35 +01:00
Simon De Backer 1871b7ad12 Add more Cmake 2020-12-08 15:20:48 +01:00
Simon De Backer 6cd6efaca9 Add Catch2 and Google Test on Cmake
ToDo:
- Add compiling QElectroTech on Cmake (help needed)
- more Tests?
   - Qt Test
   - Boost Test

to test
run qtcreator
File >  open => CMakeLists.txt
2020-12-08 12:18:20 +01:00