cmake_minimum_required ( VERSION 2.6)
+set (CMAKE_SUPPRESS_REGENERATION TRUE)
+
if (NOT BUILD_CONFIGURATION)
set(BUILD_CONFIGURATION "Release" CACHE STRING "Build type of OCCT" FORCE)
SET_PROPERTY(CACHE BUILD_CONFIGURATION PROPERTY STRINGS Release Debug RelWithDebInfo)
set (COMPILER vc10)
elseif (MSVC11)
set (COMPILER vc11)
+ elseif (MSVC12)
+ set (COMPILER vc12)
endif()
elseif (DEFINED CMAKE_COMPILER_IS_GNUCC)
set (COMPILER gcc)
if(WIN32)
add_definitions(/DWNT -wd4996)
elseif(APPLE)
- add_definitions(-fexceptions -fPIC -DOCC_CONVERT_SIGNALS -DHAVE_WOK_CONFIG_H -DHAVE_CONFIG_H)
+ add_definitions(-fexceptions -fPIC -DOCC_CONVERT_SIGNALS)
else()
- add_definitions(-fexceptions -fPIC -DOCC_CONVERT_SIGNALS -DHAVE_WOK_CONFIG_H -DHAVE_CONFIG_H -DLIN)
+ add_definitions(-fexceptions -fPIC -DOCC_CONVERT_SIGNALS -DLIN)
endif()
# enable structured exceptions for MSVC
# add required subdirs
FOREACH(UNSUBDIR ${UNSUBDIRS})
MESSAGE(STATUS "${UNSUBDIR}")
- subdirs(${TK_ROOT_DIR}/${UNSUBDIR})
+ ADD_SUBDIRECTORY (${TK_ROOT_DIR}/${UNSUBDIR})
ENDFOREACH()
ENDIF()
# samples do not support patch usage
IF (BUILD_Samples)
- SET (CMAKE_MFC_FLAG 2)
SET (OCCT_ROOT ${CMAKE_SOURCE_DIR})
SET (MFC_STANDARD_SAMPLES_DIR ${OCCT_ROOT}/samples/mfc/standard)
SET (COMMON_WINMAIN_FILE ${MFC_STANDARD_SAMPLES_DIR}/Common/Winmain.cpp)
- subdirs(samples/mfc/standard/mfcsample)
- subdirs(samples/mfc/standard/01_Geometry)
- subdirs(samples/mfc/standard/02_Modeling)
- subdirs(samples/mfc/standard/03_Viewer2d)
- subdirs(samples/mfc/standard/04_Viewer3d)
- subdirs(samples/mfc/standard/05_ImportExport)
- subdirs(samples/mfc/standard/06_Ocaf)
- subdirs(samples/mfc/standard/07_Triangulation)
- subdirs(samples/mfc/standard/08_HLR)
- subdirs(samples/mfc/standard/09_Animation)
- subdirs(samples/mfc/standard/10_Convert)
+ ADD_SUBDIRECTORY (samples/mfc/standard/mfcsample)
+ ADD_SUBDIRECTORY (samples/mfc/standard/01_Geometry)
+ ADD_SUBDIRECTORY (samples/mfc/standard/02_Modeling)
+ ADD_SUBDIRECTORY (samples/mfc/standard/03_Viewer2d)
+ ADD_SUBDIRECTORY (samples/mfc/standard/04_Viewer3d)
+ ADD_SUBDIRECTORY (samples/mfc/standard/05_ImportExport)
+ ADD_SUBDIRECTORY (samples/mfc/standard/06_Ocaf)
+ ADD_SUBDIRECTORY (samples/mfc/standard/07_Triangulation)
+ ADD_SUBDIRECTORY (samples/mfc/standard/08_HLR)
+ ADD_SUBDIRECTORY (samples/mfc/standard/09_Animation)
+ ADD_SUBDIRECTORY (samples/mfc/standard/10_Convert)
ENDIF()