Skip to content

Commit 1bc2f84

Browse files
committed
Updated helios core to v1.3.49
More fixes for zlib errors (including changes to libpng build)
1 parent 0dca1ad commit 1bc2f84

3 files changed

Lines changed: 20 additions & 8 deletions

File tree

build_scripts/build_helios.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ class HeliosBuilder:
8888
}
8989
}
9090

91-
def __init__(self, helios_root: Path, output_dir: Path, plugins: Optional[List[str]] = None, buildmode: str = 'release'):
91+
def __init__(self, helios_root, output_dir, plugins=None, buildmode='release'):
9292
"""
9393
Initialize the Helios builder.
9494
@@ -111,7 +111,7 @@ def __init__(self, helios_root: Path, output_dir: Path, plugins: Optional[List[s
111111
self.buildmode = buildmode.title() # Convert to CMake format (Debug, Release, RelWithDebInfo)
112112

113113
if self.platform_name not in self.PLATFORM_CONFIG:
114-
raise HeliosBuildError(f"Unsupported platform: {self.platform_name}")
114+
raise HeliosBuildError("Unsupported platform: {}".format(self.platform_name))
115115

116116
# Get base config and update for architecture and build mode
117117
self.config = self.PLATFORM_CONFIG[self.platform_name].copy()
@@ -135,17 +135,17 @@ def _detect_architecture(self) -> str:
135135
auditwheel_plat = os.environ.get('AUDITWHEEL_PLAT', '')
136136
if auditwheel_plat:
137137
if 'arm64' in auditwheel_plat:
138-
print(f"AUDITWHEEL_PLAT indicates arm64: {auditwheel_plat}")
138+
print("AUDITWHEEL_PLAT indicates arm64: {}".format(auditwheel_plat))
139139
return 'arm64'
140140
elif 'x86_64' in auditwheel_plat:
141-
print(f"AUDITWHEEL_PLAT indicates x86_64: {auditwheel_plat}")
141+
print("AUDITWHEEL_PLAT indicates x86_64: {}".format(auditwheel_plat))
142142
return 'x64'
143143

144144
# Use enhanced detection method for Python 3.8 compatibility on Apple Silicon
145145
# Check HOST_GNU_TYPE which is more reliable than sysconfig.get_platform()
146146
config_vars = sysconfig.get_config_vars()
147147
host_gnu_type = config_vars.get('HOST_GNU_TYPE', '')
148-
print(f"Python HOST_GNU_TYPE: {host_gnu_type}")
148+
print("Python HOST_GNU_TYPE: {}".format(host_gnu_type))
149149

150150
if host_gnu_type and 'arm64' in host_gnu_type and 'apple' in host_gnu_type:
151151
print("Detected native ARM64 Python interpreter")
@@ -156,15 +156,15 @@ def _detect_architecture(self) -> str:
156156

157157
# Fallback to sysconfig platform detection
158158
platform_str = sysconfig.get_platform()
159-
print(f"Python target platform from sysconfig: {platform_str}")
159+
print("Python target platform from sysconfig: {}".format(platform_str))
160160

161161
# For Python 3.8 on Apple Silicon, test ctypes architecture expectations
162162
# since ctypes may expect x86_64 even if sysconfig reports arm64
163163
if 'arm64' in platform_str:
164164
print("WARNING: Python 3.8 on Apple Silicon detected - testing ctypes compatibility")
165165
ctypes_arch = self._test_ctypes_architecture()
166166
if ctypes_arch:
167-
print(f"ctypes architecture test result: {ctypes_arch}")
167+
print("ctypes architecture test result: {}".format(ctypes_arch))
168168
return ctypes_arch
169169
else:
170170
print("ctypes architecture test failed - falling back to ARM64")

pyhelios_build/CMakeLists.txt

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,18 @@ include("${CMAKE_CURRENT_SOURCE_DIR}/cmake/PluginSelection.cmake")
2020
# Setup plugin system (replaces hardcoded PLUGINS variable)
2121
setup_plugin_system()
2222

23+
#-------- MANYLINUX COMPATIBILITY FIX ---------#
24+
# Apply z_size_t compatibility fix globally for all dependencies
25+
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
26+
if(DEFINED ENV{CIBUILDWHEEL} OR DEFINED ENV{AUDITWHEEL_PLAT} OR "$ENV{AUDITWHEEL_PLAT}" MATCHES "manylinux")
27+
message(STATUS "PyHelios: Applying manylinux z_size_t compatibility fix globally")
28+
# Force inclusion of stddef.h for all C/C++ compilations to ensure size_t is available
29+
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -include stddef.h")
30+
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -include stddef.h")
31+
message(STATUS "PyHelios: Applied global stddef.h inclusion for manylinux compatibility")
32+
endif()
33+
endif()
34+
2335
#-------- DO NOT MODIFY ---------#
2436
include( "${BASE_DIRECTORY}/core/CMake_project.cmake" )
2537

0 commit comments

Comments
 (0)