mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-14 00:52:04 +00:00
fix some appimage issues (#13210)
This commit is contained in:
2
deps/OpenCV/OpenCV.cmake
vendored
2
deps/OpenCV/OpenCV.cmake
vendored
@@ -55,6 +55,8 @@ orcaslicer_add_cmake_project(OpenCV
|
|||||||
-DWITH_VTK=OFF
|
-DWITH_VTK=OFF
|
||||||
-DWITH_JPEG=OFF
|
-DWITH_JPEG=OFF
|
||||||
-DWITH_WEBP=OFF
|
-DWITH_WEBP=OFF
|
||||||
|
-DWITH_TIFF=OFF
|
||||||
|
-DBUILD_TIFF=OFF
|
||||||
-DENABLE_PRECOMPILED_HEADERS=OFF
|
-DENABLE_PRECOMPILED_HEADERS=OFF
|
||||||
-DINSTALL_TESTS=OFF
|
-DINSTALL_TESTS=OFF
|
||||||
-DINSTALL_C_EXAMPLES=OFF
|
-DINSTALL_C_EXAMPLES=OFF
|
||||||
|
|||||||
1
deps/wxWidgets/wxWidgets.cmake
vendored
1
deps/wxWidgets/wxWidgets.cmake
vendored
@@ -52,6 +52,7 @@ orcaslicer_add_cmake_project(
|
|||||||
-DwxUSE_ZLIB=sys
|
-DwxUSE_ZLIB=sys
|
||||||
-DwxUSE_LIBJPEG=sys
|
-DwxUSE_LIBJPEG=sys
|
||||||
-DwxUSE_LIBTIFF=OFF
|
-DwxUSE_LIBTIFF=OFF
|
||||||
|
-DwxUSE_LIBWEBP=builtin
|
||||||
-DwxUSE_EXPAT=sys
|
-DwxUSE_EXPAT=sys
|
||||||
-DwxUSE_NANOSVG=OFF
|
-DwxUSE_NANOSVG=OFF
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -28,11 +28,36 @@ appimage_is_elf_file() {
|
|||||||
|
|
||||||
appimage_list_direct_dependencies() {
|
appimage_list_direct_dependencies() {
|
||||||
local target="$1"
|
local target="$1"
|
||||||
local line dep
|
local line dep dep_name
|
||||||
|
declare -A needed=()
|
||||||
|
|
||||||
|
# Use objdump to identify the direct DT_NEEDED entries first. ldd reports the
|
||||||
|
# full runtime tree, which can accidentally pull transitive dependencies of the
|
||||||
|
# host GTK/pixbuf stack into the AppImage bundle.
|
||||||
|
while IFS= read -r dep_name; do
|
||||||
|
if [[ -n "$dep_name" ]]; then
|
||||||
|
needed["$dep_name"]=1
|
||||||
|
fi
|
||||||
|
done < <(objdump -p "$target" 2>/dev/null | awk '$1 == "NEEDED" { print $2 }')
|
||||||
|
|
||||||
|
if (( ${#needed[@]} == 0 )); then
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
while IFS= read -r line; do
|
while IFS= read -r line; do
|
||||||
|
dep_name=""
|
||||||
|
if [[ "$line" == *"=>"* ]]; then
|
||||||
|
dep_name="$(printf '%s\n' "$line" | awk '{print $1}')"
|
||||||
|
elif [[ "$line" =~ ^[[:space:]]/ ]]; then
|
||||||
|
dep_name="$(basename "$(printf '%s\n' "$line" | awk '{print $1}')")"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ -z "$dep_name" || -z "${needed[$dep_name]+x}" ]]; then
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
if [[ "$line" == *"=> not found"* ]]; then
|
if [[ "$line" == *"=> not found"* ]]; then
|
||||||
echo "MISSING:${line%% *}"
|
echo "MISSING:$dep_name"
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
APPIMAGETOOLURL="https://github.com/AppImage/appimagetool/releases/download/continuous/appimagetool-$(uname -m).AppImage"
|
APPIMAGETOOLURL="https://github.com/AppImage/appimagetool/releases/download/continuous/appimagetool-$(uname -m).AppImage"
|
||||||
|
SCRIPT_DIR="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd)"
|
||||||
|
REPO_ROOT="$(cd -- "${SCRIPT_DIR}/../../.." && pwd)"
|
||||||
|
|
||||||
|
|
||||||
APP_IMAGE="@SLIC3R_APP_KEY@_Linux_V@SoftFever_VERSION@.AppImage"
|
APP_IMAGE="@SLIC3R_APP_KEY@_Linux_V@SoftFever_VERSION@.AppImage"
|
||||||
@@ -33,7 +35,10 @@ mkdir -p usr/share/applications
|
|||||||
cp com.orcaslicer.@SLIC3R_APP_KEY@.desktop usr/share/applications/
|
cp com.orcaslicer.@SLIC3R_APP_KEY@.desktop usr/share/applications/
|
||||||
|
|
||||||
mkdir -p usr/share/metainfo
|
mkdir -p usr/share/metainfo
|
||||||
cp @CMAKE_CURRENT_SOURCE_DIR@/scripts/flatpak/com.orcaslicer.@SLIC3R_APP_KEY@.metainfo.xml usr/share/metainfo/
|
cp "${REPO_ROOT}/scripts/flatpak/com.orcaslicer.@SLIC3R_APP_KEY@.metainfo.xml" \
|
||||||
|
"usr/share/metainfo/com.orcaslicer.@SLIC3R_APP_KEY@.metainfo.xml"
|
||||||
|
cp "${REPO_ROOT}/scripts/flatpak/com.orcaslicer.@SLIC3R_APP_KEY@.metainfo.xml" \
|
||||||
|
"usr/share/metainfo/com.orcaslicer.@SLIC3R_APP_KEY@.appdata.xml"
|
||||||
|
|
||||||
|
|
||||||
export ARCH=$(uname -m)
|
export ARCH=$(uname -m)
|
||||||
|
|||||||
Reference in New Issue
Block a user