Linux fixes: read-only settings, startup crash, link error (#565, #552)#572
Open
Arm4g3ddon wants to merge 6 commits into
Open
Linux fixes: read-only settings, startup crash, link error (#565, #552)#572Arm4g3ddon wants to merge 6 commits into
Arm4g3ddon wants to merge 6 commits into
Conversation
added 6 commits
June 2, 2026 19:59
OnToggled() called set_active_tab(nullptr) after switching the simple/advanced mode, leaving the params panel without an active tab. All parameter inputs (cooling, temperatures, etc.) then stayed greyed out / read-only until the application was restarted. Re-activate the current tab instead. Fixes CrealityOfficial#552
The Dockerfile invokes ./BuildLinux.sh directly, but the script was committed with mode 100644, so the Docker build fails at the first RUN ./BuildLinux.sh step with 'Permission denied' (exit 126).
The Ubuntu 22.04 / GCC 11.4 toolchain miscompiles libslic3r at -O3: the std::ifstream read path returns EOF for valid, non-empty profile JSONs, so startup aborts with nlohmann parse_error.101 and crashes during wx cleanup. Building with the GCC 13 / Ubuntu 24.04 toolchain (the same one the official binary uses) avoids it. Dockerfile: - base image ubuntu:22.04 -> ubuntu:24.04 - add bc (BuildLinux.sh needs it to detect 24.04 and pick linux.d/debian2) - libsoup2.4-dev -> libsoup-3.0-dev, add libjavascriptcoregtk-4.1-dev (24.04 dropped webkit2gtk-4.0; wxWidgets auto-selects 4.1/soup-3) - install libdeflate-dev before the link step (provides libdeflate.so) Carried-over link/ABI fixes (needed regardless of base image): - src/CMakeLists.txt: append libdeflate at the end of every link line via CMAKE_CXX_STANDARD_LIBRARIES (static libtiff needs -ldeflate after its last occurrence in the link order) - deps/paho-mqtt/paho-mqtt.cmake: build paho without SSL on Linux using 'if(UNIX AND NOT APPLE)' (the LINUX var needs CMake >= 3.25); avoids an OpenSSL 3.x-headers vs static-1.1.1-link ABI mismatch GCC 13 pre-emptive fixes: - deps/Assimp/Assimp.cmake: -DASSIMP_WARNINGS_AS_ERRORS=OFF - src/clipper2/CMakeLists.txt: drop -Werror
Static libtiff.a pulls in libLerc symbols (lerc_encodeForVersion, lerc_getBlobInfo, lerc_decode), but the transitive -lLerc is emitted before libtiff.a's last occurrence in the link line, so the symbols go unresolved and the final CrealityPrint link fails. Append libLerc.so at the very end of every link line via CMAKE_CXX_STANDARD_LIBRARIES (emitted last and not deduped), mirroring the existing libdeflate fix next to it.
Kingroon.json references machine/Kingroon KP3S PRO S1[ 0.4 nozzle].json, but the files were lowercased (kingroon kp3s pro s1...). On case-sensitive filesystems (Linux) the files are not found, so ProfileLoader::_LoadModelImpl reads from an unopened stream and nlohmann::json throws a parse_error. That exception propagates uncaught through tbb::parallel_for_each -> Loc_LoadProfile -> AppConfig::get_profile_machines() (called during the Plater/MainFrame build), aborting GUI init with a secondary SIGSEGV. Windows and macOS hide this because their filesystems are case-insensitive. Two-part fix: - rename the two Kingroon machine profiles to the referenced casing - guard the ifs >> json reads in ProfileLoader::_LoadModel/_LoadModelImpl/ _LoadPrinterImpl with try/catch so a missing or malformed profile file skips that entry instead of taking down the whole startup.
…realityOfficial#552) ParamsDialog (filament/process/printer settings) installs a wxWindowDisabler(this) on wxEVT_SHOW to behave like a modal dialog. On GTK this ends up making the dialog itself insensitive: the dialog is transient-for the mainframe, which gets gtk_widget_set_sensitive(FALSE), and the dialog goes down with it. The custom-drawn Creality widgets (TextInput, CheckBox, SwitchButton) keep their normal appearance but stop receiving any mouse/keyboard events, so ~all parameter inputs look editable yet behave as read-only. Windows is unaffected because Popup() reparents the dialog under the mainframe first (#ifdef __WIN32__). Skip the modal-style wxWindowDisabler on Linux (#ifndef __linux__). The settings dialog is non-modal there but fully usable again. Fixes CrealityOfficial#565 and CrealityOfficial#552.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A few fixes that are needed to build and actually use CrealityPrint on Linux. Almost all of these only surface on Linux (case-sensitive filesystem, GTK, GLVND); Windows is unaffected.
Settings UI read-only (#565, #552)
The filament / process / printer settings dialog was effectively unusable on Linux: inputs looked editable but didn't react, and checkboxes wouldn't toggle.
Cause:
ParamsDialoginstalls awxWindowDisabler(this)onwxEVT_SHOWto behave like a modal dialog. On GTK this ends up making the dialog itself insensitive — it's transient-for the mainframe, the mainframe getsgtk_widget_set_sensitive(FALSE), and the dialog goes down with it. The custom-drawn widgets keep their normal look but stop receiving mouse/keyboard events, so everything reads as locked. Windows avoids it becausePopup()reparents the dialog under the mainframe first (#ifdef __WIN32__).Fix: skip the disabler on Linux. The dialog is non-modal there but usable again.
Startup crash with a clean profile set
Kingroon.jsonreferenced two machine files with different casing than the files on disk (Kingroon KP3S PRO S1[...].jsonvskingroon kp3s pro s1[...].json). On a case-sensitive filesystem the file isn't found, so the profile loader reads from an unopened stream and nlohmann::json throws aparse_error. That propagates uncaught throughtbb::parallel_for_eachout ofAppConfig::get_profile_machines()during the Plater/MainFrame build and aborts GUI init.Fix: rename the two files to the referenced casing, and wrap the profile json reads in try/catch so one broken profile is skipped instead of taking down startup.
Link error
Static libtiff pulls in libLerc symbols, but the transitive
-lLercis emitted before libtiff's last occurrence on the link line, so the final link fails with undefined references. Append libLerc at the very end of the link line, same as the existing libdeflate workaround right next to it.Build
Docker build moved to Ubuntu 24.04 / GCC 13 (the two older commits in this branch).
Built and run on Arch (KDE / X11, NVIDIA). Settings are editable again, the app starts from a clean datadir, and the link/build go through.