]> SALOME platform Git repositories - modules/hydro.git/commitdiff
Salome HOME
tests configuration for Linux and YAMM
authorasl <asl@opencascade.com>
Fri, 3 Nov 2017 08:26:45 +0000 (11:26 +0300)
committerasl <asl@opencascade.com>
Fri, 3 Nov 2017 08:26:45 +0000 (11:26 +0300)
CMakeLists.txt
src/HYDRO_tests/CMakeLists.txt
src/HYDRO_tests/ExternalFiles.cmake

index db56a7c449c33adf07218032b194d18cf8b8dc40..f2d38cf7afdcdbacf5867fc296ffb237300f9af9 100644 (file)
@@ -197,11 +197,11 @@ MARK_AS_ADVANCED(
 # Sources
 # ========
 ADD_SUBDIRECTORY (src/shapelib)
+ADD_SUBDIRECTORY (src/HYDRO_tests)
 ADD_SUBDIRECTORY (src/HYDROData)
 ADD_SUBDIRECTORY (src/HYDROGUI)
 ADD_SUBDIRECTORY (src/HYDROPy)
 ADD_SUBDIRECTORY (src/HYDROTools)
-ADD_SUBDIRECTORY (src/HYDRO_tests)
 IF(SALOME_BUILD_DOC)
   ADD_SUBDIRECTORY(doc)
 ENDIF()
index e446a72cbe8e0b10e93467bddf59674f410ea404..552c119dd5537691cc537cc6802cd4193a679025 100644 (file)
@@ -3,6 +3,8 @@ ADD_SUBDIRECTORY(reference_data)
 include(../../CMake/Common.cmake)
 include(ExternalFiles.cmake)
 
+set (CMAKE_POSITION_INDEPENDENT_CODE ON)
+
 set(PROJECT_HEADERS
   test_HYDROData_Bathymetry.h
   test_HYDROData_Channel.h
@@ -68,7 +70,7 @@ set(PROJECT_SOURCES
   TestLib_Runner.cxx
 )
 
-add_definitions( -DLIGHT_MODE -DHYDRODATA_STATIC -DHYDROGUI_STATIC -DTEST_MODE )
+add_definitions( -DLIGHT_MODE -DHYDRODATA_STATIC -DHYDROGUI_STATIC -DTEST_MODE -DQT_GUI_LIB -DQT_WIDGETS_LIB )
 
 IF( ${WIN32} )
   add_definitions( -DWNT -D__WIN32__ -D__x86__ -D_WIN64 -D_WIN32_WINNT=0x0400 -D__NT__ -D__OSVERSION__=4 )
@@ -87,7 +89,7 @@ IF( ${WIN32} )
 ELSE()
   link_directories( $ENV{CASROOT}/lib $ENV{TBB_ROOT_DIR}/lib/intel64/gcc4.4 )
 ENDIF()
-SET( CAS_LIBRARIES TKernel TKLCAF TKCAF TKCDF TKMath TKG2d TKG3d TKBRep TKGeomBase TKTopAlgo TKGeomAlgo TKBool TKShHealing TKXSBase TKOffset TKHLR TKBO TKV3d TKService TKMesh )
+SET( CAS_LIBRARIES TKernel TKLCAF TKCAF TKCDF TKMath TKG2d TKG3d TKBRep TKGeomBase TKTopAlgo TKGeomAlgo TKBool TKShHealing TKXSBase TKOffset TKHLR TKBO TKV3d TKService TKMesh gl2ps )
 
 link_directories( $ENV{QT_ROOT_DIR}/lib $ENV{QTDIR}/lib )
 IF( ${WIN32} )
@@ -113,7 +115,7 @@ link_directories( $ENV{KERNEL_ROOT_DIR}/lib/salome $ENV{GUI_ROOT_DIR}/lib/salome
 SET( GUI_LIBRARIES ImageComposer qtx suit CAM OCCViewer GraphicsView )
 # Please do not link with LightApp since in the full SALOME it is linked with CORBA (omniORB)
 
-SET( GEOM_LIBRARIES CurveCreator GEOMUtils GEOMUtils )
+SET( GEOM_LIBRARIES CurveCreator GEOMUtils )
 
 link_directories( $ENV{ECWLIB_ROOT_DIR}/lib )
 IF( ${WIN32} )
@@ -138,6 +140,7 @@ include_directories(
 source_group( "External files" FILES ${EXTERNAL_FILES} )
 
 add_executable( HYDROData_tests ${PROJECT_SOURCES} ${PROJECT_HEADERS} ${EXTERNAL_FILES} ${PROJECT_MOC_HEADERS} )
-target_link_libraries( HYDROData_tests ${GUI_LIBRARIES} ${GEOM_LIBRARIES} ${CAS_LIBRARIES} ${QT_LIBRARIES} ${CPPUNIT_LIBRARIES} shapelib HYDROData ${ECW_LIBRARIES} )
+set_target_properties( HYDROData_tests PROPERTIES LINK_INTERFACE_LIBRARIES "" )
+target_link_libraries( HYDROData_tests ${GUI_LIBRARIES} ${GEOM_LIBRARIES} ${CAS_LIBRARIES} ${QT_LIBRARIES} ${CPPUNIT_LIBRARIES} shapelib ${ECW_LIBRARIES} )
 
 INSTALL(TARGETS HYDROData_tests EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_BINS})
index f93423ba664db911f9f4196af8ea2d1eab96b576..8bd6f0efe45ef1ea403d35416592bed92bb27455 100644 (file)
@@ -1,6 +1,7 @@
 
 find_package( Qt5Core )
 find_package( Qt5Widgets )
+set(CMAKE_AUTOMOC ON)
 
 set( EXTERNAL_FILES
   ../HYDROData/HYDROData_AltitudeObject.cxx
@@ -95,4 +96,4 @@ set( MOC_HEADERS
   ../HYDROGUI/HYDROGUI_ViewerDlg.h
 )
 
-QT_WRAP_MOC( PROJECT_MOC_HEADERS ${MOC_HEADERS} )
+#QT5_WRAP_MOC( PROJECT_MOC_HEADERS ${MOC_HEADERS} )