Skip to content

Commit 866f5e5

Browse files
committed
Include schema files in Linux standalone
If we don't include these schema files and set the appropriate environment variable, then the standalone will use the system schema files. If these are not compatible with the current versions of packages that we use, then we can get an error.
1 parent 005e651 commit 866f5e5

File tree

4 files changed

+14
-0
lines changed

4 files changed

+14
-0
lines changed

buildconfig/CMake/LinuxPackageScripts.cmake

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,15 @@ if [ -n \"\$1\" ] && [ \"\$1\" = \"--debug\" ]; then
9292
fi"
9393
)
9494

95+
# Without specifying these schema files, the standalone can fail to launch on Linux. Inside a conda environment this
96+
# environment variable is set by something else.
97+
set(GSETTINGS_SCHEMA_DEFINITIONS
98+
"# Specify path to schema files
99+
if [ -z \"${GSETTINGS_SCHEMA_DIR}\" ]; then
100+
GSETTINGS_PATH=\"GSETTINGS_SCHEMA_DIR=${INSTALLDIR}/share/glib-2.0/schemas \"
101+
fi"
102+
)
103+
95104
set(ERROR_CMD "-m mantidqt.dialogs.errorreports.main --exitcode=\$?")
96105

97106
# Local dev version

buildconfig/CMake/Packaging/launch_mantidworkbench.sh.in

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,11 @@ fi
1717

1818
@GDB_DEFINITIONS@
1919

20+
@GSETTINGS_SCHEMA_DEFINITIONS@
21+
2022
# Launch the workbench
2123
LD_PRELOAD=${LOCAL_PRELOAD} \
2224
PYTHONPATH=${LOCAL_PYTHONPATH} @QT_QPA@ \
25+
$GSETTINGS_PATH \
2326
@WRAPPER_PREFIX@$VGLRUN $GDB \
2427
@PYTHON_EXEC_LOCAL@@PYTHON_ARGS@ @MANTIDWORKBENCH_EXEC@ $SINGLEPROCESS "$@"@WRAPPER_POSTFIX@
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
- Fixed the standalone not launching on Linux, especially IDAaaS.

installers/conda/common/common.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ function trim_conda() {
2929
mv "$bundle_conda_prefix"/share "$bundle_conda_prefix"/share_tmp
3030
mkdir "$bundle_conda_prefix"/share
3131
mv "$bundle_conda_prefix"/share_tmp/doc "$bundle_conda_prefix"/share/
32+
mv "$bundle_conda_prefix"/share_tmp/glib-2.0/schemas "$bundle_conda_prefix"/share/glib-2.0/
3233
# Heavily cut down translations
3334
mv "$bundle_conda_prefix"/translations "$bundle_conda_prefix"/translations_tmp
3435
mkdir -p "$bundle_conda_prefix"/translations/qtwebengine_locales

0 commit comments

Comments
 (0)