Commit fc07cf56 authored by Marco Clemencic's avatar Marco Clemencic

Workaround for ROOT-10769

parent 42e4e7a3
......@@ -12,7 +12,11 @@
#
# The custom application class is implemented in C++ via ROOT interpreter
import cppyy
# Workaround for ROOT-10769
import warnings
with warnings.catch_warnings():
warnings.simplefilter("ignore")
import cppyy
# - we have to load GaudiKernel get the base class
cppyy.gbl.gSystem.Load("libGaudiKernel.so")
......
......@@ -47,7 +47,11 @@ if '__main__' == __name__:
print(__doc__, __author__)
# make sure cling can generate all required methods in Gaudi::Property
import cppyy
# Workaround for ROOT-10769
import warnings
with warnings.catch_warnings():
warnings.simplefilter("ignore")
import cppyy
cppyy.gbl.gInterpreter.Declare('#define NO_C_ARRAY_AS_PROPERTY_WARNING')
cppyy.gbl.gInterpreter.Declare('#include "GaudiKernel/CArrayAsProperty.h"')
......
......@@ -49,7 +49,11 @@ if '__main__' == __name__:
print(__doc__, __author__)
# make sure cling can generate all required methods in Gaudi::Property
import cppyy
# Workaround for ROOT-10769
import warnings
with warnings.catch_warnings():
warnings.simplefilter("ignore")
import cppyy
for h in ("GaudiKernel/SVectorAsProperty.h",
"GaudiKernel/VectorsAsProperty.h"):
cppyy.gbl.gInterpreter.Declare('#include "%s"' % h)
......
......@@ -32,12 +32,11 @@ import sys
import string
import warnings
import re
try:
# Workaround for ROOT-10769
with warnings.catch_warnings():
warnings.simplefilter("ignore")
import cppyy
except ImportError:
# FIXME: backward compatibility
print("# WARNING: using PyCintex as cppyy implementation")
import PyCintex as cppyy
if sys.version_info >= (3, ):
# Python 2 compatibility
......
......@@ -9,6 +9,10 @@
# or submit itself to any jurisdiction. #
#####################################################################################
"""Load the GaudiPython::Helper struct to check for Cling warnings."""
import cppyy
# Workaround for ROOT-10769
import warnings
with warnings.catch_warnings():
warnings.simplefilter("ignore")
import cppyy
cppyy.gbl.GaudiPython.Helper
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment