From: Eduardo Davila Date: Tue, 28 Aug 2018 13:06:21 +0000 (+0200) Subject: #3214 creaFeature New Normal - vtk8itk4wx3-mingw64 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=c08e99c2447c01473c687f3cd518304405f03d83;p=crea.git #3214 creaFeature New Normal - vtk8itk4wx3-mingw64 --- diff --git a/cmake/CREAMacro_FindAndUseWxWidgets.cmake b/cmake/CREAMacro_FindAndUseWxWidgets.cmake index 0c2494f..b10b9f7 100644 --- a/cmake/CREAMacro_FindAndUseWxWidgets.cmake +++ b/cmake/CREAMacro_FindAndUseWxWidgets.cmake @@ -56,8 +56,16 @@ MACRO(CREA_FIND_WXWIDGETS) ELSE(WIN32) MESSAGE ( "===============Manual wx-config 3 EED =======================") + +##2018-08-28 +if(APPLE) SET(wxWidgets_CONFIG_EXECUTABLE /usr/bin/wx-config-3.0 CACHE STRING wxWidgets_CONFIG_EXECUTABLE FORCE) SET(wxWidgets_wxrc_EXECUTABLE /usr/bin/wxrc-3.0 CACHE STRING wxWidgets_wxrc_EXECUTABLE FORCE) +elseif(UNIX) + SET(wxWidgets_CONFIG_EXECUTABLE /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxGTK/3.0/bin/wx-config CACHE STRING wxWidgets_CONFIG_EXECUTABLE FORCE) + SET(wxWidgets_wxrc_EXECUTABLE /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxGTK/3.0/bin/wxrc-3.0 CACHE STRING wxWidgets_wxrc_EXECUTABLE FORCE) +endif() + # MESSAGE ( "===============Manual wx-config 2 EED =======================") # SET(wxWidgets_CONFIG_EXECUTABLE /usr/bin/wx-config-2.0 CACHE STRING wxWidgets_CONFIG_EXECUTABLE FORCE) @@ -79,7 +87,7 @@ MACRO(CREA_FIND_WXWIDGETS) SET(WXAUILIBS "aui") # LG : These options should be set by the user at top level of crea - FIND_PACKAGE(wxWidgets COMPONENTS base core adv html + FIND_PACKAGE(wxWidgets REQUIRED COMPONENTS base core adv html ${WXAUILIBS} ${WXGLCANVASLIBS}) # @@ -91,6 +99,7 @@ MACRO(CREA_FIND_WXWIDGETS) ENDIF(NOT wxWidgets_FOUND) ENDIF(WIN32) +MESSAGE ( "EEEE") ENDMACRO(CREA_FIND_WXWIDGETS) @@ -131,6 +140,8 @@ MACRO(CREA_USE_WXWIDGETS) "${wxWidgets_LIB_DIR}/libwxmsw30u_html.a" "${wxWidgets_LIB_DIR}/libwxmsw30u_adv.a" ) ELSE(WIN32) + + ## # GTK2 ## INCLUDE_DIRECTORIES(${GTK2_INCLUDE_DIRS}) ## LINK_DIRECTORIES(${GTK2_LIBRARY_DIRS}) @@ -141,7 +152,6 @@ MACRO(CREA_USE_WXWIDGETS) LINK_LIBRARIES(${GTK3_LIBRARIES} ) # WX - # INCLUDE( ${GTK_USE_FILE} ) INCLUDE( ${wxWidgets_USE_FILE} ) MARK_AS_ADVANCED(wxWidgets_CONFIG_EXECUTABLE) @@ -151,8 +161,7 @@ MACRO(CREA_USE_WXWIDGETS) ## ${GTK2_LIBRARIES} ${GTK3_LIBRARIES} #${GTK_LIBRARIES} - - ${wxWidgets_LIBRARIES} + ${wxWidgets_LIBRARIES} ) ENDIF(WIN32) diff --git a/lib/creaDevManagerLib/CDMUtilities.h b/lib/creaDevManagerLib/CDMUtilities.h index 4558c18..2ba3250 100644 --- a/lib/creaDevManagerLib/CDMUtilities.h +++ b/lib/creaDevManagerLib/CDMUtilities.h @@ -63,6 +63,7 @@ namespace CDMUtilities #elif __APPLE__ // ------ Apple //TODO: implementation for apple + static std::string TEXT_EDITOR = "open -e"; #else static std::string TEXT_EDITOR = "gedit"; #endif @@ -76,6 +77,7 @@ namespace CDMUtilities #elif __APPLE__ // ------ Apple //TODO: implementation for apple + static std::string FILE_EXPLORER = "open "; #else static std::string FILE_EXPLORER = "nautilus"; #endif @@ -89,6 +91,7 @@ namespace CDMUtilities #elif __APPLE__ // ------ Apple //TODO: implementation for apple + static std::string TERMINAL = "open -a Terminal "; #else static std::string TERMINAL = "gnome-terminal"; #endif diff --git a/src/creaRTTI.cxx b/src/creaRTTI.cxx index 635d9da..d997215 100644 --- a/src/creaRTTI.cxx +++ b/src/creaRTTI.cxx @@ -62,43 +62,41 @@ namespace crea << " to " << TypeName(target_type) << std::endl); void* target_pointer = 0; -#if __GNUC__ > 3 || \ - (__GNUC__ == 3 && (__GNUC_MINOR__ > 1 || \ - (__GNUC_MINOR__ == 1 && \ - __GNUC_PATCHLEVEL__ > 0))) - - const abi::__class_type_info* targetTI = - (const abi::__class_type_info *)( &(target_type)); + + +#if __APPLE__ +//EED2018-08-28 Be careful #include is not complete (CommandLine mechanisme Xcode) +printf("EED creaRTTI run_time_up_or_down_cast 2018-08-28 Warnning !!!! Apple cast missing __do_upcast ") + return source_pointer; +#else + #if __GNUC__ > 3 || \ + (__GNUC__ == 3 && (__GNUC_MINOR__ > 1 || \ + (__GNUC_MINOR__ == 1 && \ + __GNUC_PATCHLEVEL__ > 0))) + const abi::__class_type_info* targetTI = (const abi::__class_type_info *)( &(target_type)); creaDebugMessage("info",7," * source = "< 1 || \ (__GNUC_MINOR__ == 1 && \ __GNUC_PATCHLEVEL__ > 0))) + #include #include + namespace crea { inline std::string demangle_type_name(const char* name)