From 01ad051a73e73a9918f8c3f14ab52c8f8e64b881 Mon Sep 17 00:00:00 2001 From: Jean-Paul Chaput Date: Sat, 17 Jul 2010 10:33:55 +0000 Subject: [PATCH] * All Main Python Modules: - Change: New problem identified with the Python modules: each module seems to be built as a complete binary, so all the static C++ initializers are allocated in each module. In particular the C++ tree inheritance is built for *each* module so we cannot longer uses the typeid() comparisons across modules... It was used by boost::program_options to perform is casts with boost::any and was starting throwing exceptions because of bad casts. program_option was first initialized in "configuration" first included by PyViewer then in PyCRL (see Utilities.cpp). A first solution is to re-order the import of Python modules in stratus1/st_model so that CRL is imported first. The second is to not not link "configuration" with boost::program_option as only the binary vlsisapd-conf-editor needs it. That is a serious problem of which we must be aware and can cause further strange behaviors. Debug code used to diagnostic has been kept commented in the sources a it may be needed again :-( This behavior do not affect our singletons because they are part of dynamic libraries that seems to be correctly shared between the various Python modules. * ./mauka: - Change: In CMakeLists.txt, makes Mauka compliant with OSX (case sensitivity). --- mauka/src/CMakeLists.txt | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/mauka/src/CMakeLists.txt b/mauka/src/CMakeLists.txt index dd658a91..4f94f777 100644 --- a/mauka/src/CMakeLists.txt +++ b/mauka/src/CMakeLists.txt @@ -46,6 +46,7 @@ add_library ( mauka ${cpps} ${mocCpps} ${pyCpps} ) target_link_libraries ( mauka ${METIS_LIBRARIES} ${NIMBUS_LIBRARIES} + ${CORIOLIS_LIBRARIES} ${HURRICANE_PYTHON_LIBRARIES} ${HURRICANE_GRAPHICAL_LIBRARIES} ${HURRICANE_LIBRARIES} @@ -60,13 +61,15 @@ ${PYTHON_LIBRARIES} -lutil ) - add_library ( Mauka MODULE ${pyCpps} ) - set_target_properties ( Mauka PROPERTIES COMPILE_FLAGS "${COMPILE_FLAGS} -D__PYTHON_MODULE__=1" - PREFIX "" + add_library ( pyMauka MODULE ${pyCpps} ) + set_target_properties ( pyMauka PROPERTIES COMPILE_FLAGS "${COMPILE_FLAGS} -D__PYTHON_MODULE__=1" + PREFIX "" + OUTPUT_NAME "Mauka" ) + target_link_libraries ( pyMauka mauka ) install ( TARGETS mauka DESTINATION lib${LIB_SUFFIX} ) - install ( TARGETS Mauka DESTINATION ${PYTHON_SITE_PACKAGES} ) + install ( TARGETS pyMauka DESTINATION ${PYTHON_SITE_PACKAGES} ) install ( FILES ${includes} ${mocIncludes} ${pyIncludes} DESTINATION include/coriolis2/mauka )