mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-09-28 11:21:30 +00:00
fix(linux): build deps on older GCC and Ubuntu 22.04 (#15151)
- GMP: name the parameters in the configure probe from 0001-GMP_GCC15.patch. Unnamed parameters are a hard error on GCC 10 and older, so configure failed there. - TBB: turn off the automatic hwloc search so a system libhwloc-dev is not picked up. - scripts/linux.d/debian: run apt update before checking which webkit2gtk package exists, and prefer webkit2gtk-4.1 since the build requires it. Add automake, which MPFR's autoreconf needs.
This commit is contained in:
Vendored
+3
-3
@@ -5,7 +5,7 @@
|
|||||||
#if defined (__GNUC__) && ! defined (__cplusplus)
|
#if defined (__GNUC__) && ! defined (__cplusplus)
|
||||||
typedef unsigned long long t1;typedef t1*t2;
|
typedef unsigned long long t1;typedef t1*t2;
|
||||||
-void g(){}
|
-void g(){}
|
||||||
+void g(int,t1 const*,t1,t2,t1 const*,int){}
|
+void g(int a,t1 const*b,t1 c,t2 dd,t1 const*e,int ff){}
|
||||||
void h(){}
|
void h(){}
|
||||||
static __inline__ t1 e(t2 rp,t2 up,int n,t1 v0)
|
static __inline__ t1 e(t2 rp,t2 up,int n,t1 v0)
|
||||||
{t1 c,x,r;int i;if(v0){c=1;for(i=1;i<n;i++){x=up[i];r=x+1;rp[i]=r;}}return c;}
|
{t1 c,x,r;int i;if(v0){c=1;for(i=1;i<n;i++){x=up[i];r=x+1;rp[i]=r;}}return c;}
|
||||||
@@ -17,7 +17,7 @@
|
|||||||
#if defined (__GNUC__) && ! defined (__cplusplus)
|
#if defined (__GNUC__) && ! defined (__cplusplus)
|
||||||
typedef unsigned long long t1;typedef t1*t2;
|
typedef unsigned long long t1;typedef t1*t2;
|
||||||
-void g(){}
|
-void g(){}
|
||||||
+void g(int,t1 const*,t1,t2,t1 const*,int){}
|
+void g(int a,t1 const*b,t1 c,t2 dd,t1 const*e,int ff){}
|
||||||
void h(){}
|
void h(){}
|
||||||
static __inline__ t1 e(t2 rp,t2 up,int n,t1 v0)
|
static __inline__ t1 e(t2 rp,t2 up,int n,t1 v0)
|
||||||
{t1 c,x,r;int i;if(v0){c=1;for(i=1;i<n;i++){x=up[i];r=x+1;rp[i]=r;}}return c;}
|
{t1 c,x,r;int i;if(v0){c=1;for(i=1;i<n;i++){x=up[i];r=x+1;rp[i]=r;}}return c;}
|
||||||
@@ -26,7 +26,7 @@
|
|||||||
#if defined (__GNUC__) && ! defined (__cplusplus)
|
#if defined (__GNUC__) && ! defined (__cplusplus)
|
||||||
typedef unsigned long long t1;typedef t1*t2;
|
typedef unsigned long long t1;typedef t1*t2;
|
||||||
-void g(){}
|
-void g(){}
|
||||||
+void g(int,t1 const*,t1,t2,t1 const*,int){}
|
+void g(int a,t1 const*b,t1 c,t2 dd,t1 const*e,int ff){}
|
||||||
void h(){}
|
void h(){}
|
||||||
static __inline__ t1 e(t2 rp,t2 up,int n,t1 v0)
|
static __inline__ t1 e(t2 rp,t2 up,int n,t1 v0)
|
||||||
{t1 c,x,r;int i;if(v0){c=1;for(i=1;i<n;i++){x=up[i];r=x+1;rp[i]=r;}}return c;}
|
{t1 c,x,r;int i;if(v0){c=1;for(i=1;i<n;i++){x=up[i];r=x+1;rp[i]=r;}}return c;}
|
||||||
|
|||||||
Vendored
+1
@@ -15,6 +15,7 @@ orcaslicer_add_cmake_project(
|
|||||||
-DTBB_BUILD_SHARED=OFF
|
-DTBB_BUILD_SHARED=OFF
|
||||||
-DTBB_BUILD_TESTS=OFF
|
-DTBB_BUILD_TESTS=OFF
|
||||||
-DTBB_TEST=OFF
|
-DTBB_TEST=OFF
|
||||||
|
-DTBB_DISABLE_HWLOC_AUTOMATIC_SEARCH=ON
|
||||||
-DTBB_ENABLE_IPO=OFF
|
-DTBB_ENABLE_IPO=OFF
|
||||||
-DCMAKE_INTERPROCEDURAL_OPTIMIZATION=OFF
|
-DCMAKE_INTERPROCEDURAL_OPTIMIZATION=OFF
|
||||||
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
|
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
|
||||||
|
|||||||
+10
-5
@@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
REQUIRED_DEV_PACKAGES=(
|
REQUIRED_DEV_PACKAGES=(
|
||||||
autoconf
|
autoconf
|
||||||
|
automake
|
||||||
build-essential
|
build-essential
|
||||||
cmake
|
cmake
|
||||||
eglexternalplatform-dev
|
eglexternalplatform-dev
|
||||||
@@ -50,16 +51,20 @@ then
|
|||||||
REQUIRED_DEV_PACKAGES+=(libssl-dev libcurl4-openssl-dev)
|
REQUIRED_DEV_PACKAGES+=(libssl-dev libcurl4-openssl-dev)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# check which version of libwebkit2gtk is available
|
# The package lists must be current before checking what is available.
|
||||||
if [ "$(apt show --quiet libwebkit2gtk-4.0-dev 2>/dev/null)" != "" ]
|
sudo apt update
|
||||||
|
|
||||||
|
# src/slic3r/CMakeLists.txt requires webkit2gtk-4.1 unconditionally (no
|
||||||
|
# 4.0 fallback), so prefer it; only fall back to 4.0-dev when 4.1 isn't
|
||||||
|
# packaged for this distro.
|
||||||
|
if [ "$(apt show --quiet libwebkit2gtk-4.1-dev 2>/dev/null)" != "" ]
|
||||||
then
|
then
|
||||||
REQUIRED_DEV_PACKAGES+=(libwebkit2gtk-4.0-dev)
|
|
||||||
else
|
|
||||||
REQUIRED_DEV_PACKAGES+=(libwebkit2gtk-4.1-dev)
|
REQUIRED_DEV_PACKAGES+=(libwebkit2gtk-4.1-dev)
|
||||||
|
else
|
||||||
|
REQUIRED_DEV_PACKAGES+=(libwebkit2gtk-4.0-dev)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# install them all at once
|
# install them all at once
|
||||||
sudo apt update
|
|
||||||
sudo apt install -y "${REQUIRED_DEV_PACKAGES[@]}"
|
sudo apt install -y "${REQUIRED_DEV_PACKAGES[@]}"
|
||||||
|
|
||||||
echo -e "done\n"
|
echo -e "done\n"
|
||||||
|
|||||||
Reference in New Issue
Block a user