previously used root specific -Drpath:BOOL=OFF no longer available) Backport fixes to python module Rebuild for pythia8 8.3.16
46 lines
1.6 KiB
Diff
46 lines
1.6 KiB
Diff
From f4577e76a5dc23842d6be0a82df804f71fc820ef Mon Sep 17 00:00:00 2001
|
|
From: Jonas Rembser <jonas.rembser@cern.ch>
|
|
Date: Mon, 1 Dec 2025 16:51:36 +0100
|
|
Subject: [PATCH] [cppyy] Remove now irrelevant `load_cpp_backend()` call
|
|
|
|
As we don't have a separate `cppyy_backend` anymore (neither as a Python
|
|
package, nor as a shared library), trying to load the backend library
|
|
will always give an exception that will be caught as an `ImportError`.
|
|
|
|
It would be cleaner if this code branch is not even taken.
|
|
---
|
|
.../cppyy/cppyy/python/cppyy/_cpython_cppyy.py | 12 ------------
|
|
1 file changed, 12 deletions(-)
|
|
|
|
diff --git a/bindings/pyroot/cppyy/cppyy/python/cppyy/_cpython_cppyy.py b/bindings/pyroot/cppyy/cppyy/python/cppyy/_cpython_cppyy.py
|
|
index bac078ea7c9..f98a34a697c 100644
|
|
--- a/bindings/pyroot/cppyy/cppyy/python/cppyy/_cpython_cppyy.py
|
|
+++ b/bindings/pyroot/cppyy/cppyy/python/cppyy/_cpython_cppyy.py
|
|
@@ -19,24 +19,12 @@ __all__ = [
|
|
'_end_capture_stderr'
|
|
]
|
|
|
|
-# First load the dependency libraries of the backend, then pull in the libcppyy
|
|
-# extension module. If the backed can't be loaded, it was probably linked
|
|
-# statically into the extension module, so we don't error out at this point.
|
|
-try:
|
|
- from cppyy_backend import loader
|
|
- c = loader.load_cpp_backend()
|
|
-except ImportError:
|
|
- c = None
|
|
-
|
|
if platform.system() == "Windows":
|
|
# On Windows, the library has to be searched without prefix
|
|
import libcppyy as _backend
|
|
else:
|
|
import cppyy.libcppyy as _backend
|
|
|
|
-if c is not None:
|
|
- _backend._cpp_backend = c
|
|
-
|
|
# explicitly expose APIs from libcppyy
|
|
_w = ctypes.CDLL(_backend.__file__, ctypes.RTLD_GLOBAL)
|
|
|
|
--
|
|
2.52.0
|
|
|