Ship 0.8 fog/freistellen and fix Windows CI for friends
Some checks are pending
Windows Release / windows-x86_64 (push) Waiting to run
Some checks are pending
Windows Release / windows-x86_64 (push) Waiting to run
Publish the portable zip to public Forgejo from the private GitHub builder, and force Ninja so MSVC 195 deps build without CMake 4.2.
This commit is contained in:
parent
97b136de3b
commit
1c1d63f376
46 changed files with 1748 additions and 156 deletions
|
|
@ -509,8 +509,58 @@ class ConanSkia(ConanFile):
|
|||
return [fw + ".framework" for fw in frameworks]
|
||||
|
||||
def build(self):
|
||||
# Optional: reuse a finished out/conan from a prior local build
|
||||
# (avoids re-hitting googlesource + full ninja). Path = .../out/conan
|
||||
reuse_out = os.environ.get("SKIA_REUSE_OUT")
|
||||
if reuse_out and os.path.isdir(reuse_out):
|
||||
import shutil
|
||||
dst = join(self.source_folder, "out", "conan")
|
||||
os.makedirs(join(self.source_folder, "out"), exist_ok=True)
|
||||
if os.path.isdir(dst):
|
||||
shutil.rmtree(dst)
|
||||
shutil.copytree(reuse_out, dst)
|
||||
return
|
||||
|
||||
# activate-emsdk fails on Windows for some reason.
|
||||
os.environ["GIT_SYNC_DEPS_SKIP_EMSDK"] = "1"
|
||||
# Default git-sync-deps fans out one thread per dep and hits
|
||||
# googlesource HTTP 429. Serialize + retry before syncing.
|
||||
replace_in_file(
|
||||
self,
|
||||
join(self.source_folder, "tools", "git-sync-deps"),
|
||||
"""def multithread(function, list_of_arg_lists):
|
||||
anything_failed = False
|
||||
threads = []
|
||||
def hook(args):
|
||||
nonlocal anything_failed
|
||||
anything_failed = True
|
||||
threading.excepthook = hook
|
||||
for args in list_of_arg_lists:
|
||||
thread = threading.Thread(None, function, None, args)
|
||||
thread.start()
|
||||
threads.append(thread)
|
||||
for thread in threads:
|
||||
thread.join()
|
||||
if anything_failed:
|
||||
raise Exception("Thread failure detected")
|
||||
""",
|
||||
"""def multithread(function, list_of_arg_lists):
|
||||
import time
|
||||
for args in list_of_arg_lists:
|
||||
last_err = None
|
||||
for attempt in range(6):
|
||||
try:
|
||||
function(*args)
|
||||
last_err = None
|
||||
break
|
||||
except Exception as e:
|
||||
last_err = e
|
||||
time.sleep(min(60, 2 ** attempt))
|
||||
if last_err is not None:
|
||||
raise last_err
|
||||
""",
|
||||
strict=True,
|
||||
)
|
||||
self.run("python3 tools/git-sync-deps")
|
||||
del os.environ["GIT_SYNC_DEPS_SKIP_EMSDK"]
|
||||
|
||||
|
|
@ -585,9 +635,21 @@ class ConanSkia(ConanFile):
|
|||
|
||||
buildenv = VirtualBuildEnv(self).vars()
|
||||
|
||||
if cc := buildenv.get("CC", default=None):
|
||||
cc = buildenv.get("CC", default=None)
|
||||
cxx = buildenv.get("CXX", default=None)
|
||||
# Fall back to tools.build:compiler_executables when VirtualBuildEnv
|
||||
# did not inject CC/CXX (common with only profile [conf]).
|
||||
try:
|
||||
executables = self.conf.get("tools.build:compiler_executables", default={}) or {}
|
||||
except Exception:
|
||||
executables = {}
|
||||
if not cc:
|
||||
cc = executables.get("c")
|
||||
if not cxx:
|
||||
cxx = executables.get("cpp")
|
||||
if cc:
|
||||
args += f"cc=\"{cc}\"\n"
|
||||
if cxx := buildenv.get("CXX", default=None):
|
||||
if cxx:
|
||||
args += f"cxx=\"{cxx}\"\n"
|
||||
if ar := buildenv.get("AR", default=None):
|
||||
args += f"ar=\"{ar}\"\n"
|
||||
|
|
|
|||
|
|
@ -216,8 +216,34 @@ class ICUConan(ConanFile):
|
|||
if dat_package_file:
|
||||
shutil.copy(str(self.options.dat_package_file), dat_package_file[0])
|
||||
|
||||
# GCC 16 ICEs compiling ICU 77 headers under -std=gnu++23 (enum in uchar.h).
|
||||
# Keep the package usable from a C++23 consumer, but build ICU itself as C++17.
|
||||
if self.settings.os == "Linux":
|
||||
import os as _os
|
||||
for var in ("CXXFLAGS", "CFLAGS"):
|
||||
cur = _os.environ.get(var, "")
|
||||
parts = [p for p in cur.split() if not p.startswith("-std=") and not p.startswith("-O")]
|
||||
if var == "CXXFLAGS":
|
||||
parts.extend(["-std=gnu++17", "-O1"])
|
||||
else:
|
||||
parts.append("-O1")
|
||||
_os.environ[var] = " ".join(parts)
|
||||
|
||||
autotools = Autotools(self)
|
||||
autotools.configure(build_script_folder=os.path.join(self.source_folder, "source"))
|
||||
|
||||
if self.settings.os == "Linux":
|
||||
for root, _, files in os.walk(self.build_folder):
|
||||
for name in files:
|
||||
if name in ("Makefile", "mh-linux") or name.endswith(".mk"):
|
||||
path = os.path.join(root, name)
|
||||
try:
|
||||
replace_in_file(self, path, "-O3", "-O1", strict=False)
|
||||
replace_in_file(self, path, "-std=gnu++23", "-std=gnu++17", strict=False)
|
||||
replace_in_file(self, path, "-std=c++23", "-std=c++17", strict=False)
|
||||
except Exception:
|
||||
pass
|
||||
|
||||
autotools.make()
|
||||
|
||||
@property
|
||||
|
|
|
|||
14
conan/profiles/linux-x86_64-clang
Normal file
14
conan/profiles/linux-x86_64-clang
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
[settings]
|
||||
arch=x86_64
|
||||
build_type=Release
|
||||
compiler=clang
|
||||
compiler.cppstd=gnu23
|
||||
compiler.libcxx=libstdc++11
|
||||
compiler.version=22
|
||||
os=Linux
|
||||
|
||||
[tool_requires]
|
||||
cmake/3.27.0
|
||||
|
||||
[conf]
|
||||
tools.build:compiler_executables={'c':'clang','cpp':'clang++'}
|
||||
21
conan/profiles/linux-x86_64-gcc15
Normal file
21
conan/profiles/linux-x86_64-gcc15
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
[settings]
|
||||
arch=x86_64
|
||||
build_type=Release
|
||||
compiler=gcc
|
||||
compiler.cppstd=gnu23
|
||||
compiler.libcxx=libstdc++11
|
||||
compiler.version=15
|
||||
os=Linux
|
||||
|
||||
[tool_requires]
|
||||
cmake/3.27.0
|
||||
|
||||
[buildenv]
|
||||
CC=/home/yuna/.local/share/gcc15-root/usr/bin/gcc-15
|
||||
CXX=/home/yuna/.local/share/gcc15-root/usr/bin/g++-15
|
||||
|
||||
[conf]
|
||||
tools.build:compiler_executables={'c':'/home/yuna/.local/share/gcc15-root/usr/bin/gcc-15','cpp':'/home/yuna/.local/share/gcc15-root/usr/bin/g++-15'}
|
||||
tools.build:jobs=2
|
||||
tools.build:cflags=["-O2"]
|
||||
tools.build:cxxflags=["-O2"]
|
||||
Loading…
Add table
Add a link
Reference in a new issue