Compare commits
1 Commits
CR26302_2
...
CR0-Intera
Author | SHA1 | Date | |
---|---|---|---|
|
961713db52 |
4
.gitattributes
vendored
@@ -1,8 +1,6 @@
|
|||||||
.gitattributes eol=lf
|
.gitattributes eol=lf
|
||||||
.gitignore eol=lf
|
.gitignore eol=lf
|
||||||
*.txt eol=lf
|
*.txt eol=lf
|
||||||
*.htm eol=lf
|
|
||||||
*.html eol=lf
|
|
||||||
*.h eol=lf
|
*.h eol=lf
|
||||||
*.c eol=lf
|
*.c eol=lf
|
||||||
*.inl eol=lf
|
*.inl eol=lf
|
||||||
@@ -31,7 +29,6 @@
|
|||||||
*.xib eol=lf
|
*.xib eol=lf
|
||||||
*.plist eol=lf
|
*.plist eol=lf
|
||||||
*.java eol=lf
|
*.java eol=lf
|
||||||
*.js eol=lf
|
|
||||||
*.igs eol=lf
|
*.igs eol=lf
|
||||||
*.iges eol=lf
|
*.iges eol=lf
|
||||||
*.stp eol=lf
|
*.stp eol=lf
|
||||||
@@ -47,7 +44,6 @@
|
|||||||
FILES eol=lf
|
FILES eol=lf
|
||||||
PACKAGES eol=lf
|
PACKAGES eol=lf
|
||||||
EXTERNLIB eol=lf
|
EXTERNLIB eol=lf
|
||||||
EXTERNLIB_STATIC eol=lf
|
|
||||||
UDLIST eol=lf
|
UDLIST eol=lf
|
||||||
tests/* eol=lf
|
tests/* eol=lf
|
||||||
tests/*/* eol=lf
|
tests/*/* eol=lf
|
||||||
|
6
.gitignore
vendored
@@ -12,6 +12,12 @@
|
|||||||
win32
|
win32
|
||||||
win64
|
win64
|
||||||
|
|
||||||
|
# standard names of directories for objects and binaries for samples
|
||||||
|
bin
|
||||||
|
obj
|
||||||
|
Debug
|
||||||
|
Release
|
||||||
|
|
||||||
# project files and artifacts
|
# project files and artifacts
|
||||||
/adm/msvc
|
/adm/msvc
|
||||||
/adm/wnt
|
/adm/wnt
|
||||||
|
227
CMakeLists.txt
@@ -91,16 +91,6 @@ if (NOT DEFINED BUILD_RELEASE_DISABLE_EXCEPTIONS)
|
|||||||
set (BUILD_RELEASE_DISABLE_EXCEPTIONS ON CACHE BOOL "${BUILD_RELEASE_DISABLE_EXCEPTIONS_DESCR}")
|
set (BUILD_RELEASE_DISABLE_EXCEPTIONS ON CACHE BOOL "${BUILD_RELEASE_DISABLE_EXCEPTIONS_DESCR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (MSVC)
|
|
||||||
set (BUILD_FORCE_RelWithDebInfo OFF CACHE BOOL "${BUILD_FORCE_RelWithDebInfo_DESCR}")
|
|
||||||
else()
|
|
||||||
set (BUILD_FORCE_RelWithDebInfo OFF)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (BUILD_FORCE_RelWithDebInfo)
|
|
||||||
set (CMAKE_CONFIGURATION_TYPES Release Debug CACHE INTERNAL "" FORCE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# option to enable or disable use of precompiled headers
|
# option to enable or disable use of precompiled headers
|
||||||
if (NOT DEFINED BUILD_USE_PCH)
|
if (NOT DEFINED BUILD_USE_PCH)
|
||||||
set (BUILD_USE_PCH OFF CACHE BOOL "${BUILD_USE_PCH_DESCR}")
|
set (BUILD_USE_PCH OFF CACHE BOOL "${BUILD_USE_PCH_DESCR}")
|
||||||
@@ -229,7 +219,7 @@ if (NOT DEFINED INSTALL_DIR_BIN)
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# define folder containing all shell/batch scripts
|
# define folder contaning all shell/batch scripts
|
||||||
if (NOT DEFINED INSTALL_DIR_SCRIPT)
|
if (NOT DEFINED INSTALL_DIR_SCRIPT)
|
||||||
if ("${INSTALL_DIR_LAYOUT}" STREQUAL "Unix")
|
if ("${INSTALL_DIR_LAYOUT}" STREQUAL "Unix")
|
||||||
set (INSTALL_DIR_SCRIPT "${INSTALL_DIR_BIN}" CACHE PATH "${INSTALL_DIR_SCRIPT_DESCR}")
|
set (INSTALL_DIR_SCRIPT "${INSTALL_DIR_BIN}" CACHE PATH "${INSTALL_DIR_SCRIPT_DESCR}")
|
||||||
@@ -321,7 +311,7 @@ if (NOT DEFINED INSTALL_DIR_DOC)
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# define folder containing CMake configuration files
|
# define folder contaning CMake configuration files
|
||||||
if (NOT DEFINED INSTALL_DIR_CMAKE)
|
if (NOT DEFINED INSTALL_DIR_CMAKE)
|
||||||
if ("${INSTALL_DIR_LAYOUT}" STREQUAL "Unix")
|
if ("${INSTALL_DIR_LAYOUT}" STREQUAL "Unix")
|
||||||
if (INSTALL_DIR_WITH_VERSION)
|
if (INSTALL_DIR_WITH_VERSION)
|
||||||
@@ -374,28 +364,12 @@ if (MSVC)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
# whether use optional 3rdparty or not
|
# whether use optional 3rdparty or not
|
||||||
set (USE_TK ON CACHE BOOL "${USE_TK_DESCR}")
|
if (APPLE)
|
||||||
set (USE_FREETYPE ON CACHE BOOL "${USE_FREETYPE_DESCR}")
|
set (USE_GLX OFF CACHE BOOL "${USE_GLX_DESCR}")
|
||||||
set (USE_FREEIMAGE OFF CACHE BOOL "${USE_FREEIMAGE_DESCR}")
|
|
||||||
set (USE_FFMPEG OFF CACHE BOOL "${USE_FFMPEG_DESCR}")
|
|
||||||
set (USE_OPENVR OFF CACHE BOOL "${USE_OPENVR_DESCR}")
|
|
||||||
set (USE_RAPIDJSON OFF CACHE BOOL "${USE_RAPIDJSON_DESCR}")
|
|
||||||
set (USE_DRACO OFF CACHE BOOL "${USE_DRACO_DESCR}")
|
|
||||||
set (USE_TBB OFF CACHE BOOL "${USE_TBB_DESCR}")
|
|
||||||
set (USE_EIGEN OFF CACHE BOOL "${USE_EIGEN_DESCR}")
|
|
||||||
|
|
||||||
if (WIN32 OR ANDROID OR IOS OR EMSCRIPTEN)
|
|
||||||
# no Xlib
|
|
||||||
elseif (APPLE)
|
|
||||||
set (USE_XLIB OFF CACHE BOOL "${USE_XLIB_DESCR}")
|
|
||||||
else()
|
|
||||||
set (USE_XLIB ON CACHE BOOL "${USE_XLIB_DESCR}")
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
set (USE_D3D OFF CACHE BOOL "${USE_D3D_DESCR}")
|
set (USE_D3D OFF CACHE BOOL "${USE_D3D_DESCR}")
|
||||||
else()
|
|
||||||
set (USE_D3D OFF)
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Enable/Disable the floating point exceptions (FPE) during runtime.
|
# Enable/Disable the floating point exceptions (FPE) during runtime.
|
||||||
@@ -409,15 +383,6 @@ else()
|
|||||||
set (BUILD_ENABLE_FPE_SIGNAL_HANDLER 0)
|
set (BUILD_ENABLE_FPE_SIGNAL_HANDLER 0)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# OpenGL
|
|
||||||
if (ANDROID OR IOS OR EMSCRIPTEN OR "${CMAKE_SYSTEM_NAME}" STREQUAL "WindowsStore")
|
|
||||||
set (USE_OPENGL OFF)
|
|
||||||
set (USE_GLES2 ON)
|
|
||||||
else()
|
|
||||||
set (USE_OPENGL ON CACHE BOOL "${USE_OPENGL_DESCR}")
|
|
||||||
set (USE_GLES2 OFF CACHE BOOL "${USE_GLES2_DESCR}")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# include the patched or original list of modules
|
# include the patched or original list of modules
|
||||||
# list <MODULENAME>_TOOLKITS is created foreach module and contains its toolkits
|
# list <MODULENAME>_TOOLKITS is created foreach module and contains its toolkits
|
||||||
# list <OCCT_MODULES> will contain all modules
|
# list <OCCT_MODULES> will contain all modules
|
||||||
@@ -449,6 +414,10 @@ if (NOT DEFINED BUILD_DOC_Overview)
|
|||||||
set (BUILD_DOC_Overview ${CAN_DOXYGEN_BE_USED} CACHE BOOL "${BUILD_DOC_Overview_DESCR}")
|
set (BUILD_DOC_Overview ${CAN_DOXYGEN_BE_USED} CACHE BOOL "${BUILD_DOC_Overview_DESCR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if (NOT USE_D3D)
|
||||||
|
list (REMOVE_ITEM Visualization_TOOLKITS TKD3DHost)
|
||||||
|
endif()
|
||||||
|
|
||||||
# accumulate used toolkits (first level) in BUILD_TOOLKITS variable
|
# accumulate used toolkits (first level) in BUILD_TOOLKITS variable
|
||||||
list (APPEND BUILD_TOOLKITS ${BUILD_ADDITIONAL_TOOLKITS})
|
list (APPEND BUILD_TOOLKITS ${BUILD_ADDITIONAL_TOOLKITS})
|
||||||
|
|
||||||
@@ -458,6 +427,12 @@ foreach (OCCT_MODULE ${OCCT_MODULES})
|
|||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
|
# DRAWEXE excluded when library build is static
|
||||||
|
if (NOT BUILD_SHARED_LIBS)
|
||||||
|
list (REMOVE_ITEM BUILD_TOOLKITS DRAWEXE)
|
||||||
|
message (STATUS "Info: DRAWEXE is not included due to ${BUILD_LIBRARY_TYPE} build library type")
|
||||||
|
endif()
|
||||||
|
|
||||||
# accumulate all used toolkits
|
# accumulate all used toolkits
|
||||||
list (REMOVE_DUPLICATES BUILD_TOOLKITS)
|
list (REMOVE_DUPLICATES BUILD_TOOLKITS)
|
||||||
set (RAW_BUILD_TOOLKITS)
|
set (RAW_BUILD_TOOLKITS)
|
||||||
@@ -509,70 +484,35 @@ endif()
|
|||||||
# search for CSF variable in EXTERNLIB of each being used toolkit
|
# search for CSF variable in EXTERNLIB of each being used toolkit
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_FreeImagePlus CAN_USE_FREEIMAGE)
|
OCCT_IS_PRODUCT_REQUIRED (CSF_FreeImagePlus CAN_USE_FREEIMAGE)
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_TclLibs USE_TCL)
|
OCCT_IS_PRODUCT_REQUIRED (CSF_TclLibs USE_TCL)
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_TclTkLibs CAN_USE_TK)
|
OCCT_IS_PRODUCT_REQUIRED (CSF_FREETYPE USE_FREETYPE)
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_XwLibs CAN_USE_XLIB)
|
OCCT_IS_PRODUCT_REQUIRED (CSF_OpenGlLibs CAN_USE_GLES2)
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_FREETYPE CAN_USE_FREETYPE)
|
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_OpenGlLibs CAN_USE_OPENGL)
|
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_OpenGlesLibs CAN_USE_GLES2)
|
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_TBB CAN_USE_TBB)
|
OCCT_IS_PRODUCT_REQUIRED (CSF_TBB CAN_USE_TBB)
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_EIGEN CAN_USE_EIGEN)
|
OCCT_IS_PRODUCT_REQUIRED (CSF_EIGEN CAN_USE_EIGEN)
|
||||||
|
|
||||||
# define CSF variable
|
# define CSF variable
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/occt_csf")
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/occt_csf")
|
||||||
|
|
||||||
# Tcl (mandatory for Draw Harness)
|
|
||||||
if (USE_TCL)
|
if (USE_TCL)
|
||||||
message (STATUS "Info: TCL is used by OCCT")
|
message (STATUS "Info: TCL is used by OCCT")
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/tcl")
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/tcl")
|
||||||
|
|
||||||
|
message (STATUS "Info: TK is used by OCCT")
|
||||||
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/tk")
|
||||||
else()
|
else()
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_TCL")
|
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_TCL")
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_TCL")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# Tk (optional for Draw Harness)
|
|
||||||
if (CAN_USE_TK)
|
|
||||||
if (USE_TK)
|
|
||||||
message (STATUS "Info: TK is used by OCCT")
|
|
||||||
add_definitions (-DHAVE_TK)
|
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/tk")
|
|
||||||
else()
|
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_TK")
|
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_TK")
|
|
||||||
endif()
|
|
||||||
else()
|
|
||||||
OCCT_CHECK_AND_UNSET ("USE_TK")
|
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_TK")
|
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_TK")
|
||||||
|
|
||||||
|
OCCT_CHECK_AND_UNSET ("INSTALL_TCL")
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_TK")
|
OCCT_CHECK_AND_UNSET ("INSTALL_TK")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Xlib
|
if (USE_FREETYPE)
|
||||||
if (CAN_USE_XLIB)
|
message (STATUS "Info: Freetype is used by OCCT")
|
||||||
if (USE_XLIB)
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/freetype")
|
||||||
message (STATUS "Info: Xlib is used by OCCT")
|
|
||||||
add_definitions (-DHAVE_XLIB)
|
|
||||||
if (APPLE)
|
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/glx")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
else()
|
else()
|
||||||
OCCT_CHECK_AND_UNSET ("USE_XLIB")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# FreeType
|
|
||||||
if (CAN_USE_FREETYPE)
|
|
||||||
if (USE_FREETYPE)
|
|
||||||
message (STATUS "Info: FreeType is used by OCCT")
|
|
||||||
add_definitions (-DHAVE_FREETYPE)
|
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/freetype")
|
|
||||||
else()
|
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_FREETYPE")
|
|
||||||
OCCT_CHECK_AND_UNSET ("3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2")
|
|
||||||
OCCT_CHECK_AND_UNSET ("3RDPARTY_FREETYPE_INCLUDE_DIR_ft2build")
|
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_FREETYPE")
|
|
||||||
endif()
|
|
||||||
else()
|
|
||||||
OCCT_CHECK_AND_UNSET ("USE_FREETYPE")
|
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_FREETYPE")
|
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_FREETYPE")
|
||||||
|
OCCT_CHECK_AND_UNSET ("3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2")
|
||||||
|
OCCT_CHECK_AND_UNSET ("3RDPARTY_FREETYPE_INCLUDE_DIR_ft2build")
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_FREETYPE")
|
OCCT_CHECK_AND_UNSET ("INSTALL_FREETYPE")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -592,8 +532,25 @@ else()
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
# D3D
|
||||||
|
if (USE_D3D)
|
||||||
|
add_definitions (-DHAVE_D3D)
|
||||||
|
#if(MSVC_VERSION LESS 1700)
|
||||||
|
#OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/d3d")
|
||||||
|
#endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
# GLX
|
||||||
|
if (USE_GLX)
|
||||||
|
add_definitions (-DMACOSX_USE_GLX)
|
||||||
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/glx")
|
||||||
|
endif()
|
||||||
|
|
||||||
# FREEIMAGE
|
# FREEIMAGE
|
||||||
|
|
||||||
if (CAN_USE_FREEIMAGE)
|
if (CAN_USE_FREEIMAGE)
|
||||||
|
set (USE_FREEIMAGE OFF CACHE BOOL "${USE_FREEIMAGE_DESCR}")
|
||||||
|
|
||||||
if (USE_FREEIMAGE)
|
if (USE_FREEIMAGE)
|
||||||
add_definitions (-DHAVE_FREEIMAGE)
|
add_definitions (-DHAVE_FREEIMAGE)
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/freeimage")
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/freeimage")
|
||||||
@@ -608,29 +565,13 @@ else()
|
|||||||
OCCT_CHECK_AND_UNSET ("INSTALL_FREEIMAGE")
|
OCCT_CHECK_AND_UNSET ("INSTALL_FREEIMAGE")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# OpenVR
|
|
||||||
# search for CSF_OpenVR variable in EXTERNLIB of each being used toolkit
|
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_OpenVR CAN_USE_OPENVR)
|
|
||||||
if (CAN_USE_OPENVR)
|
|
||||||
if (USE_OPENVR)
|
|
||||||
add_definitions (-DHAVE_OPENVR)
|
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/openvr")
|
|
||||||
else()
|
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_OPENVR")
|
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_OPENVR")
|
|
||||||
endif()
|
|
||||||
else()
|
|
||||||
OCCT_CHECK_AND_UNSET ("USE_OPENVR")
|
|
||||||
|
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_OPENVR")
|
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_OPENVR")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# FFmpeg
|
# FFmpeg
|
||||||
# search for CSF_FFmpeg variable in EXTERNLIB of each being used toolkit
|
# search for CSF_FFmpeg variable in EXTERNLIB of each being used toolkit
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_FFmpeg CAN_USE_FFMPEG)
|
OCCT_IS_PRODUCT_REQUIRED (CSF_FFmpeg CAN_USE_FFMPEG)
|
||||||
|
|
||||||
if (CAN_USE_FFMPEG)
|
if (CAN_USE_FFMPEG)
|
||||||
|
set (USE_FFMPEG OFF CACHE BOOL "${USE_FFMPEG_DESCR}")
|
||||||
|
|
||||||
if (USE_FFMPEG)
|
if (USE_FFMPEG)
|
||||||
add_definitions (-DHAVE_FFMPEG)
|
add_definitions (-DHAVE_FFMPEG)
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/ffmpeg")
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/ffmpeg")
|
||||||
@@ -645,31 +586,23 @@ else()
|
|||||||
OCCT_CHECK_AND_UNSET ("INSTALL_FFMPEG")
|
OCCT_CHECK_AND_UNSET ("INSTALL_FFMPEG")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# OpenGL
|
|
||||||
if (CAN_USE_OPENGL)
|
|
||||||
if (USE_OPENGL)
|
|
||||||
add_definitions (-DHAVE_OPENGL_EXT)
|
|
||||||
else()
|
|
||||||
list (REMOVE_ITEM BUILD_TOOLKITS TKOpenGl)
|
|
||||||
list (REMOVE_ITEM BUILD_TOOLKITS TKOpenGlTest)
|
|
||||||
endif()
|
|
||||||
else()
|
|
||||||
OCCT_CHECK_AND_UNSET ("USE_OPENGL")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# OpenGL ES 2.0
|
# OpenGL ES 2.0
|
||||||
if (CAN_USE_GLES2)
|
if (CAN_USE_GLES2)
|
||||||
|
if ("${CMAKE_SYSTEM_NAME}" STREQUAL "WindowsStore")
|
||||||
|
set (USE_GLES2 ON)
|
||||||
|
else()
|
||||||
|
set (USE_GLES2 OFF CACHE BOOL "${USE_GLES2_DESCR}")
|
||||||
|
endif()
|
||||||
|
|
||||||
if (USE_GLES2)
|
if (USE_GLES2)
|
||||||
add_definitions (-DHAVE_GLES2_EXT)
|
add_definitions (-DHAVE_GLES2)
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/egl")
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/egl")
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/gles2")
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/gles2")
|
||||||
else()
|
else()
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_EGL")
|
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_EGL")
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_GLES2")
|
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_GLES2")
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_EGL")
|
OCCT_CHECK_AND_UNSET ("INSTALL_EGL")
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_GLES2")
|
OCCT_CHECK_AND_UNSET ("INSTALL_GLES2")
|
||||||
list (REMOVE_ITEM BUILD_TOOLKITS TKOpenGles)
|
|
||||||
list (REMOVE_ITEM BUILD_TOOLKITS TKOpenGlesTest)
|
|
||||||
endif()
|
endif()
|
||||||
else()
|
else()
|
||||||
OCCT_CHECK_AND_UNSET ("USE_GLES2")
|
OCCT_CHECK_AND_UNSET ("USE_GLES2")
|
||||||
@@ -680,19 +613,10 @@ else()
|
|||||||
OCCT_CHECK_AND_UNSET ("INSTALL_GLES2")
|
OCCT_CHECK_AND_UNSET ("INSTALL_GLES2")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# D3D
|
|
||||||
if (USE_D3D)
|
|
||||||
add_definitions (-DHAVE_D3D)
|
|
||||||
#if(MSVC_VERSION LESS 1700)
|
|
||||||
#OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/d3d")
|
|
||||||
#endif()
|
|
||||||
else()
|
|
||||||
list (REMOVE_ITEM BUILD_TOOLKITS TKD3DHost)
|
|
||||||
list (REMOVE_ITEM BUILD_TOOLKITS TKD3DHostTest)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# TBB
|
# TBB
|
||||||
if (NOT DEFINED ANDROID AND CAN_USE_TBB)
|
if (NOT DEFINED ANDROID AND CAN_USE_TBB)
|
||||||
|
set (USE_TBB OFF CACHE BOOL "${USE_TBB_DESCR}")
|
||||||
|
|
||||||
if (USE_TBB)
|
if (USE_TBB)
|
||||||
add_definitions (-DHAVE_TBB)
|
add_definitions (-DHAVE_TBB)
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/tbb")
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/tbb")
|
||||||
@@ -713,6 +637,8 @@ endif()
|
|||||||
# search for CSF_RapidJSON variable in EXTERNLIB of each being used toolkit
|
# search for CSF_RapidJSON variable in EXTERNLIB of each being used toolkit
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_RapidJSON CAN_USE_RAPIDJSON)
|
OCCT_IS_PRODUCT_REQUIRED (CSF_RapidJSON CAN_USE_RAPIDJSON)
|
||||||
if (CAN_USE_RAPIDJSON)
|
if (CAN_USE_RAPIDJSON)
|
||||||
|
set (USE_RAPIDJSON OFF CACHE BOOL "${USE_RAPIDJSON_DESCR}")
|
||||||
|
|
||||||
if (USE_RAPIDJSON)
|
if (USE_RAPIDJSON)
|
||||||
add_definitions (-DHAVE_RAPIDJSON)
|
add_definitions (-DHAVE_RAPIDJSON)
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/rapidjson")
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/rapidjson")
|
||||||
@@ -727,26 +653,10 @@ else()
|
|||||||
OCCT_CHECK_AND_UNSET ("INSTALL_RAPIDJSON")
|
OCCT_CHECK_AND_UNSET ("INSTALL_RAPIDJSON")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Draco library
|
|
||||||
# search for CSF_Draco variable in EXTERNLIB of each being used toolkit
|
|
||||||
OCCT_IS_PRODUCT_REQUIRED (CSF_Draco CAN_USE_DRACO)
|
|
||||||
if (CAN_USE_DRACO)
|
|
||||||
if (USE_DRACO)
|
|
||||||
add_definitions (-DHAVE_DRACO)
|
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/draco")
|
|
||||||
else()
|
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_DRACO")
|
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_DRACO")
|
|
||||||
endif()
|
|
||||||
else()
|
|
||||||
OCCT_CHECK_AND_UNSET ("USE_DRACO")
|
|
||||||
|
|
||||||
OCCT_CHECK_AND_UNSET_GROUP ("3RDPARTY_DRACO")
|
|
||||||
OCCT_CHECK_AND_UNSET ("INSTALL_DRACO")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# EIGEN
|
# EIGEN
|
||||||
if (CAN_USE_EIGEN)
|
if (CAN_USE_EIGEN)
|
||||||
|
set (USE_EIGEN OFF CACHE BOOL "${USE_EIGEN_DESCR}")
|
||||||
|
|
||||||
if (USE_EIGEN)
|
if (USE_EIGEN)
|
||||||
add_definitions (-DHAVE_EIGEN)
|
add_definitions (-DHAVE_EIGEN)
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/eigen")
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/eigen")
|
||||||
@@ -939,11 +849,9 @@ if (INSTALL_SAMPLES)
|
|||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/java" "${INSTALL_DIR_SAMPLES}")
|
OCCT_INSTALL_FILE_OR_DIR ("samples/java" "${INSTALL_DIR_SAMPLES}")
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/ocafsamples" "${INSTALL_DIR_SAMPLES}")
|
OCCT_INSTALL_FILE_OR_DIR ("samples/ocafsamples" "${INSTALL_DIR_SAMPLES}")
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/qt" "${INSTALL_DIR_SAMPLES}")
|
OCCT_INSTALL_FILE_OR_DIR ("samples/qt" "${INSTALL_DIR_SAMPLES}")
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/OCCTOverview/code" "${INSTALL_DIR_SAMPLES}/OCCTOverview")
|
|
||||||
|
|
||||||
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SAMPLES}/qt/FuncDemo" RENAME "env.${SCRIPT_EXT}")
|
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SAMPLES}/qt/FuncDemo" RENAME "env.${SCRIPT_EXT}")
|
||||||
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SAMPLES}/qt/IESample" RENAME "env.${SCRIPT_EXT}")
|
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SAMPLES}/qt/IESample" RENAME "env.${SCRIPT_EXT}")
|
||||||
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SAMPLES}/qt/OCCTOverview" RENAME "env.${SCRIPT_EXT}")
|
|
||||||
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SAMPLES}/qt/Tutorial" RENAME "env.${SCRIPT_EXT}")
|
install (FILES "${CMAKE_BINARY_DIR}/env.samples.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SAMPLES}/qt/Tutorial" RENAME "env.${SCRIPT_EXT}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -1022,9 +930,6 @@ if (WIN32)
|
|||||||
OCCT_CONFIGURE ("adm/templates/env.${SCRIPT_EXT}.in" "env.${SCRIPT_EXT}")
|
OCCT_CONFIGURE ("adm/templates/env.${SCRIPT_EXT}.in" "env.${SCRIPT_EXT}")
|
||||||
# install env script
|
# install env script
|
||||||
install (FILES "${CMAKE_BINARY_DIR}/env.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SCRIPT}")
|
install (FILES "${CMAKE_BINARY_DIR}/env.${SCRIPT_EXT}" DESTINATION "${INSTALL_DIR_SCRIPT}")
|
||||||
# copy build.bat and install.bat scripts to CMake binary folder
|
|
||||||
OCCT_COPY_FILE_OR_DIR ("adm/templates/build.bat" "${CMAKE_BINARY_DIR}")
|
|
||||||
OCCT_COPY_FILE_OR_DIR ("adm/templates/install.bat" "${CMAKE_BINARY_DIR}")
|
|
||||||
else()
|
else()
|
||||||
set (SUB_ENV_NAME "env.${SCRIPT_EXT}")
|
set (SUB_ENV_NAME "env.${SCRIPT_EXT}")
|
||||||
set (SUB_ENV_BUILD_NAME "env.install.${SCRIPT_EXT}")
|
set (SUB_ENV_BUILD_NAME "env.install.${SCRIPT_EXT}")
|
||||||
@@ -1057,15 +962,6 @@ if (BUILD_SAMPLES_QT)
|
|||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/${RESOURCE}" "${INSTALL_DIR_RESOURCE}/samples")
|
OCCT_INSTALL_FILE_OR_DIR ("samples/${RESOURCE}" "${INSTALL_DIR_RESOURCE}/samples")
|
||||||
#message("Copy Sample resources: samples/${RESOURCE} into ${INSTALL_DIR_RESOURCE}/samples")
|
#message("Copy Sample resources: samples/${RESOURCE} into ${INSTALL_DIR_RESOURCE}/samples")
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
## Copy sources of OCCTOverview for using in the sample
|
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/OCCTOverview/code/DataExchangeSamples.cxx" "${INSTALL_DIR_SAMPLES}/OCCTOverview/code")
|
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/OCCTOverview/code/OcafSamples.cxx" "${INSTALL_DIR_SAMPLES}/OCCTOverview/code")
|
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/OCCTOverview/code/GeometrySamples.cxx" "${INSTALL_DIR_SAMPLES}/OCCTOverview/code")
|
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/OCCTOverview/code/TopologySamples.cxx" "${INSTALL_DIR_SAMPLES}/OCCTOverview/code")
|
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/OCCTOverview/code/TriangulationSamples.cxx" "${INSTALL_DIR_SAMPLES}/OCCTOverview/code")
|
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/OCCTOverview/code/Viewer2dSamples.cxx" "${INSTALL_DIR_SAMPLES}/OCCTOverview/code")
|
|
||||||
OCCT_INSTALL_FILE_OR_DIR ("samples/OCCTOverview/code/Viewer3dSamples.cxx" "${INSTALL_DIR_SAMPLES}/OCCTOverview/code")
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
|
||||||
@@ -1209,9 +1105,6 @@ foreach (OCCT_TOOLKIT ${BUILD_TOOLKITS})
|
|||||||
endforeach()
|
endforeach()
|
||||||
list (REMOVE_DUPLICATES OCCT_MODULES_ENABLED)
|
list (REMOVE_DUPLICATES OCCT_MODULES_ENABLED)
|
||||||
list (REMOVE_DUPLICATES OCCT_COMPILE_DEFINITIONS)
|
list (REMOVE_DUPLICATES OCCT_COMPILE_DEFINITIONS)
|
||||||
# these macros are defined for specific tookits, not globalwise
|
|
||||||
list (REMOVE_ITEM OCCT_COMPILE_DEFINITIONS HAVE_OPENGL)
|
|
||||||
list (REMOVE_ITEM OCCT_COMPILE_DEFINITIONS HAVE_GLES2)
|
|
||||||
|
|
||||||
# export compile definitions and C/C++ flags for each configuration to OpenCASCADE config files
|
# export compile definitions and C/C++ flags for each configuration to OpenCASCADE config files
|
||||||
foreach (OCCT_CONFIGURATION ${CMAKE_CONFIGURATION_TYPES})
|
foreach (OCCT_CONFIGURATION ${CMAKE_CONFIGURATION_TYPES})
|
||||||
@@ -1265,7 +1158,7 @@ if (WIN32)
|
|||||||
set (SET_OpenCASCADE_WITH_D3D "set (OpenCASCADE_WITH_D3D ${USE_D3D})")
|
set (SET_OpenCASCADE_WITH_D3D "set (OpenCASCADE_WITH_D3D ${USE_D3D})")
|
||||||
endif()
|
endif()
|
||||||
if (APPLE)
|
if (APPLE)
|
||||||
set (SET_OpenCASCADE_WITH_GLX "set (OpenCASCADE_WITH_GLX ${USE_XLIB})")
|
set (SET_OpenCASCADE_WITH_GLX "set (OpenCASCADE_WITH_GLX ${USE_GLX})")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Configure and install cmake config file
|
# Configure and install cmake config file
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
FoundationClasses TKernel TKMath
|
FoundationClasses TKernel TKMath
|
||||||
ModelingData TKG2d TKG3d TKGeomBase TKBRep
|
ModelingData TKG2d TKG3d TKGeomBase TKBRep
|
||||||
ModelingAlgorithms TKGeomAlgo TKTopAlgo TKPrim TKBO TKBool TKHLR TKFillet TKOffset TKFeat TKMesh TKXMesh TKShHealing
|
ModelingAlgorithms TKGeomAlgo TKTopAlgo TKPrim TKBO TKBool TKHLR TKFillet TKOffset TKFeat TKMesh TKXMesh TKShHealing
|
||||||
Visualization TKService TKV3d TKOpenGl TKOpenGles TKMeshVS TKIVtk TKD3DHost
|
Visualization TKService TKV3d TKOpenGl TKMeshVS TKIVtk TKD3DHost
|
||||||
ApplicationFramework TKCDF TKLCAF TKCAF TKBinL TKXmlL TKBin TKXml TKStdL TKStd TKTObj TKBinTObj TKXmlTObj TKVCAF
|
ApplicationFramework TKCDF TKLCAF TKCAF TKBinL TKXmlL TKBin TKXml TKStdL TKStd TKTObj TKBinTObj TKXmlTObj TKVCAF
|
||||||
DataExchange TKXSBase TKSTEPBase TKSTEPAttr TKSTEP209 TKSTEP TKIGES TKXCAF TKXDEIGES TKXDESTEP TKSTL TKVRML TKXmlXCAF TKBinXCAF TKRWMesh
|
DataExchange TKXSBase TKSTEPBase TKSTEPAttr TKSTEP209 TKSTEP TKIGES TKXCAF TKXDEIGES TKXDESTEP TKSTL TKVRML TKXmlXCAF TKBinXCAF TKRWMesh
|
||||||
Draw TKDraw TKTopTest TKOpenGlTest TKOpenGlesTest TKD3DHostTest TKViewerTest TKXSDRAW TKDCAF TKXDEDRAW TKTObjDRAW TKQADraw TKIVtkDraw DRAWEXE
|
Draw TKDraw TKTopTest TKViewerTest TKXSDRAW TKDCAF TKXDEDRAW TKTObjDRAW TKQADraw TKIVtkDraw DRAWEXE
|
||||||
|
@@ -3,7 +3,6 @@ StdResource
|
|||||||
SHMessage
|
SHMessage
|
||||||
Textures
|
Textures
|
||||||
Shaders
|
Shaders
|
||||||
XRResources
|
|
||||||
XSMessage
|
XSMessage
|
||||||
XSTEPResource
|
XSTEPResource
|
||||||
XmlOcafResource
|
XmlOcafResource
|
||||||
|
@@ -1 +1 @@
|
|||||||
qt AndroidQt FuncDemo IESample Tutorial OCCTOverview
|
qt AndroidQt FuncDemo IESample Tutorial
|
@@ -1,3 +1,2 @@
|
|||||||
qt/Common/res/
|
qt/Common/res/
|
||||||
qt/Tutorial/res/
|
qt/Tutorial/res/
|
||||||
qt/OCCTOverview/res/
|
|
@@ -1,4 +1,4 @@
|
|||||||
TModelingData TKShapeView TKMessageModel TKMessageView
|
TModelingData TKShapeView
|
||||||
TVisualization TKView TKVInspector
|
TVisualization TKView TKVInspector
|
||||||
TApplicationFramework TKTreeModel TKTInspectorAPI TKDFBrowser
|
TApplicationFramework TKTreeModel TKTInspectorAPI TKDFBrowser
|
||||||
TTool TKTInspector TKToolsDraw TInspectorEXE
|
TTool TKTInspector TKToolsDraw TInspectorEXE
|
37
adm/UDLIST
@@ -11,6 +11,7 @@ n Expr
|
|||||||
n ExprIntrp
|
n ExprIntrp
|
||||||
n FSD
|
n FSD
|
||||||
n GeomAbs
|
n GeomAbs
|
||||||
|
n MMgt
|
||||||
n Message
|
n Message
|
||||||
n OSD
|
n OSD
|
||||||
n PLib
|
n PLib
|
||||||
@@ -107,7 +108,6 @@ n BRepMesh
|
|||||||
n BRepMeshData
|
n BRepMeshData
|
||||||
n BRepOffset
|
n BRepOffset
|
||||||
n BRepOffsetAPI
|
n BRepOffsetAPI
|
||||||
n BRepPreviewAPI
|
|
||||||
n BRepPrim
|
n BRepPrim
|
||||||
n BRepPrimAPI
|
n BRepPrimAPI
|
||||||
n BRepProj
|
n BRepProj
|
||||||
@@ -197,16 +197,15 @@ t TKPrim
|
|||||||
t TKShHealing
|
t TKShHealing
|
||||||
t TKTopAlgo
|
t TKTopAlgo
|
||||||
t TKXMesh
|
t TKXMesh
|
||||||
|
n InterfaceGraphic
|
||||||
n AIS
|
n AIS
|
||||||
n Aspect
|
n Aspect
|
||||||
n DsgPrs
|
n DsgPrs
|
||||||
n PrsDim
|
|
||||||
n Graphic3d
|
n Graphic3d
|
||||||
n Image
|
n Image
|
||||||
n Media
|
n Media
|
||||||
n MeshVS
|
n MeshVS
|
||||||
n OpenGl
|
n OpenGl
|
||||||
n OpenGles
|
|
||||||
n D3DHost
|
n D3DHost
|
||||||
n Prs3d
|
n Prs3d
|
||||||
n PrsMgr
|
n PrsMgr
|
||||||
@@ -215,17 +214,15 @@ n SelectBasics
|
|||||||
n SelectMgr
|
n SelectMgr
|
||||||
n StdPrs
|
n StdPrs
|
||||||
n StdSelect
|
n StdSelect
|
||||||
|
n TColQuantity
|
||||||
n V3d
|
n V3d
|
||||||
n Wasm
|
|
||||||
n WNT
|
n WNT
|
||||||
n Xw
|
n Xw
|
||||||
n Cocoa
|
n Cocoa
|
||||||
r Textures
|
r Textures
|
||||||
r Shaders
|
r Shaders
|
||||||
r XRResources
|
|
||||||
t TKMeshVS
|
t TKMeshVS
|
||||||
t TKOpenGl
|
t TKOpenGl
|
||||||
t TKOpenGles
|
|
||||||
t TKD3DHost
|
t TKD3DHost
|
||||||
t TKService
|
t TKService
|
||||||
t TKV3d
|
t TKV3d
|
||||||
@@ -328,7 +325,6 @@ n RWStepDimTol
|
|||||||
n RWStepElement
|
n RWStepElement
|
||||||
n RWStepFEA
|
n RWStepFEA
|
||||||
n RWStepGeom
|
n RWStepGeom
|
||||||
n RWStepKinematics
|
|
||||||
n RWStepRepr
|
n RWStepRepr
|
||||||
n RWStepShape
|
n RWStepShape
|
||||||
n RWStepVisual
|
n RWStepVisual
|
||||||
@@ -348,7 +344,6 @@ n StepDimTol
|
|||||||
n StepElement
|
n StepElement
|
||||||
n StepFEA
|
n StepFEA
|
||||||
n StepGeom
|
n StepGeom
|
||||||
n StepKinematics
|
|
||||||
n StepRepr
|
n StepRepr
|
||||||
n StepSelect
|
n StepSelect
|
||||||
n StepShape
|
n StepShape
|
||||||
@@ -406,9 +401,6 @@ n HLRTest
|
|||||||
n MeshTest
|
n MeshTest
|
||||||
n SWDRAW
|
n SWDRAW
|
||||||
n TObjDRAW
|
n TObjDRAW
|
||||||
n OpenGlTest
|
|
||||||
n OpenGlesTest
|
|
||||||
n D3DHostTest
|
|
||||||
n ViewerTest
|
n ViewerTest
|
||||||
n XDEDRAW
|
n XDEDRAW
|
||||||
n XSDRAW
|
n XSDRAW
|
||||||
@@ -420,9 +412,6 @@ t TKDCAF
|
|||||||
t TKDraw
|
t TKDraw
|
||||||
t TKTObjDRAW
|
t TKTObjDRAW
|
||||||
t TKTopTest
|
t TKTopTest
|
||||||
t TKOpenGlTest
|
|
||||||
t TKOpenGlesTest
|
|
||||||
t TKD3DHostTest
|
|
||||||
t TKViewerTest
|
t TKViewerTest
|
||||||
t TKXDEDRAW
|
t TKXDEDRAW
|
||||||
t TKXSDRAW
|
t TKXSDRAW
|
||||||
@@ -454,23 +443,3 @@ t TKRWMesh
|
|||||||
n RWGltf
|
n RWGltf
|
||||||
n RWMesh
|
n RWMesh
|
||||||
n RWObj
|
n RWObj
|
||||||
n DFBrowser
|
|
||||||
n DFBrowserPane
|
|
||||||
n DFBrowserPaneXDE
|
|
||||||
n ShapeView
|
|
||||||
n TInspector
|
|
||||||
n TInspectorAPI
|
|
||||||
x TInspectorEXE
|
|
||||||
t TKDFBrowser
|
|
||||||
t TKShapeView
|
|
||||||
t TKTInspector
|
|
||||||
t TKTInspectorAPI
|
|
||||||
t TKToolsDraw
|
|
||||||
t TKTreeModel
|
|
||||||
t TKView
|
|
||||||
t TKVInspector
|
|
||||||
n ToolsDraw
|
|
||||||
n TreeModel
|
|
||||||
n View
|
|
||||||
n ViewControl
|
|
||||||
n VInspector
|
|
||||||
|
@@ -97,12 +97,12 @@ macro (THIRDPARTY_PRODUCT PRODUCT_NAME HEADER_NAME LIBRARY_CSF_NAME LIBRARY_NAME
|
|||||||
if (3RDPARTY_${PRODUCT_NAME}_DIR AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DIR}")
|
if (3RDPARTY_${PRODUCT_NAME}_DIR AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DIR}")
|
||||||
find_path (3RDPARTY_${PRODUCT_NAME}_INCLUDE_DIR NAMES ${HEADER_NAME}
|
find_path (3RDPARTY_${PRODUCT_NAME}_INCLUDE_DIR NAMES ${HEADER_NAME}
|
||||||
PATHS ${3RDPARTY_${PRODUCT_NAME}_DIR}
|
PATHS ${3RDPARTY_${PRODUCT_NAME}_DIR}
|
||||||
PATH_SUFFIXES include inc headers
|
PATH_SUFFIXES include inc
|
||||||
CMAKE_FIND_ROOT_PATH_BOTH
|
CMAKE_FIND_ROOT_PATH_BOTH
|
||||||
NO_DEFAULT_PATH)
|
NO_DEFAULT_PATH)
|
||||||
else()
|
else()
|
||||||
find_path (3RDPARTY_${PRODUCT_NAME}_INCLUDE_DIR NAMES ${HEADER_NAME}
|
find_path (3RDPARTY_${PRODUCT_NAME}_INCLUDE_DIR NAMES ${HEADER_NAME}
|
||||||
PATH_SUFFIXES include inc headers
|
PATH_SUFFIXES include inc
|
||||||
CMAKE_FIND_ROOT_PATH_BOTH)
|
CMAKE_FIND_ROOT_PATH_BOTH)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
@@ -125,14 +125,10 @@ macro (THIRDPARTY_PRODUCT PRODUCT_NAME HEADER_NAME LIBRARY_CSF_NAME LIBRARY_NAME
|
|||||||
set (${PRODUCT_NAME}_PATH_SUFFIXES lib)
|
set (${PRODUCT_NAME}_PATH_SUFFIXES lib)
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
set (${PRODUCT_NAME}_PATH_SUFFIXES ${${PRODUCT_NAME}_PATH_SUFFIXES} win${COMPILER_BITNESS}/${COMPILER}/lib)
|
set (${PRODUCT_NAME}_PATH_SUFFIXES ${${PRODUCT_NAME}_PATH_SUFFIXES} win${COMPILER_BITNESS}/${COMPILER}/lib)
|
||||||
set (${PRODUCT_NAME}_PATH_SUFFIXES ${${PRODUCT_NAME}_PATH_SUFFIXES} lib/win${COMPILER_BITNESS})
|
|
||||||
endif()
|
endif()
|
||||||
if (ANDROID)
|
if (ANDROID)
|
||||||
set (${PRODUCT_NAME}_PATH_SUFFIXES ${${PRODUCT_NAME}_PATH_SUFFIXES} libs/${ANDROID_ABI})
|
set (${PRODUCT_NAME}_PATH_SUFFIXES ${${PRODUCT_NAME}_PATH_SUFFIXES} libs/${ANDROID_ABI})
|
||||||
endif()
|
endif()
|
||||||
if(UNIX AND NOT APPLE AND NOT ANDROID)
|
|
||||||
set (${PRODUCT_NAME}_PATH_SUFFIXES ${${PRODUCT_NAME}_PATH_SUFFIXES} lib/linux${COMPILER_BITNESS})
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# set 3RDPARTY_${PRODUCT_NAME}_LIBRARY as notfound, otherwise find_library can't assign a new value to 3RDPARTY_${PRODUCT_NAME}_LIBRARY
|
# set 3RDPARTY_${PRODUCT_NAME}_LIBRARY as notfound, otherwise find_library can't assign a new value to 3RDPARTY_${PRODUCT_NAME}_LIBRARY
|
||||||
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY_${LIBRARY_NAME_SUFFIX} "3RDPARTY_${PRODUCT_NAME}_LIBRARY_${LIBRARY_NAME_SUFFIX}-NOTFOUND" CACHE FILEPATH "The path to ${PRODUCT_NAME} library \"${LIBRARY_NAME}\"" FORCE)
|
set (3RDPARTY_${PRODUCT_NAME}_LIBRARY_${LIBRARY_NAME_SUFFIX} "3RDPARTY_${PRODUCT_NAME}_LIBRARY_${LIBRARY_NAME_SUFFIX}-NOTFOUND" CACHE FILEPATH "The path to ${PRODUCT_NAME} library \"${LIBRARY_NAME}\"" FORCE)
|
||||||
@@ -188,7 +184,7 @@ macro (THIRDPARTY_PRODUCT PRODUCT_NAME HEADER_NAME LIBRARY_CSF_NAME LIBRARY_NAME
|
|||||||
if ((3RDPARTY_${PRODUCT_NAME}_DIR AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DIR}") OR (3RDPARTY_${PRODUCT_NAME}_DLL_DIR_${LIBRARY_NAME} AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR_${LIBRARY_NAME}}"))
|
if ((3RDPARTY_${PRODUCT_NAME}_DIR AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DIR}") OR (3RDPARTY_${PRODUCT_NAME}_DLL_DIR_${LIBRARY_NAME} AND EXISTS "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR_${LIBRARY_NAME}}"))
|
||||||
find_library (3RDPARTY_${PRODUCT_NAME}_DLL_${LIBRARY_NAME_SUFFIX} NAMES ${LIBRARY_NAME}
|
find_library (3RDPARTY_${PRODUCT_NAME}_DLL_${LIBRARY_NAME_SUFFIX} NAMES ${LIBRARY_NAME}
|
||||||
PATHS "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR_${LIBRARY_NAME}}" "${3RDPARTY_${PRODUCT_NAME}_DIR}"
|
PATHS "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR_${LIBRARY_NAME}}" "${3RDPARTY_${PRODUCT_NAME}_DIR}"
|
||||||
PATH_SUFFIXES bin win${COMPILER_BITNESS}/${COMPILER}/bin bin/win${COMPILER_BITNESS}
|
PATH_SUFFIXES bin win${COMPILER_BITNESS}/${COMPILER}/bin
|
||||||
NO_DEFAULT_PATH)
|
NO_DEFAULT_PATH)
|
||||||
if (3RDPARTY_${PRODUCT_NAME}_DLL_${LIBRARY_NAME_SUFFIX} STREQUAL "3RDPARTY_${PRODUCT_NAME}_DLL_${LIBRARY_NAME_SUFFIX}-NOTFOUND")
|
if (3RDPARTY_${PRODUCT_NAME}_DLL_${LIBRARY_NAME_SUFFIX} STREQUAL "3RDPARTY_${PRODUCT_NAME}_DLL_${LIBRARY_NAME_SUFFIX}-NOTFOUND")
|
||||||
# find directory recursive
|
# find directory recursive
|
||||||
@@ -242,7 +238,6 @@ macro (THIRDPARTY_PRODUCT PRODUCT_NAME HEADER_NAME LIBRARY_CSF_NAME LIBRARY_NAME
|
|||||||
if (INSTALL_${PRODUCT_NAME})
|
if (INSTALL_${PRODUCT_NAME})
|
||||||
OCCT_MAKE_OS_WITH_BITNESS()
|
OCCT_MAKE_OS_WITH_BITNESS()
|
||||||
OCCT_MAKE_COMPILER_SHORT_NAME()
|
OCCT_MAKE_COMPILER_SHORT_NAME()
|
||||||
set (USED_3RDPARTY_${PRODUCT_NAME}_DIR "")
|
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
if (SINGLE_GENERATOR)
|
if (SINGLE_GENERATOR)
|
||||||
@@ -285,17 +280,14 @@ macro (THIRDPARTY_PRODUCT PRODUCT_NAME HEADER_NAME LIBRARY_CSF_NAME LIBRARY_NAME
|
|||||||
endif()
|
endif()
|
||||||
else()
|
else()
|
||||||
# the library directory for using by the executable
|
# the library directory for using by the executable
|
||||||
foreach (LIBRARY_NAME ${${LIBRARY_CSF_NAME}})
|
foreach (LIBRARY_NAME ${${LIBRARY_CSF_NAME}})
|
||||||
string (REPLACE "." "" LIBRARY_NAME_SUFFIX "${LIBRARY_NAME}")
|
string (REPLACE "." "" LIBRARY_NAME_SUFFIX "${LIBRARY_NAME}")
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
set (USED_3RDPARTY_${PRODUCT_NAME}_DIRS "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR_${LIBRARY_NAME_SUFFIX}};${USED_3RDPARTY_${PRODUCT_NAME}_DIRS}")
|
set (USED_3RDPARTY_${PRODUCT_NAME}_DIRS "${3RDPARTY_${PRODUCT_NAME}_DLL_DIR_${LIBRARY_NAME_SUFFIX}};${USED_3RDPARTY_${PRODUCT_NAME}_DIRS}")
|
||||||
else()
|
else()
|
||||||
set (USED_3RDPARTY_${PRODUCT_NAME}_DIRS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR_${LIBRARY_NAME_SUFFIX}}:${USED_3RDPARTY_${PRODUCT_NAME}_DIRS}")
|
set (USED_3RDPARTY_${PRODUCT_NAME}_DIRS "${3RDPARTY_${PRODUCT_NAME}_LIBRARY_DIR_${LIBRARY_NAME_SUFFIX}}:${USED_3RDPARTY_${PRODUCT_NAME}_DIRS}")
|
||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
if (WIN32)
|
|
||||||
set (USED_3RDPARTY_${PRODUCT_NAME}_DIR ${3RDPARTY_${PRODUCT_NAME}_DLL_DIR_${LIBRARY_NAME_SUFFIX}})
|
|
||||||
endif()
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
mark_as_advanced (3RDPARTY_${PRODUCT_NAME}_LIBRARY_${LIBRARY_NAME_SUFFIX} 3RDPARTY_${PRODUCT_NAME}_DLL_${LIBRARY_NAME_SUFFIX})
|
mark_as_advanced (3RDPARTY_${PRODUCT_NAME}_LIBRARY_${LIBRARY_NAME_SUFFIX} 3RDPARTY_${PRODUCT_NAME}_DLL_${LIBRARY_NAME_SUFFIX})
|
||||||
|
@@ -2,26 +2,19 @@
|
|||||||
|
|
||||||
# execute FindBISON script by "find_package (Bison)" is required to define BISON_TARGET macro
|
# execute FindBISON script by "find_package (Bison)" is required to define BISON_TARGET macro
|
||||||
|
|
||||||
# delete obsolete 3RDPARTY_BISON_EXECUTABLE cache variable (not used anymore)
|
if (NOT DEFINED 3RDPARTY_BISON_EXECUTABLE)
|
||||||
unset (3RDPARTY_BISON_EXECUTABLE CACHE)
|
set (3RDPARTY_BISON_EXECUTABLE "" CACHE FILEPATH "The path to the bison command")
|
||||||
|
|
||||||
# delete BISON_EXECUTABLE cache variable if it is empty, otherwise find_package will fail
|
|
||||||
# without reasonable diagnostic
|
|
||||||
if (NOT BISON_EXECUTABLE OR NOT EXISTS "${BISON_EXECUTABLE}")
|
|
||||||
unset (BISON_EXECUTABLE CACHE)
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Add paths to 3rdparty subfolders containing name "bison" to CMAKE_PROGRAM_PATH variable to make
|
# BISON_EXECUTABLE is required by BISON_TARGET macro and should be defined
|
||||||
# these paths searhed by find_package
|
set (BISON_EXECUTABLE "${3RDPARTY_BISON_EXECUTABLE}" CACHE FILEPATH "path to the bison executable" FORCE)
|
||||||
if (3RDPARTY_DIR)
|
|
||||||
file (GLOB BISON_PATHS LIST_DIRECTORIES true "${3RDPARTY_DIR}/*bison*/")
|
find_package (BISON)
|
||||||
foreach (candidate_path ${BISON_PATHS})
|
|
||||||
if (IS_DIRECTORY ${candidate_path})
|
if (BISON_FOUND)
|
||||||
list (APPEND CMAKE_PROGRAM_PATH ${candidate_path})
|
set (3RDPARTY_BISON_EXECUTABLE "${BISON_EXECUTABLE}" CACHE FILEPATH "The Path to the bison command" FORCE)
|
||||||
endif()
|
|
||||||
endforeach()
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# bison 3.2 is required because it provides options to avoid generation of redundant header
|
if (NOT 3RDPARTY_BISON_EXECUTABLE OR NOT EXISTS "${3RDPARTY_BISON_EXECUTABLE}")
|
||||||
# files and embedding of local paths in the generated code
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_BISON_EXECUTABLE)
|
||||||
find_package (BISON 3.2)
|
endif()
|
@@ -2402,7 +2402,7 @@ function (cotire_setup_target_pch_usage _languages _target _wholeTarget)
|
|||||||
message (STATUS "add_custom_command: TARGET ${_target} PRE_BUILD ${_cmds}")
|
message (STATUS "add_custom_command: TARGET ${_target} PRE_BUILD ${_cmds}")
|
||||||
endif()
|
endif()
|
||||||
# because CMake PRE_BUILD command does not support dependencies,
|
# because CMake PRE_BUILD command does not support dependencies,
|
||||||
# we check dependencies explicitly in cotire script mode when the pre-build action is run
|
# we check dependencies explicity in cotire script mode when the pre-build action is run
|
||||||
add_custom_command(
|
add_custom_command(
|
||||||
TARGET "${_target}"
|
TARGET "${_target}"
|
||||||
PRE_BUILD ${_cmds}
|
PRE_BUILD ${_cmds}
|
||||||
@@ -3017,7 +3017,7 @@ function (cotire_setup_unity_build_target _languages _configurations _target)
|
|||||||
endif()
|
endif()
|
||||||
else()
|
else()
|
||||||
if (_targetAutoMoc OR _targetAutoUic OR _targetAutoRcc)
|
if (_targetAutoMoc OR _targetAutoUic OR _targetAutoRcc)
|
||||||
# depend on the original target's implicitly generated <targetname>_automoc target
|
# depend on the original target's implicity generated <targetname>_automoc target
|
||||||
if (CMAKE_VERSION VERSION_LESS "3.8.0")
|
if (CMAKE_VERSION VERSION_LESS "3.8.0")
|
||||||
add_dependencies(${_unityTargetName} ${_target}_automoc)
|
add_dependencies(${_unityTargetName} ${_target}_automoc)
|
||||||
else()
|
else()
|
||||||
|
@@ -1,4 +0,0 @@
|
|||||||
# Draco - a library for a lossy vertex data compression, used as extension to glTF format.
|
|
||||||
# https://github.com/google/draco
|
|
||||||
|
|
||||||
THIRDPARTY_PRODUCT("DRACO" "draco/compression/decode.h" "CSF_Draco" "")
|
|
@@ -1,3 +1,3 @@
|
|||||||
# EGL
|
# EGL
|
||||||
|
|
||||||
THIRDPARTY_PRODUCT("EGL" "EGL/egl.h" "CSF_OpenGlesLibs" "")
|
THIRDPARTY_PRODUCT("EGL" "EGL/egl.h" "CSF_OpenGlLibs" "")
|
||||||
|
@@ -191,13 +191,13 @@ foreach (LIBRARY_NAME ${CSF_FFmpeg})
|
|||||||
else()
|
else()
|
||||||
install (FILES "${3RDPARTY_FFMPEG_DLL_${LIBRARY_NAME}}"
|
install (FILES "${3RDPARTY_FFMPEG_DLL_${LIBRARY_NAME}}"
|
||||||
CONFIGURATIONS Release
|
CONFIGURATIONS Release
|
||||||
DESTINATION "${INSTALL_DIR}/${OS_WITH_BIT}/${COMPILER}/${INSTALL_DIR_BIN}")
|
DESTINATION "${INSTALL_DIR}/${OS_WITH_BIT}/${COMPILER}/bin")
|
||||||
install (FILES "${3RDPARTY_FFMPEG_DLL_${LIBRARY_NAME}}"
|
install (FILES "${3RDPARTY_FFMPEG_DLL_${LIBRARY_NAME}}"
|
||||||
CONFIGURATIONS RelWithDebInfo
|
CONFIGURATIONS RelWithDebInfo
|
||||||
DESTINATION "${INSTALL_DIR}/${OS_WITH_BIT}/${COMPILER}/${INSTALL_DIR_BIN}i")
|
DESTINATION "${INSTALL_DIR}/${OS_WITH_BIT}/${COMPILER}/bini")
|
||||||
install (FILES "${3RDPARTY_FFMPEG_DLL_${LIBRARY_NAME}}"
|
install (FILES "${3RDPARTY_FFMPEG_DLL_${LIBRARY_NAME}}"
|
||||||
CONFIGURATIONS Debug
|
CONFIGURATIONS Debug
|
||||||
DESTINATION "${INSTALL_DIR}/${OS_WITH_BIT}/${COMPILER}/${INSTALL_DIR_BIN}d")
|
DESTINATION "${INSTALL_DIR}/${OS_WITH_BIT}/${COMPILER}/bind")
|
||||||
endif()
|
endif()
|
||||||
else()
|
else()
|
||||||
get_filename_component(3RDPARTY_FFMPEG_LIBRARY_ABS ${3RDPARTY_FFMPEG_LIBRARY_${LIBRARY_NAME}} REALPATH)
|
get_filename_component(3RDPARTY_FFMPEG_LIBRARY_ABS ${3RDPARTY_FFMPEG_LIBRARY_${LIBRARY_NAME}} REALPATH)
|
||||||
|
@@ -2,34 +2,19 @@
|
|||||||
|
|
||||||
# execute FindFLEX script by "find_package (Flex)" is required to define FLEX_TARGET macro
|
# execute FindFLEX script by "find_package (Flex)" is required to define FLEX_TARGET macro
|
||||||
|
|
||||||
# delete obsolete 3RDPARTY_FLEX_EXECUTABLE cache variable (not used anymore)
|
if (NOT DEFINED 3RDPARTY_FLEX_EXECUTABLE)
|
||||||
unset (3RDPARTY_FLEX_EXECUTABLE CACHE)
|
set (3RDPARTY_FLEX_EXECUTABLE "" CACHE FILEPATH "The Path to the flex command")
|
||||||
|
|
||||||
# delete FLEX_EXECUTABLE cache variable if it is empty, otherwise find_package will fail
|
|
||||||
# without reasonable diagnostic
|
|
||||||
if (NOT FLEX_EXECUTABLE OR NOT EXISTS "${FLEX_EXECUTABLE}")
|
|
||||||
unset (FLEX_EXECUTABLE CACHE)
|
|
||||||
endif()
|
|
||||||
if (NOT FLEX_INCLUDE_DIR OR NOT EXISTS "${FLEX_INCLUDE_DIR}")
|
|
||||||
unset (FLEX_INCLUDE_DIR CACHE)
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Add paths to 3rdparty subfolders containing name "flex" to CMAKE_PROGRAM_PATH and
|
# FLEX_EXECUTABLE is required by FLEX_TARGET macro and should be defined
|
||||||
# CMAKE_INCLUDE_PATH variables to make these paths searhed by find_package
|
set (FLEX_EXECUTABLE "${3RDPARTY_FLEX_EXECUTABLE}" CACHE FILEPATH "path to the flex executable" FORCE)
|
||||||
if (3RDPARTY_DIR)
|
|
||||||
file (GLOB FLEX_PATHS LIST_DIRECTORIES true "${3RDPARTY_DIR}/*flex*")
|
find_package (FLEX)
|
||||||
foreach (candidate_path ${FLEX_PATHS})
|
|
||||||
if (IS_DIRECTORY ${candidate_path})
|
if (FLEX_FOUND)
|
||||||
list (APPEND CMAKE_PROGRAM_PATH ${candidate_path})
|
set (3RDPARTY_FLEX_EXECUTABLE "${FLEX_EXECUTABLE}" CACHE FILEPATH "The Path to the flex command" FORCE)
|
||||||
list (APPEND CMAKE_INCLUDE_PATH ${candidate_path})
|
|
||||||
endif()
|
|
||||||
endforeach()
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# flex 2.5.37 is required because closest known lower version, 2.5.3 from WOK 6.8.0,
|
if (NOT 3RDPARTY_FLEX_EXECUTABLE OR NOT EXISTS "${3RDPARTY_FLEX_EXECUTABLE}")
|
||||||
# generates code which is unusable on Windows (includes unistd.h without any way to avoid this)
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_FLEX_EXECUTABLE)
|
||||||
find_package (FLEX 2.5.37)
|
|
||||||
|
|
||||||
if (NOT FLEX_FOUND OR NOT FLEX_INCLUDE_DIR OR NOT EXISTS "${FLEX_INCLUDE_DIR}/FlexLexer.h")
|
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED FLEX_INCLUDE_DIR)
|
|
||||||
endif()
|
endif()
|
@@ -1,3 +1,3 @@
|
|||||||
# OpenGL ES 2.0
|
# OpenGL ES 2.0
|
||||||
|
|
||||||
THIRDPARTY_PRODUCT("GLES2" "GLES2/gl2.h" "CSF_OpenGlesLibs" "")
|
THIRDPARTY_PRODUCT("GLES2" "GLES2/gl2.h" "CSF_OpenGlLibs" "")
|
||||||
|
@@ -42,46 +42,22 @@ else()
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# OpenVR
|
# TCL/TK
|
||||||
if (USE_OPENVR)
|
|
||||||
set (CSF_OpenVR "openvr_api")
|
|
||||||
else()
|
|
||||||
set (CSF_OpenVR)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# TCL
|
|
||||||
if (USE_TCL)
|
if (USE_TCL)
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
set (CSF_TclLibs "tcl86")
|
set (CSF_TclLibs "tcl86")
|
||||||
else()
|
|
||||||
if(APPLE)
|
|
||||||
set (CSF_TclLibs Tcl)
|
|
||||||
elseif(UNIX)
|
|
||||||
set (CSF_TclLibs "tcl8.6")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# TK
|
|
||||||
if (USE_TK)
|
|
||||||
if (WIN32)
|
|
||||||
set (CSF_TclTkLibs "tk86")
|
set (CSF_TclTkLibs "tk86")
|
||||||
else()
|
else()
|
||||||
if(APPLE)
|
if(APPLE)
|
||||||
set (CSF_TclTkLibs Tk)
|
set (CSF_TclTkLibs Tk)
|
||||||
|
set (CSF_TclLibs Tcl)
|
||||||
elseif(UNIX)
|
elseif(UNIX)
|
||||||
set (CSF_TclTkLibs "tk8.6")
|
set (CSF_TclLibs "tcl8.6")
|
||||||
|
set (CSF_TclTkLibs "tk8.6")
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Draco
|
|
||||||
if (USE_DRACO)
|
|
||||||
set (CSF_Draco "draco")
|
|
||||||
else()
|
|
||||||
set (CSF_Draco)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
set (CSF_advapi32 "advapi32.lib")
|
set (CSF_advapi32 "advapi32.lib")
|
||||||
set (CSF_gdi32 "gdi32.lib")
|
set (CSF_gdi32 "gdi32.lib")
|
||||||
@@ -91,8 +67,12 @@ if (WIN32)
|
|||||||
set (CSF_psapi "psapi.lib")
|
set (CSF_psapi "psapi.lib")
|
||||||
set (CSF_winmm "winmm.lib")
|
set (CSF_winmm "winmm.lib")
|
||||||
set (CSF_d3d9 "D3D9.lib")
|
set (CSF_d3d9 "D3D9.lib")
|
||||||
set (CSF_OpenGlLibs "opengl32.lib")
|
if ("${CMAKE_SYSTEM_NAME}" STREQUAL "WindowsStore" OR USE_GLES2)
|
||||||
set (CSF_OpenGlesLibs "libEGL libGLESv2")
|
set (CSF_OpenGlLibs "libEGL libGLESv2")
|
||||||
|
else()
|
||||||
|
set (CSF_OpenGlLibs "opengl32.lib")
|
||||||
|
endif()
|
||||||
|
|
||||||
else()
|
else()
|
||||||
|
|
||||||
if (APPLE)
|
if (APPLE)
|
||||||
@@ -113,38 +93,30 @@ else()
|
|||||||
OCCT_CHECK_AND_UNSET (IOKit_LIB)
|
OCCT_CHECK_AND_UNSET (IOKit_LIB)
|
||||||
|
|
||||||
if (IOS)
|
if (IOS)
|
||||||
find_library (OpenGlesLibs_LIB NAMES OpenGLES)
|
find_library (OpenGlLibs_LIB NAMES OpenGLES)
|
||||||
set (CSF_OpenGlesLibs ${OpenGlesLibs_LIB})
|
set (CSF_OpenGlLibs ${OpenGlLibs_LIB})
|
||||||
OCCT_CHECK_AND_UNSET (OpenGlesLibs_LIB)
|
OCCT_CHECK_AND_UNSET (OpenGlLibs_LIB)
|
||||||
elseif (USE_XLIB)
|
elseif (USE_GLX)
|
||||||
set (CSF_OpenGlLibs "GL")
|
set (CSF_OpenGlLibs GL)
|
||||||
set (CSF_XwLibs "X11")
|
set (CSF_XwLibs "X11 Xext Xmu Xi")
|
||||||
else()
|
else()
|
||||||
find_library (OpenGlLibs_LIB NAMES OpenGL)
|
find_library (OpenGlLibs_LIB NAMES OpenGL)
|
||||||
set (CSF_OpenGlLibs ${OpenGlLibs_LIB})
|
set (CSF_OpenGlLibs ${OpenGlLibs_LIB})
|
||||||
OCCT_CHECK_AND_UNSET (OpenGlLibs_LIB)
|
OCCT_CHECK_AND_UNSET (OpenGlLibs_LIB)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
elseif (EMSCRIPTEN)
|
|
||||||
set (CSF_ThreadLibs "pthread rt stdc++")
|
|
||||||
set (CSF_OpenGlesLibs "EGL GLESv2")
|
|
||||||
set (CSF_dl "dl")
|
|
||||||
elseif (ANDROID)
|
elseif (ANDROID)
|
||||||
set (CSF_ThreadLibs "c")
|
set (CSF_ThreadLibs "c")
|
||||||
set (CSF_OpenGlesLibs "EGL GLESv2")
|
set (CSF_OpenGlLibs "EGL GLESv2")
|
||||||
set (CSF_androidlog "log")
|
|
||||||
elseif (UNIX)
|
elseif (UNIX)
|
||||||
set (CSF_ThreadLibs "pthread rt stdc++")
|
set (CSF_ThreadLibs "pthread rt stdc++")
|
||||||
if (USE_XLIB)
|
if (USE_GLES2)
|
||||||
set (CSF_OpenGlLibs "GL")
|
set (CSF_OpenGlLibs "EGL GLESv2")
|
||||||
set (CSF_XwLibs "X11")
|
|
||||||
else()
|
else()
|
||||||
set (CSF_OpenGlLibs "GL EGL")
|
set (CSF_OpenGlLibs "GL")
|
||||||
endif()
|
endif()
|
||||||
set (CSF_OpenGlesLibs "EGL GLESv2")
|
set (CSF_XwLibs "X11 Xext Xmu Xi")
|
||||||
set (CSF_dl "dl")
|
set (CSF_dl "dl")
|
||||||
if (USE_FREETYPE)
|
set (CSF_fontconfig "fontconfig")
|
||||||
set (CSF_fontconfig "fontconfig")
|
|
||||||
endif()
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
@@ -40,19 +40,6 @@ elseif (MSVC)
|
|||||||
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /EHa")
|
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /EHa")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (MSVC)
|
|
||||||
# string pooling (GF), function-level linking (Gy)
|
|
||||||
set (CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /GF /Gy")
|
|
||||||
set (CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} /GF /Gy")
|
|
||||||
if (BUILD_FORCE_RelWithDebInfo)
|
|
||||||
# generate debug info (Zi), inline expansion level (Ob1)
|
|
||||||
set (CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /Zi /Ob1")
|
|
||||||
set (CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} /Zi /Ob1")
|
|
||||||
# generate debug info (debug), OptimizeReferences=true (OPT:REF), EnableCOMDATFolding=true (OPT:ICF)
|
|
||||||
set (CMAKE_SHARED_LINKER_FLAGS_RELEASE "${CMAKE_SHARED_LINKER_FLAGS_RELEASE} /debug /OPT:REF /OPT:ICF")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# remove _WINDOWS flag if it exists
|
# remove _WINDOWS flag if it exists
|
||||||
string (REGEX MATCH "/D_WINDOWS" IS_WINDOWSFLAG "${CMAKE_CXX_FLAGS}")
|
string (REGEX MATCH "/D_WINDOWS" IS_WINDOWSFLAG "${CMAKE_CXX_FLAGS}")
|
||||||
if (IS_WINDOWSFLAG)
|
if (IS_WINDOWSFLAG)
|
||||||
@@ -124,33 +111,34 @@ elseif (CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_GNUCXX OR "${CMAKE_CXX_COMP
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if ("x${CMAKE_CXX_COMPILER_ID}" STREQUAL "xClang")
|
if(MINGW)
|
||||||
|
# Set default release optimization option to O2 instead of O3, since in
|
||||||
|
# some OCCT related examples, this gives significantly smaller binaries
|
||||||
|
# at comparable performace with MinGW-w64.
|
||||||
|
string (REGEX MATCH "-O3" IS_O3_CXX "${CMAKE_CXX_FLAGS_RELEASE}")
|
||||||
|
if (IS_O3_CXX)
|
||||||
|
string (REGEX REPLACE "-O3" "-O2" CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE}")
|
||||||
|
else()
|
||||||
|
set (CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -O2")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set (CMAKE_CXX_FLAGS "-std=gnu++0x ${CMAKE_CXX_FLAGS}")
|
||||||
|
add_definitions(-D_WIN32_WINNT=0x0501)
|
||||||
|
# workaround bugs in mingw with vtable export
|
||||||
|
set (CMAKE_SHARED_LINKER_FLAGS "-Wl,--export-all-symbols")
|
||||||
|
elseif ("x${CMAKE_CXX_COMPILER_ID}" STREQUAL "xClang")
|
||||||
if (APPLE)
|
if (APPLE)
|
||||||
# CLang can be used with both libstdc++ and libc++, however on OS X libstdc++ is outdated.
|
# CLang can be used with both libstdc++ and libc++, however on OS X libstdc++ is outdated.
|
||||||
set (CMAKE_CXX_FLAGS "-std=c++0x -stdlib=libc++ ${CMAKE_CXX_FLAGS}")
|
set (CMAKE_CXX_FLAGS "-std=c++0x -stdlib=libc++ ${CMAKE_CXX_FLAGS}")
|
||||||
elseif(NOT WIN32)
|
else()
|
||||||
# CLang for Windows (at least CLang 8.0 distributed with VS 2019)
|
|
||||||
# does not support option "-std=c++0x"
|
|
||||||
set (CMAKE_CXX_FLAGS "-std=c++0x ${CMAKE_CXX_FLAGS}")
|
set (CMAKE_CXX_FLAGS "-std=c++0x ${CMAKE_CXX_FLAGS}")
|
||||||
endif()
|
endif()
|
||||||
# Optimize size of binaries
|
|
||||||
set (CMAKE_SHARED_LINKER_FLAGS "-Wl,-s ${CMAKE_SHARED_LINKER_FLAGS}")
|
|
||||||
elseif(MINGW)
|
|
||||||
add_definitions(-D_WIN32_WINNT=0x0601)
|
|
||||||
# _WIN32_WINNT=0x0601 (use Windows 7 SDK)
|
|
||||||
#set (CMAKE_SYSTEM_VERSION "6.1")
|
|
||||||
# workaround bugs in mingw with vtable export
|
|
||||||
set (CMAKE_SHARED_LINKER_FLAGS "-Wl,--export-all-symbols")
|
|
||||||
|
|
||||||
# Require C++11
|
|
||||||
set (CMAKE_CXX_FLAGS "-std=gnu++0x ${CMAKE_CXX_FLAGS}")
|
|
||||||
# Optimize size of binaries
|
|
||||||
set (CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -s")
|
|
||||||
set (CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -s")
|
|
||||||
elseif (DEFINED CMAKE_COMPILER_IS_GNUCXX)
|
elseif (DEFINED CMAKE_COMPILER_IS_GNUCXX)
|
||||||
# Require C++11
|
|
||||||
set (CMAKE_CXX_FLAGS "-std=c++0x ${CMAKE_CXX_FLAGS}")
|
set (CMAKE_CXX_FLAGS "-std=c++0x ${CMAKE_CXX_FLAGS}")
|
||||||
# Optimize size of binaries
|
endif()
|
||||||
|
|
||||||
|
# Optimize size of binaries
|
||||||
|
if (CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_GNUCXX OR MINGW)
|
||||||
set (CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -s")
|
set (CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -s")
|
||||||
set (CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -s")
|
set (CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -s")
|
||||||
endif()
|
endif()
|
||||||
|
@@ -12,12 +12,18 @@ macro (OCCT_CHECK_AND_UNSET VARNAME)
|
|||||||
endif()
|
endif()
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
macro (OCCT_CHECK_AND_UNSET_GROUP GROUPNAME)
|
macro (OCCT_CHECK_AND_UNSET_GROUP VARNAME)
|
||||||
get_cmake_property(VARS VARIABLES)
|
OCCT_CHECK_AND_UNSET ("${VARNAME}_DIR")
|
||||||
string (REGEX MATCHALL "(^|;)${GROUPNAME}[A-Za-z0-9_]*" GROUPNAME_VARS "${VARS}")
|
|
||||||
foreach(GROUPNAME_VAR ${GROUPNAME_VARS})
|
OCCT_CHECK_AND_UNSET ("${VARNAME}_INCLUDE_DIR")
|
||||||
OCCT_CHECK_AND_UNSET(${GROUPNAME_VAR})
|
|
||||||
endforeach()
|
OCCT_CHECK_AND_UNSET ("${VARNAME}_LIBRARY")
|
||||||
|
OCCT_CHECK_AND_UNSET ("${VARNAME}_LIBRARY_DIR")
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
OCCT_CHECK_AND_UNSET ("${VARNAME}_DLL")
|
||||||
|
OCCT_CHECK_AND_UNSET ("${VARNAME}_DLL_DIR")
|
||||||
|
endif()
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
macro (OCCT_CHECK_AND_UNSET_INSTALL_DIR_SUBDIRS)
|
macro (OCCT_CHECK_AND_UNSET_INSTALL_DIR_SUBDIRS)
|
||||||
|
@@ -22,7 +22,7 @@ if ("${OCCT_TOOLKITS_NAME_SUFFIX}" STREQUAL "")
|
|||||||
set (OCCT_TOOLKITS_NAME_SUFFIX "TOOLKITS")
|
set (OCCT_TOOLKITS_NAME_SUFFIX "TOOLKITS")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# parse PACKAGES file
|
# parce PACKAGES file
|
||||||
FILE_TO_LIST ("${RELATIVE_SOURCES_DIR}/${PROJECT_NAME}/PACKAGES" USED_PACKAGES)
|
FILE_TO_LIST ("${RELATIVE_SOURCES_DIR}/${PROJECT_NAME}/PACKAGES" USED_PACKAGES)
|
||||||
if ("${USED_PACKAGES}" STREQUAL "")
|
if ("${USED_PACKAGES}" STREQUAL "")
|
||||||
set (USED_PACKAGES ${PROJECT_NAME})
|
set (USED_PACKAGES ${PROJECT_NAME})
|
||||||
@@ -39,7 +39,7 @@ set (PRECOMPILED_DEFS)
|
|||||||
|
|
||||||
if (NOT BUILD_SHARED_LIBS)
|
if (NOT BUILD_SHARED_LIBS)
|
||||||
list (APPEND PRECOMPILED_DEFS "-DOCCT_NO_PLUGINS")
|
list (APPEND PRECOMPILED_DEFS "-DOCCT_NO_PLUGINS")
|
||||||
if (WIN32 AND NOT EXECUTABLE_PROJECT)
|
if (WIN32)
|
||||||
list (APPEND PRECOMPILED_DEFS "-DOCCT_STATIC_BUILD")
|
list (APPEND PRECOMPILED_DEFS "-DOCCT_STATIC_BUILD")
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
@@ -57,140 +57,117 @@ foreach (OCCT_PACKAGE ${USED_PACKAGES})
|
|||||||
set (OCCT_PACKAGE_NAME "${OCCT_PACKAGE}")
|
set (OCCT_PACKAGE_NAME "${OCCT_PACKAGE}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (WIN32)
|
# TKService contains platform-dependent packages: Xw and WNT
|
||||||
list (APPEND PRECOMPILED_DEFS "-D__${OCCT_PACKAGE_NAME}_DLL")
|
if ((WIN32 AND "${OCCT_PACKAGE}" STREQUAL "Xw") OR (NOT WIN32 AND "${OCCT_PACKAGE}" STREQUAL "WNT"))
|
||||||
endif()
|
# do nothing
|
||||||
|
|
||||||
set (SOURCE_FILES)
|
|
||||||
set (HEADER_FILES)
|
|
||||||
|
|
||||||
# Generate Flex and Bison files
|
|
||||||
if (${BUILD_YACCLEX})
|
|
||||||
# flex files
|
|
||||||
OCCT_ORIGIN_AND_PATCHED_FILES ("${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}" "*[.]lex" SOURCE_FILES_FLEX)
|
|
||||||
list (LENGTH SOURCE_FILES_FLEX SOURCE_FILES_FLEX_LEN)
|
|
||||||
|
|
||||||
# bison files
|
|
||||||
OCCT_ORIGIN_AND_PATCHED_FILES ("${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}" "*[.]yacc" SOURCE_FILES_BISON)
|
|
||||||
list (LENGTH SOURCE_FILES_BISON SOURCE_FILES_BISON_LEN)
|
|
||||||
|
|
||||||
if (${SOURCE_FILES_FLEX_LEN} EQUAL ${SOURCE_FILES_BISON_LEN} AND NOT ${SOURCE_FILES_FLEX_LEN} EQUAL 0)
|
|
||||||
|
|
||||||
list (SORT SOURCE_FILES_FLEX)
|
|
||||||
list (SORT SOURCE_FILES_BISON)
|
|
||||||
|
|
||||||
math (EXPR SOURCE_FILES_FLEX_LEN "${SOURCE_FILES_FLEX_LEN} - 1")
|
|
||||||
foreach (FLEX_FILE_INDEX RANGE ${SOURCE_FILES_FLEX_LEN})
|
|
||||||
|
|
||||||
list (GET SOURCE_FILES_FLEX ${FLEX_FILE_INDEX} CURRENT_FLEX_FILE)
|
|
||||||
get_filename_component (CURRENT_FLEX_FILE_NAME ${CURRENT_FLEX_FILE} NAME_WE)
|
|
||||||
|
|
||||||
list (GET SOURCE_FILES_BISON ${FLEX_FILE_INDEX} CURRENT_BISON_FILE)
|
|
||||||
get_filename_component (CURRENT_BISON_FILE_NAME ${CURRENT_BISON_FILE} NAME_WE)
|
|
||||||
|
|
||||||
string (COMPARE EQUAL ${CURRENT_FLEX_FILE_NAME} ${CURRENT_BISON_FILE_NAME} ARE_FILES_EQUAL)
|
|
||||||
|
|
||||||
if (EXISTS "${CURRENT_FLEX_FILE}" AND EXISTS "${CURRENT_BISON_FILE}" AND ${ARE_FILES_EQUAL})
|
|
||||||
|
|
||||||
# Note: files are generated in original source directory (not in patch!)
|
|
||||||
set (FLEX_BISON_TARGET_DIR "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}")
|
|
||||||
|
|
||||||
# choose appropriate extension for generated files: "cxx" if source file contains
|
|
||||||
# instruction to generate C++ code, "c" otherwise
|
|
||||||
set (BISON_OUTPUT_FILE_EXT "c")
|
|
||||||
set (FLEX_OUTPUT_FILE_EXT "c")
|
|
||||||
file (STRINGS "${CURRENT_BISON_FILE}" FILE_BISON_CONTENT)
|
|
||||||
foreach (FILE_BISON_CONTENT_LINE ${FILE_BISON_CONTENT})
|
|
||||||
string (REGEX MATCH "%language \"C\\+\\+\"" CXX_BISON_LANGUAGE_FOUND ${FILE_BISON_CONTENT_LINE})
|
|
||||||
if (CXX_BISON_LANGUAGE_FOUND)
|
|
||||||
set (BISON_OUTPUT_FILE_EXT "cxx")
|
|
||||||
endif()
|
|
||||||
endforeach()
|
|
||||||
file (STRINGS "${CURRENT_FLEX_FILE}" FILE_FLEX_CONTENT)
|
|
||||||
foreach (FILE_FLEX_CONTENT_LINE ${FILE_FLEX_CONTENT})
|
|
||||||
string (REGEX MATCH "%option c\\+\\+" CXX_FLEX_LANGUAGE_FOUND ${FILE_FLEX_CONTENT_LINE})
|
|
||||||
if (CXX_FLEX_LANGUAGE_FOUND)
|
|
||||||
set (FLEX_OUTPUT_FILE_EXT "cxx")
|
|
||||||
|
|
||||||
# install copy of FlexLexer.h locally to allow further building without flex
|
|
||||||
if (FLEX_INCLUDE_DIR AND EXISTS "${FLEX_INCLUDE_DIR}/FlexLexer.h")
|
|
||||||
configure_file("${FLEX_INCLUDE_DIR}/FlexLexer.h" "${FLEX_BISON_TARGET_DIR}/FlexLexer.h" @ONLY NEWLINE_STYLE LF)
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
endforeach()
|
|
||||||
set (BISON_OUTPUT_FILE ${CURRENT_BISON_FILE_NAME}.tab.${BISON_OUTPUT_FILE_EXT})
|
|
||||||
set (FLEX_OUTPUT_FILE lex.${CURRENT_FLEX_FILE_NAME}.${FLEX_OUTPUT_FILE_EXT})
|
|
||||||
|
|
||||||
BISON_TARGET (Parser_${CURRENT_BISON_FILE_NAME} ${CURRENT_BISON_FILE} "${FLEX_BISON_TARGET_DIR}/${BISON_OUTPUT_FILE}"
|
|
||||||
COMPILE_FLAGS "-p ${CURRENT_BISON_FILE_NAME} -l -M ${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/=")
|
|
||||||
FLEX_TARGET (Scanner_${CURRENT_FLEX_FILE_NAME} ${CURRENT_FLEX_FILE} "${FLEX_BISON_TARGET_DIR}/${FLEX_OUTPUT_FILE}"
|
|
||||||
COMPILE_FLAGS "-P${CURRENT_FLEX_FILE_NAME} -L")
|
|
||||||
ADD_FLEX_BISON_DEPENDENCY (Scanner_${CURRENT_FLEX_FILE_NAME} Parser_${CURRENT_BISON_FILE_NAME})
|
|
||||||
|
|
||||||
list (APPEND SOURCE_FILES ${BISON_OUTPUT_FILE} ${FLEX_OUTPUT_FILE})
|
|
||||||
endif()
|
|
||||||
endforeach()
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# header files
|
|
||||||
if (BUILD_PATCH AND EXISTS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES")
|
|
||||||
file (STRINGS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" HEADER_FILES_M REGEX ".+[.]h")
|
|
||||||
file (STRINGS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" HEADER_FILES_LXX REGEX ".+[.]lxx")
|
|
||||||
file (STRINGS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" HEADER_FILES_GXX REGEX ".+[.]gxx")
|
|
||||||
|
|
||||||
file (STRINGS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" SOURCE_FILES_C REGEX ".+[.]c")
|
|
||||||
if(APPLE)
|
|
||||||
file (STRINGS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" SOURCE_FILES_M REGEX ".+[.]mm")
|
|
||||||
endif()
|
|
||||||
else()
|
else()
|
||||||
file (STRINGS "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" HEADER_FILES_M REGEX ".+[.]h")
|
|
||||||
file (STRINGS "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" HEADER_FILES_LXX REGEX ".+[.]lxx")
|
|
||||||
file (STRINGS "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" HEADER_FILES_GXX REGEX ".+[.]gxx")
|
|
||||||
|
|
||||||
file (STRINGS "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" SOURCE_FILES_C REGEX ".+[.]c")
|
if (WIN32)
|
||||||
|
list (APPEND PRECOMPILED_DEFS "-D__${OCCT_PACKAGE_NAME}_DLL")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set (SOURCE_FILES)
|
||||||
|
set (HEADER_FILES)
|
||||||
|
|
||||||
|
# Generate Flex and Bison files
|
||||||
|
if (${BUILD_YACCLEX})
|
||||||
|
|
||||||
|
# flex files
|
||||||
|
OCCT_ORIGIN_AND_PATCHED_FILES ("${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}" "*[.]lex" SOURCE_FILES_FLEX)
|
||||||
|
list (LENGTH SOURCE_FILES_FLEX SOURCE_FILES_FLEX_LEN)
|
||||||
|
|
||||||
|
# bison files
|
||||||
|
OCCT_ORIGIN_AND_PATCHED_FILES ("${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}" "*[.]yacc" SOURCE_FILES_BISON)
|
||||||
|
list (LENGTH SOURCE_FILES_BISON SOURCE_FILES_BISON_LEN)
|
||||||
|
|
||||||
|
if (${SOURCE_FILES_FLEX_LEN} EQUAL ${SOURCE_FILES_BISON_LEN} AND NOT ${SOURCE_FILES_FLEX_LEN} EQUAL 0)
|
||||||
|
|
||||||
|
list (SORT SOURCE_FILES_FLEX)
|
||||||
|
list (SORT SOURCE_FILES_BISON)
|
||||||
|
|
||||||
|
math (EXPR SOURCE_FILES_FLEX_LEN "${SOURCE_FILES_FLEX_LEN} - 1")
|
||||||
|
foreach (FLEX_FILE_INDEX RANGE ${SOURCE_FILES_FLEX_LEN})
|
||||||
|
|
||||||
|
list (GET SOURCE_FILES_FLEX ${FLEX_FILE_INDEX} CURRENT_FLEX_FILE)
|
||||||
|
get_filename_component (CURRENT_FLEX_FILE_NAME ${CURRENT_FLEX_FILE} NAME_WE)
|
||||||
|
|
||||||
|
list (GET SOURCE_FILES_BISON ${FLEX_FILE_INDEX} CURRENT_BISON_FILE)
|
||||||
|
get_filename_component (CURRENT_BISON_FILE_NAME ${CURRENT_BISON_FILE} NAME_WE)
|
||||||
|
|
||||||
|
string (COMPARE EQUAL ${CURRENT_FLEX_FILE_NAME} ${CURRENT_BISON_FILE_NAME} ARE_FILES_EQUAL)
|
||||||
|
|
||||||
|
if (EXISTS "${CURRENT_FLEX_FILE}" AND EXISTS "${CURRENT_BISON_FILE}" AND ${ARE_FILES_EQUAL})
|
||||||
|
set (BISON_OUTPUT_FILE ${CURRENT_BISON_FILE_NAME}.tab.c)
|
||||||
|
set (FLEX_OUTPUT_FILE lex.${CURRENT_FLEX_FILE_NAME}.c)
|
||||||
|
BISON_TARGET (Parser_${CURRENT_BISON_FILE_NAME} ${CURRENT_BISON_FILE} ${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${BISON_OUTPUT_FILE} COMPILE_FLAGS "-p ${CURRENT_BISON_FILE_NAME}")
|
||||||
|
FLEX_TARGET (Scanner_${CURRENT_FLEX_FILE_NAME} ${CURRENT_FLEX_FILE} ${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${FLEX_OUTPUT_FILE} COMPILE_FLAGS "-P${CURRENT_FLEX_FILE_NAME}")
|
||||||
|
ADD_FLEX_BISON_DEPENDENCY (Scanner_${CURRENT_FLEX_FILE_NAME} Parser_${CURRENT_BISON_FILE_NAME})
|
||||||
|
|
||||||
|
list (APPEND SOURCE_FILES ${BISON_OUTPUT_FILE} ${FLEX_OUTPUT_FILE})
|
||||||
|
endif()
|
||||||
|
endforeach()
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
# header files
|
||||||
|
if (BUILD_PATCH AND EXISTS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES")
|
||||||
|
file (STRINGS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" HEADER_FILES_M REGEX ".+[.]h")
|
||||||
|
file (STRINGS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" HEADER_FILES_LXX REGEX ".+[.]lxx")
|
||||||
|
file (STRINGS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" HEADER_FILES_GXX REGEX ".+[.]gxx")
|
||||||
|
|
||||||
|
file (STRINGS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" SOURCE_FILES_C REGEX ".+[.]c")
|
||||||
|
if(APPLE)
|
||||||
|
file (STRINGS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" SOURCE_FILES_M REGEX ".+[.]mm")
|
||||||
|
endif()
|
||||||
|
else()
|
||||||
|
file (STRINGS "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" HEADER_FILES_M REGEX ".+[.]h")
|
||||||
|
file (STRINGS "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" HEADER_FILES_LXX REGEX ".+[.]lxx")
|
||||||
|
file (STRINGS "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" HEADER_FILES_GXX REGEX ".+[.]gxx")
|
||||||
|
|
||||||
|
file (STRINGS "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" SOURCE_FILES_C REGEX ".+[.]c")
|
||||||
|
if(APPLE)
|
||||||
|
file (STRINGS "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" SOURCE_FILES_M REGEX ".+[.]mm")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
list (APPEND HEADER_FILES ${HEADER_FILES_M} ${HEADER_FILES_LXX} ${SOURCE_FILES_GXX})
|
||||||
|
list (APPEND SOURCE_FILES ${SOURCE_FILES_C})
|
||||||
if(APPLE)
|
if(APPLE)
|
||||||
file (STRINGS "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/FILES" SOURCE_FILES_M REGEX ".+[.]mm")
|
list (APPEND SOURCE_FILES ${SOURCE_FILES_M})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
foreach(HEADER_FILE ${HEADER_FILES})
|
||||||
|
if (BUILD_PATCH AND EXISTS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${HEADER_FILE}")
|
||||||
|
message (STATUS "Info: consider patched file: ${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${HEADER_FILE}")
|
||||||
|
list (APPEND USED_INCFILES "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${HEADER_FILE}")
|
||||||
|
SOURCE_GROUP ("Header Files\\${OCCT_PACKAGE_NAME}" FILES "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${HEADER_FILE}")
|
||||||
|
else()
|
||||||
|
list (APPEND USED_INCFILES "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${HEADER_FILE}")
|
||||||
|
SOURCE_GROUP ("Header Files\\${OCCT_PACKAGE_NAME}" FILES "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${HEADER_FILE}")
|
||||||
|
endif()
|
||||||
|
endforeach()
|
||||||
|
|
||||||
|
foreach(SOURCE_FILE ${SOURCE_FILES})
|
||||||
|
if (BUILD_PATCH AND EXISTS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${SOURCE_FILE}")
|
||||||
|
message (STATUS "Info: consider patched file: ${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${SOURCE_FILE}")
|
||||||
|
list (APPEND USED_SRCFILES "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${SOURCE_FILE}")
|
||||||
|
SOURCE_GROUP ("Source Files\\${OCCT_PACKAGE_NAME}" FILES "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${SOURCE_FILE}")
|
||||||
|
else()
|
||||||
|
list (APPEND USED_SRCFILES "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${SOURCE_FILE}")
|
||||||
|
SOURCE_GROUP ("Source Files\\${OCCT_PACKAGE_NAME}" FILES "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${SOURCE_FILE}")
|
||||||
|
endif()
|
||||||
|
endforeach()
|
||||||
|
|
||||||
|
if (USE_QT)
|
||||||
|
FIND_AND_INSTALL_QT_RESOURCES (${OCCT_PACKAGE} RESOURCE_FILES)
|
||||||
|
#message("Qt Resource files are: ${QT_RESOURCE_FILES} in ${OCCT_PACKAGE}")
|
||||||
|
endif(USE_QT)
|
||||||
|
|
||||||
|
#message("Resource files are: ${RESOURCE_FILES} in ${OCCT_PACKAGE}")
|
||||||
|
foreach(RESOURCE_FILE ${RESOURCE_FILES})
|
||||||
|
SOURCE_GROUP ("Resource Files\\${OCCT_PACKAGE_NAME}" FILES "${RESOURCE_FILE}")
|
||||||
|
endforeach()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
list (APPEND HEADER_FILES ${HEADER_FILES_M} ${HEADER_FILES_LXX} ${SOURCE_FILES_GXX})
|
|
||||||
list (APPEND SOURCE_FILES ${SOURCE_FILES_C})
|
|
||||||
if(APPLE)
|
|
||||||
list (APPEND SOURCE_FILES ${SOURCE_FILES_M})
|
|
||||||
endif()
|
|
||||||
|
|
||||||
foreach(HEADER_FILE ${HEADER_FILES})
|
|
||||||
if (BUILD_PATCH AND EXISTS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${HEADER_FILE}")
|
|
||||||
message (STATUS "Info: consider patched file: ${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${HEADER_FILE}")
|
|
||||||
list (APPEND USED_INCFILES "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${HEADER_FILE}")
|
|
||||||
SOURCE_GROUP ("Header Files\\${OCCT_PACKAGE_NAME}" FILES "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${HEADER_FILE}")
|
|
||||||
else()
|
|
||||||
list (APPEND USED_INCFILES "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${HEADER_FILE}")
|
|
||||||
SOURCE_GROUP ("Header Files\\${OCCT_PACKAGE_NAME}" FILES "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${HEADER_FILE}")
|
|
||||||
endif()
|
|
||||||
endforeach()
|
|
||||||
|
|
||||||
foreach(SOURCE_FILE ${SOURCE_FILES})
|
|
||||||
if (BUILD_PATCH AND EXISTS "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${SOURCE_FILE}")
|
|
||||||
message (STATUS "Info: consider patched file: ${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${SOURCE_FILE}")
|
|
||||||
list (APPEND USED_SRCFILES "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${SOURCE_FILE}")
|
|
||||||
SOURCE_GROUP ("Source Files\\${OCCT_PACKAGE_NAME}" FILES "${BUILD_PATCH}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${SOURCE_FILE}")
|
|
||||||
else()
|
|
||||||
list (APPEND USED_SRCFILES "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${SOURCE_FILE}")
|
|
||||||
SOURCE_GROUP ("Source Files\\${OCCT_PACKAGE_NAME}" FILES "${CMAKE_SOURCE_DIR}/${RELATIVE_SOURCES_DIR}/${OCCT_PACKAGE}/${SOURCE_FILE}")
|
|
||||||
endif()
|
|
||||||
endforeach()
|
|
||||||
|
|
||||||
if (USE_QT)
|
|
||||||
FIND_AND_INSTALL_QT_RESOURCES (${OCCT_PACKAGE} RESOURCE_FILES)
|
|
||||||
#message("Qt Resource files are: ${QT_RESOURCE_FILES} in ${OCCT_PACKAGE}")
|
|
||||||
endif(USE_QT)
|
|
||||||
|
|
||||||
#message("Resource files are: ${RESOURCE_FILES} in ${OCCT_PACKAGE}")
|
|
||||||
foreach(RESOURCE_FILE ${RESOURCE_FILES})
|
|
||||||
SOURCE_GROUP ("Resource Files\\${OCCT_PACKAGE_NAME}" FILES "${RESOURCE_FILE}")
|
|
||||||
endforeach()
|
|
||||||
endforeach()
|
endforeach()
|
||||||
string (REGEX REPLACE ";" " " PRECOMPILED_DEFS "${PRECOMPILED_DEFS}")
|
string (REGEX REPLACE ";" " " PRECOMPILED_DEFS "${PRECOMPILED_DEFS}")
|
||||||
|
|
||||||
@@ -228,21 +205,12 @@ if (EXECUTABLE_PROJECT)
|
|||||||
|
|
||||||
install (TARGETS ${PROJECT_NAME}
|
install (TARGETS ${PROJECT_NAME}
|
||||||
DESTINATION "${INSTALL_DIR_BIN}\${OCCT_INSTALL_BIN_LETTER}")
|
DESTINATION "${INSTALL_DIR_BIN}\${OCCT_INSTALL_BIN_LETTER}")
|
||||||
|
|
||||||
if (EMSCRIPTEN)
|
|
||||||
install(FILES ${CMAKE_BINARY_DIR}/${OS_WITH_BIT}/${COMPILER}/bin\${OCCT_INSTALL_BIN_LETTER}/${PROJECT_NAME}.wasm DESTINATION "${INSTALL_DIR_BIN}/${OCCT_INSTALL_BIN_LETTER}")
|
|
||||||
endif()
|
|
||||||
else()
|
else()
|
||||||
add_library (${PROJECT_NAME} ${USED_SRCFILES} ${USED_INCFILES} ${USED_RCFILE} ${RESOURCE_FILES} ${${PROJECT_NAME}_MOC_FILES})
|
add_library (${PROJECT_NAME} ${USED_SRCFILES} ${USED_INCFILES} ${USED_RCFILE} ${RESOURCE_FILES} ${${PROJECT_NAME}_MOC_FILES})
|
||||||
|
|
||||||
if (MSVC)
|
if (MSVC)
|
||||||
if (BUILD_FORCE_RelWithDebInfo)
|
|
||||||
set (aReleasePdbConf "Release")
|
|
||||||
else()
|
|
||||||
set (aReleasePdbConf)
|
|
||||||
endif()
|
|
||||||
install (FILES ${CMAKE_BINARY_DIR}/${OS_WITH_BIT}/${COMPILER}/bin\${OCCT_INSTALL_BIN_LETTER}/${PROJECT_NAME}.pdb
|
install (FILES ${CMAKE_BINARY_DIR}/${OS_WITH_BIT}/${COMPILER}/bin\${OCCT_INSTALL_BIN_LETTER}/${PROJECT_NAME}.pdb
|
||||||
CONFIGURATIONS Debug ${aReleasePdbConf} RelWithDebInfo
|
CONFIGURATIONS Debug RelWithDebInfo
|
||||||
DESTINATION "${INSTALL_DIR_BIN}\${OCCT_INSTALL_BIN_LETTER}")
|
DESTINATION "${INSTALL_DIR_BIN}\${OCCT_INSTALL_BIN_LETTER}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -292,12 +260,8 @@ endif()
|
|||||||
set (USED_TOOLKITS_BY_CURRENT_PROJECT)
|
set (USED_TOOLKITS_BY_CURRENT_PROJECT)
|
||||||
set (USED_EXTERNAL_LIBS_BY_CURRENT_PROJECT)
|
set (USED_EXTERNAL_LIBS_BY_CURRENT_PROJECT)
|
||||||
|
|
||||||
# parse EXTERNLIB file
|
# parce EXTERNLIB file
|
||||||
if (CUSTOM_EXTERNLIB)
|
FILE_TO_LIST ("${RELATIVE_SOURCES_DIR}/${PROJECT_NAME}/EXTERNLIB" USED_EXTERNLIB_AND_TOOLKITS)
|
||||||
set (USED_EXTERNLIB_AND_TOOLKITS ${CUSTOM_EXTERNLIB})
|
|
||||||
else()
|
|
||||||
FILE_TO_LIST ("${RELATIVE_SOURCES_DIR}/${PROJECT_NAME}/EXTERNLIB" USED_EXTERNLIB_AND_TOOLKITS)
|
|
||||||
endif()
|
|
||||||
foreach (USED_ITEM ${USED_EXTERNLIB_AND_TOOLKITS})
|
foreach (USED_ITEM ${USED_EXTERNLIB_AND_TOOLKITS})
|
||||||
string (REGEX MATCH "^ *#" COMMENT_FOUND ${USED_ITEM})
|
string (REGEX MATCH "^ *#" COMMENT_FOUND ${USED_ITEM})
|
||||||
if (NOT COMMENT_FOUND)
|
if (NOT COMMENT_FOUND)
|
||||||
@@ -316,13 +280,6 @@ foreach (USED_ITEM ${USED_EXTERNLIB_AND_TOOLKITS})
|
|||||||
else() # get CSF_ value
|
else() # get CSF_ value
|
||||||
set (CURRENT_CSF ${${USED_ITEM}})
|
set (CURRENT_CSF ${${USED_ITEM}})
|
||||||
if (NOT "x${CURRENT_CSF}" STREQUAL "x")
|
if (NOT "x${CURRENT_CSF}" STREQUAL "x")
|
||||||
if ("${CURRENT_CSF}" STREQUAL "CSF_OpenGlLibs")
|
|
||||||
add_definitions (-DHAVE_OPENGL)
|
|
||||||
endif()
|
|
||||||
if ("${CURRENT_CSF}" STREQUAL "CSF_OpenGlesLibs")
|
|
||||||
add_definitions (-DHAVE_GLES2)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
set (LIBRARY_FROM_CACHE 0)
|
set (LIBRARY_FROM_CACHE 0)
|
||||||
separate_arguments (CURRENT_CSF)
|
separate_arguments (CURRENT_CSF)
|
||||||
foreach (CSF_LIBRARY ${CURRENT_CSF})
|
foreach (CSF_LIBRARY ${CURRENT_CSF})
|
||||||
@@ -364,7 +321,7 @@ endforeach()
|
|||||||
if (APPLE)
|
if (APPLE)
|
||||||
list (FIND USED_EXTERNAL_LIBS_BY_CURRENT_PROJECT X11 IS_X11_FOUND)
|
list (FIND USED_EXTERNAL_LIBS_BY_CURRENT_PROJECT X11 IS_X11_FOUND)
|
||||||
if (NOT ${IS_X11_FOUND} EQUAL -1)
|
if (NOT ${IS_X11_FOUND} EQUAL -1)
|
||||||
find_package (X11 COMPONENTS X11)
|
find_package (X11 COMPONENTS X11 Xext Xmu Xi)
|
||||||
if (NOT X11_FOUND)
|
if (NOT X11_FOUND)
|
||||||
message (STATUS "Warning: X11 is not found. It's required to install The XQuartz project: http://www.xquartz.org")
|
message (STATUS "Warning: X11 is not found. It's required to install The XQuartz project: http://www.xquartz.org")
|
||||||
endif()
|
endif()
|
||||||
@@ -373,7 +330,7 @@ endif()
|
|||||||
|
|
||||||
# Update list of used VTK libraries if OpenGL2 Rendering BackEnd is used.
|
# Update list of used VTK libraries if OpenGL2 Rendering BackEnd is used.
|
||||||
# Add VTK_OPENGL2_BACKEND definition.
|
# Add VTK_OPENGL2_BACKEND definition.
|
||||||
if("${VTK_RENDERING_BACKEND}" STREQUAL "OpenGL2" OR IS_VTK_9XX)
|
if("${VTK_RENDERING_BACKEND}" STREQUAL "OpenGL2")
|
||||||
add_definitions(-DVTK_OPENGL2_BACKEND)
|
add_definitions(-DVTK_OPENGL2_BACKEND)
|
||||||
foreach (VTK_EXCLUDE_LIBRARY vtkRenderingOpenGL vtkRenderingFreeTypeOpenGL)
|
foreach (VTK_EXCLUDE_LIBRARY vtkRenderingOpenGL vtkRenderingFreeTypeOpenGL)
|
||||||
list (FIND USED_TOOLKITS_BY_CURRENT_PROJECT "${VTK_EXCLUDE_LIBRARY}" IS_VTK_OPENGL_FOUND)
|
list (FIND USED_TOOLKITS_BY_CURRENT_PROJECT "${VTK_EXCLUDE_LIBRARY}" IS_VTK_OPENGL_FOUND)
|
||||||
@@ -396,10 +353,7 @@ else()
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (BUILD_SHARED_LIBS OR EXECUTABLE_PROJECT)
|
if (BUILD_SHARED_LIBS)
|
||||||
if(IS_VTK_9XX)
|
|
||||||
string (REGEX REPLACE "vtk" "VTK::" USED_TOOLKITS_BY_CURRENT_PROJECT "${USED_TOOLKITS_BY_CURRENT_PROJECT}")
|
|
||||||
endif()
|
|
||||||
target_link_libraries (${PROJECT_NAME} ${USED_TOOLKITS_BY_CURRENT_PROJECT} ${USED_EXTERNAL_LIBS_BY_CURRENT_PROJECT})
|
target_link_libraries (${PROJECT_NAME} ${USED_TOOLKITS_BY_CURRENT_PROJECT} ${USED_EXTERNAL_LIBS_BY_CURRENT_PROJECT})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
@@ -1,5 +0,0 @@
|
|||||||
# OpenVR SDK
|
|
||||||
# OpenVR is an API and runtime that allows access to VR hardware from multiple vendors without requiring that applications have specific knowledge of the hardware they are targeting.
|
|
||||||
# https://github.com/ValveSoftware/openvr
|
|
||||||
|
|
||||||
THIRDPARTY_PRODUCT("OPENVR" "openvr.h" "CSF_OpenVR" "")
|
|
@@ -7,8 +7,7 @@ if (NOT DEFINED ${3RDPARTY_QT_DIR} AND ${3RDPARTY_QT_DIR} STREQUAL "")
|
|||||||
FIND_PRODUCT_DIR ("${3RDPARTY_DIR}" Qt 3RDPARTY_QT_DIR_NAME)
|
FIND_PRODUCT_DIR ("${3RDPARTY_DIR}" Qt 3RDPARTY_QT_DIR_NAME)
|
||||||
|
|
||||||
if (NOT DEFINED ${3RDPARTY_QT_DIR_NAME} AND ${3RDPARTY_QT_DIR_NAME} STREQUAL "")
|
if (NOT DEFINED ${3RDPARTY_QT_DIR_NAME} AND ${3RDPARTY_QT_DIR_NAME} STREQUAL "")
|
||||||
set (3RDPARTY_QT_DIR "" CACHE PATH "The directory containing qt")
|
message (FATAL_ERROR "... Qt root directory was not found")
|
||||||
message (FATAL_ERROR "Could not find used third-party product: 3RDPARTY_QT_DIR")
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Combine directory name with absolute path and show in GUI
|
# Combine directory name with absolute path and show in GUI
|
||||||
@@ -33,9 +32,3 @@ if (NOT ${Qt5_FOUND})
|
|||||||
else()
|
else()
|
||||||
#message (STATUS "Qt5 cmake configuration")
|
#message (STATUS "Qt5 cmake configuration")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (3RDPARTY_QT_DIR OR EXISTS "${3RDPARTY_QT_DIR}")
|
|
||||||
list (APPEND 3RDPARTY_DLL_DIRS "${3RDPARTY_QT_DIR}/bin")
|
|
||||||
else()
|
|
||||||
list (APPEND 3RDPARTY_NO_DLLS 3RDPARTY_QT_DLL_DIR)
|
|
||||||
endif()
|
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
# tcl
|
# tcl
|
||||||
|
|
||||||
if (NOT DEFINED INSTALL_TCL)
|
if (NOT DEFINED INSTALL_TCL AND BUILD_SHARED_LIBS)
|
||||||
set (INSTALL_TCL OFF CACHE BOOL "${INSTALL_TCL_DESCR}")
|
set (INSTALL_TCL OFF CACHE BOOL "${INSTALL_TCL_DESCR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@@ -14,30 +14,30 @@ if (NOT DEFINED 3RDPARTY_TCL_INCLUDE_DIR)
|
|||||||
set (3RDPARTY_TCL_INCLUDE_DIR "" CACHE FILEPATH "The directory containing headers of tcl")
|
set (3RDPARTY_TCL_INCLUDE_DIR "" CACHE FILEPATH "The directory containing headers of tcl")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if (BUILD_SHARED_LIBS)
|
||||||
|
# tcl library file (with absolute path)
|
||||||
|
if (NOT DEFINED 3RDPARTY_TCL_LIBRARY OR NOT 3RDPARTY_TCL_LIBRARY_DIR)
|
||||||
|
set (3RDPARTY_TCL_LIBRARY "" CACHE FILEPATH "tcl library" FORCE)
|
||||||
|
endif()
|
||||||
|
|
||||||
# tcl library file (with absolute path)
|
# tcl library directory
|
||||||
if (NOT DEFINED 3RDPARTY_TCL_LIBRARY OR NOT 3RDPARTY_TCL_LIBRARY_DIR)
|
if (NOT DEFINED 3RDPARTY_TCL_LIBRARY_DIR)
|
||||||
set (3RDPARTY_TCL_LIBRARY "" CACHE FILEPATH "tcl library" FORCE)
|
set (3RDPARTY_TCL_LIBRARY_DIR "" CACHE FILEPATH "The directory containing tcl library")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# tcl library directory
|
# tcl shared library (with absolute path)
|
||||||
if (NOT DEFINED 3RDPARTY_TCL_LIBRARY_DIR)
|
if (WIN32)
|
||||||
set (3RDPARTY_TCL_LIBRARY_DIR "" CACHE FILEPATH "The directory containing tcl library")
|
if (NOT DEFINED 3RDPARTY_TCL_DLL OR NOT 3RDPARTY_TCL_DLL_DIR)
|
||||||
endif()
|
set (3RDPARTY_TCL_DLL "" CACHE FILEPATH "tcl shared library" FORCE)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
# tcl shared library (with absolute path)
|
# tcl shared library directory
|
||||||
if (WIN32)
|
if (WIN32 AND NOT DEFINED 3RDPARTY_TCL_DLL_DIR)
|
||||||
if (NOT DEFINED 3RDPARTY_TCL_DLL OR NOT 3RDPARTY_TCL_DLL_DIR)
|
set (3RDPARTY_TCL_DLL_DIR "" CACHE FILEPATH "The directory containing tcl shared library")
|
||||||
set (3RDPARTY_TCL_DLL "" CACHE FILEPATH "tcl shared library" FORCE)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# tcl shared library directory
|
|
||||||
if (WIN32 AND NOT DEFINED 3RDPARTY_TCL_DLL_DIR)
|
|
||||||
set (3RDPARTY_TCL_DLL_DIR "" CACHE FILEPATH "The directory containing tcl shared library")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
|
|
||||||
# search for tcl in user defined directory
|
# search for tcl in user defined directory
|
||||||
if (NOT 3RDPARTY_TCL_DIR AND 3RDPARTY_DIR)
|
if (NOT 3RDPARTY_TCL_DIR AND 3RDPARTY_DIR)
|
||||||
FIND_PRODUCT_DIR("${3RDPARTY_DIR}" tcl TCL_DIR_NAME)
|
FIND_PRODUCT_DIR("${3RDPARTY_DIR}" tcl TCL_DIR_NAME)
|
||||||
@@ -64,197 +64,203 @@ if (NOT 3RDPARTY_TCL_INCLUDE_DIR)
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# tcl dir and library
|
if (BUILD_SHARED_LIBS)
|
||||||
if (NOT 3RDPARTY_TCL_LIBRARY)
|
# tcl dir and library
|
||||||
if (TCL_LIBRARY AND EXISTS "${TCL_LIBRARY}")
|
if (NOT 3RDPARTY_TCL_LIBRARY)
|
||||||
set (3RDPARTY_TCL_LIBRARY "${TCL_LIBRARY}" CACHE FILEPATH "TCL library" FORCE)
|
if (TCL_LIBRARY AND EXISTS "${TCL_LIBRARY}")
|
||||||
|
set (3RDPARTY_TCL_LIBRARY "${TCL_LIBRARY}" CACHE FILEPATH "TCL library" FORCE)
|
||||||
|
|
||||||
if (NOT 3RDPARTY_TCL_LIBRARY_DIR)
|
if (NOT 3RDPARTY_TCL_LIBRARY_DIR)
|
||||||
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY}" PATH)
|
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY}" PATH)
|
||||||
set (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY_DIR}" CACHE FILEPATH "The directory containing TCL library" FORCE)
|
set (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY_DIR}" CACHE FILEPATH "The directory containing TCL library" FORCE)
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
if (NOT 3RDPARTY_TCL_DLL)
|
|
||||||
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .dll .a)
|
|
||||||
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "")
|
if (WIN32)
|
||||||
if (3RDPARTY_TCL_DLL_DIR)
|
if (NOT 3RDPARTY_TCL_DLL)
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DLL_DIR}")
|
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .dll .a)
|
||||||
elseif (3RDPARTY_TCL_DIR)
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DIR}/bin")
|
set (DLL_FOLDER_FOR_SEARCH "")
|
||||||
elseif (3RDPARTY_TCL_LIBRARY_DIR)
|
if (3RDPARTY_TCL_DLL_DIR)
|
||||||
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR_PARENT "${3RDPARTY_TCL_LIBRARY_DIR}" PATH)
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DLL_DIR}")
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_LIBRARY_DIR_PARENT}/bin")
|
elseif (3RDPARTY_TCL_DIR)
|
||||||
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DIR}/bin")
|
||||||
|
elseif (3RDPARTY_TCL_LIBRARY_DIR)
|
||||||
|
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR_PARENT "${3RDPARTY_TCL_LIBRARY_DIR}" PATH)
|
||||||
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_LIBRARY_DIR_PARENT}/bin")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set (3RDPARTY_TCL_DLL "3RDPARTY_TCL_DLL-NOTFOUND" CACHE FILEPATH "TCL shared library" FORCE)
|
||||||
|
find_library (3RDPARTY_TCL_DLL NAMES ${CSF_TclLibs}
|
||||||
|
PATHS "${DLL_FOLDER_FOR_SEARCH}"
|
||||||
|
NO_DEFAULT_PATH)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set (3RDPARTY_TCL_DLL "3RDPARTY_TCL_DLL-NOTFOUND" CACHE FILEPATH "TCL shared library" FORCE)
|
|
||||||
find_library (3RDPARTY_TCL_DLL NAMES ${CSF_TclLibs}
|
|
||||||
PATHS "${DLL_FOLDER_FOR_SEARCH}"
|
|
||||||
NO_DEFAULT_PATH)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
COMPLIANCE_PRODUCT_CONSISTENCY(TCL)
|
COMPLIANCE_PRODUCT_CONSISTENCY(TCL)
|
||||||
|
|
||||||
# tcl dir and library
|
if (BUILD_SHARED_LIBS)
|
||||||
if (NOT 3RDPARTY_TCL_LIBRARY)
|
# tcl dir and library
|
||||||
set (3RDPARTY_TCL_LIBRARY "3RDPARTY_TCL_LIBRARY-NOTFOUND" CACHE FILEPATH "TCL library" FORCE)
|
if (NOT 3RDPARTY_TCL_LIBRARY)
|
||||||
find_library (3RDPARTY_TCL_LIBRARY NAMES ${CSF_TclLibs}
|
set (3RDPARTY_TCL_LIBRARY "3RDPARTY_TCL_LIBRARY-NOTFOUND" CACHE FILEPATH "TCL library" FORCE)
|
||||||
PATHS "${3RDPARTY_TCL_LIBRARY_DIR}"
|
find_library (3RDPARTY_TCL_LIBRARY NAMES ${CSF_TclLibs}
|
||||||
NO_DEFAULT_PATH)
|
PATHS "${3RDPARTY_TCL_LIBRARY_DIR}"
|
||||||
|
NO_DEFAULT_PATH)
|
||||||
|
|
||||||
# search in another place if previous search doesn't find anything
|
# search in another place if previous search doesn't find anything
|
||||||
find_library (3RDPARTY_TCL_LIBRARY NAMES ${CSF_TclLibs}
|
find_library (3RDPARTY_TCL_LIBRARY NAMES ${CSF_TclLibs}
|
||||||
PATHS "${3RDPARTY_TCL_DIR}/lib"
|
PATHS "${3RDPARTY_TCL_DIR}/lib"
|
||||||
NO_DEFAULT_PATH)
|
NO_DEFAULT_PATH)
|
||||||
|
|
||||||
if (NOT 3RDPARTY_TCL_LIBRARY OR NOT EXISTS "${3RDPARTY_TCL_LIBRARY}")
|
|
||||||
set (3RDPARTY_TCL_LIBRARY "" CACHE FILEPATH "TCL library" FORCE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (NOT 3RDPARTY_TCL_LIBRARY_DIR AND 3RDPARTY_TCL_LIBRARY)
|
if (NOT 3RDPARTY_TCL_LIBRARY OR NOT EXISTS "${3RDPARTY_TCL_LIBRARY}")
|
||||||
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY}" PATH)
|
set (3RDPARTY_TCL_LIBRARY "" CACHE FILEPATH "TCL library" FORCE)
|
||||||
set (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY_DIR}" CACHE FILEPATH "The directory containing TCL library" FORCE)
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
set (3RDPARTY_TCL_LIBRARY_VERSION "")
|
|
||||||
if (3RDPARTY_TCL_LIBRARY AND EXISTS "${3RDPARTY_TCL_LIBRARY}")
|
|
||||||
get_filename_component (TCL_LIBRARY_NAME "${3RDPARTY_TCL_LIBRARY}" NAME)
|
|
||||||
string(REGEX REPLACE "^.*tcl([0-9]\\.*[0-9]).*$" "\\1" TCL_LIBRARY_VERSION "${TCL_LIBRARY_NAME}")
|
|
||||||
|
|
||||||
if (NOT "${TCL_LIBRARY_VERSION}" STREQUAL "${TCL_LIBRARY_NAME}")
|
|
||||||
set (3RDPARTY_TCL_LIBRARY_VERSION "${TCL_LIBRARY_VERSION}")
|
|
||||||
else() # if the version isn't found - seek other library with 8.6 or 8.5 version in the same dir
|
|
||||||
message (STATUS "Info: TCL version isn't found")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
set (3RDPARTY_TCL_LIBRARY_VERSION_WITH_DOT "")
|
|
||||||
if (3RDPARTY_TCL_LIBRARY_VERSION)
|
|
||||||
string (REGEX REPLACE "^.*([0-9])[^0-9]*[0-9].*$" "\\1" 3RDPARTY_TCL_MAJOR_VERSION "${3RDPARTY_TCL_LIBRARY_VERSION}")
|
|
||||||
string (REGEX REPLACE "^.*[0-9][^0-9]*([0-9]).*$" "\\1" 3RDPARTY_TCL_MINOR_VERSION "${3RDPARTY_TCL_LIBRARY_VERSION}")
|
|
||||||
set (3RDPARTY_TCL_LIBRARY_VERSION_WITH_DOT "${3RDPARTY_TCL_MAJOR_VERSION}.${3RDPARTY_TCL_MINOR_VERSION}")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
if (NOT 3RDPARTY_TCL_DLL)
|
|
||||||
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .dll .a)
|
|
||||||
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "")
|
|
||||||
if (3RDPARTY_TCL_DLL_DIR)
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DLL_DIR}")
|
|
||||||
elseif (3RDPARTY_TCL_DIR)
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DIR}/bin")
|
|
||||||
else()
|
|
||||||
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR_PARENT "${3RDPARTY_TCL_LIBRARY_DIR}" PATH)
|
|
||||||
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_LIBRARY_DIR_PARENT}/bin")
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set (3RDPARTY_TCL_DLL "3RDPARTY_TCL_DLL-NOTFOUND" CACHE FILEPATH "TCL shared library" FORCE)
|
if (NOT 3RDPARTY_TCL_LIBRARY_DIR AND 3RDPARTY_TCL_LIBRARY)
|
||||||
find_library (3RDPARTY_TCL_DLL NAMES tcl${3RDPARTY_TCL_LIBRARY_VERSION}
|
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY}" PATH)
|
||||||
PATHS "${DLL_FOLDER_FOR_SEARCH}"
|
set (3RDPARTY_TCL_LIBRARY_DIR "${3RDPARTY_TCL_LIBRARY_DIR}" CACHE FILEPATH "The directory containing TCL library" FORCE)
|
||||||
NO_DEFAULT_PATH)
|
|
||||||
|
|
||||||
if (NOT 3RDPARTY_TCL_DLL OR NOT EXISTS "${3RDPARTY_TCL_DLL}")
|
|
||||||
set (3RDPARTY_TCL_DLL "" CACHE FILEPATH "TCL shared library" FORCE)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
if (NOT 3RDPARTY_TCL_DLL_DIR AND 3RDPARTY_TCL_DLL)
|
|
||||||
get_filename_component (3RDPARTY_TCL_DLL_DIR "${3RDPARTY_TCL_DLL}" PATH)
|
set (3RDPARTY_TCL_LIBRARY_VERSION "")
|
||||||
set (3RDPARTY_TCL_DLL_DIR "${3RDPARTY_TCL_DLL_DIR}" CACHE FILEPATH "The directory containing TCL shared library" FORCE)
|
if (3RDPARTY_TCL_LIBRARY AND EXISTS "${3RDPARTY_TCL_LIBRARY}")
|
||||||
|
get_filename_component (TCL_LIBRARY_NAME "${3RDPARTY_TCL_LIBRARY}" NAME)
|
||||||
|
string(REGEX REPLACE "^.*tcl([0-9]\\.*[0-9]).*$" "\\1" TCL_LIBRARY_VERSION "${TCL_LIBRARY_NAME}")
|
||||||
|
|
||||||
|
if (NOT "${TCL_LIBRARY_VERSION}" STREQUAL "${TCL_LIBRARY_NAME}")
|
||||||
|
set (3RDPARTY_TCL_LIBRARY_VERSION "${TCL_LIBRARY_VERSION}")
|
||||||
|
else() # if the version isn't found - seek other library with 8.6 or 8.5 version in the same dir
|
||||||
|
message (STATUS "Info: TCL version isn't found")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
# include found paths to common variables
|
set (3RDPARTY_TCL_LIBRARY_VERSION_WITH_DOT "")
|
||||||
if (3RDPARTY_TCL_INCLUDE_DIR AND EXISTS "${3RDPARTY_TCL_INCLUDE_DIR}")
|
if (3RDPARTY_TCL_LIBRARY_VERSION)
|
||||||
list (APPEND 3RDPARTY_INCLUDE_DIRS "${3RDPARTY_TCL_INCLUDE_DIR}")
|
string (REGEX REPLACE "^.*([0-9])[^0-9]*[0-9].*$" "\\1" 3RDPARTY_TCL_MAJOR_VERSION "${3RDPARTY_TCL_LIBRARY_VERSION}")
|
||||||
else()
|
string (REGEX REPLACE "^.*[0-9][^0-9]*([0-9]).*$" "\\1" 3RDPARTY_TCL_MINOR_VERSION "${3RDPARTY_TCL_LIBRARY_VERSION}")
|
||||||
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TCL_INCLUDE_DIR)
|
set (3RDPARTY_TCL_LIBRARY_VERSION_WITH_DOT "${3RDPARTY_TCL_MAJOR_VERSION}.${3RDPARTY_TCL_MINOR_VERSION}")
|
||||||
endif()
|
|
||||||
|
|
||||||
if (3RDPARTY_TCL_LIBRARY AND EXISTS "${3RDPARTY_TCL_LIBRARY}")
|
|
||||||
list (APPEND 3RDPARTY_LIBRARY_DIRS "${3RDPARTY_TCL_LIBRARY_DIR}")
|
|
||||||
else()
|
|
||||||
list (APPEND 3RDPARTY_NO_LIBS 3RDPARTY_TCL_LIBRARY_DIR)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
if (3RDPARTY_TCL_DLL OR EXISTS "${3RDPARTY_TCL_DLL}")
|
|
||||||
list (APPEND 3RDPARTY_DLL_DIRS "${3RDPARTY_TCL_DLL_DIR}")
|
|
||||||
else()
|
|
||||||
list (APPEND 3RDPARTY_NO_DLLS 3RDPARTY_TCL_DLL_DIR)
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
# install tcl
|
|
||||||
if (INSTALL_TCL)
|
|
||||||
# include occt macros. compiler_bitness, os_wiht_bit, compiler
|
|
||||||
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/occt_macros")
|
|
||||||
|
|
||||||
OCCT_MAKE_OS_WITH_BITNESS()
|
|
||||||
OCCT_MAKE_COMPILER_SHORT_NAME()
|
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
# tcl 8.6 requires zlib. install all dlls from tcl bin folder that may contain zlib also
|
if (NOT 3RDPARTY_TCL_DLL)
|
||||||
|
set (CMAKE_FIND_LIBRARY_SUFFIXES .lib .dll .a)
|
||||||
|
|
||||||
# collect and install all dlls from tcl dll dirs
|
set (DLL_FOLDER_FOR_SEARCH "")
|
||||||
file (GLOB TCL_DLLS "${3RDPARTY_TCL_DLL_DIR}/*.dll")
|
if (3RDPARTY_TCL_DLL_DIR)
|
||||||
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DLL_DIR}")
|
||||||
|
elseif (3RDPARTY_TCL_DIR)
|
||||||
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_DIR}/bin")
|
||||||
|
else()
|
||||||
|
get_filename_component (3RDPARTY_TCL_LIBRARY_DIR_PARENT "${3RDPARTY_TCL_LIBRARY_DIR}" PATH)
|
||||||
|
set (DLL_FOLDER_FOR_SEARCH "${3RDPARTY_TCL_LIBRARY_DIR_PARENT}/bin")
|
||||||
|
endif()
|
||||||
|
|
||||||
if (SINGLE_GENERATOR)
|
set (3RDPARTY_TCL_DLL "3RDPARTY_TCL_DLL-NOTFOUND" CACHE FILEPATH "TCL shared library" FORCE)
|
||||||
install (FILES ${TCL_DLLS} DESTINATION "${INSTALL_DIR_BIN}")
|
find_library (3RDPARTY_TCL_DLL NAMES tcl${3RDPARTY_TCL_LIBRARY_VERSION}
|
||||||
else()
|
PATHS "${DLL_FOLDER_FOR_SEARCH}"
|
||||||
install (FILES ${TCL_DLLS}
|
NO_DEFAULT_PATH)
|
||||||
CONFIGURATIONS Release
|
|
||||||
DESTINATION "${INSTALL_DIR_BIN}")
|
if (NOT 3RDPARTY_TCL_DLL OR NOT EXISTS "${3RDPARTY_TCL_DLL}")
|
||||||
install (FILES ${TCL_DLLS}
|
set (3RDPARTY_TCL_DLL "" CACHE FILEPATH "TCL shared library" FORCE)
|
||||||
CONFIGURATIONS RelWithDebInfo
|
endif()
|
||||||
DESTINATION "${INSTALL_DIR_BIN}i")
|
|
||||||
install (FILES ${TCL_DLLS}
|
|
||||||
CONFIGURATIONS Debug
|
|
||||||
DESTINATION "${INSTALL_DIR_BIN}d")
|
|
||||||
endif()
|
endif()
|
||||||
else()
|
if (NOT 3RDPARTY_TCL_DLL_DIR AND 3RDPARTY_TCL_DLL)
|
||||||
get_filename_component(3RDPARTY_TCL_LIBRARY_REALPATH ${3RDPARTY_TCL_LIBRARY} REALPATH)
|
get_filename_component (3RDPARTY_TCL_DLL_DIR "${3RDPARTY_TCL_DLL}" PATH)
|
||||||
|
set (3RDPARTY_TCL_DLL_DIR "${3RDPARTY_TCL_DLL_DIR}" CACHE FILEPATH "The directory containing TCL shared library" FORCE)
|
||||||
if (SINGLE_GENERATOR)
|
|
||||||
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH} DESTINATION "${INSTALL_DIR_LIB}")
|
|
||||||
else()
|
|
||||||
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH}
|
|
||||||
CONFIGURATIONS Release
|
|
||||||
DESTINATION "${INSTALL_DIR_LIB}")
|
|
||||||
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH}
|
|
||||||
CONFIGURATIONS RelWithDebInfo
|
|
||||||
DESTINATION "${INSTALL_DIR_LIB}i")
|
|
||||||
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH}
|
|
||||||
CONFIGURATIONS Debug
|
|
||||||
DESTINATION "${INSTALL_DIR_LIB}d")
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (TCL_TCLSH_VERSION)
|
# include found paths to common variables
|
||||||
# tcl is required to install in lib folder (without)
|
if (3RDPARTY_TCL_INCLUDE_DIR AND EXISTS "${3RDPARTY_TCL_INCLUDE_DIR}")
|
||||||
install (DIRECTORY "${3RDPARTY_TCL_LIBRARY_DIR}/tcl8" DESTINATION "${INSTALL_DIR_LIB}")
|
list (APPEND 3RDPARTY_INCLUDE_DIRS "${3RDPARTY_TCL_INCLUDE_DIR}")
|
||||||
install (DIRECTORY "${3RDPARTY_TCL_LIBRARY_DIR}/tcl${TCL_TCLSH_VERSION}" DESTINATION "${INSTALL_DIR_LIB}")
|
|
||||||
else()
|
else()
|
||||||
message (STATUS "\nWarning: tclX.X subdir won't be copied during the installation process.")
|
list (APPEND 3RDPARTY_NOT_INCLUDED 3RDPARTY_TCL_INCLUDE_DIR)
|
||||||
message (STATUS "Try seeking tcl within another folder by changing 3RDPARTY_TCL_DIR variable.")
|
endif()
|
||||||
|
|
||||||
|
if (3RDPARTY_TCL_LIBRARY AND EXISTS "${3RDPARTY_TCL_LIBRARY}")
|
||||||
|
list (APPEND 3RDPARTY_LIBRARY_DIRS "${3RDPARTY_TCL_LIBRARY_DIR}")
|
||||||
|
else()
|
||||||
|
list (APPEND 3RDPARTY_NO_LIBS 3RDPARTY_TCL_LIBRARY_DIR)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set (USED_3RDPARTY_TCL_DIR "")
|
|
||||||
else()
|
|
||||||
# the library directory for using by the executable
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
set (USED_3RDPARTY_TCL_DIR ${3RDPARTY_TCL_DLL_DIR})
|
if (3RDPARTY_TCL_DLL OR EXISTS "${3RDPARTY_TCL_DLL}")
|
||||||
else()
|
list (APPEND 3RDPARTY_DLL_DIRS "${3RDPARTY_TCL_DLL_DIR}")
|
||||||
set (USED_3RDPARTY_TCL_DIR ${3RDPARTY_TCL_LIBRARY_DIR})
|
else()
|
||||||
|
list (APPEND 3RDPARTY_NO_DLLS 3RDPARTY_TCL_DLL_DIR)
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
mark_as_advanced (3RDPARTY_TCL_LIBRARY 3RDPARTY_TCL_DLL)
|
# install tcl
|
||||||
|
if (INSTALL_TCL)
|
||||||
|
# include occt macros. compiler_bitness, os_wiht_bit, compiler
|
||||||
|
OCCT_INCLUDE_CMAKE_FILE ("adm/cmake/occt_macros")
|
||||||
|
|
||||||
|
OCCT_MAKE_OS_WITH_BITNESS()
|
||||||
|
OCCT_MAKE_COMPILER_SHORT_NAME()
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
# tcl 8.6 requires zlib. install all dlls from tcl bin folder that may contain zlib also
|
||||||
|
|
||||||
|
# collect and install all dlls from tcl dll dirs
|
||||||
|
file (GLOB TCL_DLLS "${3RDPARTY_TCL_DLL_DIR}/*.dll")
|
||||||
|
|
||||||
|
if (SINGLE_GENERATOR)
|
||||||
|
install (FILES ${TCL_DLLS} DESTINATION "${INSTALL_DIR_BIN}")
|
||||||
|
else()
|
||||||
|
install (FILES ${TCL_DLLS}
|
||||||
|
CONFIGURATIONS Release
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}")
|
||||||
|
install (FILES ${TCL_DLLS}
|
||||||
|
CONFIGURATIONS RelWithDebInfo
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}i")
|
||||||
|
install (FILES ${TCL_DLLS}
|
||||||
|
CONFIGURATIONS Debug
|
||||||
|
DESTINATION "${INSTALL_DIR_BIN}d")
|
||||||
|
endif()
|
||||||
|
else()
|
||||||
|
get_filename_component(3RDPARTY_TCL_LIBRARY_REALPATH ${3RDPARTY_TCL_LIBRARY} REALPATH)
|
||||||
|
|
||||||
|
if (SINGLE_GENERATOR)
|
||||||
|
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH} DESTINATION "${INSTALL_DIR_LIB}")
|
||||||
|
else()
|
||||||
|
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH}
|
||||||
|
CONFIGURATIONS Release
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}")
|
||||||
|
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH}
|
||||||
|
CONFIGURATIONS RelWithDebInfo
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}i")
|
||||||
|
install (FILES ${3RDPARTY_TCL_LIBRARY_REALPATH}
|
||||||
|
CONFIGURATIONS Debug
|
||||||
|
DESTINATION "${INSTALL_DIR_LIB}d")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (TCL_TCLSH_VERSION)
|
||||||
|
# tcl is required to install in lib folder (without)
|
||||||
|
install (DIRECTORY "${3RDPARTY_TCL_LIBRARY_DIR}/tcl8" DESTINATION "${INSTALL_DIR_LIB}")
|
||||||
|
install (DIRECTORY "${3RDPARTY_TCL_LIBRARY_DIR}/tcl${TCL_TCLSH_VERSION}" DESTINATION "${INSTALL_DIR_LIB}")
|
||||||
|
else()
|
||||||
|
message (STATUS "\nWarning: tclX.X subdir won't be copyied during the installation process.")
|
||||||
|
message (STATUS "Try seeking tcl within another folder by changing 3RDPARTY_TCL_DIR variable.")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set (USED_3RDPARTY_TCL_DIR "")
|
||||||
|
else()
|
||||||
|
# the library directory for using by the executable
|
||||||
|
if (WIN32)
|
||||||
|
set (USED_3RDPARTY_TCL_DIR ${3RDPARTY_TCL_DLL_DIR})
|
||||||
|
else()
|
||||||
|
set (USED_3RDPARTY_TCL_DIR ${3RDPARTY_TCL_LIBRARY_DIR})
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
mark_as_advanced (3RDPARTY_TCL_LIBRARY 3RDPARTY_TCL_DLL)
|
||||||
|
endif()
|
||||||
|
|
||||||
if (TK_FOUND AND 3RDPARTY_TCL_DIR)
|
if (TK_FOUND AND 3RDPARTY_TCL_DIR)
|
||||||
|
|
||||||
@@ -279,3 +285,10 @@ OCCT_CHECK_AND_UNSET (TK_LIBRARY)
|
|||||||
OCCT_CHECK_AND_UNSET (TK_INCLUDE_PATH)
|
OCCT_CHECK_AND_UNSET (TK_INCLUDE_PATH)
|
||||||
OCCT_CHECK_AND_UNSET (TK_WISH)
|
OCCT_CHECK_AND_UNSET (TK_WISH)
|
||||||
|
|
||||||
|
if (NOT BUILD_SHARED_LIBS)
|
||||||
|
OCCT_CHECK_AND_UNSET (3RDPARTY_TCL_LIBRARY)
|
||||||
|
OCCT_CHECK_AND_UNSET (3RDPARTY_TCL_LIBRARY_DIR)
|
||||||
|
OCCT_CHECK_AND_UNSET (3RDPARTY_TCL_DLL)
|
||||||
|
OCCT_CHECK_AND_UNSET (3RDPARTY_TCL_DLL_DIR)
|
||||||
|
OCCT_CHECK_AND_UNSET (INSTALL_TCL)
|
||||||
|
endif()
|
||||||
|
@@ -250,7 +250,7 @@ if (BUILD_SHARED_LIBS)
|
|||||||
# tk is required to install in lib folder (without)
|
# tk is required to install in lib folder (without)
|
||||||
install (DIRECTORY "${3RDPARTY_TK_LIBRARY_DIR}/tk${TCL_TCLSH_VERSION}" DESTINATION "${INSTALL_DIR_LIB}")
|
install (DIRECTORY "${3RDPARTY_TK_LIBRARY_DIR}/tk${TCL_TCLSH_VERSION}" DESTINATION "${INSTALL_DIR_LIB}")
|
||||||
else()
|
else()
|
||||||
message (STATUS "\nWarning: tkX.X subdir won't be copied during the installation process.")
|
message (STATUS "\nWarning: tkX.X subdir won't be copyied during the installation process.")
|
||||||
message (STATUS "Try seeking tk within another folder by changing 3RDPARTY_TK_DIR variable.")
|
message (STATUS "Try seeking tk within another folder by changing 3RDPARTY_TK_DIR variable.")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
@@ -38,9 +38,6 @@ set (BUILD_ENABLE_FPE_SIGNAL_HANDLER_DESCR
|
|||||||
Corresponding environment variable (CSF_FPE) can be changed manually
|
Corresponding environment variable (CSF_FPE) can be changed manually
|
||||||
in custom.bat/sh scripts without regeneration by CMake.")
|
in custom.bat/sh scripts without regeneration by CMake.")
|
||||||
|
|
||||||
set (BUILD_FORCE_RelWithDebInfo_DESCR
|
|
||||||
"Generate PDB files within normal Release build.")
|
|
||||||
|
|
||||||
set (BUILD_USE_PCH_DESCR
|
set (BUILD_USE_PCH_DESCR
|
||||||
"Use precompiled headers to accelerate the build.
|
"Use precompiled headers to accelerate the build.
|
||||||
Precompiled headers are generated automatically by Cotire tool.")
|
Precompiled headers are generated automatically by Cotire tool.")
|
||||||
@@ -92,7 +89,6 @@ INSTALL_MESSAGE (INSTALL_TEST_CASES "non-regression OCCT test scripts")
|
|||||||
INSTALL_MESSAGE (INSTALL_DOC_Overview "OCCT overview documentation (HTML format)")
|
INSTALL_MESSAGE (INSTALL_DOC_Overview "OCCT overview documentation (HTML format)")
|
||||||
INSTALL_MESSAGE (INSTALL_FFMPEG "FFmpeg binaries")
|
INSTALL_MESSAGE (INSTALL_FFMPEG "FFmpeg binaries")
|
||||||
INSTALL_MESSAGE (INSTALL_FREEIMAGE "FreeImage binaries")
|
INSTALL_MESSAGE (INSTALL_FREEIMAGE "FreeImage binaries")
|
||||||
INSTALL_MESSAGE (INSTALL_OPENVR "OpenVR binaries")
|
|
||||||
INSTALL_MESSAGE (INSTALL_EIGEN "EIGEN header files")
|
INSTALL_MESSAGE (INSTALL_EIGEN "EIGEN header files")
|
||||||
INSTALL_MESSAGE (INSTALL_EGL "EGL binaries")
|
INSTALL_MESSAGE (INSTALL_EGL "EGL binaries")
|
||||||
INSTALL_MESSAGE (INSTALL_GLES2 "OpenGL ES 2.0 binaries")
|
INSTALL_MESSAGE (INSTALL_GLES2 "OpenGL ES 2.0 binaries")
|
||||||
@@ -158,38 +154,25 @@ set (3RDPARTY_DIR_DESCR
|
|||||||
third-party product have been found - corresponding CMake variables will be specified
|
third-party product have been found - corresponding CMake variables will be specified
|
||||||
(VTK: 3RDPARTY_VTK_DIR, 3RDPARTY_VTK_INCLUDE_DIR, 3RDPARTY_VTK_LIBRARY_DIR)")
|
(VTK: 3RDPARTY_VTK_DIR, 3RDPARTY_VTK_INCLUDE_DIR, 3RDPARTY_VTK_LIBRARY_DIR)")
|
||||||
|
|
||||||
set (USE_TK_DESCR
|
|
||||||
"Indicates whether Tk product should be used by Draw Harness for user interface")
|
|
||||||
|
|
||||||
set (USE_FREETYPE_DESCR
|
|
||||||
"Indicates whether FreeType product should be used in OCCT for text rendering using external font files")
|
|
||||||
|
|
||||||
set (USE_FFMPEG_DESCR
|
set (USE_FFMPEG_DESCR
|
||||||
"Indicates whether FFmpeg framework is used or not. FFmpeg stands for
|
"Indicates whether FFmpeg framework is used or not. FFmpeg stands for
|
||||||
multimedia data handling, open-source software libraries used for video encoding and decoding.")
|
multimedia data handling, open-source software libraries used for video encoding and decoding.")
|
||||||
|
|
||||||
set (USE_FREEIMAGE_DESCR
|
set (USE_FREEIMAGE_DESCR
|
||||||
"Indicates whether FreeImage product should be used in OCCT visualization
|
"Indicates whether Freeimage product should be used in OCCT visualization
|
||||||
module for support of popular graphics image formats (PNG, BMP etc)")
|
module for support of popular graphics image formats (PNG, BMP etc)")
|
||||||
|
|
||||||
set (USE_OPENVR_DESCR
|
|
||||||
"Indicates whether OpenVR should be used in OCCT visualization module for VR support")
|
|
||||||
|
|
||||||
set (USE_RAPIDJSON_DESCR
|
set (USE_RAPIDJSON_DESCR
|
||||||
"Indicates whether RapidJSON product should be used in OCCT DataExchange
|
"Indicates whether RapidJSON product should be used in OCCT DataExchange
|
||||||
module for support of JSON-based formats like glTF")
|
module for support of JSON-based formats like glTF")
|
||||||
|
|
||||||
set (USE_DRACO_DESCR
|
|
||||||
"Indicates whether Draco mesh decoding library should be used by glTF reader")
|
|
||||||
|
|
||||||
set (USE_EGL_DESCR
|
set (USE_EGL_DESCR
|
||||||
"Indicates whether EGL should be used in OCCT visualization
|
"Indicates whether EGL should be used in OCCT visualization
|
||||||
module instead of conventional OpenGL context creation APIs")
|
module instead of conventional OpenGL context creation APIs")
|
||||||
|
|
||||||
set (USE_OPENGL_DESCR
|
|
||||||
"Indicates whether OpenGL desktop should be used in OCCT visualization module")
|
|
||||||
set (USE_GLES2_DESCR
|
set (USE_GLES2_DESCR
|
||||||
"Indicates whether OpenGL ES 2.0 should be used in OCCT visualization module")
|
"Indicates whether OpenGL ES 2.0 should be used in OCCT visualization
|
||||||
|
module instead of desktop OpenGL")
|
||||||
|
|
||||||
set (USE_TBB_DESCR
|
set (USE_TBB_DESCR
|
||||||
"Indicates whether TBB is used or not. TBB stands for Threading Building Blocks,
|
"Indicates whether TBB is used or not. TBB stands for Threading Building Blocks,
|
||||||
@@ -202,7 +185,7 @@ ToolKit, the technology of Kitware Inc intended for general-purpose scientific
|
|||||||
visualization. OCCT comes with a bridge between CAD data representation and
|
visualization. OCCT comes with a bridge between CAD data representation and
|
||||||
VTK by means of its dedicated VIS component (VTK Integration Services).")
|
VTK by means of its dedicated VIS component (VTK Integration Services).")
|
||||||
|
|
||||||
set (USE_XLIB_DESCR "Indicates whether X11 is used or not")
|
set (USE_GLX_DESCR "Indicates whether X11 OpenGl on OSX is used or not")
|
||||||
|
|
||||||
set (USE_D3D_DESCR "Indicates whether optional Direct3D wrapper in OCCT visualization module should be build or not")
|
set (USE_D3D_DESCR "Indicates whether optional Direct3D wrapper in OCCT visualization module should be build or not")
|
||||||
|
|
||||||
|
@@ -66,15 +66,10 @@ if (3RDPARTY_VTK_DIR AND EXISTS "${3RDPARTY_VTK_DIR}")
|
|||||||
set (ENV{VTK_DIR} ${CACHED_VTK_DIR})
|
set (ENV{VTK_DIR} ${CACHED_VTK_DIR})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
unset (IS_VTK_9XX)
|
|
||||||
if (VTK_FOUND)
|
if (VTK_FOUND)
|
||||||
message ("VTK version (${VTK_VERSION})")
|
|
||||||
if(VTK_MAJOR_VERSION EQUAL 8 AND VTK_MINOR_VERSION GREATER 9 OR VTK_MAJOR_VERSION GREATER 8)
|
# add compiler flags, preprocessor definitions, include and link dirs
|
||||||
set (IS_VTK_9XX 1)
|
include (${VTK_USE_FILE})
|
||||||
else()
|
|
||||||
# add compiler flags, preprocessor definitions, include and link dirs
|
|
||||||
include (${VTK_USE_FILE})
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (VTK_LIBRARIES)
|
if (VTK_LIBRARIES)
|
||||||
|
|
||||||
@@ -86,83 +81,79 @@ if (VTK_FOUND)
|
|||||||
# endif()
|
# endif()
|
||||||
|
|
||||||
foreach (VTK_LIBRARY ${VTK_LIBRARIES})
|
foreach (VTK_LIBRARY ${VTK_LIBRARIES})
|
||||||
if (IS_VTK_9XX)
|
string (REGEX MATCH "^vtk" IS_VTK_LIBRARY ${VTK_LIBRARY})
|
||||||
string (REGEX MATCH "^VTK::" IS_VTK_LIBRARY ${VTK_LIBRARY})
|
if (IS_VTK_LIBRARY AND TARGET ${VTK_LIBRARY})
|
||||||
else()
|
# get paths from corresponding variables
|
||||||
string (REGEX MATCH "^vtk" IS_VTK_LIBRARY ${VTK_LIBRARY})
|
if (${VTK_LIBRARY}_INCLUDE_DIRS AND EXISTS "${${VTK_LIBRARY}_INCLUDE_DIRS}")
|
||||||
endif()
|
list (APPEND 3RDPARTY_VTK_INCLUDE_DIRS "${${VTK_LIBRARY}_INCLUDE_DIRS}")
|
||||||
if (NOT IS_VTK_LIBRARY OR NOT TARGET ${VTK_LIBRARY})
|
|
||||||
continue()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# get paths from corresponding variables
|
|
||||||
if (${VTK_LIBRARY}_INCLUDE_DIRS AND EXISTS "${${VTK_LIBRARY}_INCLUDE_DIRS}")
|
|
||||||
list (APPEND 3RDPARTY_VTK_INCLUDE_DIRS "${${VTK_LIBRARY}_INCLUDE_DIRS}")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (${VTK_LIBRARY}_LIBRARY_DIRS AND EXISTS "${${VTK_LIBRARY}_LIBRARY_DIRS}")
|
|
||||||
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${${VTK_LIBRARY}_LIBRARY_DIRS}")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS AND EXISTS "${${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS}")
|
|
||||||
list (APPEND 3RDPARTY_VTK_DLL_DIRS "${${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS}")
|
|
||||||
if (NOT WIN32)
|
|
||||||
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS}")
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
# get paths from corresponding properties
|
if (${VTK_LIBRARY}_LIBRARY_DIRS AND EXISTS "${${VTK_LIBRARY}_LIBRARY_DIRS}")
|
||||||
get_target_property (TARGET_VTK_IMPORT_CONFS ${VTK_LIBRARY} IMPORTED_CONFIGURATIONS)
|
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${${VTK_LIBRARY}_LIBRARY_DIRS}")
|
||||||
if (TARGET_VTK_IMPORT_CONFS)
|
|
||||||
list (GET TARGET_VTK_IMPORT_CONFS 0 CHOSEN_IMPORT_CONF)
|
|
||||||
|
|
||||||
# todo: choose configuration in connection with the build type
|
|
||||||
#if (CMAKE_BUILD_TYPE)
|
|
||||||
# foreach (IMPORT_CONF ${TARGET_VTK_IMPORT_CONFS})
|
|
||||||
# endforeach()
|
|
||||||
#endif()
|
|
||||||
|
|
||||||
# Work-around against link failure in case if VTK contains dependency
|
|
||||||
# on DirectX: its run-time is always present on Windows, but SDK can
|
|
||||||
# be absent on current workstation, while not actually needed for
|
|
||||||
# OCCT linking.
|
|
||||||
# VTK 6.1 for VC 10
|
|
||||||
get_target_property (TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${VTK_LIBRARY} IMPORTED_LINK_INTERFACE_LIBRARIES_${CHOSEN_IMPORT_CONF})
|
|
||||||
if(TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES)
|
|
||||||
string (REGEX MATCH "[^;]*d3d[0-9]+[.]lib" HARDCODED_D3D9_LIB "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
|
||||||
if (HARDCODED_D3D9_LIB)
|
|
||||||
message (STATUS "Warning: ${HARDCODED_D3D9_LIB} has been removed from imported dependencies of ${VTK_LIBRARY}")
|
|
||||||
|
|
||||||
list (REMOVE_ITEM TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${HARDCODED_D3D9_LIB})
|
|
||||||
set_target_properties (${VTK_LIBRARY} PROPERTIES IMPORTED_LINK_INTERFACE_LIBRARIES_${CHOSEN_IMPORT_CONF} "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
# VTK 6.1 for VC 12, 14
|
|
||||||
get_target_property (TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${VTK_LIBRARY} INTERFACE_LINK_LIBRARIES)
|
|
||||||
if(TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES)
|
|
||||||
string (REGEX MATCH "[^;]*d3d[0-9]+[.]lib" HARDCODED_D3D9_LIB "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
|
||||||
if (HARDCODED_D3D9_LIB)
|
|
||||||
message (STATUS "Warning: ${HARDCODED_D3D9_LIB} has been removed from imported dependencies of ${VTK_LIBRARY}")
|
|
||||||
|
|
||||||
list (REMOVE_ITEM TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${HARDCODED_D3D9_LIB})
|
if (${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS AND EXISTS "${${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS}")
|
||||||
set_target_properties (${VTK_LIBRARY} PROPERTIES INTERFACE_LINK_LIBRARIES "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
list (APPEND 3RDPARTY_VTK_DLL_DIRS "${${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS}")
|
||||||
|
if (NOT WIN32)
|
||||||
|
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${${VTK_LIBRARY}_RUNTIME_LIBRARY_DIRS}")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
get_target_property (TARGET_PROPERTY_IMP_PATH ${VTK_LIBRARY} IMPORTED_IMPLIB_${CHOSEN_IMPORT_CONF})
|
# get paths from corresponding properties
|
||||||
if(TARGET_PROPERTY_IMP_PATH AND EXISTS "${TARGET_PROPERTY_IMP_PATH}")
|
get_target_property (TARGET_VTK_IMPORT_CONFS ${VTK_LIBRARY} IMPORTED_CONFIGURATIONS)
|
||||||
get_filename_component (TARGET_PROPERTY_IMP_DIR "${TARGET_PROPERTY_IMP_PATH}" PATH)
|
|
||||||
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${TARGET_PROPERTY_IMP_DIR}")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
get_target_property (TARGET_PROPERTY_LOCATION_PATH ${VTK_LIBRARY} IMPORTED_LOCATION_${CHOSEN_IMPORT_CONF})
|
if (TARGET_VTK_IMPORT_CONFS)
|
||||||
if(TARGET_PROPERTY_LOCATION_PATH AND EXISTS "${TARGET_PROPERTY_LOCATION_PATH}")
|
list (GET TARGET_VTK_IMPORT_CONFS 0 CHOSEN_IMPORT_CONF)
|
||||||
get_filename_component (TARGET_PROPERTY_LOCATION_DIR "${TARGET_PROPERTY_LOCATION_PATH}" PATH)
|
|
||||||
|
|
||||||
if (WIN32)
|
# todo: choose configuration in connection with the build type
|
||||||
list (APPEND 3RDPARTY_VTK_DLL_DIRS "${TARGET_PROPERTY_LOCATION_DIR}")
|
#if (CMAKE_BUILD_TYPE)
|
||||||
else()
|
# foreach (IMPORT_CONF ${TARGET_VTK_IMPORT_CONFS})
|
||||||
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${TARGET_PROPERTY_LOCATION_DIR}")
|
# endforeach()
|
||||||
|
#endif()
|
||||||
|
|
||||||
|
# Work-around against link failure in case if VTK contains dependency
|
||||||
|
# on DirectX: its run-time is always present on Windows, but SDK can
|
||||||
|
# be absent on current workstation, while not actually needed for
|
||||||
|
# OCCT linking.
|
||||||
|
# VTK 6.1 for VC 10
|
||||||
|
get_target_property (TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${VTK_LIBRARY} IMPORTED_LINK_INTERFACE_LIBRARIES_${CHOSEN_IMPORT_CONF})
|
||||||
|
if(TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES)
|
||||||
|
string (REGEX MATCH "[^;]*d3d[0-9]+[.]lib" HARDCODED_D3D9_LIB "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
||||||
|
if (HARDCODED_D3D9_LIB)
|
||||||
|
message (STATUS "Warning: ${HARDCODED_D3D9_LIB} has been removed from imported dependencies of ${VTK_LIBRARY}")
|
||||||
|
|
||||||
|
list (REMOVE_ITEM TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${HARDCODED_D3D9_LIB})
|
||||||
|
set_target_properties (${VTK_LIBRARY} PROPERTIES IMPORTED_LINK_INTERFACE_LIBRARIES_${CHOSEN_IMPORT_CONF} "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
# VTK 6.1 for VC 12, 14
|
||||||
|
get_target_property (TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${VTK_LIBRARY} INTERFACE_LINK_LIBRARIES)
|
||||||
|
if(TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES)
|
||||||
|
string (REGEX MATCH "[^;]*d3d[0-9]+[.]lib" HARDCODED_D3D9_LIB "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
||||||
|
if (HARDCODED_D3D9_LIB)
|
||||||
|
message (STATUS "Warning: ${HARDCODED_D3D9_LIB} has been removed from imported dependencies of ${VTK_LIBRARY}")
|
||||||
|
|
||||||
|
list (REMOVE_ITEM TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES ${HARDCODED_D3D9_LIB})
|
||||||
|
set_target_properties (${VTK_LIBRARY} PROPERTIES INTERFACE_LINK_LIBRARIES "${TARGET_PROPERTY_IMP_LINK_INTERFACE_LIBRARIES}")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
get_target_property (TARGET_PROPERTY_IMP_PATH ${VTK_LIBRARY} IMPORTED_IMPLIB_${CHOSEN_IMPORT_CONF})
|
||||||
|
if(TARGET_PROPERTY_IMP_PATH AND EXISTS "${TARGET_PROPERTY_IMP_PATH}")
|
||||||
|
get_filename_component (TARGET_PROPERTY_IMP_DIR "${TARGET_PROPERTY_IMP_PATH}" PATH)
|
||||||
|
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${TARGET_PROPERTY_IMP_DIR}")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
get_target_property (TARGET_PROPERTY_LOCATION_PATH ${VTK_LIBRARY} IMPORTED_LOCATION_${CHOSEN_IMPORT_CONF})
|
||||||
|
if(TARGET_PROPERTY_LOCATION_PATH AND EXISTS "${TARGET_PROPERTY_LOCATION_PATH}")
|
||||||
|
get_filename_component (TARGET_PROPERTY_LOCATION_DIR "${TARGET_PROPERTY_LOCATION_PATH}" PATH)
|
||||||
|
|
||||||
|
if (WIN32)
|
||||||
|
list (APPEND 3RDPARTY_VTK_DLL_DIRS "${TARGET_PROPERTY_LOCATION_DIR}")
|
||||||
|
else()
|
||||||
|
list (APPEND 3RDPARTY_VTK_LIBRARY_DIRS "${TARGET_PROPERTY_LOCATION_DIR}")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
@@ -196,7 +187,6 @@ if (VTK_FOUND)
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
# endif()
|
# endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
if (3RDPARTY_VTK_INCLUDE_DIR AND EXISTS "${3RDPARTY_VTK_INCLUDE_DIR}")
|
if (3RDPARTY_VTK_INCLUDE_DIR AND EXISTS "${3RDPARTY_VTK_INCLUDE_DIR}")
|
||||||
list (APPEND 3RDPARTY_INCLUDE_DIRS ${3RDPARTY_VTK_INCLUDE_DIR})
|
list (APPEND 3RDPARTY_INCLUDE_DIRS ${3RDPARTY_VTK_INCLUDE_DIR})
|
||||||
|
496
adm/genconf.tcl
@@ -56,52 +56,31 @@ lappend ::SYS_PRJNAME_LIST "Qt Creator (.pro)"
|
|||||||
|
|
||||||
set aPrjIndex [lsearch $::SYS_PRJFMT_LIST $::PRJFMT]
|
set aPrjIndex [lsearch $::SYS_PRJFMT_LIST $::PRJFMT]
|
||||||
set ::PRJNAME [lindex $::SYS_PRJNAME_LIST $aPrjIndex]
|
set ::PRJNAME [lindex $::SYS_PRJNAME_LIST $aPrjIndex]
|
||||||
set ::CONFIG "Release"
|
|
||||||
|
|
||||||
set SYS_VS_LIST {}
|
set SYS_VS_LIST {}
|
||||||
set SYS_VC_LIST {}
|
set SYS_VC_LIST {}
|
||||||
set SYS_VCVARS_LIST {}
|
set SYS_VCVARS_LIST {}
|
||||||
|
|
||||||
# detect installed Visual Studio 2017+ instances by running vswhere.exe
|
# detect installed Visual Studio 2017+ instances by running vswhere.exe
|
||||||
if { ! [catch {exec vswhere.exe -version "\[15.0,15.99\]" -latest -requires Microsoft.VisualStudio.Workload.NativeDesktop -property installationPath} res] && "$res" != "" } {
|
if { ! [catch {exec vswhere.exe -version "\[15.0,15.99\]" -latest -requires Microsoft.VisualStudio.Workload.NativeDesktop -property installationPath} res] } {
|
||||||
lappend ::SYS_VS_LIST "Visual Studio 2017 (15, toolset v141)"
|
lappend ::SYS_VS_LIST "Visual Studio 2017 (15, toolset v141)"
|
||||||
lappend ::SYS_VC_LIST "vc141"
|
lappend ::SYS_VC_LIST "vc141"
|
||||||
lappend ::SYS_VCVARS_LIST "$res\\VC\\Auxiliary\\Build\\vcvarsall.bat"
|
lappend ::SYS_VCVARS_LIST "$res\\VC\\vcvarsall.bat"
|
||||||
}
|
}
|
||||||
if { ! [catch {exec vswhere.exe -version "\[15.0,15.99\]" -latest -requires Microsoft.VisualStudio.Workload.Universal -property installationPath} res] && "$res" != "" } {
|
if { ! [catch {exec vswhere.exe -version "\[15.0,15.99\]" -latest -requires Microsoft.VisualStudio.Workload.Universal -property installationPath} res] } {
|
||||||
lappend ::SYS_VS_LIST "Visual Studio 2017 (15, toolset v141) UWP"
|
lappend ::SYS_VS_LIST "Visual Studio 2017 (15, toolset v141) UWP"
|
||||||
lappend ::SYS_VC_LIST "vc141-uwp"
|
lappend ::SYS_VC_LIST "vc141-uwp"
|
||||||
lappend ::SYS_VCVARS_LIST "$res\\VC\\Auxiliary\\Build\\vcvarsall.bat"
|
lappend ::SYS_VCVARS_LIST "$res\\VC\\vcvarsall.bat"
|
||||||
}
|
}
|
||||||
if { ! [catch {exec vswhere.exe -version "\[16.0,16.99\]" -latest -requires Microsoft.VisualStudio.Workload.NativeDesktop -property installationPath} res] && "$res" != "" } {
|
if { ! [catch {exec vswhere.exe -version "\[16.0,16.99\]" -latest -requires Microsoft.VisualStudio.Workload.NativeDesktop -property installationPath} res] } {
|
||||||
lappend ::SYS_VS_LIST "Visual Studio 2019 (16, toolset v142)"
|
lappend ::SYS_VS_LIST "Visual Studio 2019 (16, toolset v142)"
|
||||||
lappend ::SYS_VC_LIST "vc142"
|
lappend ::SYS_VC_LIST "vc142"
|
||||||
lappend ::SYS_VCVARS_LIST "$res\\VC\\Auxiliary\\Build\\vcvarsall.bat"
|
lappend ::SYS_VCVARS_LIST "$res\\VC\\vcvarsall.bat"
|
||||||
}
|
}
|
||||||
if { ! [catch {exec vswhere.exe -version "\[16.0,16.99\]" -latest -requires Microsoft.VisualStudio.Workload.Universal -property installationPath} res] && "$res" != "" } {
|
if { ! [catch {exec vswhere.exe -version "\[16.0,16.99\]" -latest -requires Microsoft.VisualStudio.Workload.Universal -property installationPath} res] } {
|
||||||
lappend ::SYS_VS_LIST "Visual Studio 2019 (16, toolset v142) UWP"
|
lappend ::SYS_VS_LIST "Visual Studio 2019 (16, toolset v142) UWP"
|
||||||
lappend ::SYS_VC_LIST "vc142-uwp"
|
lappend ::SYS_VC_LIST "vc142-uwp"
|
||||||
lappend ::SYS_VCVARS_LIST "$res\\VC\\Auxiliary\\Build\\vcvarsall.bat"
|
lappend ::SYS_VCVARS_LIST "$res\\VC\\vcvarsall.bat"
|
||||||
}
|
|
||||||
if { ! [catch {exec vswhere.exe -version "\[16.0,16.99\]" -latest -requires Microsoft.VisualStudio.Component.VC.ClangCL -property installationPath} res] && "$res" != "" } {
|
|
||||||
lappend ::SYS_VS_LIST "Visual Studio 2019 (16, toolset ClangCL)"
|
|
||||||
lappend ::SYS_VC_LIST "vclang"
|
|
||||||
lappend ::SYS_VCVARS_LIST "$res\\VC\Auxiliary\\Build\\vcvarsall.bat"
|
|
||||||
}
|
|
||||||
if { ! [catch {exec vswhere.exe -version "\[17.0,17.99\]" -latest -requires Microsoft.VisualStudio.Workload.NativeDesktop -property installationPath} res] && "$res" != "" } {
|
|
||||||
lappend ::SYS_VS_LIST "Visual Studio 2022 (17, toolset v143)"
|
|
||||||
lappend ::SYS_VC_LIST "vc143"
|
|
||||||
lappend ::SYS_VCVARS_LIST "$res\\VC\\Auxiliary\\Build\\vcvarsall.bat"
|
|
||||||
}
|
|
||||||
if { ! [catch {exec vswhere.exe -version "\[17.0,17.99\]" -latest -requires Microsoft.VisualStudio.Workload.Universal -property installationPath} res] && "$res" != "" } {
|
|
||||||
lappend ::SYS_VS_LIST "Visual Studio 2022 (17, toolset v143) UWP"
|
|
||||||
lappend ::SYS_VC_LIST "vc143-uwp"
|
|
||||||
lappend ::SYS_VCVARS_LIST "$res\\VC\\Auxiliary\\Build\\vcvarsall.bat"
|
|
||||||
}
|
|
||||||
if { ! [catch {exec vswhere.exe -version "\[17.0,17.99\]" -latest -requires Microsoft.VisualStudio.Component.VC.ClangCL -property installationPath} res] && "$res" != "" } {
|
|
||||||
lappend ::SYS_VS_LIST "Visual Studio 2022 (17, toolset ClangCL)"
|
|
||||||
lappend ::SYS_VC_LIST "vclang"
|
|
||||||
lappend ::SYS_VCVARS_LIST "$res\\VC\\Auxiliary\\Build\\vcvarsall.bat"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# detect installed Visual Studio instances from global environment
|
# detect installed Visual Studio instances from global environment
|
||||||
@@ -154,13 +133,6 @@ proc wokdep:gui:Close {} {
|
|||||||
exit
|
exit
|
||||||
}
|
}
|
||||||
|
|
||||||
proc wokdep:gui:configSuffix {} {
|
|
||||||
if { "$::CONFIG" == "Debug" } {
|
|
||||||
return "D"
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
proc wokdep:gui:SwitchConfig {} {
|
proc wokdep:gui:SwitchConfig {} {
|
||||||
set ::PRJFMT [lindex $::SYS_PRJFMT_LIST [.myFrame.myPrjFrame.myPrjCombo current]]
|
set ::PRJFMT [lindex $::SYS_PRJFMT_LIST [.myFrame.myPrjFrame.myPrjCombo current]]
|
||||||
set ::VCVER [lindex $::SYS_VC_LIST [.myFrame.myVsFrame.myVsCombo current]]
|
set ::VCVER [lindex $::SYS_VC_LIST [.myFrame.myVsFrame.myVsCombo current]]
|
||||||
@@ -171,15 +143,16 @@ proc wokdep:gui:SwitchConfig {} {
|
|||||||
set ::CSF_OPT_LIB64 {}
|
set ::CSF_OPT_LIB64 {}
|
||||||
set ::CSF_OPT_BIN32 {}
|
set ::CSF_OPT_BIN32 {}
|
||||||
set ::CSF_OPT_BIN64 {}
|
set ::CSF_OPT_BIN64 {}
|
||||||
set ::CSF_OPT_LIB32D {}
|
|
||||||
set ::CSF_OPT_LIB64D {}
|
|
||||||
set ::CSF_OPT_BIN32D {}
|
|
||||||
set ::CSF_OPT_BIN64D {}
|
|
||||||
wokdep:gui:UpdateList
|
wokdep:gui:UpdateList
|
||||||
}
|
}
|
||||||
|
|
||||||
proc wokdep:gui:SwitchArch {} {
|
proc wokdep:gui:SwitchArch {} {
|
||||||
wokdep:gui:Show3264Bitness ::aRowIter
|
if { "$::ARCH" == "32" } {
|
||||||
|
wokdep:gui:Show32Bitness ::aRowIter
|
||||||
|
}
|
||||||
|
if { "$::ARCH" == "64" } {
|
||||||
|
wokdep:gui:Show64Bitness ::aRowIter
|
||||||
|
}
|
||||||
|
|
||||||
if { [llength [grid info .myFrame.mySave]] != 0 } {
|
if { [llength [grid info .myFrame.mySave]] != 0 } {
|
||||||
grid forget .myFrame.mySave .myFrame.myClose
|
grid forget .myFrame.mySave .myFrame.myClose
|
||||||
@@ -190,16 +163,6 @@ proc wokdep:gui:SwitchArch {} {
|
|||||||
grid .myFrame.myClose -row $::aRowIter -column 6 -columnspan 2
|
grid .myFrame.myClose -row $::aRowIter -column 6 -columnspan 2
|
||||||
}
|
}
|
||||||
|
|
||||||
# update label text and visibility
|
|
||||||
font create wokdep:gui:EmptyFont -size -1
|
|
||||||
proc wokdep:gui:SetLabelText {theLabel theText} {
|
|
||||||
set aFont TkDefaultFont
|
|
||||||
if { $theText == "" } {
|
|
||||||
set aFont wokdep:gui:EmptyFont
|
|
||||||
}
|
|
||||||
$theLabel configure -text $theText -font $aFont
|
|
||||||
}
|
|
||||||
|
|
||||||
proc wokdep:gui:UpdateList {} {
|
proc wokdep:gui:UpdateList {} {
|
||||||
set anIncErrs {}
|
set anIncErrs {}
|
||||||
set anLib32Errs {}
|
set anLib32Errs {}
|
||||||
@@ -207,9 +170,7 @@ proc wokdep:gui:UpdateList {} {
|
|||||||
set anBin32Errs {}
|
set anBin32Errs {}
|
||||||
set anBin64Errs {}
|
set anBin64Errs {}
|
||||||
wokdep:SearchTclTk anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchTclTk anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
if { "$::HAVE_FREETYPE" == "true" } {
|
wokdep:SearchFreeType anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
wokdep:SearchFreeType anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
|
||||||
}
|
|
||||||
wokdep:SearchX11 anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchX11 anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
if { "$::HAVE_GLES2" == "true" } {
|
if { "$::HAVE_GLES2" == "true" } {
|
||||||
wokdep:SearchEGL anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchEGL anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
@@ -221,9 +182,6 @@ proc wokdep:gui:UpdateList {} {
|
|||||||
if { "$::HAVE_FFMPEG" == "true" } {
|
if { "$::HAVE_FFMPEG" == "true" } {
|
||||||
wokdep:SearchFFmpeg anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchFFmpeg anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
}
|
}
|
||||||
if { "$::HAVE_OPENVR" == "true" } {
|
|
||||||
wokdep:SearchOpenVR anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
|
||||||
}
|
|
||||||
if { "$::HAVE_TBB" == "true" } {
|
if { "$::HAVE_TBB" == "true" } {
|
||||||
wokdep:SearchTBB anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchTBB anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
}
|
}
|
||||||
@@ -235,11 +193,7 @@ proc wokdep:gui:UpdateList {} {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if { "$::HAVE_ZLIB" == "true" } {
|
if { "$::HAVE_ZLIB" == "true" } {
|
||||||
set aCheckLib "z"
|
wokdep:SearchStandardLibrary anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs "zlib" "zlib.h" "zlib" {"zlib"}
|
||||||
if { "$::tcl_platform(platform)" == "windows" } {
|
|
||||||
set aCheckLib "zlib"
|
|
||||||
}
|
|
||||||
wokdep:SearchStandardLibrary anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs "zlib" "zlib.h" "$aCheckLib" {"zlib"}
|
|
||||||
}
|
}
|
||||||
if { "$::HAVE_LIBLZMA" == "true" } {
|
if { "$::HAVE_LIBLZMA" == "true" } {
|
||||||
set aCheckLib "lzma"
|
set aCheckLib "lzma"
|
||||||
@@ -259,45 +213,19 @@ proc wokdep:gui:UpdateList {} {
|
|||||||
if { "$::HAVE_RAPIDJSON" == "true" } {
|
if { "$::HAVE_RAPIDJSON" == "true" } {
|
||||||
wokdep:SearchRapidJson anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchRapidJson anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
}
|
}
|
||||||
if { "$::HAVE_DRACO" == "true" } {
|
|
||||||
set aDummy {}
|
|
||||||
wokdep:SearchStandardLibrary anIncErrs anLib32Errs anLib64Errs aDummy aDummy "draco" "draco/compression/decode.h" "draco" {"draco"}
|
|
||||||
}
|
|
||||||
|
|
||||||
if {"$::BUILD_Inspector" == "true" } {
|
if { "$::CHECK_QT4" == "true" } {
|
||||||
set ::CHECK_QT "true"
|
wokdep:SearchQt4 anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
}
|
}
|
||||||
|
|
||||||
if { "$::CHECK_QT" == "true" } {
|
|
||||||
wokdep:SearchQt anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
|
||||||
}
|
|
||||||
|
|
||||||
if { "$::CHECK_JDK" == "true" } {
|
if { "$::CHECK_JDK" == "true" } {
|
||||||
wokdep:SearchJDK anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
wokdep:SearchJDK anIncErrs anLib32Errs anLib64Errs anBin32Errs anBin64Errs
|
||||||
}
|
}
|
||||||
|
|
||||||
wokdep:gui:SetLabelText .myFrame.myIncErrLbl [join $anIncErrs "\n"]
|
.myFrame.myIncErrLbl configure -text [join $anIncErrs "\n"]
|
||||||
|
.myFrame.myLib32ErrLbl configure -text [join $anLib32Errs "\n"]
|
||||||
wokdep:gui:SetLabelText .myFrame.myIncErrLbl [join $anIncErrs "\n"]
|
.myFrame.myLib64ErrLbl configure -text [join $anLib64Errs "\n"]
|
||||||
wokdep:gui:SetLabelText .myFrame.myLib32_ErrLbl [join $anLib32Errs "\n"]
|
.myFrame.myBin32ErrLbl configure -text [join $anBin32Errs "\n"]
|
||||||
wokdep:gui:SetLabelText .myFrame.myLib64_ErrLbl [join $anLib64Errs "\n"]
|
.myFrame.myBin64ErrLbl configure -text [join $anBin64Errs "\n"]
|
||||||
wokdep:gui:SetLabelText .myFrame.myBin32_ErrLbl [join $anBin32Errs "\n"]
|
|
||||||
wokdep:gui:SetLabelText .myFrame.myBin64_ErrLbl [join $anBin64Errs "\n"]
|
|
||||||
|
|
||||||
wokdep:gui:SetLabelText .myFrame.myLib32D_ErrLbl [join $anLib32Errs "\n"]
|
|
||||||
wokdep:gui:SetLabelText .myFrame.myLib64D_ErrLbl [join $anLib64Errs "\n"]
|
|
||||||
wokdep:gui:SetLabelText .myFrame.myBin32D_ErrLbl [join $anBin32Errs "\n"]
|
|
||||||
wokdep:gui:SetLabelText .myFrame.myBin64D_ErrLbl [join $anBin64Errs "\n"]
|
|
||||||
|
|
||||||
# merge duplicates
|
|
||||||
set ::CSF_OPT_LIB32 [lsort -unique $::CSF_OPT_LIB32]
|
|
||||||
set ::CSF_OPT_LIB64 [lsort -unique $::CSF_OPT_LIB64]
|
|
||||||
set ::CSF_OPT_BIN32 [lsort -unique $::CSF_OPT_BIN32]
|
|
||||||
set ::CSF_OPT_BIN64 [lsort -unique $::CSF_OPT_BIN64]
|
|
||||||
set ::CSF_OPT_LIB32D [lsort -unique $::CSF_OPT_LIB32D]
|
|
||||||
set ::CSF_OPT_LIB64D [lsort -unique $::CSF_OPT_LIB64D]
|
|
||||||
set ::CSF_OPT_BIN32D [lsort -unique $::CSF_OPT_BIN32D]
|
|
||||||
set ::CSF_OPT_BIN64D [lsort -unique $::CSF_OPT_BIN64D]
|
|
||||||
}
|
}
|
||||||
|
|
||||||
proc wokdep:gui:BrowseVcVars {} {
|
proc wokdep:gui:BrowseVcVars {} {
|
||||||
@@ -323,20 +251,34 @@ proc wokdep:gui:AddIncPath {} {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
proc wokdep:gui:AddLibPath {} {
|
proc wokdep:gui:AddLib32Path {} {
|
||||||
set aCfg [wokdep:gui:configSuffix]
|
|
||||||
set aResult [tk_chooseDirectory -title "Choose a directory"]
|
set aResult [tk_chooseDirectory -title "Choose a directory"]
|
||||||
if { "$aResult" != "" } {
|
if { "$aResult" != "" } {
|
||||||
lappend ::CSF_OPT_LIB${::ARCH}${aCfg} "$aResult"
|
lappend ::CSF_OPT_LIB32 "$aResult"
|
||||||
wokdep:gui:UpdateList
|
wokdep:gui:UpdateList
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
proc wokdep:gui:AddBinPath {} {
|
proc wokdep:gui:AddLib64Path {} {
|
||||||
set aCfg [wokdep:gui:configSuffix]
|
|
||||||
set aResult [tk_chooseDirectory -title "Choose a directory"]
|
set aResult [tk_chooseDirectory -title "Choose a directory"]
|
||||||
if { "$aResult" != "" } {
|
if { "$aResult" != "" } {
|
||||||
lappend ::CSF_OPT_BIN${::ARCH}${aCfg} "$aResult"
|
lappend ::CSF_OPT_LIB64 "$aResult"
|
||||||
|
wokdep:gui:UpdateList
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
proc wokdep:gui:AddBin32Path {} {
|
||||||
|
set aResult [tk_chooseDirectory -title "Choose a directory"]
|
||||||
|
if { "$aResult" != "" } {
|
||||||
|
lappend ::CSF_OPT_BIN32 "$aResult"
|
||||||
|
wokdep:gui:UpdateList
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
proc wokdep:gui:AddBin64Path {} {
|
||||||
|
set aResult [tk_chooseDirectory -title "Choose a directory"]
|
||||||
|
if { "$aResult" != "" } {
|
||||||
|
lappend ::CSF_OPT_BIN64 "$aResult"
|
||||||
wokdep:gui:UpdateList
|
wokdep:gui:UpdateList
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -349,20 +291,34 @@ proc wokdep:gui:RemoveIncPath {} {
|
|||||||
wokdep:gui:UpdateList
|
wokdep:gui:UpdateList
|
||||||
}
|
}
|
||||||
|
|
||||||
proc wokdep:gui:RemoveLibPath {} {
|
proc wokdep:gui:RemoveLib32Path {} {
|
||||||
set aCfg [wokdep:gui:configSuffix]
|
set aSelIndices [.myFrame.myLib32List curselection]
|
||||||
set aSelIndices [.myFrame.myLib${::ARCH}${aCfg}_List curselection]
|
|
||||||
if { [llength $aSelIndices] != 0 } {
|
if { [llength $aSelIndices] != 0 } {
|
||||||
.myFrame.myLib${::ARCH}${aCfg}_List delete [lindex $aSelIndices 0]
|
.myFrame.myLib32List delete [lindex $aSelIndices 0]
|
||||||
}
|
}
|
||||||
wokdep:gui:UpdateList
|
wokdep:gui:UpdateList
|
||||||
}
|
}
|
||||||
|
|
||||||
proc wokdep:gui:RemoveBinPath {} {
|
proc wokdep:gui:RemoveLib64Path {} {
|
||||||
set aCfg [wokdep:gui:configSuffix]
|
set aSelIndices [.myFrame.myLib64List curselection]
|
||||||
set aSelIndices [.myFrame.myBin${::ARCH}${aCfg}_List curselection]
|
|
||||||
if { [llength $aSelIndices] != 0 } {
|
if { [llength $aSelIndices] != 0 } {
|
||||||
.myFrame.myBin${::ARCH}${aCfg}_List delete [lindex $aSelIndices 0]
|
.myFrame.myLib64List delete [lindex $aSelIndices 0]
|
||||||
|
}
|
||||||
|
wokdep:gui:UpdateList
|
||||||
|
}
|
||||||
|
|
||||||
|
proc wokdep:gui:RemoveBin32Path {} {
|
||||||
|
set aSelIndices [.myFrame.myBin32List curselection]
|
||||||
|
if { [llength $aSelIndices] != 0 } {
|
||||||
|
.myFrame.myBin32List delete [lindex $aSelIndices 0]
|
||||||
|
}
|
||||||
|
wokdep:gui:UpdateList
|
||||||
|
}
|
||||||
|
|
||||||
|
proc wokdep:gui:RemoveBin64Path {} {
|
||||||
|
set aSelIndices [.myFrame.myBin64List curselection]
|
||||||
|
if { [llength $aSelIndices] != 0 } {
|
||||||
|
.myFrame.myBin64List delete [lindex $aSelIndices 0]
|
||||||
}
|
}
|
||||||
wokdep:gui:UpdateList
|
wokdep:gui:UpdateList
|
||||||
}
|
}
|
||||||
@@ -372,73 +328,109 @@ proc wokdep:gui:ResetIncPath {} {
|
|||||||
wokdep:gui:UpdateList
|
wokdep:gui:UpdateList
|
||||||
}
|
}
|
||||||
|
|
||||||
proc wokdep:gui:ResetLibPath {} {
|
proc wokdep:gui:ResetLib32Path {} {
|
||||||
set ::CSF_OPT_LIB${::ARCH} {}
|
set ::CSF_OPT_LIB32 {}
|
||||||
set ::CSF_OPT_LIB${::ARCH}D {}
|
|
||||||
set ::CSF_OPT_BIN${::ARCH} {}
|
|
||||||
set ::CSF_OPT_BIN${::ARCH}D {}
|
|
||||||
wokdep:gui:UpdateList
|
wokdep:gui:UpdateList
|
||||||
}
|
}
|
||||||
|
|
||||||
proc wokdep:gui:Show3264Bitness { theRowIter } {
|
proc wokdep:gui:ResetLib64Path {} {
|
||||||
|
set ::CSF_OPT_LIB64 {}
|
||||||
|
wokdep:gui:UpdateList
|
||||||
|
}
|
||||||
|
|
||||||
|
proc wokdep:gui:ResetBin32Path {} {
|
||||||
|
set ::CSF_OPT_BIN32 {}
|
||||||
|
wokdep:gui:UpdateList
|
||||||
|
}
|
||||||
|
|
||||||
|
proc wokdep:gui:ResetBin64Path {} {
|
||||||
|
set ::CSF_OPT_BIN64 {}
|
||||||
|
wokdep:gui:UpdateList
|
||||||
|
}
|
||||||
|
|
||||||
|
proc wokdep:gui:Show32Bitness { theRowIter } {
|
||||||
upvar $theRowIter aRowIter
|
upvar $theRowIter aRowIter
|
||||||
|
|
||||||
set aArchOld ""
|
if { [llength [grid info .myFrame.myLib64Lbl]] != 0 } {
|
||||||
set aCfg [wokdep:gui:configSuffix]
|
grid forget .myFrame.myLib64Lbl .myFrame.myLib64List .myFrame.myLib64Scrl
|
||||||
if { "$::ARCH" == "32" } {
|
grid forget .myFrame.myLib64Add .myFrame.myLib64Remove .myFrame.myLib64Clear .myFrame.myLib64ErrLbl
|
||||||
set aArchOld "64"
|
grid forget .myFrame.myBin64Lbl .myFrame.myBin64List .myFrame.myBin64Scrl
|
||||||
} else {
|
grid forget .myFrame.myBin64Add .myFrame.myBin64Remove .myFrame.myBin64Clear .myFrame.myBin64ErrLbl
|
||||||
set aArchOld "32"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
set aCfgOld "D"
|
# Additional libraries (32-bit) search paths
|
||||||
if { "$::CONFIG" == "Debug" } { set aCfgOld "" }
|
grid .myFrame.myLib32Lbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
set aDelArch ${aArchOld}${aCfg}
|
|
||||||
if { [llength [grid info .myFrame.myLib${aDelArch}_Lbl]] != 0 } {
|
|
||||||
grid forget .myFrame.myLib${aDelArch}_Lbl .myFrame.myLib${aDelArch}_List .myFrame.myLib${aDelArch}_Scrl
|
|
||||||
grid forget .myFrame.myLib${aDelArch}_Add .myFrame.myLib${aDelArch}_Remove .myFrame.myLib${aDelArch}_Clear .myFrame.myLib${aDelArch}_ErrLbl
|
|
||||||
grid forget .myFrame.myBin${aDelArch}_Lbl .myFrame.myBin${aDelArch}_List .myFrame.myBin${aDelArch}_Scrl
|
|
||||||
grid forget .myFrame.myBin${aDelArch}_Add .myFrame.myBin${aDelArch}_Remove .myFrame.myBin${aDelArch}_Clear .myFrame.myBin${aDelArch}_ErrLbl
|
|
||||||
}
|
|
||||||
set aDelCfg ${::ARCH}${aCfgOld}
|
|
||||||
if { [llength [grid info .myFrame.myLib${aDelCfg}_Lbl]] != 0 } {
|
|
||||||
grid forget .myFrame.myLib${aDelCfg}_Lbl .myFrame.myLib${aDelCfg}_List .myFrame.myLib${aDelCfg}_Scrl
|
|
||||||
grid forget .myFrame.myLib${aDelCfg}_Add .myFrame.myLib${aDelCfg}_Remove .myFrame.myLib${aDelCfg}_Clear .myFrame.myLib${aDelCfg}_ErrLbl
|
|
||||||
grid forget .myFrame.myBin${aDelCfg}_Lbl .myFrame.myBin${aDelCfg}_List .myFrame.myBin${aDelCfg}_Scrl
|
|
||||||
grid forget .myFrame.myBin${aDelCfg}_Add .myFrame.myBin${aDelCfg}_Remove .myFrame.myBin${aDelCfg}_Clear .myFrame.myBin${aDelCfg}_ErrLbl
|
|
||||||
}
|
|
||||||
|
|
||||||
set aNewCfg ${::ARCH}${aCfg}
|
|
||||||
# Additional libraries search paths
|
|
||||||
grid .myFrame.myLib${aNewCfg}_Lbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
grid .myFrame.myLib${aNewCfg}_List -row $aRowIter -column 0 -rowspan 4 -columnspan 5
|
grid .myFrame.myLib32List -row $aRowIter -column 0 -rowspan 4 -columnspan 5
|
||||||
grid .myFrame.myLib${aNewCfg}_Scrl -row $aRowIter -column 5 -rowspan 4
|
grid .myFrame.myLib32Scrl -row $aRowIter -column 5 -rowspan 4
|
||||||
grid .myFrame.myLib${aNewCfg}_Add -row $aRowIter -column 6
|
grid .myFrame.myLib32Add -row $aRowIter -column 6
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
#grid .myFrame.myLib${aNewCfg}_Edit -row $aRowIter -column 6
|
#grid .myFrame.myLib32Edit -row $aRowIter -column 6
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
grid .myFrame.myLib${aNewCfg}_Remove -row $aRowIter -column 6
|
grid .myFrame.myLib32Remove -row $aRowIter -column 6
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
grid .myFrame.myLib${aNewCfg}_Clear -row $aRowIter -column 6
|
grid .myFrame.myLib32Clear -row $aRowIter -column 6
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
grid .myFrame.myLib${aNewCfg}_ErrLbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
grid .myFrame.myLib32ErrLbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
|
|
||||||
# Additional executables search paths
|
# Additional executables (32-bit) search paths
|
||||||
grid .myFrame.myBin${aNewCfg}_Lbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
grid .myFrame.myBin32Lbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
grid .myFrame.myBin${aNewCfg}_List -row $aRowIter -column 0 -rowspan 4 -columnspan 5
|
grid .myFrame.myBin32List -row $aRowIter -column 0 -rowspan 4 -columnspan 5
|
||||||
grid .myFrame.myBin${aNewCfg}_Scrl -row $aRowIter -column 5 -rowspan 4
|
grid .myFrame.myBin32Scrl -row $aRowIter -column 5 -rowspan 4
|
||||||
grid .myFrame.myBin${aNewCfg}_Add -row $aRowIter -column 6
|
grid .myFrame.myBin32Add -row $aRowIter -column 6
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
#grid .myFrame.myBin${aNewCfg}_Edit -row $aRowIter -column 6
|
#grid .myFrame.myBin32Edit -row $aRowIter -column 6
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
grid .myFrame.myBin${aNewCfg}_Remove -row $aRowIter -column 6
|
grid .myFrame.myBin32Remove -row $aRowIter -column 6
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
grid .myFrame.myBin${aNewCfg}_Clear -row $aRowIter -column 6
|
grid .myFrame.myBin32Clear -row $aRowIter -column 6
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
grid .myFrame.myBin${aNewCfg}_ErrLbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
grid .myFrame.myBin32ErrLbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
|
incr aRowIter
|
||||||
|
}
|
||||||
|
|
||||||
|
proc wokdep:gui:Show64Bitness { theRowIter } {
|
||||||
|
upvar $theRowIter aRowIter
|
||||||
|
|
||||||
|
if { [llength [grid info .myFrame.myLib32Lbl]] != 0 } {
|
||||||
|
grid forget .myFrame.myLib32Lbl .myFrame.myLib32List .myFrame.myLib32Scrl
|
||||||
|
grid forget .myFrame.myLib32Add .myFrame.myLib32Remove .myFrame.myLib32Clear .myFrame.myLib32ErrLbl
|
||||||
|
grid forget .myFrame.myBin32Lbl .myFrame.myBin32List .myFrame.myBin32Scrl
|
||||||
|
grid forget .myFrame.myBin32Add .myFrame.myBin32Remove .myFrame.myBin32Clear .myFrame.myBin32ErrLbl
|
||||||
|
}
|
||||||
|
|
||||||
|
# Additional libraries (64-bit) search paths
|
||||||
|
grid .myFrame.myLib64Lbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
|
incr aRowIter
|
||||||
|
grid .myFrame.myLib64List -row $aRowIter -column 0 -rowspan 4 -columnspan 5
|
||||||
|
grid .myFrame.myLib64Scrl -row $aRowIter -column 5 -rowspan 4
|
||||||
|
grid .myFrame.myLib64Add -row $aRowIter -column 6
|
||||||
|
incr aRowIter
|
||||||
|
#grid .myFrame.myLib64Edit -row $aRowIter -column 6
|
||||||
|
incr aRowIter
|
||||||
|
grid .myFrame.myLib64Remove -row $aRowIter -column 6
|
||||||
|
incr aRowIter
|
||||||
|
grid .myFrame.myLib64Clear -row $aRowIter -column 6
|
||||||
|
incr aRowIter
|
||||||
|
grid .myFrame.myLib64ErrLbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
|
incr aRowIter
|
||||||
|
|
||||||
|
# Additional executables (64-bit) search paths
|
||||||
|
grid .myFrame.myBin64Lbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
|
incr aRowIter
|
||||||
|
grid .myFrame.myBin64List -row $aRowIter -column 0 -rowspan 4 -columnspan 5
|
||||||
|
grid .myFrame.myBin64Scrl -row $aRowIter -column 5 -rowspan 4
|
||||||
|
grid .myFrame.myBin64Add -row $aRowIter -column 6
|
||||||
|
incr aRowIter
|
||||||
|
#grid .myFrame.myBin64Edit -row $aRowIter -column 6
|
||||||
|
incr aRowIter
|
||||||
|
grid .myFrame.myBin64Remove -row $aRowIter -column 6
|
||||||
|
incr aRowIter
|
||||||
|
grid .myFrame.myBin64Clear -row $aRowIter -column 6
|
||||||
|
incr aRowIter
|
||||||
|
grid .myFrame.myBin64ErrLbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -448,7 +440,6 @@ ttk::combobox .myFrame.myPrjFrame.myPrjCombo -values $SYS_PRJNAME_LIST -state
|
|||||||
ttk::label .myFrame.myVsFrame.myVsLbl -text "Visual Studio configuration:" -padding {5 5 20 5}
|
ttk::label .myFrame.myVsFrame.myVsLbl -text "Visual Studio configuration:" -padding {5 5 20 5}
|
||||||
ttk::combobox .myFrame.myVsFrame.myVsCombo -values $SYS_VS_LIST -state readonly -textvariable VSVER -width 40
|
ttk::combobox .myFrame.myVsFrame.myVsCombo -values $SYS_VS_LIST -state readonly -textvariable VSVER -width 40
|
||||||
ttk::combobox .myFrame.myVsFrame.myArchCombo -values { {32} {64} } -textvariable ARCH -state readonly -width 6
|
ttk::combobox .myFrame.myVsFrame.myArchCombo -values { {32} {64} } -textvariable ARCH -state readonly -width 6
|
||||||
ttk::combobox .myFrame.myVsFrame.myConfigCombo -values { {Release} {Debug} } -textvariable CONFIG -state readonly -width 6
|
|
||||||
entry .myFrame.myVcEntry -textvariable VCVER -width 10
|
entry .myFrame.myVcEntry -textvariable VCVER -width 10
|
||||||
entry .myFrame.myVcVarsEntry -textvariable VCVARS -width 70
|
entry .myFrame.myVcVarsEntry -textvariable VCVARS -width 70
|
||||||
ttk::button .myFrame.myVcBrowseBtn -text "Browse" -command wokdep:gui:BrowseVcVars
|
ttk::button .myFrame.myVcBrowseBtn -text "Browse" -command wokdep:gui:BrowseVcVars
|
||||||
@@ -463,14 +454,10 @@ ttk::label .myFrame.myHxxChecks.myScutsLbl -text "Strategy for filling he
|
|||||||
ttk::label .myFrame.mySrchLbl -text "3rd-parties search path:" -padding {5 5 80 5}
|
ttk::label .myFrame.mySrchLbl -text "3rd-parties search path:" -padding {5 5 80 5}
|
||||||
entry .myFrame.mySrchEntry -textvariable PRODUCTS_PATH_INPUT -width 80
|
entry .myFrame.mySrchEntry -textvariable PRODUCTS_PATH_INPUT -width 80
|
||||||
ttk::button .myFrame.mySrchBrowseBtn -text "Browse" -command wokdep:gui:BrowsePartiesRoot
|
ttk::button .myFrame.mySrchBrowseBtn -text "Browse" -command wokdep:gui:BrowsePartiesRoot
|
||||||
checkbutton .myFrame.myChecks.myFreeTypeCheck -offvalue "false" -onvalue "true" -variable HAVE_FREETYPE -command wokdep:gui:UpdateList
|
|
||||||
ttk::label .myFrame.myChecks.myFreeTypeLbl -text "Use FreeType"
|
|
||||||
checkbutton .myFrame.myChecks.myFImageCheck -offvalue "false" -onvalue "true" -variable HAVE_FREEIMAGE -command wokdep:gui:UpdateList
|
checkbutton .myFrame.myChecks.myFImageCheck -offvalue "false" -onvalue "true" -variable HAVE_FREEIMAGE -command wokdep:gui:UpdateList
|
||||||
ttk::label .myFrame.myChecks.myFImageLbl -text "Use FreeImage"
|
ttk::label .myFrame.myChecks.myFImageLbl -text "Use FreeImage"
|
||||||
checkbutton .myFrame.myChecks.myTbbCheck -offvalue "false" -onvalue "true" -variable HAVE_TBB -command wokdep:gui:UpdateList
|
checkbutton .myFrame.myChecks.myTbbCheck -offvalue "false" -onvalue "true" -variable HAVE_TBB -command wokdep:gui:UpdateList
|
||||||
ttk::label .myFrame.myChecks.myTbbLbl -text "Use Intel TBB"
|
ttk::label .myFrame.myChecks.myTbbLbl -text "Use Intel TBB"
|
||||||
checkbutton .myFrame.myChecks.myOpenVrCheck -offvalue "false" -onvalue "true" -variable HAVE_OPENVR -command wokdep:gui:UpdateList
|
|
||||||
ttk::label .myFrame.myChecks.myOpenVrLbl -text "Use OpenVR"
|
|
||||||
if { "$::tcl_platform(os)" != "Darwin" } {
|
if { "$::tcl_platform(os)" != "Darwin" } {
|
||||||
checkbutton .myFrame.myChecks.myGlesCheck -offvalue "false" -onvalue "true" -variable HAVE_GLES2 -command wokdep:gui:UpdateList
|
checkbutton .myFrame.myChecks.myGlesCheck -offvalue "false" -onvalue "true" -variable HAVE_GLES2 -command wokdep:gui:UpdateList
|
||||||
ttk::label .myFrame.myChecks.myGlesLbl -text "Use OpenGL ES"
|
ttk::label .myFrame.myChecks.myGlesLbl -text "Use OpenGL ES"
|
||||||
@@ -485,11 +472,9 @@ ttk::label .myFrame.myChecks.myFFmpegLbl -text "Use FFmpeg"
|
|||||||
#ttk::label .myFrame.myChecks.myOpenClLbl -text "Use OpenCL"
|
#ttk::label .myFrame.myChecks.myOpenClLbl -text "Use OpenCL"
|
||||||
checkbutton .myFrame.myChecks.myRapidJsonCheck -offvalue "false" -onvalue "true" -variable HAVE_RAPIDJSON -command wokdep:gui:UpdateList
|
checkbutton .myFrame.myChecks.myRapidJsonCheck -offvalue "false" -onvalue "true" -variable HAVE_RAPIDJSON -command wokdep:gui:UpdateList
|
||||||
ttk::label .myFrame.myChecks.myRapidJsonLbl -text "Use RapidJSON"
|
ttk::label .myFrame.myChecks.myRapidJsonLbl -text "Use RapidJSON"
|
||||||
checkbutton .myFrame.myChecks.myDracoCheck -offvalue "false" -onvalue "true" -variable HAVE_DRACO -command wokdep:gui:UpdateList
|
|
||||||
ttk::label .myFrame.myChecks.myDracoLbl -text "Use Draco"
|
|
||||||
|
|
||||||
checkbutton .myFrame.myChecks.myXLibCheck -offvalue "false" -onvalue "true" -variable HAVE_XLIB
|
checkbutton .myFrame.myChecks.myMacGLXCheck -offvalue "false" -onvalue "true" -variable MACOSX_USE_GLX
|
||||||
ttk::label .myFrame.myChecks.myXLibLbl -text "Use X11 for windows drawing"
|
ttk::label .myFrame.myChecks.myMacGLXLbl -text "Use X11 for windows drawing"
|
||||||
ttk::label .myFrame.myChecks.myVtkLbl -text "Use VTK"
|
ttk::label .myFrame.myChecks.myVtkLbl -text "Use VTK"
|
||||||
checkbutton .myFrame.myChecks.myVtkCheck -offvalue "false" -onvalue "true" -variable HAVE_VTK -command wokdep:gui:UpdateList
|
checkbutton .myFrame.myChecks.myVtkCheck -offvalue "false" -onvalue "true" -variable HAVE_VTK -command wokdep:gui:UpdateList
|
||||||
|
|
||||||
@@ -500,16 +485,11 @@ ttk::label .myFrame.myChecks.myLzmaLbl -text "Use liblzma"
|
|||||||
checkbutton .myFrame.myChecks.myE57Check -offvalue "false" -onvalue "true" -variable HAVE_E57 -command wokdep:gui:UpdateList
|
checkbutton .myFrame.myChecks.myE57Check -offvalue "false" -onvalue "true" -variable HAVE_E57 -command wokdep:gui:UpdateList
|
||||||
ttk::label .myFrame.myChecks.myE57Lbl -text "Use E57"
|
ttk::label .myFrame.myChecks.myE57Lbl -text "Use E57"
|
||||||
|
|
||||||
checkbutton .myFrame.myChecks.myQtCheck -offvalue "false" -onvalue "true" -variable CHECK_QT -command wokdep:gui:UpdateList
|
checkbutton .myFrame.myChecks.myQt4Check -offvalue "false" -onvalue "true" -variable CHECK_QT4 -command wokdep:gui:UpdateList
|
||||||
ttk::label .myFrame.myChecks.myQtLbl -text "Search Qt"
|
ttk::label .myFrame.myChecks.myQt4Lbl -text "Search Qt4"
|
||||||
checkbutton .myFrame.myChecks.myJDKCheck -offvalue "false" -onvalue "true" -variable CHECK_JDK -command wokdep:gui:UpdateList
|
checkbutton .myFrame.myChecks.myJDKCheck -offvalue "false" -onvalue "true" -variable CHECK_JDK -command wokdep:gui:UpdateList
|
||||||
ttk::label .myFrame.myChecks.myJDKLbl -text "Search JDK"
|
ttk::label .myFrame.myChecks.myJDKLbl -text "Search JDK"
|
||||||
|
|
||||||
if { "$::tcl_platform(platform)" == "windows" } {
|
|
||||||
checkbutton .myFrame.myChecks.myInspectorBuild -offvalue "false" -onvalue "true" -variable BUILD_Inspector -command wokdep:gui:UpdateList
|
|
||||||
ttk::label .myFrame.myChecks.myInspectorLbl -text "Build Inspector"
|
|
||||||
}
|
|
||||||
|
|
||||||
# Additional headers search paths
|
# Additional headers search paths
|
||||||
ttk::label .myFrame.myIncLbl -text "Additional headers search paths:" -padding {5 5 80 5}
|
ttk::label .myFrame.myIncLbl -text "Additional headers search paths:" -padding {5 5 80 5}
|
||||||
scrollbar .myFrame.myIncScrl -command ".myFrame.myIncList yview"
|
scrollbar .myFrame.myIncScrl -command ".myFrame.myIncList yview"
|
||||||
@@ -521,84 +501,44 @@ ttk::button .myFrame.myIncClear -text "Reset" -command wokdep:gui:ResetIncP
|
|||||||
ttk::label .myFrame.myIncErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
ttk::label .myFrame.myIncErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
||||||
|
|
||||||
# Additional libraries (32-bit) search paths
|
# Additional libraries (32-bit) search paths
|
||||||
ttk::label .myFrame.myLib32_Lbl -text "Additional libraries (32-bit) search paths:" -padding {5 5 80 5}
|
ttk::label .myFrame.myLib32Lbl -text "Additional libraries (32-bit) search paths:" -padding {5 5 80 5}
|
||||||
scrollbar .myFrame.myLib32_Scrl -command ".myFrame.myLib32_List yview"
|
scrollbar .myFrame.myLib32Scrl -command ".myFrame.myLib32List yview"
|
||||||
listbox .myFrame.myLib32_List -listvariable CSF_OPT_LIB32 -width 80 -height 5 -yscrollcommand ".myFrame.myLib32_Scrl set"
|
listbox .myFrame.myLib32List -listvariable CSF_OPT_LIB32 -width 80 -height 5 -yscrollcommand ".myFrame.myLib32Scrl set"
|
||||||
ttk::button .myFrame.myLib32_Add -text "Add" -command wokdep:gui:AddLibPath
|
ttk::button .myFrame.myLib32Add -text "Add" -command wokdep:gui:AddLib32Path
|
||||||
ttk::button .myFrame.myLib32_Edit -text "Edit"
|
ttk::button .myFrame.myLib32Edit -text "Edit"
|
||||||
ttk::button .myFrame.myLib32_Remove -text "Remove" -command wokdep:gui:RemoveLibPath
|
ttk::button .myFrame.myLib32Remove -text "Remove" -command wokdep:gui:RemoveLib32Path
|
||||||
ttk::button .myFrame.myLib32_Clear -text "Reset" -command wokdep:gui:ResetLibPath
|
ttk::button .myFrame.myLib32Clear -text "Reset" -command wokdep:gui:ResetLib32Path
|
||||||
ttk::label .myFrame.myLib32_ErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
ttk::label .myFrame.myLib32ErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
||||||
|
|
||||||
# Additional debug libraries (32-bit) search paths
|
|
||||||
ttk::label .myFrame.myLib32D_Lbl -text "Additional debug libraries (32-bit) search paths:" -padding {5 5 80 5}
|
|
||||||
scrollbar .myFrame.myLib32D_Scrl -command ".myFrame.myLib32D_List yview"
|
|
||||||
listbox .myFrame.myLib32D_List -listvariable CSF_OPT_LIB32D -width 80 -height 5 -yscrollcommand ".myFrame.myLib32D_Scrl set"
|
|
||||||
ttk::button .myFrame.myLib32D_Add -text "Add" -command wokdep:gui:AddLibPath
|
|
||||||
ttk::button .myFrame.myLib32D_Edit -text "Edit"
|
|
||||||
ttk::button .myFrame.myLib32D_Remove -text "Remove" -command wokdep:gui:RemoveLibPath
|
|
||||||
ttk::button .myFrame.myLib32D_Clear -text "Reset" -command wokdep:gui:ResetLibPath
|
|
||||||
ttk::label .myFrame.myLib32D_ErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
|
||||||
|
|
||||||
# Additional libraries (64-bit) search paths
|
# Additional libraries (64-bit) search paths
|
||||||
ttk::label .myFrame.myLib64_Lbl -text "Additional libraries (64-bit) search paths:" -padding {5 5 80 5}
|
ttk::label .myFrame.myLib64Lbl -text "Additional libraries (64-bit) search paths:" -padding {5 5 80 5}
|
||||||
scrollbar .myFrame.myLib64_Scrl -command ".myFrame.myLib64_List yview"
|
scrollbar .myFrame.myLib64Scrl -command ".myFrame.myLib64List yview"
|
||||||
listbox .myFrame.myLib64_List -listvariable CSF_OPT_LIB64 -width 80 -height 5 -yscrollcommand ".myFrame.myLib64_Scrl set"
|
listbox .myFrame.myLib64List -listvariable CSF_OPT_LIB64 -width 80 -height 5 -yscrollcommand ".myFrame.myLib64Scrl set"
|
||||||
ttk::button .myFrame.myLib64_Add -text "Add" -command wokdep:gui:AddLibPath
|
ttk::button .myFrame.myLib64Add -text "Add" -command wokdep:gui:AddLib64Path
|
||||||
ttk::button .myFrame.myLib64_Edit -text "Edit"
|
ttk::button .myFrame.myLib64Edit -text "Edit"
|
||||||
ttk::button .myFrame.myLib64_Remove -text "Remove" -command wokdep:gui:RemoveLibPath
|
ttk::button .myFrame.myLib64Remove -text "Remove" -command wokdep:gui:RemoveLib64Path
|
||||||
ttk::button .myFrame.myLib64_Clear -text "Reset" -command wokdep:gui:ResetLibPath
|
ttk::button .myFrame.myLib64Clear -text "Reset" -command wokdep:gui:ResetLib64Path
|
||||||
ttk::label .myFrame.myLib64_ErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
ttk::label .myFrame.myLib64ErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
||||||
|
|
||||||
# Additional debug libraries (64-bit) search paths
|
|
||||||
ttk::label .myFrame.myLib64D_Lbl -text "Additional debug libraries (64-bit) search paths:" -padding {5 5 80 5}
|
|
||||||
scrollbar .myFrame.myLib64D_Scrl -command ".myFrame.myLib64D_List yview"
|
|
||||||
listbox .myFrame.myLib64D_List -listvariable CSF_OPT_LIB64D -width 80 -height 5 -yscrollcommand ".myFrame.myLib64D_Scrl set"
|
|
||||||
ttk::button .myFrame.myLib64D_Add -text "Add" -command wokdep:gui:AddLibPath
|
|
||||||
ttk::button .myFrame.myLib64D_Edit -text "Edit"
|
|
||||||
ttk::button .myFrame.myLib64D_Remove -text "Remove" -command wokdep:gui:RemoveLibPath
|
|
||||||
ttk::button .myFrame.myLib64D_Clear -text "Reset" -command wokdep:gui:ResetLibPath
|
|
||||||
ttk::label .myFrame.myLib64D_ErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
|
||||||
|
|
||||||
# Additional executables (32-bit) search paths
|
# Additional executables (32-bit) search paths
|
||||||
ttk::label .myFrame.myBin32_Lbl -text "Additional executables (32-bit) search paths:" -padding {5 5 80 5}
|
ttk::label .myFrame.myBin32Lbl -text "Additional executables (32-bit) search paths:" -padding {5 5 80 5}
|
||||||
scrollbar .myFrame.myBin32_Scrl -command ".myFrame.myBin32_List yview"
|
scrollbar .myFrame.myBin32Scrl -command ".myFrame.myBin32List yview"
|
||||||
listbox .myFrame.myBin32_List -listvariable CSF_OPT_BIN32 -width 80 -height 5 -yscrollcommand ".myFrame.myBin32_Scrl set"
|
listbox .myFrame.myBin32List -listvariable CSF_OPT_BIN32 -width 80 -height 5 -yscrollcommand ".myFrame.myBin32Scrl set"
|
||||||
ttk::button .myFrame.myBin32_Add -text "Add" -command wokdep:gui:AddBinPath
|
ttk::button .myFrame.myBin32Add -text "Add" -command wokdep:gui:AddBin32Path
|
||||||
ttk::button .myFrame.myBin32_Edit -text "Edit"
|
ttk::button .myFrame.myBin32Edit -text "Edit"
|
||||||
ttk::button .myFrame.myBin32_Remove -text "Remove" -command wokdep:gui:RemoveBinPath
|
ttk::button .myFrame.myBin32Remove -text "Remove" -command wokdep:gui:RemoveBin32Path
|
||||||
ttk::button .myFrame.myBin32_Clear -text "Reset" -command wokdep:gui:ResetLibPath
|
ttk::button .myFrame.myBin32Clear -text "Reset" -command wokdep:gui:ResetBin32Path
|
||||||
ttk::label .myFrame.myBin32_ErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
ttk::label .myFrame.myBin32ErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
||||||
|
|
||||||
# Additional debug executables (32-bit) search paths
|
|
||||||
ttk::label .myFrame.myBin32D_Lbl -text "Additional debug executables (32-bit) search paths:" -padding {5 5 80 5}
|
|
||||||
scrollbar .myFrame.myBin32D_Scrl -command ".myFrame.myBin32D_List yview"
|
|
||||||
listbox .myFrame.myBin32D_List -listvariable CSF_OPT_BIN32D -width 80 -height 5 -yscrollcommand ".myFrame.myBin32D_Scrl set"
|
|
||||||
ttk::button .myFrame.myBin32D_Add -text "Add" -command wokdep:gui:AddBinPath
|
|
||||||
ttk::button .myFrame.myBin32D_Edit -text "Edit"
|
|
||||||
ttk::button .myFrame.myBin32D_Remove -text "Remove" -command wokdep:gui:RemoveBinPath
|
|
||||||
ttk::button .myFrame.myBin32D_Clear -text "Reset" -command wokdep:gui:ResetLibPath
|
|
||||||
ttk::label .myFrame.myBin32D_ErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
|
||||||
|
|
||||||
# Additional executables (64-bit) search paths
|
# Additional executables (64-bit) search paths
|
||||||
ttk::label .myFrame.myBin64_Lbl -text "Additional executables (64-bit) search paths:" -padding {5 5 80 5}
|
ttk::label .myFrame.myBin64Lbl -text "Additional executables (64-bit) search paths:" -padding {5 5 80 5}
|
||||||
scrollbar .myFrame.myBin64_Scrl -command ".myFrame.myBin64_List yview"
|
scrollbar .myFrame.myBin64Scrl -command ".myFrame.myBin64List yview"
|
||||||
listbox .myFrame.myBin64_List -listvariable CSF_OPT_BIN64 -width 80 -height 5 -yscrollcommand ".myFrame.myBin64_Scrl set"
|
listbox .myFrame.myBin64List -listvariable CSF_OPT_BIN64 -width 80 -height 5 -yscrollcommand ".myFrame.myBin64Scrl set"
|
||||||
ttk::button .myFrame.myBin64_Add -text "Add" -command wokdep:gui:AddBinPath
|
ttk::button .myFrame.myBin64Add -text "Add" -command wokdep:gui:AddBin64Path
|
||||||
ttk::button .myFrame.myBin64_Edit -text "Edit"
|
ttk::button .myFrame.myBin64Edit -text "Edit"
|
||||||
ttk::button .myFrame.myBin64_Remove -text "Remove" -command wokdep:gui:RemoveBinPath
|
ttk::button .myFrame.myBin64Remove -text "Remove" -command wokdep:gui:RemoveBin64Path
|
||||||
ttk::button .myFrame.myBin64_Clear -text "Reset" -command wokdep:gui:ResetLibPath
|
ttk::button .myFrame.myBin64Clear -text "Reset" -command wokdep:gui:ResetBin64Path
|
||||||
ttk::label .myFrame.myBin64_ErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
ttk::label .myFrame.myBin64ErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
||||||
|
|
||||||
# Additional debug executables (64-bit) search paths
|
|
||||||
ttk::label .myFrame.myBin64D_Lbl -text "Additional debug executables (64-bit) search paths:" -padding {5 5 80 5}
|
|
||||||
scrollbar .myFrame.myBin64D_Scrl -command ".myFrame.myBin64D_List yview"
|
|
||||||
listbox .myFrame.myBin64D_List -listvariable CSF_OPT_BIN64D -width 80 -height 5 -yscrollcommand ".myFrame.myBin64D_Scrl set"
|
|
||||||
ttk::button .myFrame.myBin64D_Add -text "Add" -command wokdep:gui:AddBinPath
|
|
||||||
ttk::button .myFrame.myBin64D_Edit -text "Edit"
|
|
||||||
ttk::button .myFrame.myBin64D_Remove -text "Remove" -command wokdep:gui:RemoveBinPath
|
|
||||||
ttk::button .myFrame.myBin64D_Clear -text "Reset" -command wokdep:gui:ResetLibPath
|
|
||||||
ttk::label .myFrame.myBin64D_ErrLbl -text "Error: " -foreground red -padding {5 5 5 5}
|
|
||||||
|
|
||||||
# Bottom
|
# Bottom
|
||||||
ttk::button .myFrame.mySave -text "Save" -command wokdep:SaveCustom
|
ttk::button .myFrame.mySave -text "Save" -command wokdep:SaveCustom
|
||||||
@@ -609,22 +549,17 @@ ttk::button .myFrame.myClose -text "Close" -command wokdep:gui:Close
|
|||||||
grid .myFrame.myPrjFrame -row $aRowIter -column 0 -columnspan 10 -sticky w
|
grid .myFrame.myPrjFrame -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
grid .myFrame.myPrjFrame.myPrjLbl -row 0 -column 0
|
grid .myFrame.myPrjFrame.myPrjLbl -row 0 -column 0
|
||||||
grid .myFrame.myPrjFrame.myPrjCombo -row 0 -column 1
|
grid .myFrame.myPrjFrame.myPrjCombo -row 0 -column 1
|
||||||
|
incr aRowIter
|
||||||
if { "$tcl_platform(platform)" == "windows" } {
|
if { "$tcl_platform(platform)" == "windows" } {
|
||||||
incr aRowIter
|
|
||||||
grid .myFrame.myVsFrame -row $aRowIter -column 0 -columnspan 10 -sticky w
|
grid .myFrame.myVsFrame -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
grid .myFrame.myVsFrame.myVsLbl -row 0 -column 0
|
grid .myFrame.myVsFrame.myVsLbl -row 0 -column 0
|
||||||
grid .myFrame.myVsFrame.myVsCombo -row 0 -column 1 -padx 5
|
grid .myFrame.myVsFrame.myVsCombo -row 0 -column 1 -padx 5
|
||||||
grid .myFrame.myVsFrame.myArchCombo -row 0 -column 2
|
grid .myFrame.myVsFrame.myArchCombo -row 0 -column 2
|
||||||
grid .myFrame.myVsFrame.myConfigCombo -row 0 -column 3
|
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
grid .myFrame.myVcEntry -row $aRowIter -column 0
|
grid .myFrame.myVcEntry -row $aRowIter -column 0
|
||||||
grid .myFrame.myVcVarsEntry -row $aRowIter -column 1 -columnspan 4 -sticky w
|
grid .myFrame.myVcVarsEntry -row $aRowIter -column 1 -columnspan 4 -sticky w
|
||||||
grid .myFrame.myVcBrowseBtn -row $aRowIter -column 6
|
grid .myFrame.myVcBrowseBtn -row $aRowIter -column 6
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
} else {
|
|
||||||
grid .myFrame.myVsFrame -row $aRowIter -column 4 -sticky w
|
|
||||||
grid .myFrame.myVsFrame.myConfigCombo -row 0 -column 0
|
|
||||||
incr aRowIter
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#
|
#
|
||||||
@@ -645,10 +580,10 @@ incr aRowIter
|
|||||||
|
|
||||||
grid .myFrame.myChecks -row $aRowIter -column 0 -columnspan 10 -sticky w
|
grid .myFrame.myChecks -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
grid .myFrame.myChecks.myFreeTypeCheck -row $aCheckRowIter -column 0 -sticky e
|
grid .myFrame.myChecks.myFImageCheck -row $aCheckRowIter -column 0 -sticky e
|
||||||
grid .myFrame.myChecks.myFreeTypeLbl -row $aCheckRowIter -column 1 -sticky w
|
grid .myFrame.myChecks.myFImageLbl -row $aCheckRowIter -column 1 -sticky w
|
||||||
grid .myFrame.myChecks.myRapidJsonCheck -row $aCheckRowIter -column 2 -sticky e
|
grid .myFrame.myChecks.myTbbCheck -row $aCheckRowIter -column 2 -sticky e
|
||||||
grid .myFrame.myChecks.myRapidJsonLbl -row $aCheckRowIter -column 3 -sticky w
|
grid .myFrame.myChecks.myTbbLbl -row $aCheckRowIter -column 3 -sticky w
|
||||||
if { "$::tcl_platform(os)" != "Darwin" } {
|
if { "$::tcl_platform(os)" != "Darwin" } {
|
||||||
grid .myFrame.myChecks.myGlesCheck -row $aCheckRowIter -column 4 -sticky e
|
grid .myFrame.myChecks.myGlesCheck -row $aCheckRowIter -column 4 -sticky e
|
||||||
grid .myFrame.myChecks.myGlesLbl -row $aCheckRowIter -column 5 -sticky w
|
grid .myFrame.myChecks.myGlesLbl -row $aCheckRowIter -column 5 -sticky w
|
||||||
@@ -658,21 +593,20 @@ if { "$::tcl_platform(os)" != "Darwin" } {
|
|||||||
grid .myFrame.myChecks.myZLibCheck -row $aCheckRowIter -column 6 -sticky e
|
grid .myFrame.myChecks.myZLibCheck -row $aCheckRowIter -column 6 -sticky e
|
||||||
grid .myFrame.myChecks.myZLibLbl -row $aCheckRowIter -column 7 -sticky w
|
grid .myFrame.myChecks.myZLibLbl -row $aCheckRowIter -column 7 -sticky w
|
||||||
|
|
||||||
grid .myFrame.myChecks.myQtCheck -row $aCheckRowIter -column 12 -sticky e
|
grid .myFrame.myChecks.myQt4Check -row $aCheckRowIter -column 12 -sticky e
|
||||||
grid .myFrame.myChecks.myQtLbl -row $aCheckRowIter -column 13 -sticky w
|
grid .myFrame.myChecks.myQt4Lbl -row $aCheckRowIter -column 13 -sticky w
|
||||||
|
|
||||||
incr aCheckRowIter
|
incr aCheckRowIter
|
||||||
grid .myFrame.myChecks.myFImageCheck -row $aCheckRowIter -column 0 -sticky e
|
grid .myFrame.myChecks.myFFmpegCheck -row $aCheckRowIter -column 0 -sticky e
|
||||||
grid .myFrame.myChecks.myFImageLbl -row $aCheckRowIter -column 1 -sticky w
|
grid .myFrame.myChecks.myFFmpegLbl -row $aCheckRowIter -column 1 -sticky w
|
||||||
grid .myFrame.myChecks.myDracoCheck -row $aCheckRowIter -column 2 -sticky e
|
grid .myFrame.myChecks.myVtkCheck -row $aCheckRowIter -column 2 -sticky e
|
||||||
grid .myFrame.myChecks.myDracoLbl -row $aCheckRowIter -column 3 -sticky w
|
grid .myFrame.myChecks.myVtkLbl -row $aCheckRowIter -column 3 -sticky w
|
||||||
|
|
||||||
if { "$::tcl_platform(platform)" == "windows" } {
|
if { "$::tcl_platform(platform)" == "windows" } {
|
||||||
grid .myFrame.myChecks.myD3dCheck -row $aCheckRowIter -column 4 -sticky e
|
grid .myFrame.myChecks.myD3dCheck -row $aCheckRowIter -column 4 -sticky e
|
||||||
grid .myFrame.myChecks.myD3dLbl -row $aCheckRowIter -column 5 -sticky w
|
grid .myFrame.myChecks.myD3dLbl -row $aCheckRowIter -column 5 -sticky w
|
||||||
} else {
|
} elseif { "$::tcl_platform(os)" == "Darwin" } {
|
||||||
grid .myFrame.myChecks.myXLibCheck -row $aCheckRowIter -column 4 -sticky e
|
grid .myFrame.myChecks.myMacGLXCheck -row $aCheckRowIter -column 4 -sticky e
|
||||||
grid .myFrame.myChecks.myXLibLbl -row $aCheckRowIter -column 5 -sticky w
|
grid .myFrame.myChecks.myMacGLXLbl -row $aCheckRowIter -column 5 -sticky w
|
||||||
}
|
}
|
||||||
grid .myFrame.myChecks.myLzmaCheck -row $aCheckRowIter -column 6 -sticky e
|
grid .myFrame.myChecks.myLzmaCheck -row $aCheckRowIter -column 6 -sticky e
|
||||||
grid .myFrame.myChecks.myLzmaLbl -row $aCheckRowIter -column 7 -sticky w
|
grid .myFrame.myChecks.myLzmaLbl -row $aCheckRowIter -column 7 -sticky w
|
||||||
@@ -680,25 +614,11 @@ grid .myFrame.myChecks.myJDKCheck -row $aCheckRowIter -column 12 -sticky e
|
|||||||
grid .myFrame.myChecks.myJDKLbl -row $aCheckRowIter -column 13 -sticky w
|
grid .myFrame.myChecks.myJDKLbl -row $aCheckRowIter -column 13 -sticky w
|
||||||
|
|
||||||
incr aCheckRowIter
|
incr aCheckRowIter
|
||||||
grid .myFrame.myChecks.myFFmpegCheck -row $aCheckRowIter -column 0 -sticky e
|
grid .myFrame.myChecks.myRapidJsonCheck -row $aCheckRowIter -column 0 -sticky e
|
||||||
grid .myFrame.myChecks.myFFmpegLbl -row $aCheckRowIter -column 1 -sticky w
|
grid .myFrame.myChecks.myRapidJsonLbl -row $aCheckRowIter -column 1 -sticky w
|
||||||
grid .myFrame.myChecks.myVtkCheck -row $aCheckRowIter -column 2 -sticky e
|
|
||||||
grid .myFrame.myChecks.myVtkLbl -row $aCheckRowIter -column 3 -sticky w
|
|
||||||
grid .myFrame.myChecks.myOpenVrCheck -row $aCheckRowIter -column 4 -sticky e
|
|
||||||
grid .myFrame.myChecks.myOpenVrLbl -row $aCheckRowIter -column 5 -sticky w
|
|
||||||
grid .myFrame.myChecks.myE57Check -row $aCheckRowIter -column 6 -sticky e
|
grid .myFrame.myChecks.myE57Check -row $aCheckRowIter -column 6 -sticky e
|
||||||
grid .myFrame.myChecks.myE57Lbl -row $aCheckRowIter -column 7 -sticky w
|
grid .myFrame.myChecks.myE57Lbl -row $aCheckRowIter -column 7 -sticky w
|
||||||
|
|
||||||
if { "$::tcl_platform(platform)" == "windows" } {
|
|
||||||
grid .myFrame.myChecks.myInspectorBuild -row $aCheckRowIter -column 12 -sticky e
|
|
||||||
grid .myFrame.myChecks.myInspectorLbl -row $aCheckRowIter -column 13 -sticky w
|
|
||||||
}
|
|
||||||
|
|
||||||
incr aCheckRowIter
|
|
||||||
|
|
||||||
grid .myFrame.myChecks.myTbbCheck -row $aCheckRowIter -column 12 -sticky e
|
|
||||||
grid .myFrame.myChecks.myTbbLbl -row $aCheckRowIter -column 13 -sticky w
|
|
||||||
|
|
||||||
incr aCheckRowIter
|
incr aCheckRowIter
|
||||||
|
|
||||||
# Additional headers search paths
|
# Additional headers search paths
|
||||||
@@ -717,8 +637,15 @@ incr aRowIter
|
|||||||
grid .myFrame.myIncErrLbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
grid .myFrame.myIncErrLbl -row $aRowIter -column 0 -columnspan 10 -sticky w
|
||||||
incr aRowIter
|
incr aRowIter
|
||||||
|
|
||||||
# Additional search paths
|
# Additional 32-bit search paths
|
||||||
wokdep:gui:Show3264Bitness aRowIter
|
if { "$ARCH" == "32" } {
|
||||||
|
wokdep:gui:Show32Bitness aRowIter
|
||||||
|
}
|
||||||
|
|
||||||
|
# Additional 64-bit search paths
|
||||||
|
if { "$ARCH" == "64" } {
|
||||||
|
wokdep:gui:Show64Bitness aRowIter
|
||||||
|
}
|
||||||
|
|
||||||
# Bottom section
|
# Bottom section
|
||||||
grid .myFrame.mySave -row $aRowIter -column 4 -columnspan 2
|
grid .myFrame.mySave -row $aRowIter -column 4 -columnspan 2
|
||||||
@@ -734,9 +661,6 @@ bind .myFrame.myVsFrame.myVsCombo <<ComboboxSelected>> {
|
|||||||
bind .myFrame.myVsFrame.myArchCombo <<ComboboxSelected>> {
|
bind .myFrame.myVsFrame.myArchCombo <<ComboboxSelected>> {
|
||||||
wokdep:gui:SwitchArch
|
wokdep:gui:SwitchArch
|
||||||
}
|
}
|
||||||
bind .myFrame.myVsFrame.myConfigCombo <<ComboboxSelected>> {
|
|
||||||
wokdep:gui:SwitchArch
|
|
||||||
}
|
|
||||||
|
|
||||||
.myFrame.mySrchEntry configure -validate all -validatecommand {
|
.myFrame.mySrchEntry configure -validate all -validatecommand {
|
||||||
set ::PRODUCTS_PATH [file normalize "$::PRODUCTS_PATH_INPUT"]
|
set ::PRODUCTS_PATH [file normalize "$::PRODUCTS_PATH_INPUT"]
|
||||||
|
@@ -52,10 +52,6 @@ set CSF_OPT_LIB32 [list]
|
|||||||
set CSF_OPT_LIB64 [list]
|
set CSF_OPT_LIB64 [list]
|
||||||
set CSF_OPT_BIN32 [list]
|
set CSF_OPT_BIN32 [list]
|
||||||
set CSF_OPT_BIN64 [list]
|
set CSF_OPT_BIN64 [list]
|
||||||
set CSF_OPT_LIB32D [list]
|
|
||||||
set CSF_OPT_LIB64D [list]
|
|
||||||
set CSF_OPT_BIN32D [list]
|
|
||||||
set CSF_OPT_BIN64D [list]
|
|
||||||
|
|
||||||
if { "$tcl_platform(pointerSize)" == "4" } {
|
if { "$tcl_platform(pointerSize)" == "4" } {
|
||||||
set ARCH "32"
|
set ARCH "32"
|
||||||
@@ -72,15 +68,9 @@ if { [info exists ::env(SHORTCUT_HEADERS)] } {
|
|||||||
}
|
}
|
||||||
|
|
||||||
# fetch environment variables (e.g. set by custom.sh or custom.bat) and set them as tcl variables with the same name
|
# fetch environment variables (e.g. set by custom.sh or custom.bat) and set them as tcl variables with the same name
|
||||||
set THE_ENV_VARIABLES { HAVE_TK HAVE_FREETYPE HAVE_FREEIMAGE HAVE_FFMPEG HAVE_TBB HAVE_GLES2 HAVE_D3D HAVE_VTK \
|
set THE_ENV_VARIABLES {HAVE_FREEIMAGE HAVE_FFMPEG HAVE_TBB HAVE_GLES2 HAVE_D3D HAVE_VTK HAVE_ZLIB HAVE_LIBLZMA HAVE_E57 HAVE_RAPIDJSON HAVE_OPENCL CHECK_QT4 CHECK_JDK MACOSX_USE_GLX HAVE_RelWithDebInfo}
|
||||||
HAVE_ZLIB HAVE_LIBLZMA HAVE_E57 HAVE_RAPIDJSON HAVE_DRACO HAVE_OPENVR HAVE_OPENCL \
|
|
||||||
CHECK_QT4 CHECK_JDK HAVE_XLIB \
|
|
||||||
HAVE_RelWithDebInfo BUILD_Inspector }
|
|
||||||
foreach anEnvIter $THE_ENV_VARIABLES { set ${anEnvIter} "false" }
|
|
||||||
set HAVE_TK "true"
|
|
||||||
set HAVE_FREETYPE "true"
|
|
||||||
if { "$tcl_platform(os)" != "Darwin" } { set HAVE_XLIB "true" }
|
|
||||||
foreach anEnvIter $THE_ENV_VARIABLES {
|
foreach anEnvIter $THE_ENV_VARIABLES {
|
||||||
|
set ${anEnvIter} "false"
|
||||||
if { [info exists ::env(${anEnvIter})] } {
|
if { [info exists ::env(${anEnvIter})] } {
|
||||||
set ${anEnvIter} "$::env(${anEnvIter})"
|
set ${anEnvIter} "$::env(${anEnvIter})"
|
||||||
}
|
}
|
||||||
@@ -88,12 +78,12 @@ foreach anEnvIter $THE_ENV_VARIABLES {
|
|||||||
# do not export platform-specific variables
|
# do not export platform-specific variables
|
||||||
if { "$::tcl_platform(os)" == "Darwin" } {
|
if { "$::tcl_platform(os)" == "Darwin" } {
|
||||||
set HAVE_GLES2 ""
|
set HAVE_GLES2 ""
|
||||||
|
} else {
|
||||||
|
set MACOSX_USE_GLX ""
|
||||||
}
|
}
|
||||||
if { "$tcl_platform(platform)" != "windows" } {
|
if { "$tcl_platform(platform)" != "windows" } {
|
||||||
set HAVE_D3D ""
|
set HAVE_D3D ""
|
||||||
set HAVE_RelWithDebInfo ""
|
set HAVE_RelWithDebInfo ""
|
||||||
} else {
|
|
||||||
set HAVE_XLIB ""
|
|
||||||
}
|
}
|
||||||
foreach anEnvIter {ARCH VCVER VCVARS PRJFMT } {
|
foreach anEnvIter {ARCH VCVER VCVARS PRJFMT } {
|
||||||
if { [info exists ::env(${anEnvIter})] } {
|
if { [info exists ::env(${anEnvIter})] } {
|
||||||
@@ -120,35 +110,6 @@ if { [info exists ::env(CSF_OPT_BIN64)] } {
|
|||||||
set CSF_OPT_BIN64 [split "$::env(CSF_OPT_BIN64)" $::SYS_PATH_SPLITTER]
|
set CSF_OPT_BIN64 [split "$::env(CSF_OPT_BIN64)" $::SYS_PATH_SPLITTER]
|
||||||
}
|
}
|
||||||
|
|
||||||
if { [info exists ::env(CSF_OPT_LIB32D)] } {
|
|
||||||
set CSF_OPT_LIB32D [split "$::env(CSF_OPT_LIB32D)" $::SYS_PATH_SPLITTER]
|
|
||||||
foreach aLibIter $::CSF_OPT_LIB32 {
|
|
||||||
set aPos [lsearch -exact $::CSF_OPT_LIB32D $aLibIter]
|
|
||||||
set ::CSF_OPT_LIB32D [lreplace $::CSF_OPT_LIB32D $aPos $aPos]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if { [info exists ::env(CSF_OPT_LIB64D)] } {
|
|
||||||
set CSF_OPT_LIB64D [split "$::env(CSF_OPT_LIB64D)" $::SYS_PATH_SPLITTER]
|
|
||||||
foreach aLibIter $::CSF_OPT_LIB64 {
|
|
||||||
set aPos [lsearch -exact $::CSF_OPT_LIB64D $aLibIter]
|
|
||||||
set ::CSF_OPT_LIB64D [lreplace $::CSF_OPT_LIB64D $aPos $aPos]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if { [info exists ::env(CSF_OPT_BIN32D)] } {
|
|
||||||
set CSF_OPT_BIN32D [split "$::env(CSF_OPT_BIN32D)" $::SYS_PATH_SPLITTER]
|
|
||||||
foreach aLibIter $::CSF_OPT_BIN32 {
|
|
||||||
set aPos [lsearch -exact $::CSF_OPT_BIN32D $aLibIter]
|
|
||||||
set ::CSF_OPT_BIN32D [lreplace $::CSF_OPT_BIN32D $aPos $aPos]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if { [info exists ::env(CSF_OPT_BIN64D)] } {
|
|
||||||
set CSF_OPT_BIN64D [split "$::env(CSF_OPT_BIN64D)" $::SYS_PATH_SPLITTER]
|
|
||||||
foreach aLibIter $::CSF_OPT_BIN64 {
|
|
||||||
set aPos [lsearch -exact $::CSF_OPT_BIN64D $aLibIter]
|
|
||||||
set ::CSF_OPT_BIN64D [lreplace $::CSF_OPT_BIN64D $aPos $aPos]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
# Search header file in $::CSF_OPT_INC and standard paths
|
# Search header file in $::CSF_OPT_INC and standard paths
|
||||||
proc wokdep:SearchHeader {theHeader} {
|
proc wokdep:SearchHeader {theHeader} {
|
||||||
# search in custom paths
|
# search in custom paths
|
||||||
@@ -280,11 +241,7 @@ proc wokdep:Preferred {theList theCmpl theArch} {
|
|||||||
|
|
||||||
# keep only two first digits in "vc141"
|
# keep only two first digits in "vc141"
|
||||||
if { ! [regexp {^vc[0-9][0-9]} $theCmpl aCmpl] } {
|
if { ! [regexp {^vc[0-9][0-9]} $theCmpl aCmpl] } {
|
||||||
if { [regexp {^vclang} $theCmpl] } {
|
set aCmpl $theCmpl
|
||||||
set aCmpl vc14
|
|
||||||
} else {
|
|
||||||
set aCmpl $theCmpl
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
set aShortList {}
|
set aShortList {}
|
||||||
@@ -349,12 +306,6 @@ proc wokdep:SearchStandardLibrary {theErrInc theErrLib32 theErrLib64 theErrBin32
|
|||||||
lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib"
|
lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib"
|
||||||
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
||||||
set hasLib true
|
set hasLib true
|
||||||
|
|
||||||
set aLibDPath [wokdep:SearchLib "$theCheckLib" "$anArchIter" "$aPath/libd"]
|
|
||||||
if { "$aLibDPath" != "" } {
|
|
||||||
lappend ::CSF_OPT_LIB${anArchIter}D "$aPath/libd"
|
|
||||||
lappend ::CSF_OPT_BIN${anArchIter}D "$aPath/bind"
|
|
||||||
}
|
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -670,59 +621,6 @@ proc wokdep:SearchFFmpeg {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBi
|
|||||||
return "$isFound"
|
return "$isFound"
|
||||||
}
|
}
|
||||||
|
|
||||||
# Search OpenVR SDK placement
|
|
||||||
proc wokdep:SearchOpenVR {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64} {
|
|
||||||
upvar $theErrInc anErrInc
|
|
||||||
upvar $theErrLib32 anErrLib32
|
|
||||||
upvar $theErrLib64 anErrLib64
|
|
||||||
upvar $theErrBin32 anErrBin32
|
|
||||||
upvar $theErrBin64 anErrBin64
|
|
||||||
|
|
||||||
set isFound "true"
|
|
||||||
set anOpenVrHPath [wokdep:SearchHeader "openvr.h"]
|
|
||||||
if { "$anOpenVrHPath" == "" } {
|
|
||||||
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{openvr}*] "$::VCVER" "$::ARCH" ]
|
|
||||||
if { "$aPath" != "" && [file exists "$aPath/include/openvr.h"] } {
|
|
||||||
lappend ::CSF_OPT_INC "$aPath/include"
|
|
||||||
} elseif { "$aPath" != "" && [file exists "$aPath/headers/openvr.h"] } {
|
|
||||||
lappend ::CSF_OPT_INC "$aPath/headers"
|
|
||||||
} else {
|
|
||||||
lappend anErrInc "Error: 'openvr.h' not found (OpenVR)"
|
|
||||||
set isFound "false"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
set aPlatform "unknown"
|
|
||||||
if { "$::tcl_platform(platform)" == "windows" } {
|
|
||||||
set aPlatform "win"
|
|
||||||
} elseif { "$::tcl_platform(os)" == "Darwin" } {
|
|
||||||
set aPlatform "osx"
|
|
||||||
} elseif { "$::tcl_platform(os)" == "Linux" } {
|
|
||||||
set aPlatform "linux"
|
|
||||||
}
|
|
||||||
|
|
||||||
foreach anArchIter {64 32} {
|
|
||||||
set anOpenVrLibPath [wokdep:SearchLib "openvr_api" "$anArchIter"]
|
|
||||||
if { "$anOpenVrLibPath" == "" } {
|
|
||||||
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{openvr}*] "$::VCVER" "$anArchIter" ]
|
|
||||||
set anOpenVrLibPath [wokdep:SearchLib "openvr_api" "$anArchIter" "$aPath/lib/${aPlatform}${anArchIter}"]
|
|
||||||
set anOpenVrLibPath2 [wokdep:SearchLib "openvr_api" "$anArchIter" "$aPath/lib"]
|
|
||||||
if { "$anOpenVrLibPath" != "" } {
|
|
||||||
lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib/${aPlatform}${anArchIter}"
|
|
||||||
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin/${aPlatform}${anArchIter}"
|
|
||||||
} elseif { "$anOpenVrLibPath2" != "" } {
|
|
||||||
lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib"
|
|
||||||
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
|
||||||
} else {
|
|
||||||
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}openvr_api.${::SYS_LIB_SUFFIX}' not found (OpenVR)"
|
|
||||||
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return "$isFound"
|
|
||||||
}
|
|
||||||
|
|
||||||
# Search TBB library placement
|
# Search TBB library placement
|
||||||
proc wokdep:SearchTBB {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64} {
|
proc wokdep:SearchTBB {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64} {
|
||||||
upvar $theErrInc anErrInc
|
upvar $theErrInc anErrInc
|
||||||
@@ -733,11 +631,7 @@ proc wokdep:SearchTBB {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64
|
|||||||
|
|
||||||
# keep only two first digits in "vc141"
|
# keep only two first digits in "vc141"
|
||||||
if { ! [regexp {^vc[0-9][0-9]} ${::VCVER} aVcLib] } {
|
if { ! [regexp {^vc[0-9][0-9]} ${::VCVER} aVcLib] } {
|
||||||
if { [regexp {^vclang} ${::VCVER}] } {
|
set aVcLib ${::VCVER}
|
||||||
set aVcLib vc14
|
|
||||||
} else {
|
|
||||||
set aVcLib ${::VCVER}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
set isFound "true"
|
set isFound "true"
|
||||||
@@ -1086,51 +980,42 @@ proc wokdep:SearchVTK {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
# Search binary path
|
# Search binary path
|
||||||
if { "$::tcl_platform(platform)" == "windows" } {
|
if { "$::tcl_platform(platform)" == "windows" } {
|
||||||
set aVtkBinPath [wokdep:SearchBin "vtkCommonCore-${aVtkVer}.dll" "$anArchIter"]
|
foreach anArchIter {64 32} {
|
||||||
if { "$aVtkBinPath" == "" } {
|
set aVtkBinPath [wokdep:SearchBin "vtkCommonCore-${aVtkVer}.dll" "$anArchIter"]
|
||||||
set aPathList [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{VTK}*]
|
if { "$aVtkBinPath" == "" } {
|
||||||
set aPath [wokdep:Preferred $aPathList "$::VCVER" "$anArchIter" ]
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{VTK}*] "$::VCVER" "$anArchIter" ]
|
||||||
set aVtkBinPath [wokdep:SearchBin "vtkCommonCore-${aVtkVer}.dll" "$anArchIter" "$aPath/bin"]
|
set aVtkBinPath [wokdep:SearchBin "vtkCommonCore-${aVtkVer}.dll" "$anArchIter" "$aPath/bin"]
|
||||||
if { "$aVtkBinPath" != "" } {
|
if { "$aVtkBinPath" != "" } { lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
||||||
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
|
||||||
} else {
|
|
||||||
# Try to find in lib path
|
|
||||||
set aVtkBinPath [wokdep:SearchBin "vtkCommonCore-${aVtkVer}.dll" "$anArchIter" "$aPath/lib"]
|
|
||||||
if { "$aVtkBinPath" != "" } {
|
|
||||||
lappend ::CSF_OPT_BIN$anArchIter "$aPath/lib"
|
|
||||||
} else {
|
} else {
|
||||||
# We didn't find preferred binary path => search through all available VTK directories
|
set aVtkBinPath [wokdep:SearchBin "vtkCommonCore-${aVtkVer}.dll" "$anArchIter" "$aPath/lib"]
|
||||||
foreach anIt $aPathList {
|
if { "$aVtkBinPath" != "" } { lappend ::CSF_OPT_BIN$anArchIter "$aPath/lib" }
|
||||||
set aVtkBinPath [wokdep:SearchBin "vtkCommonCore-${aVtkVer}.dll" "$anArchIter" "$anIt/bin"]
|
|
||||||
if { "$aVtkBinPath" != "" } {
|
|
||||||
lappend ::CSF_OPT_BIN$anArchIter "$anIt/bin"
|
|
||||||
break
|
|
||||||
} else {
|
|
||||||
# Try to find in lib path
|
|
||||||
set aVtkBinPath [wokdep:SearchBin "vtkCommonCore-${aVtkVer}.dll" "$anArchIter" "$anIt/lib"]
|
|
||||||
if { "$aVtkBinPath" != "" } {
|
|
||||||
lappend ::CSF_OPT_BIN$anArchIter "$anIt/lib"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if { "$aVtkBinPath" == "" } {
|
|
||||||
lappend anErrBin$anArchIter "Error: 'vtkCommonCore-${aVtkVer}.dll' not found (VTK)"
|
|
||||||
set isFound "false"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# We didn't find preferred binary path => search through inc path or among all available VTK directories
|
||||||
|
if { "$aVtkBinPath" == "" } {
|
||||||
|
# Try to find in lib path
|
||||||
|
set aPath [wokdep:SearchBin "vtkCommonCore-${aVtkVer}.dll" "$anArchIter" "$aVtkLibPath/bin"]
|
||||||
|
if { "$aPath" != "" } { lappend ::CSF_OPT_BIN$anArchIter "$aVtkLibPath/bin"
|
||||||
|
} elseif { [wokdep:SearchBin "vtkCommonCore-${aVtkVer}.dll" "$anArchIter" "$aVtkLibPath/lib"] != "" } {
|
||||||
|
lappend ::CSF_OPT_BIN$anArchIter "$aVtkLibPath/lib"
|
||||||
|
} else {
|
||||||
|
lappend anErrBin$anArchIter "Error: 'vtkCommonCore-${aVtkVer}.dll' not found (VTK)"
|
||||||
|
set isFound "false"
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
return "$isFound"
|
return "$isFound"
|
||||||
}
|
}
|
||||||
|
|
||||||
# Search Qt libraries placement
|
# Search Qt4 libraries placement
|
||||||
proc wokdep:SearchQt {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64} {
|
proc wokdep:SearchQt4 {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64} {
|
||||||
upvar $theErrInc anErrInc
|
upvar $theErrInc anErrInc
|
||||||
upvar $theErrLib32 anErrLib32
|
upvar $theErrLib32 anErrLib32
|
||||||
upvar $theErrLib64 anErrLib64
|
upvar $theErrLib64 anErrLib64
|
||||||
@@ -1138,46 +1023,53 @@ proc wokdep:SearchQt {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64}
|
|||||||
upvar $theErrBin64 anErrBin64
|
upvar $theErrBin64 anErrBin64
|
||||||
|
|
||||||
set isFound "true"
|
set isFound "true"
|
||||||
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{qt}*] "$::VCVER" "$::ARCH" ]
|
set aQMsgBoxHPath [wokdep:SearchHeader "QtGui/qmessagebox.h"]
|
||||||
set aQMsgBoxHPath [wokdep:SearchHeader "QtGui/qguiapplication.h"]
|
|
||||||
if { "$aQMsgBoxHPath" == "" } {
|
if { "$aQMsgBoxHPath" == "" } {
|
||||||
if { "$aPath" != "" && [file exists "$aPath/include/QtGui/qguiapplication.h"] } {
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{qt4}*] "$::VCVER" "$::ARCH" ]
|
||||||
|
if { "$aPath" != "" && [file exists "$aPath/include/QtGui/qmessagebox.h"] } {
|
||||||
lappend ::CSF_OPT_INC "$aPath/include"
|
lappend ::CSF_OPT_INC "$aPath/include"
|
||||||
lappend ::CSF_OPT_INC "$aPath/include/Qt"
|
lappend ::CSF_OPT_INC "$aPath/include/Qt"
|
||||||
lappend ::CSF_OPT_INC "$aPath/include/QtGui"
|
lappend ::CSF_OPT_INC "$aPath/include/QtGui"
|
||||||
lappend ::CSF_OPT_INC "$aPath/include/QtCore"
|
lappend ::CSF_OPT_INC "$aPath/include/QtCore"
|
||||||
lappend ::CSF_OPT_INC "$aPath/include/QtWidgets"
|
|
||||||
lappend ::CSF_OPT_INC "$aPath/include/QtXml"
|
|
||||||
} else {
|
} else {
|
||||||
lappend anErrInc "Error: 'QtGui/qguiapplication.h' not found"
|
if { [file exists "/usr/include/qt4/QtGui/qmessagebox.h"] } {
|
||||||
|
lappend ::CSF_OPT_INC "/usr/include/qt4"
|
||||||
|
lappend ::CSF_OPT_INC "/usr/include/qt4/Qt"
|
||||||
|
lappend ::CSF_OPT_INC "/usr/include/qt4/QtGui"
|
||||||
|
lappend ::CSF_OPT_INC "/usr/include/qt4/QtCore"
|
||||||
|
} else {
|
||||||
|
lappend anErrInc "Error: 'QtGui/qmessagebox.h' not found (Qt4)"
|
||||||
set isFound "false"
|
set isFound "false"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
set aQtGuiLibName "QtGui"
|
set aQtGuiLibName "QtGui"
|
||||||
if { "$::tcl_platform(platform)" == "windows" } {
|
if { "$::tcl_platform(platform)" == "windows" } {
|
||||||
set aQtGuiLibName "Qt5Gui"
|
set aQtGuiLibName "QtGui4"
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach anArchIter {64 32} {
|
foreach anArchIter {64 32} {
|
||||||
set aQMsgBoxLibPath [wokdep:SearchLib "${aQtGuiLibName}" "$anArchIter"]
|
set aQMsgBoxLibPath [wokdep:SearchLib "${aQtGuiLibName}" "$anArchIter"]
|
||||||
if { "$aQMsgBoxLibPath" == "" } {
|
if { "$aQMsgBoxLibPath" == "" } {
|
||||||
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{qt4}*] "$::VCVER" "$anArchIter" ]
|
||||||
set aQMsgBoxLibPath [wokdep:SearchLib "${aQtGuiLibName}" "$anArchIter" "$aPath/lib"]
|
set aQMsgBoxLibPath [wokdep:SearchLib "${aQtGuiLibName}" "$anArchIter" "$aPath/lib"]
|
||||||
if { "$aQMsgBoxLibPath" != "" } {
|
if { "$aQMsgBoxLibPath" != "" } {
|
||||||
lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib"
|
lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib"
|
||||||
} else {
|
} else {
|
||||||
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}${aQtGuiLibName}.${::SYS_LIB_SUFFIX}' not found (Qt)"
|
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}${aQtGuiLibName}.${::SYS_LIB_SUFFIX}' not found (Qt4)"
|
||||||
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if { "$::tcl_platform(platform)" == "windows" } {
|
if { "$::tcl_platform(platform)" == "windows" } {
|
||||||
set aQMsgBoxDllPath [wokdep:SearchBin "${aQtGuiLibName}.dll" "$anArchIter"]
|
set aQMsgBoxDllPath [wokdep:SearchBin "QtGui4.dll" "$anArchIter"]
|
||||||
if { "$aQMsgBoxDllPath" == "" } {
|
if { "$aQMsgBoxDllPath" == "" } {
|
||||||
set aQMsgBoxDllPath [wokdep:SearchBin "${aQtGuiLibName}.dll" "$anArchIter" "$aPath/bin"]
|
set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{qt4}*] "$::VCVER" "$anArchIter" ]
|
||||||
|
set aQMsgBoxDllPath [wokdep:SearchBin "QtGui4.dll" "$anArchIter" "$aPath/bin"]
|
||||||
if { "$aQMsgBoxDllPath" != "" } {
|
if { "$aQMsgBoxDllPath" != "" } {
|
||||||
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin"
|
||||||
} else {
|
} else {
|
||||||
lappend anErrBin$anArchIter "Error: '${aQtGuiLibName}.dll' not found (Qt)"
|
lappend anErrBin$anArchIter "Error: 'QtGui4.dll' not found (Qt4)"
|
||||||
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1247,7 +1139,7 @@ proc wokdep:SearchX11 {theErrInc theErrLib32 theErrLib64 theErrBin32 theErrBin64
|
|||||||
upvar $theErrBin64 anErrBin64
|
upvar $theErrBin64 anErrBin64
|
||||||
|
|
||||||
set isFound "true"
|
set isFound "true"
|
||||||
if { "$::tcl_platform(platform)" == "windows" || ( "$::tcl_platform(os)" == "Darwin" && "$::HAVE_XLIB" != "true" ) } {
|
if { "$::tcl_platform(platform)" == "windows" || ( "$::tcl_platform(os)" == "Darwin" && "$::MACOSX_USE_GLX" != "true" ) } {
|
||||||
return "$isFound"
|
return "$isFound"
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1326,18 +1218,6 @@ proc wokdep:SaveCustom {} {
|
|||||||
puts $aFile "rem Additional libraries (32-bit) search paths"
|
puts $aFile "rem Additional libraries (32-bit) search paths"
|
||||||
puts $aFile "set \"CSF_OPT_LIB32=$aStringLib32\""
|
puts $aFile "set \"CSF_OPT_LIB32=$aStringLib32\""
|
||||||
|
|
||||||
set aStringLib32d [join $::CSF_OPT_LIB32D $::SYS_PATH_SPLITTER]
|
|
||||||
if { "$::PRODUCTS_PATH" != "" } {
|
|
||||||
set aStringLib32d [regsub -all "$::PRODUCTS_PATH" $aStringLib32d "%PRODUCTS_PATH%"]
|
|
||||||
}
|
|
||||||
puts $aFile ""
|
|
||||||
puts $aFile "rem Additional debug libraries (32-bit) search paths"
|
|
||||||
if { "$aStringLib32d" != "" && "$aStringLib32" != "" } {
|
|
||||||
puts $aFile "set \"CSF_OPT_LIB32D=$aStringLib32d;%CSF_OPT_LIB32%\""
|
|
||||||
} else {
|
|
||||||
puts $aFile "set \"CSF_OPT_LIB32D=$aStringLib32d\""
|
|
||||||
}
|
|
||||||
|
|
||||||
set aStringLib64 [join $::CSF_OPT_LIB64 $::SYS_PATH_SPLITTER]
|
set aStringLib64 [join $::CSF_OPT_LIB64 $::SYS_PATH_SPLITTER]
|
||||||
if { "$::PRODUCTS_PATH" != "" } {
|
if { "$::PRODUCTS_PATH" != "" } {
|
||||||
set aStringLib64 [regsub -all "$::PRODUCTS_PATH" $aStringLib64 "%PRODUCTS_PATH%"]
|
set aStringLib64 [regsub -all "$::PRODUCTS_PATH" $aStringLib64 "%PRODUCTS_PATH%"]
|
||||||
@@ -1346,18 +1226,6 @@ proc wokdep:SaveCustom {} {
|
|||||||
puts $aFile "rem Additional libraries (64-bit) search paths"
|
puts $aFile "rem Additional libraries (64-bit) search paths"
|
||||||
puts $aFile "set \"CSF_OPT_LIB64=$aStringLib64\""
|
puts $aFile "set \"CSF_OPT_LIB64=$aStringLib64\""
|
||||||
|
|
||||||
set aStringLib64d [join $::CSF_OPT_LIB64D $::SYS_PATH_SPLITTER]
|
|
||||||
if { "$::PRODUCTS_PATH" != "" } {
|
|
||||||
set aStringLib64d [regsub -all "$::PRODUCTS_PATH" $aStringLib64d "%PRODUCTS_PATH%"]
|
|
||||||
}
|
|
||||||
puts $aFile ""
|
|
||||||
puts $aFile "rem Additional debug libraries (64-bit) search paths"
|
|
||||||
if { "$aStringLib64d" != "" && "$aStringLib64" != "" } {
|
|
||||||
puts $aFile "set \"CSF_OPT_LIB64D=$aStringLib64d;%CSF_OPT_LIB64%\""
|
|
||||||
} else {
|
|
||||||
puts $aFile "set \"CSF_OPT_LIB64D=$aStringLib64d\""
|
|
||||||
}
|
|
||||||
|
|
||||||
set aStringBin32 [join $::CSF_OPT_BIN32 $::SYS_PATH_SPLITTER]
|
set aStringBin32 [join $::CSF_OPT_BIN32 $::SYS_PATH_SPLITTER]
|
||||||
if { "$::PRODUCTS_PATH" != "" } {
|
if { "$::PRODUCTS_PATH" != "" } {
|
||||||
set aStringBin32 [regsub -all "$::PRODUCTS_PATH" $aStringBin32 "%PRODUCTS_PATH%"]
|
set aStringBin32 [regsub -all "$::PRODUCTS_PATH" $aStringBin32 "%PRODUCTS_PATH%"]
|
||||||
@@ -1366,18 +1234,6 @@ proc wokdep:SaveCustom {} {
|
|||||||
puts $aFile "rem Additional (32-bit) search paths"
|
puts $aFile "rem Additional (32-bit) search paths"
|
||||||
puts $aFile "set \"CSF_OPT_BIN32=$aStringBin32\""
|
puts $aFile "set \"CSF_OPT_BIN32=$aStringBin32\""
|
||||||
|
|
||||||
set aStringBin32d [join $::CSF_OPT_BIN32D $::SYS_PATH_SPLITTER]
|
|
||||||
if { "$::PRODUCTS_PATH" != "" } {
|
|
||||||
set aStringBin32d [regsub -all "$::PRODUCTS_PATH" $aStringBin32d "%PRODUCTS_PATH%"]
|
|
||||||
}
|
|
||||||
puts $aFile ""
|
|
||||||
puts $aFile "rem Additional debug (32-bit) search paths"
|
|
||||||
if { "$aStringBin32d" != "" && "$aStringBin32" != "" } {
|
|
||||||
puts $aFile "set \"CSF_OPT_BIN32D=$aStringBin32d;%CSF_OPT_BIN32%\""
|
|
||||||
} else {
|
|
||||||
puts $aFile "set \"CSF_OPT_BIN32D=$aStringBin32d\""
|
|
||||||
}
|
|
||||||
|
|
||||||
set aStringBin64 [join $::CSF_OPT_BIN64 $::SYS_PATH_SPLITTER]
|
set aStringBin64 [join $::CSF_OPT_BIN64 $::SYS_PATH_SPLITTER]
|
||||||
if { "$::PRODUCTS_PATH" != "" } {
|
if { "$::PRODUCTS_PATH" != "" } {
|
||||||
set aStringBin64 [regsub -all "$::PRODUCTS_PATH" $aStringBin64 "%PRODUCTS_PATH%"]
|
set aStringBin64 [regsub -all "$::PRODUCTS_PATH" $aStringBin64 "%PRODUCTS_PATH%"]
|
||||||
@@ -1386,18 +1242,6 @@ proc wokdep:SaveCustom {} {
|
|||||||
puts $aFile "rem Additional (64-bit) search paths"
|
puts $aFile "rem Additional (64-bit) search paths"
|
||||||
puts $aFile "set \"CSF_OPT_BIN64=$aStringBin64\""
|
puts $aFile "set \"CSF_OPT_BIN64=$aStringBin64\""
|
||||||
|
|
||||||
set aStringBin64d [join $::CSF_OPT_BIN64D $::SYS_PATH_SPLITTER]
|
|
||||||
if { "$::PRODUCTS_PATH" != "" } {
|
|
||||||
set aStringBin64d [regsub -all "$::PRODUCTS_PATH" $aStringBin64d "%PRODUCTS_PATH%"]
|
|
||||||
}
|
|
||||||
puts $aFile ""
|
|
||||||
puts $aFile "rem Additional debug (64-bit) search paths"
|
|
||||||
if { "$aStringBin64d" != "" && "$aStringBin64" != "" } {
|
|
||||||
puts $aFile "set \"CSF_OPT_BIN64D=$aStringBin64d;%CSF_OPT_BIN64%\""
|
|
||||||
} else {
|
|
||||||
puts $aFile "set \"CSF_OPT_BIN64D=$aStringBin64d\""
|
|
||||||
}
|
|
||||||
|
|
||||||
close $aFile
|
close $aFile
|
||||||
} else {
|
} else {
|
||||||
set aCustomFilePath "./custom.sh"
|
set aCustomFilePath "./custom.sh"
|
||||||
@@ -1439,18 +1283,6 @@ proc wokdep:SaveCustom {} {
|
|||||||
puts $aFile "# Additional libraries ($::ARCH-bit) search paths"
|
puts $aFile "# Additional libraries ($::ARCH-bit) search paths"
|
||||||
puts $aFile "export CSF_OPT_LIB$::ARCH=\"[set aStringLib]\""
|
puts $aFile "export CSF_OPT_LIB$::ARCH=\"[set aStringLib]\""
|
||||||
|
|
||||||
set aStringLibD [join [set ::CSF_OPT_LIB${::ARCH}D] $::SYS_PATH_SPLITTER]
|
|
||||||
if { "$::PRODUCTS_PATH" != "" } {
|
|
||||||
set aStringLibD [regsub -all "$::PRODUCTS_PATH" $aStringLibD "\${PRODUCTS_PATH}"]
|
|
||||||
}
|
|
||||||
puts $aFile ""
|
|
||||||
puts $aFile "# Additional debug libraries ($::ARCH-bit) search paths"
|
|
||||||
if { "$aStringLibD" != "" && "$aStringLib" != "" } {
|
|
||||||
puts $aFile "export CSF_OPT_LIB${::ARCH}D=\"[set aStringLibD]:\$CSF_OPT_LIB${::ARCH}\""
|
|
||||||
} else {
|
|
||||||
puts $aFile "export CSF_OPT_LIB${::ARCH}D=\"[set aStringLibD]\""
|
|
||||||
}
|
|
||||||
|
|
||||||
set aStringBin [join [set ::CSF_OPT_BIN$::ARCH] $::SYS_PATH_SPLITTER]
|
set aStringBin [join [set ::CSF_OPT_BIN$::ARCH] $::SYS_PATH_SPLITTER]
|
||||||
if { "$::PRODUCTS_PATH" != "" } {
|
if { "$::PRODUCTS_PATH" != "" } {
|
||||||
set aStringBin [regsub -all "$::PRODUCTS_PATH" $aStringBin "\${PRODUCTS_PATH}"]
|
set aStringBin [regsub -all "$::PRODUCTS_PATH" $aStringBin "\${PRODUCTS_PATH}"]
|
||||||
@@ -1459,18 +1291,6 @@ proc wokdep:SaveCustom {} {
|
|||||||
puts $aFile "# Additional ($::ARCH-bit) search paths"
|
puts $aFile "# Additional ($::ARCH-bit) search paths"
|
||||||
puts $aFile "export CSF_OPT_BIN$::ARCH=\"[set aStringBin]\""
|
puts $aFile "export CSF_OPT_BIN$::ARCH=\"[set aStringBin]\""
|
||||||
|
|
||||||
set aStringBinD [join [set ::CSF_OPT_BIN${::ARCH}D] $::SYS_PATH_SPLITTER]
|
|
||||||
if { "$::PRODUCTS_PATH" != "" } {
|
|
||||||
set aStringBinD [regsub -all "$::PRODUCTS_PATH" $aStringBinD "\${PRODUCTS_PATH}"]
|
|
||||||
}
|
|
||||||
puts $aFile ""
|
|
||||||
puts $aFile "# Additional debug ($::ARCH-bit) search paths"
|
|
||||||
if { "$aStringBinD" != "" && "$aStringBin" != "" } {
|
|
||||||
puts $aFile "export CSF_OPT_BIN${::ARCH}D=\"[set aStringBinD]:\$CSF_OPT_BIN${::ARCH}\""
|
|
||||||
} else {
|
|
||||||
puts $aFile "export CSF_OPT_BIN${::ARCH}D=\"[set aStringBinD]\""
|
|
||||||
}
|
|
||||||
|
|
||||||
close $aFile
|
close $aFile
|
||||||
}
|
}
|
||||||
puts "Configuration saved to file '$aCustomFilePath'"
|
puts "Configuration saved to file '$aCustomFilePath'"
|
||||||
@@ -1508,27 +1328,6 @@ proc wokdep:SaveCustom {} {
|
|||||||
puts $aFile "INCLUDEPATH += \"${anIncPath}\""
|
puts $aFile "INCLUDEPATH += \"${anIncPath}\""
|
||||||
}
|
}
|
||||||
|
|
||||||
puts $aFile ""
|
|
||||||
puts $aFile "CONFIG(debug, debug|release) {"
|
|
||||||
puts $aFile " # Additional debug libraries search paths"
|
|
||||||
foreach aLibPath [set ::CSF_OPT_LIB${::ARCH}D] {
|
|
||||||
if { "$::PRODUCTS_PATH" != "" } {
|
|
||||||
set aLibPath [regsub -all "$::PRODUCTS_PATH" $aLibPath "\$\$\{PRODUCTS_PATH\}"]
|
|
||||||
}
|
|
||||||
puts $aFile " LIBS += -L\"${aLibPath}\""
|
|
||||||
}
|
|
||||||
if { "$::tcl_platform(platform)" == "windows" } {
|
|
||||||
puts $aFile ""
|
|
||||||
puts $aFile " # Additional debug DLLs search paths"
|
|
||||||
foreach aDllPath [set ::CSF_OPT_BIN${::ARCH}D] {
|
|
||||||
if { "$::PRODUCTS_PATH" != "" } {
|
|
||||||
set aDllPath [regsub -all "$::PRODUCTS_PATH" $aDllPath "\$\$\{PRODUCTS_PATH\}"]
|
|
||||||
}
|
|
||||||
puts $aFile " LIBS += -L\"${aDllPath}\""
|
|
||||||
}
|
|
||||||
}
|
|
||||||
puts $aFile "}"
|
|
||||||
|
|
||||||
puts $aFile ""
|
puts $aFile ""
|
||||||
puts $aFile "# Additional libraries search paths"
|
puts $aFile "# Additional libraries search paths"
|
||||||
foreach aLibPath [set ::CSF_OPT_LIB$::ARCH] {
|
foreach aLibPath [set ::CSF_OPT_LIB$::ARCH] {
|
||||||
|
@@ -236,7 +236,7 @@ proc gendoc {args} {
|
|||||||
return -1
|
return -1
|
||||||
}
|
}
|
||||||
} elseif {$arg_n == "s"} {
|
} elseif {$arg_n == "s"} {
|
||||||
if { [ lsearch $args_names "pdf" ] == -1 } {
|
if { [ lsearch $args_names "pdf" ] != -1 } {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
if {$args_values(s) != "NULL"} {
|
if {$args_values(s) != "NULL"} {
|
||||||
@@ -686,17 +686,6 @@ proc OCCDoc_MakeDoxyfile {docType outDir tagFileDir {doxyFileName} {generatorMod
|
|||||||
# Write specific options
|
# Write specific options
|
||||||
if { $docType == "REFMAN" } {
|
if { $docType == "REFMAN" } {
|
||||||
|
|
||||||
# always include optional components
|
|
||||||
set aHaveD3dBack ""
|
|
||||||
set aHaveGlesBack ""
|
|
||||||
set aHaveVtkBack ""
|
|
||||||
if { [info exists ::env(HAVE_D3D)] } { set aHaveD3dBack "$::env(HAVE_D3D)" }
|
|
||||||
if { [info exists ::env(HAVE_GLES2)] } { set aHaveGlesBack "$::env(HAVE_GLES2)" }
|
|
||||||
if { [info exists ::env(HAVE_VTK)] } { set aHaveVtkBack "$::env(HAVE_VTK)" }
|
|
||||||
set ::env(HAVE_D3D) "true"
|
|
||||||
set ::env(HAVE_GLES2) "true"
|
|
||||||
set ::env(HAVE_VTK) "true"
|
|
||||||
|
|
||||||
# Load lists of modules scripts
|
# Load lists of modules scripts
|
||||||
if { $productsPath == "" } {
|
if { $productsPath == "" } {
|
||||||
set modules_scripts [glob -nocomplain -type f -directory "[OCCDoc_GetSourceDir $productsPath]/OS/" *.tcl]
|
set modules_scripts [glob -nocomplain -type f -directory "[OCCDoc_GetSourceDir $productsPath]/OS/" *.tcl]
|
||||||
@@ -822,11 +811,6 @@ proc OCCDoc_MakeDoxyfile {docType outDir tagFileDir {doxyFileName} {generatorMod
|
|||||||
|
|
||||||
puts $doxyFile ""
|
puts $doxyFile ""
|
||||||
|
|
||||||
# restore environment variables
|
|
||||||
set ::env(HAVE_D3D) "$aHaveD3dBack"
|
|
||||||
set ::env(HAVE_GLES2) "$aHaveGlesBack"
|
|
||||||
set ::env(HAVE_VTK) "$aHaveVtkBack"
|
|
||||||
|
|
||||||
} elseif { $docType == "OVERVIEW" } {
|
} elseif { $docType == "OVERVIEW" } {
|
||||||
|
|
||||||
# Add common options for generation of Overview and User Guides
|
# Add common options for generation of Overview and User Guides
|
||||||
|
715
adm/genproj.tcl
@@ -16,7 +16,7 @@
|
|||||||
# commercial license or contractual agreement.
|
# commercial license or contractual agreement.
|
||||||
|
|
||||||
# =======================================================================
|
# =======================================================================
|
||||||
# This script contains auxiliary functions which can be used
|
# This script contains auxilary functions which can be used
|
||||||
# in documentation generation process
|
# in documentation generation process
|
||||||
# =======================================================================
|
# =======================================================================
|
||||||
|
|
||||||
@@ -179,10 +179,8 @@ proc OCCDoc_DetectNecessarySoftware { DOXYGEN_PATH GRAPHVIZ_PATH INKSCAPE_PATH H
|
|||||||
}
|
}
|
||||||
if {"$is_win" == "yes"} {
|
if {"$is_win" == "yes"} {
|
||||||
set exe ".exe"
|
set exe ".exe"
|
||||||
set com ".com"
|
|
||||||
} else {
|
} else {
|
||||||
set exe ""
|
set exe ""
|
||||||
set com ""
|
|
||||||
}
|
}
|
||||||
|
|
||||||
set g_flag "no"
|
set g_flag "no"
|
||||||
@@ -226,11 +224,11 @@ proc OCCDoc_DetectNecessarySoftware { DOXYGEN_PATH GRAPHVIZ_PATH INKSCAPE_PATH H
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if {$i_flag == "no"} {
|
if {$i_flag == "no"} {
|
||||||
if { [file exists $path/inkscape$com] } {
|
if { [file exists $path/inkscape$exe] } {
|
||||||
catch { exec $path/inkscape -V } version
|
catch { exec $path/inkscape -V } version
|
||||||
puts "Info: $version "
|
puts "Info: $version "
|
||||||
puts " found in $path."
|
puts " found in $path."
|
||||||
set inkscape_path "$path/inkscape$com"
|
set inkscape_path "$path/inkscape$exe"
|
||||||
set i_flag "yes"
|
set i_flag "yes"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -358,29 +356,15 @@ proc OCCDoc_DetectNecessarySoftware { DOXYGEN_PATH GRAPHVIZ_PATH INKSCAPE_PATH H
|
|||||||
# Convert SVG files to PDF format to allow including them to PDF
|
# Convert SVG files to PDF format to allow including them to PDF
|
||||||
# (requires InkScape to be in PATH)
|
# (requires InkScape to be in PATH)
|
||||||
proc OCCDoc_ProcessSvg {latexDir verboseMode} {
|
proc OCCDoc_ProcessSvg {latexDir verboseMode} {
|
||||||
set anSvgList [glob -nocomplain $latexDir/*.svg]
|
|
||||||
if { $anSvgList == {} } {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
catch { exec inkscape -V } anInkVer
|
foreach file [glob -nocomplain $latexDir/*.svg] {
|
||||||
set isOldSyntax 0
|
|
||||||
if {[string match "Inkscape 0.*" $anInkVer]} { set isOldSyntax 1 }
|
|
||||||
foreach file $anSvgList {
|
|
||||||
if {$verboseMode == "YES"} {
|
if {$verboseMode == "YES"} {
|
||||||
puts "Info: Converting file $file..."
|
puts "Info: Converting file $file..."
|
||||||
}
|
}
|
||||||
set pdffile "[file rootname $file].pdf"
|
set pdffile "[file rootname $file].pdf"
|
||||||
if { $isOldSyntax == 1 } {
|
if { [catch {exec inkscape -z -D --file=$file --export-pdf=$pdffile} res] } {
|
||||||
if { [catch {exec inkscape -z -D --file=$file --export-pdf=$pdffile} res] } {
|
#puts "Error: $res."
|
||||||
#puts "Error: $res."
|
return
|
||||||
return
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
if { [catch {exec inkscape $file --export-area-drawing --export-type=pdf --export-filename=$pdffile} res] } {
|
|
||||||
#puts "Error: $res."
|
|
||||||
return
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -635,7 +619,7 @@ proc OCCDoc_MakeMainPage {outDir outFile modules {theProductsDir ""} } {
|
|||||||
foreach mod $modules {
|
foreach mod $modules {
|
||||||
puts $fd "\\li \\subpage [string tolower $module_prefix$mod]"
|
puts $fd "\\li \\subpage [string tolower $module_prefix$mod]"
|
||||||
}
|
}
|
||||||
# insert modules relationship diagram
|
# insert modules relationship diagramm
|
||||||
puts $fd "\\dotfile [OCCDoc_CreateModulesDependencyGraph $outDir/html schema_all_modules $modules $module_prefix]"
|
puts $fd "\\dotfile [OCCDoc_CreateModulesDependencyGraph $outDir/html schema_all_modules $modules $module_prefix]"
|
||||||
puts $fd "**/\n"
|
puts $fd "**/\n"
|
||||||
}
|
}
|
||||||
|
@@ -13,8 +13,8 @@ OccGitRoot = $$_PRO_FILE_PWD_/../../../..
|
|||||||
|
|
||||||
# Define compilation flags
|
# Define compilation flags
|
||||||
CONFIG += warn_on
|
CONFIG += warn_on
|
||||||
QMAKE_CFLAGS_WARN_ON = -Wall -Wextra
|
QMAKE_CFLAGS_WARN_ON = -Wall
|
||||||
QMAKE_CXXFLAGS_WARN_ON = -Wall -Wextra
|
QMAKE_CXXFLAGS_WARN_ON = -Wall
|
||||||
win32 {
|
win32 {
|
||||||
QMAKE_CFLAGS_WARN_ON = -W4
|
QMAKE_CFLAGS_WARN_ON = -W4
|
||||||
QMAKE_CXXFLAGS_WARN_ON = -W4
|
QMAKE_CXXFLAGS_WARN_ON = -W4
|
||||||
@@ -49,9 +49,6 @@ win32 {
|
|||||||
} else {
|
} else {
|
||||||
QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.14
|
QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.14
|
||||||
}
|
}
|
||||||
} else:gcc {
|
|
||||||
# ask linker to report missing library dependencies
|
|
||||||
QMAKE_LFLAGS += -Wl,-z,defs
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
!CONFIG(debug, debug|release) {
|
!CONFIG(debug, debug|release) {
|
||||||
@@ -156,4 +153,5 @@ win32 {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
OBJECTS_DIR = $$DESTDIR/../obj$${MY_BUILDTYPE}/$${TARGET}
|
#OBJECTS_DIR = $$DESTDIR/../obj$${MY_BUILDTYPE}/$${TARGET}
|
||||||
|
OBJECTS_DIR = $$DESTDIR/../obj$${MY_BUILDTYPE}
|
||||||
|
@@ -15,14 +15,8 @@ for (aModuleIter, aModuleList) {
|
|||||||
equals (aToolKit, $$OCC_MODULE_NAME) { toSkipToolkit = 1 }
|
equals (aToolKit, $$OCC_MODULE_NAME) { toSkipToolkit = 1 }
|
||||||
!HAVE_VTK:equals (aToolKit, "TKIVtk") { toSkipToolkit = 1 }
|
!HAVE_VTK:equals (aToolKit, "TKIVtk") { toSkipToolkit = 1 }
|
||||||
!HAVE_VTK:equals (aToolKit, "TKIVtkDraw") { toSkipToolkit = 1 }
|
!HAVE_VTK:equals (aToolKit, "TKIVtkDraw") { toSkipToolkit = 1 }
|
||||||
#!HAVE_OPENGL: equals (aToolKit, "TKOpenGl") { toSkipToolkit = 1 }
|
|
||||||
#!HAVE_OPENGL: equals (aToolKit, "TKOpenGlTest") { toSkipToolkit = 1 }
|
|
||||||
!HAVE_GLES2: equals (aToolKit, "TKOpenGles") { toSkipToolkit = 1 }
|
|
||||||
!HAVE_GLES2: equals (aToolKit, "TKOpenGlesTest") { toSkipToolkit = 1 }
|
|
||||||
!win32: equals (aToolKit, "TKD3DHost") { toSkipToolkit = 1 }
|
!win32: equals (aToolKit, "TKD3DHost") { toSkipToolkit = 1 }
|
||||||
!win32: equals (aToolKit, "TKD3DHostTest") { toSkipToolkit = 1 }
|
|
||||||
equals (toSkipToolkit, 0) {
|
equals (toSkipToolkit, 0) {
|
||||||
|
|
||||||
#warning(aToolKit($$OCC_MODULE_NAME)=$$aToolKit)
|
#warning(aToolKit($$OCC_MODULE_NAME)=$$aToolKit)
|
||||||
eval(occtkgen_$${aToolKit}.input = $$_PRO_FILE_PWD_/../OccToolkit.pro.in)
|
eval(occtkgen_$${aToolKit}.input = $$_PRO_FILE_PWD_/../OccToolkit.pro.in)
|
||||||
eval(occtkgen_$${aToolKit}.output = $$_PRO_FILE_PWD_/$${aToolKit}/$${aToolKit}.pro)
|
eval(occtkgen_$${aToolKit}.output = $$_PRO_FILE_PWD_/$${aToolKit}/$${aToolKit}.pro)
|
||||||
|
@@ -18,7 +18,7 @@ aHxxRoot = $$OccGitRoot/inc
|
|||||||
INCLUDEPATH += $$aHxxRoot
|
INCLUDEPATH += $$aHxxRoot
|
||||||
|
|
||||||
# CSF variables
|
# CSF variables
|
||||||
HAVE_FREETYPE { CSF_FREETYPE = -lfreetype }
|
CSF_FREETYPE = -lfreetype
|
||||||
CSF_TclLibs = -ltcl8.6
|
CSF_TclLibs = -ltcl8.6
|
||||||
CSF_TclTkLibs = -ltk8.6
|
CSF_TclTkLibs = -ltk8.6
|
||||||
HAVE_FREEIMAGE { CSF_FreeImagePlus = -lfreeimage } else:win32 { CSF_FreeImagePlus = -lwindowscodecs -lole32 }
|
HAVE_FREEIMAGE { CSF_FreeImagePlus = -lfreeimage } else:win32 { CSF_FreeImagePlus = -lwindowscodecs -lole32 }
|
||||||
@@ -36,7 +36,7 @@ win32 {
|
|||||||
CSF_wsock32 = -lwsock32
|
CSF_wsock32 = -lwsock32
|
||||||
CSF_netapi32 = -lnetapi32
|
CSF_netapi32 = -lnetapi32
|
||||||
CSF_OpenGlLibs = -lopengl32
|
CSF_OpenGlLibs = -lopengl32
|
||||||
CSF_OpenGlesLibs = -llibEGL -llibGLESv2
|
HAVE_GLES2 { CSF_OpenGlLibs = -llibEGL -llibGLESv2 }
|
||||||
CSF_psapi = -lPsapi
|
CSF_psapi = -lPsapi
|
||||||
CSF_winmm = -lwinmm
|
CSF_winmm = -lwinmm
|
||||||
CSF_d3d9 = -ld3d9
|
CSF_d3d9 = -ld3d9
|
||||||
@@ -46,12 +46,12 @@ win32 {
|
|||||||
} else:mac {
|
} else:mac {
|
||||||
CSF_dl = -ldl
|
CSF_dl = -ldl
|
||||||
CSF_objc = -lobjc
|
CSF_objc = -lobjc
|
||||||
CSF_OpenGlLibs = -framework OpenGL
|
|
||||||
CSF_OpenGlesLibs = -framework OpenGLES
|
|
||||||
iphoneos {
|
iphoneos {
|
||||||
CSF_Appkit = -framework UIKit
|
CSF_Appkit = -framework UIKit
|
||||||
|
CSF_OpenGlLibs = -framework OpenGLES
|
||||||
} else {
|
} else {
|
||||||
CSF_Appkit = -framework AppKit
|
CSF_Appkit = -framework AppKit
|
||||||
|
CSF_OpenGlLibs = -framework OpenGL
|
||||||
}
|
}
|
||||||
CSF_IOKit = -framework IOKit
|
CSF_IOKit = -framework IOKit
|
||||||
CSF_TclLibs = -framework Tcl
|
CSF_TclLibs = -framework Tcl
|
||||||
@@ -59,31 +59,26 @@ win32 {
|
|||||||
} else {
|
} else {
|
||||||
CSF_dl = -ldl
|
CSF_dl = -ldl
|
||||||
CSF_ThreadLibs = -lpthread -lrt
|
CSF_ThreadLibs = -lpthread -lrt
|
||||||
CSF_OpenGlesLibs = -lEGL -lGLESv2
|
CSF_OpenGlLibs = -lGL
|
||||||
CSF_TclTkLibs = -ltk8.6
|
CSF_TclTkLibs = -lX11 -ltk8.6
|
||||||
HAVE_XLIB {
|
CSF_XwLibs = -lX11 -lXext -lXmu -lXi
|
||||||
CSF_OpenGlLibs = -lGL
|
CSF_MotifLibs = -lX11
|
||||||
CSF_XwLibs = -lX11
|
CSF_fontconfig = -lfontconfig
|
||||||
} else {
|
HAVE_GLES2 { CSF_OpenGlLibs = -lEGL -lGLESv2 }
|
||||||
CSF_OpenGlLibs = -lGL -lEGL
|
|
||||||
}
|
|
||||||
HAVE_FREETYPE { CSF_fontconfig = -lfontconfig }
|
|
||||||
}
|
}
|
||||||
|
|
||||||
for (aCfgIter, CONFIG) {
|
for (aCfgIter, CONFIG) {
|
||||||
aRes = $$find(aCfgIter, "^HAVE_")
|
aRes = $$find(aCfgIter, "^HAVE_")
|
||||||
!equals(aCfgIter, "HAVE_GLES2") {
|
count(aRes, 1) {
|
||||||
count(aRes, 1) {
|
DEFINES += $$aCfgIter
|
||||||
DEFINES += $$aCfgIter
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
# Define the list of standard OCCT file extensions
|
# Define the list of standard OCCT file extensions
|
||||||
aHxxRegex = ^.*\.(hxx|h|lxx|gxx)$
|
aHxxRegex = ^.*\.(hxx|h|lxx|gxx)$
|
||||||
aPxxRegex = ^.*\.(pxx)$
|
aPxxRegex = ^.*\.(pxx)$
|
||||||
aCxxRegex = ^.*\.(cxx|cpp|c)$
|
aCxxRegex = ^.*\.(cxx|c)$
|
||||||
mac { aCxxRegex = ^.*\.(cxx|cpp|c|m|mm)$ }
|
mac { aCxxRegex = ^.*\.(cxx|c|m|mm)$ }
|
||||||
|
|
||||||
# Auxiliary function for probing file extension
|
# Auxiliary function for probing file extension
|
||||||
defineTest (occCheckExtension) {
|
defineTest (occCheckExtension) {
|
||||||
@@ -108,12 +103,6 @@ for (anExternLib, anExternLibs) {
|
|||||||
count(hasCsf, 1) {
|
count(hasCsf, 1) {
|
||||||
aList = $$split($$anExternLib, "\n")
|
aList = $$split($$anExternLib, "\n")
|
||||||
LIBS += $$aList
|
LIBS += $$aList
|
||||||
equals(anExternLib, "CSF_OpenGlLibs") {
|
|
||||||
DEFINES += "HAVE_OPENGL"
|
|
||||||
}
|
|
||||||
equals(anExternLib, "CSF_OpenGlesLibs") {
|
|
||||||
DEFINES += "HAVE_GLES2"
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
LIBS += -l$$anExternLib
|
LIBS += -l$$anExternLib
|
||||||
}
|
}
|
||||||
|
@@ -9,10 +9,6 @@
|
|||||||
# - Open project in Qt Creator, and call "Run qmake".
|
# - Open project in Qt Creator, and call "Run qmake".
|
||||||
# - Close the project in Qt Creator, open it again so that you should see the sub-modules in Project tree; call "Run qmake" again.
|
# - Close the project in Qt Creator, open it again so that you should see the sub-modules in Project tree; call "Run qmake" again.
|
||||||
# - "Run qmake" and perform Build.
|
# - "Run qmake" and perform Build.
|
||||||
#
|
|
||||||
# Within Debian-based Linux repository Qt Creator can be installed like this:
|
|
||||||
# > sudo apt-get install qtcreator qtbase5-dev
|
|
||||||
|
|
||||||
TEMPLATE = subdirs
|
TEMPLATE = subdirs
|
||||||
exists(custom.auto.pri) { include(custom.auto.pri) }
|
exists(custom.auto.pri) { include(custom.auto.pri) }
|
||||||
exists(custom.pri) { include(custom.pri) }
|
exists(custom.pri) { include(custom.pri) }
|
||||||
|
@@ -1,39 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<!DOCTYPE QtCreatorCodeStyle>
|
|
||||||
<!-- Written by QtCreator 3.6.1, 2016-05-19T14:46:43. -->
|
|
||||||
<qtcreator>
|
|
||||||
<data>
|
|
||||||
<variable>CodeStyleData</variable>
|
|
||||||
<valuemap type="QVariantMap">
|
|
||||||
<value type="bool" key="AlignAssignments">true</value>
|
|
||||||
<value type="bool" key="AutoSpacesForTabs">false</value>
|
|
||||||
<value type="bool" key="BindStarToIdentifier">false</value>
|
|
||||||
<value type="bool" key="BindStarToLeftSpecifier">true</value>
|
|
||||||
<value type="bool" key="BindStarToRightSpecifier">false</value>
|
|
||||||
<value type="bool" key="BindStarToTypeName">true</value>
|
|
||||||
<value type="bool" key="ExtraPaddingForConditionsIfConfusingAlign">true</value>
|
|
||||||
<value type="bool" key="IndentAccessSpecifiers">false</value>
|
|
||||||
<value type="bool" key="IndentBlockBody">true</value>
|
|
||||||
<value type="bool" key="IndentBlockBraces">false</value>
|
|
||||||
<value type="bool" key="IndentBlocksRelativeToSwitchLabels">true</value>
|
|
||||||
<value type="bool" key="IndentClassBraces">false</value>
|
|
||||||
<value type="bool" key="IndentControlFlowRelativeToSwitchLabels">true</value>
|
|
||||||
<value type="bool" key="IndentDeclarationsRelativeToAccessSpecifiers">true</value>
|
|
||||||
<value type="bool" key="IndentEnumBraces">false</value>
|
|
||||||
<value type="bool" key="IndentFunctionBody">true</value>
|
|
||||||
<value type="bool" key="IndentFunctionBraces">false</value>
|
|
||||||
<value type="bool" key="IndentNamespaceBody">true</value>
|
|
||||||
<value type="bool" key="IndentNamespaceBraces">false</value>
|
|
||||||
<value type="int" key="IndentSize">2</value>
|
|
||||||
<value type="bool" key="IndentStatementsRelativeToSwitchLabels">true</value>
|
|
||||||
<value type="bool" key="IndentSwitchLabels">true</value>
|
|
||||||
<value type="int" key="PaddingMode">2</value>
|
|
||||||
<value type="bool" key="SpacesForTabs">true</value>
|
|
||||||
<value type="int" key="TabSize">2</value>
|
|
||||||
</valuemap>
|
|
||||||
</data>
|
|
||||||
<data>
|
|
||||||
<variable>DisplayName</variable>
|
|
||||||
<value type="QString">occt</value>
|
|
||||||
</data>
|
|
||||||
</qtcreator>
|
|
2
adm/scripts/.gitignore
vendored
@@ -1,2 +0,0 @@
|
|||||||
*custom.bat
|
|
||||||
*custom.sh
|
|
@@ -1,267 +0,0 @@
|
|||||||
@echo OFF
|
|
||||||
|
|
||||||
rem Auxiliary script for semi-automated building of OCCT for Android platform.
|
|
||||||
rem android_custom.bat should be configured with paths
|
|
||||||
rem to CMake, 3rd-parties, Android NDK and MinGW make tool.
|
|
||||||
|
|
||||||
set "aCasSrc=%~dp0..\.."
|
|
||||||
set "aBuildRoot=%aCasSrc%\work"
|
|
||||||
|
|
||||||
set aNbJobs=%NUMBER_OF_PROCESSORS%
|
|
||||||
|
|
||||||
rem Paths to 3rd-party tools and libraries
|
|
||||||
set "anNdkPath="
|
|
||||||
set "aFreeType="
|
|
||||||
set "aRapidJson="
|
|
||||||
set "aDraco="
|
|
||||||
|
|
||||||
rem Build stages to perform
|
|
||||||
set "toCMake=1"
|
|
||||||
set "toClean=0"
|
|
||||||
set "toMake=1"
|
|
||||||
set "toInstall=1"
|
|
||||||
set "toPack=1"
|
|
||||||
set "isStatic=0"
|
|
||||||
|
|
||||||
rem Minimal Android platform and CPU architectures
|
|
||||||
set "anNdkApiLevel=21"
|
|
||||||
set "anNdkAbiList=armeabi-v7a x86 arm64-v8a x86_64"
|
|
||||||
|
|
||||||
rem OCCT Modules to build
|
|
||||||
set "BUILD_ModelingData=ON"
|
|
||||||
set "BUILD_ModelingAlgorithms=ON"
|
|
||||||
set "BUILD_Visualization=ON"
|
|
||||||
set "BUILD_ApplicationFramework=ON"
|
|
||||||
set "BUILD_DataExchange=ON"
|
|
||||||
|
|
||||||
rem Optional 3rd-party libraries to enable
|
|
||||||
set "USE_FREETYPE=ON"
|
|
||||||
set "USE_RAPIDJSON=OFF"
|
|
||||||
set "USE_DRACO=OFF"
|
|
||||||
|
|
||||||
rem Archive tool
|
|
||||||
set "THE_7Z_PARAMS=-t7z -m0=lzma -mx=9 -mfb=64 -md=32m -ms=on"
|
|
||||||
set "THE_7Z_PATH=%ProgramW6432%\7-Zip\7z.exe"
|
|
||||||
|
|
||||||
rem Configuration file
|
|
||||||
if exist "%~dp0android_custom.bat" call "%~dp0android_custom.bat"
|
|
||||||
|
|
||||||
set "aCompiler=gcc"
|
|
||||||
set "aCppLib=gnustl_shared"
|
|
||||||
if not exist "%anNdkPath%/sources/cxx-stl/gnu-libstdc++" (
|
|
||||||
if exist "%anNdkPath%/sources/cxx-stl/llvm-libc++" (
|
|
||||||
set "aCompiler=clang"
|
|
||||||
set "aCppLib=c++_shared"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
set "aLibType=Shared"
|
|
||||||
if ["%isStatic%"] == ["1"] set "aLibType=Static"
|
|
||||||
set "aDestDir=%aBuildRoot%\android-%aCompiler%"
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
if ["%toClean%"] == ["1"] (
|
|
||||||
rmdir /S /Q %aDestDir%"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
set "anOcctVerSuffix="
|
|
||||||
set "anOcctVersion=0.0.0"
|
|
||||||
set "aGitBranch="
|
|
||||||
for /f tokens^=2^ delims^=^" %%i in ('findstr /b /c:"#define OCC_VERSION_DEVELOPMENT" "%aCasSrc%\src\Standard\Standard_Version.hxx"') do ( set "anOcctVerSuffix=%%i" )
|
|
||||||
for /f tokens^=2^ delims^=^" %%i in ('findstr /b /c:"#define OCC_VERSION_COMPLETE" "%aCasSrc%\src\Standard\Standard_Version.hxx"') do ( set "anOcctVersion=%%i" )
|
|
||||||
for /f %%i in ('git symbolic-ref --short HEAD') do ( set "aGitBranch=%%i" )
|
|
||||||
|
|
||||||
for %%s in (%anNdkAbiList%) do (
|
|
||||||
call :cmakeGenerate "%anNdkApiLevel%" "%%s"
|
|
||||||
if errorlevel 1 (
|
|
||||||
if not ["%1"] == ["-nopause"] (
|
|
||||||
pause
|
|
||||||
)
|
|
||||||
exit /B 1
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
for /F "skip=1 delims=" %%F in ('
|
|
||||||
wmic PATH Win32_LocalTime GET Day^,Month^,Year /FORMAT:TABLE
|
|
||||||
') do (
|
|
||||||
for /F "tokens=1-3" %%L in ("%%F") do (
|
|
||||||
set DAY00=0%%L
|
|
||||||
set MONTH00=0%%M
|
|
||||||
set YEAR=%%N
|
|
||||||
)
|
|
||||||
)
|
|
||||||
set DAY00=%DAY00:~-2%
|
|
||||||
set MONTH00=%MONTH00:~-2%
|
|
||||||
set "aRevision=-%YEAR%-%MONTH00%-%DAY00%"
|
|
||||||
rem set "aRevision=-%aGitBranch%"
|
|
||||||
set "anArchName=occt-%anOcctVersion%%anOcctVerSuffix%%aRevision%-android"
|
|
||||||
set "aTarget=%aBuildRoot%\%anArchName%"
|
|
||||||
if ["%toPack%"] == ["1"] (
|
|
||||||
echo Creating archive %anArchName%.7z
|
|
||||||
rmdir /S /Q "%aTarget%"
|
|
||||||
if not exist "%aTarget%" ( mkdir "%aTarget%" )
|
|
||||||
if exist "%aBuildRoot%/%anArchName%.7z" del "%aBuildRoot%/%anArchName%.7z"
|
|
||||||
xcopy /S /Y "%aDestDir%\*" "%aTarget%\"
|
|
||||||
|
|
||||||
"%THE_7Z_PATH%" a -r %THE_7Z_PARAMS% "%aBuildRoot%/%anArchName%.7z" "%aTarget%"
|
|
||||||
)
|
|
||||||
if not ["%1"] == ["-nopause"] (
|
|
||||||
pause
|
|
||||||
)
|
|
||||||
|
|
||||||
goto :eof
|
|
||||||
|
|
||||||
:cmakeGenerate
|
|
||||||
set "anApi=%~1"
|
|
||||||
set "anAbi=%~2"
|
|
||||||
if ["%anApi%"] == [""] (
|
|
||||||
set "anApi=21"
|
|
||||||
if ["%anAbi%"] == ["armeabi-v7a"] ( set "anApi=16" )
|
|
||||||
if ["%anAbi%"] == ["x86"] ( set "anApi=16" )
|
|
||||||
)
|
|
||||||
set "aPlatformAndCompiler=android-%anAbi%-%aCompiler%"
|
|
||||||
set "aWorkDir=%aBuildRoot%\%aPlatformAndCompiler%-make"
|
|
||||||
set "aLogFile=%aBuildRoot%\build-%aPlatformAndCompiler%.log"
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
if ["%toClean%"] == ["1"] (
|
|
||||||
rmdir /S /Q %aWorkDir%"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
if not exist "%aWorkDir%" ( mkdir "%aWorkDir%" )
|
|
||||||
if exist "%aLogFile%" ( del "%aLogFile%" )
|
|
||||||
|
|
||||||
rem include some information about OCCT into archive
|
|
||||||
echo ^<pre^>> "%aWorkDir%\VERSION.html"
|
|
||||||
git status >> "%aWorkDir%\VERSION.html"
|
|
||||||
git log -n 100 >> "%aWorkDir%\VERSION.html"
|
|
||||||
echo ^</pre^>>> "%aWorkDir%\VERSION.html"
|
|
||||||
|
|
||||||
echo Start building OCCT for %aPlatformAndCompiler%
|
|
||||||
echo Start building OCCT for %aPlatformAndCompiler%, API level %anApi%>> %aLogFile%
|
|
||||||
|
|
||||||
pushd "%aWorkDir%"
|
|
||||||
|
|
||||||
set "aFreeTypeLibName=libfreetype.so"
|
|
||||||
if exist "%aFreeType%/libs/%anAbi%/libfreetype.a" ( set "aFreeTypeLibName=libfreetype.a" )
|
|
||||||
|
|
||||||
set "aTimeZERO=%TIME%"
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
echo Configuring OCCT for Android %anAbi%, API level %anApi%...
|
|
||||||
cmake -G "MinGW Makefiles" ^
|
|
||||||
-D CMAKE_SYSTEM_NAME:STRING="Android" ^
|
|
||||||
-D CMAKE_ANDROID_NDK="%anNdkPath%" ^
|
|
||||||
-D CMAKE_BUILD_TYPE:STRING="Release" ^
|
|
||||||
-D CMAKE_ANDROID_ARCH_ABI:STRING="%anAbi%" ^
|
|
||||||
-D CMAKE_SYSTEM_VERSION:STRING="%anApi%" ^
|
|
||||||
-D CMAKE_ANDROID_STL_TYPE="%aCppLib%" ^
|
|
||||||
-D BUILD_LIBRARY_TYPE:STRING="%aLibType%" ^
|
|
||||||
-D INSTALL_DIR:PATH="%aDestDir%" ^
|
|
||||||
-D INSTALL_DIR_INCLUDE:STRING="inc" ^
|
|
||||||
-D INSTALL_DIR_LIB:STRING="libs/%anAbi%" ^
|
|
||||||
-D INSTALL_DIR_CMAKE:STRING="libs/%anAbi%/cmake/opencascade" ^
|
|
||||||
-D INSTALL_DIR_RESOURCE:STRING="src" ^
|
|
||||||
-D BUILD_MODULE_FoundationClasses:BOOL="ON" ^
|
|
||||||
-D BUILD_MODULE_ModelingData:BOOL="%BUILD_ModelingData%" ^
|
|
||||||
-D BUILD_MODULE_ModelingAlgorithms:BOOL="%BUILD_ModelingAlgorithms%" ^
|
|
||||||
-D BUILD_MODULE_Visualization:BOOL="%BUILD_Visualization%" ^
|
|
||||||
-D BUILD_MODULE_ApplicationFramework:BOOL="%BUILD_ApplicationFramework%" ^
|
|
||||||
-D BUILD_MODULE_DataExchange:BOOL="%BUILD_DataExchange%" ^
|
|
||||||
-D BUILD_MODULE_Draw:BOOL="OFF" ^
|
|
||||||
-D BUILD_DOC_Overview:BOOL="OFF" ^
|
|
||||||
-D USE_FREETYPE:BOOL="%USE_FREETYPE%" ^
|
|
||||||
-D 3RDPARTY_FREETYPE_DIR:PATH="%aFreeType%" ^
|
|
||||||
-D 3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2:FILEPATH="%aFreeType%/include" ^
|
|
||||||
-D 3RDPARTY_FREETYPE_INCLUDE_DIR_ft2build:FILEPATH="%aFreeType%/include" ^
|
|
||||||
-D 3RDPARTY_FREETYPE_LIBRARY_DIR:PATH="%aFreeType%/libs/%anAbi%" ^
|
|
||||||
-D 3RDPARTY_FREETYPE_LIBRARY:FILEPATH="%aFreeType%/libs/%anAbi%/%aFreeTypeLibName%" ^
|
|
||||||
-D USE_RAPIDJSON:BOOL="%USE_RAPIDJSON%" ^
|
|
||||||
-D 3RDPARTY_RAPIDJSON_DIR:PATH="%aRapidJson%" ^
|
|
||||||
-D 3RDPARTY_RAPIDJSON_INCLUDE_DIR:PATH="%aRapidJson%/include" ^
|
|
||||||
-D USE_DRACO:BOOL="%USE_DRACO%" ^
|
|
||||||
-D 3RDPARTY_DRACO_DIR:PATH="%aDraco%" ^
|
|
||||||
-D 3RDPARTY_DRACO_INCLUDE_DIR:FILEPATH="%aDraco%/include" ^
|
|
||||||
-D 3RDPARTY_DRACO_LIBRARY_DIR_draco:PATH="%aDraco%/libs/%anAbi%" ^
|
|
||||||
"%aCasSrc%"
|
|
||||||
|
|
||||||
if errorlevel 1 (
|
|
||||||
popd
|
|
||||||
exit /B 1
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
)
|
|
||||||
set "aTimeGEN=%TIME%"
|
|
||||||
call :computeDuration %aTimeZERO% %aTimeGEN%
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
echo Generation time: %DURATION%
|
|
||||||
echo Generation time: %DURATION%>> "%aLogFile%"
|
|
||||||
)
|
|
||||||
|
|
||||||
if ["%toClean%"] == ["1"] (
|
|
||||||
mingw32-make clean
|
|
||||||
)
|
|
||||||
|
|
||||||
if ["%toMake%"] == ["1"] (
|
|
||||||
echo Building...
|
|
||||||
mingw32-make -j %aNbJobs% 2>> "%aLogFile%"
|
|
||||||
if errorlevel 1 (
|
|
||||||
type "%aLogFile%"
|
|
||||||
popd
|
|
||||||
exit /B 1
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
type "%aLogFile%"
|
|
||||||
)
|
|
||||||
set "aTimeBUILD=%TIME%"
|
|
||||||
call :computeDuration %aTimeGEN% %aTimeBUILD%
|
|
||||||
if ["%toMake%"] == ["1"] (
|
|
||||||
echo Building time: %DURATION%
|
|
||||||
echo Building time: %DURATION%>> "%aLogFile%"
|
|
||||||
)
|
|
||||||
call :computeDuration %aTimeZERO% %aTimeBUILD%
|
|
||||||
if ["%toMake%"] == ["1"] (
|
|
||||||
echo Total building time: %DURATION%
|
|
||||||
echo Total building time: %DURATION%>> "%aLogFile%"
|
|
||||||
)
|
|
||||||
|
|
||||||
if ["%toInstall%"] == ["1"] (
|
|
||||||
echo Installing into %aDestDir%...
|
|
||||||
mingw32-make install 2>> "%aLogFile%"
|
|
||||||
copy /Y "%aWorkDir%\VERSION.html" "%aDestDir%\VERSION.html"
|
|
||||||
)
|
|
||||||
set "aTimeINSTALL=%TIME%"
|
|
||||||
call :computeDuration "%aTimeBUILD%" "%aTimeINSTALL%"
|
|
||||||
if ["%toInstall%"] == ["1"] (
|
|
||||||
echo Install time: %DURATION%
|
|
||||||
echo Install time: %DURATION%>> "%aLogFile%"
|
|
||||||
)
|
|
||||||
|
|
||||||
call :computeDuration "%aTimeZERO%" "%aTimeINSTALL%"
|
|
||||||
echo Total time: %DURATION%
|
|
||||||
echo Total time: %DURATION%>> "%aLogFile%"
|
|
||||||
|
|
||||||
popd
|
|
||||||
goto :eof
|
|
||||||
|
|
||||||
:computeDuration
|
|
||||||
set "aTimeFrom=%~1"
|
|
||||||
set "aTimeEnd=%~2"
|
|
||||||
rem handle time before 10AM (win10 - remove empty space at the beginning)
|
|
||||||
if "%aTimeFrom:~0,1%"==" " set "aTimeFrom=%aTimeFrom:~1%"
|
|
||||||
if "%aTimeEnd:~0,1%"==" " set "aTimeEnd=%aTimeEnd:~1%"
|
|
||||||
rem handle time before 10AM (win7 - add 0 at the beginning)
|
|
||||||
if "%aTimeFrom:~1,1%"==":" set "aTimeFrom=0%aTimeFrom%"
|
|
||||||
if "%aTimeEnd:~1,1%"==":" set "aTimeEnd=0%aTimeEnd%"
|
|
||||||
rem convert hours:minutes:seconds:ms into duration
|
|
||||||
set /A aTimeFrom=(1%aTimeFrom:~0,2%-100)*360000 + (1%aTimeFrom:~3,2%-100)*6000 + (1%aTimeFrom:~6,2%-100)*100 + (1%aTimeFrom:~9,2%-100)
|
|
||||||
set /A aTimeEnd= (1%aTimeEnd:~0,2%-100)*360000 + (1%aTimeEnd:~3,2%-100)*6000 + (1%aTimeEnd:~6,2%-100)*100 + (1%aTimeEnd:~9,2%-100)
|
|
||||||
set /A aDurTotalSec=%aTimeEnd%-%aTimeFrom%
|
|
||||||
if %aTimeEnd% LSS %aTimeFrom% set set /A aDurTotalSec=%aTimeFrom%-%aTimeEnd%
|
|
||||||
set /A aDurHH=%aDurTotalSec% / 360000
|
|
||||||
set /A aDurMM=(%aDurTotalSec% - %aDurHH%*360000) / 6000
|
|
||||||
set /A aDurSS=(%aDurTotalSec% - %aDurHH%*360000 - %aDurMM%*6000) / 100
|
|
||||||
if %aDurHH% LSS 10 set aDurHH=0%aDurHH%
|
|
||||||
if %aDurMM% LSS 10 set aDurMM=0%aDurMM%
|
|
||||||
if %aDurSS% LSS 10 set aDurSS=0%aDurSS%
|
|
||||||
|
|
||||||
set "DURATION=%aDurHH%:%aDurMM%:%aDurSS%"
|
|
||||||
goto :eof
|
|
@@ -1,33 +0,0 @@
|
|||||||
rem Environment configuration template for android_build.bat (to be renamed as android_custom.bat)
|
|
||||||
|
|
||||||
rem Paths to 3rd-party tools and libraries
|
|
||||||
rem call c:\TDM-GCC-64\mingwvars.bat
|
|
||||||
rem set "PATH=c:\CMake\bin;%PATH%"
|
|
||||||
rem set "anNdkPath=c:/android-ndk-r12"
|
|
||||||
rem set "aFreeType=c:/freetype-2.7.1-android"
|
|
||||||
rem set "aRapidJson=c:/rapidjson-1.1.0"
|
|
||||||
rem set "aDraco=c:/draco-1.4.1-android"
|
|
||||||
|
|
||||||
rem Uncomment to customize building steps
|
|
||||||
rem set "aBuildRoot=%~dp0..\..\work"
|
|
||||||
rem set "toCMake=1"
|
|
||||||
rem set "toClean=0"
|
|
||||||
rem set "toMake=1"
|
|
||||||
rem set "toInstall=1"
|
|
||||||
rem set "toPack=1"
|
|
||||||
rem set "isStatic=0"
|
|
||||||
|
|
||||||
rem Minimal Android platform and CPU architectures
|
|
||||||
rem set "anNdkApiLevel=21"
|
|
||||||
rem set "anNdkAbiList=arm64-v8a x86_64"
|
|
||||||
|
|
||||||
rem OCCT Modules to build
|
|
||||||
rem set "BUILD_ModelingData=ON"
|
|
||||||
rem set "BUILD_ModelingAlgorithms=ON"
|
|
||||||
rem set "BUILD_Visualization=ON"
|
|
||||||
rem set "BUILD_ApplicationFramework=ON"
|
|
||||||
rem set "BUILD_DataExchange=ON"
|
|
||||||
|
|
||||||
rem Optional 3rd-party libraries to enable
|
|
||||||
rem set "USE_RAPIDJSON=ON"
|
|
||||||
rem set "USE_DRACO=ON"
|
|
@@ -1,48 +0,0 @@
|
|||||||
rem Environment configuration template for cmake_gen.bat (to be renamed as cmake_gen_custom.bat)
|
|
||||||
|
|
||||||
set "OCCT3RDPARTY=%SrcRoot%\..\3rdparty"
|
|
||||||
|
|
||||||
set VS=14
|
|
||||||
set VSDATA=2015
|
|
||||||
|
|
||||||
rem Leave VSPLATFORM empty to build for x86 platform
|
|
||||||
set VSPLATFORM=Win64
|
|
||||||
|
|
||||||
rem ------------------------------------
|
|
||||||
rem Uncomment to customize building steps
|
|
||||||
rem ------------------------------------
|
|
||||||
|
|
||||||
rem set "BUILD_DIR=build-vs%VS%-%VSPLATFORM%"
|
|
||||||
rem set "INSTALL_DIR=%SrcRoot%\install"
|
|
||||||
|
|
||||||
rem set BUILD_DOC_Overview=OFF
|
|
||||||
rem set BUILD_Inspector=OFF
|
|
||||||
rem set BUILD_LIBRARY_TYPE=Shared
|
|
||||||
rem set BUILD_RELEASE_DISABLE_EXCEPTIONS=ON
|
|
||||||
rem set BUILD_WITH_DEBUG=OFF
|
|
||||||
rem set BUILD_ENABLE_FPE_SIGNAL_HANDLER=ON
|
|
||||||
rem set BUILD_USE_PCH=OFF
|
|
||||||
rem set BUILD_FORCE_RelWithDebInfo=OFF
|
|
||||||
|
|
||||||
rem Use semicolon-separated list of toolkits if you want to disable all modules
|
|
||||||
rem and build only some toolkits.
|
|
||||||
rem set BUILD_ADDITIONAL_TOOLKITS=
|
|
||||||
|
|
||||||
rem Set a directory recognized as a patch for OCCT.
|
|
||||||
rem set BUILD_PATCH=
|
|
||||||
|
|
||||||
rem set BUILD_MODULE_ApplicationFramework=ON
|
|
||||||
rem set BUILD_MODULE_DataExchange=ON
|
|
||||||
rem set BUILD_MODULE_Draw=ON
|
|
||||||
rem set BUILD_MODULE_ModelingAlgorithms=ON
|
|
||||||
rem set BUILD_MODULE_ModelingData=ON
|
|
||||||
rem set BUILD_MODULE_Visualization=ON
|
|
||||||
|
|
||||||
rem set USE_D3D=OFF
|
|
||||||
rem set USE_FFMPEG=OFF
|
|
||||||
rem set USE_FREEIMAGE=OFF
|
|
||||||
rem set USE_GLES2=OFF
|
|
||||||
rem set USE_RAPIDJSON=OFF
|
|
||||||
rem set USE_DRACO=OFF
|
|
||||||
rem set USE_TBB=OFF
|
|
||||||
rem set USE_VTK=OFF
|
|
@@ -1,43 +0,0 @@
|
|||||||
# Environment configuration template for cmake_gen.sh (to be renamed as cmake_gen_custom.sh)
|
|
||||||
|
|
||||||
OCCT3RDPARTY="$SrcRoot/../3rdparty"
|
|
||||||
FREETYPE_DIR="$OCCT3RDPARTY/freetype-2.7.1"
|
|
||||||
|
|
||||||
# ------------------------------------
|
|
||||||
# Uncomment to customize building steps
|
|
||||||
# ------------------------------------
|
|
||||||
|
|
||||||
#BUILD_DIR=build
|
|
||||||
#INSTALL_DIR="$SrcRoot/install"
|
|
||||||
|
|
||||||
#BUILD_DOC_Overview=OFF
|
|
||||||
#BUILD_Inspector=OFF
|
|
||||||
#BUILD_LIBRARY_TYPE=Shared
|
|
||||||
#BUILD_RELEASE_DISABLE_EXCEPTIONS=ON
|
|
||||||
#BUILD_WITH_DEBUG=OFF
|
|
||||||
#BUILD_ENABLE_FPE_SIGNAL_HANDLER=ON
|
|
||||||
|
|
||||||
# Use semicolon-separated list of toolkits if you want to disable all modules
|
|
||||||
# and build only some toolkits.
|
|
||||||
#BUILD_ADDITIONAL_TOOLKITS=
|
|
||||||
|
|
||||||
# Set a directory recognized as a patch for OCCT.
|
|
||||||
#BUILD_PATCH=
|
|
||||||
|
|
||||||
#BUILD_MODULE_ApplicationFramework=ON
|
|
||||||
#BUILD_MODULE_DataExchange=ON
|
|
||||||
#BUILD_MODULE_Draw=ON
|
|
||||||
#BUILD_MODULE_ModelingAlgorithms=ON
|
|
||||||
#BUILD_MODULE_ModelingData=ON
|
|
||||||
#BUILD_MODULE_Visualization=ON
|
|
||||||
|
|
||||||
#USE_FFMPEG=OFF
|
|
||||||
#USE_FREEIMAGE=OFF
|
|
||||||
#USE_GLES2=OFF
|
|
||||||
#USE_RAPIDJSON=OFF
|
|
||||||
#USE_DRACO=OFF
|
|
||||||
#USE_TBB=OFF
|
|
||||||
#USE_VTK=OFF
|
|
||||||
|
|
||||||
# This is to add any additional arguments to cmake
|
|
||||||
#AUX_ARGS=
|
|
@@ -1,88 +0,0 @@
|
|||||||
@echo off
|
|
||||||
|
|
||||||
rem Auxiliary script for semi-automated building of OCCT using cmake.
|
|
||||||
rem cmake_custom.bat should be configured with VS version and path to 3rd-parties.
|
|
||||||
rem OCCT3RDPARTY must be specified as mandatory dependency.
|
|
||||||
|
|
||||||
setlocal
|
|
||||||
|
|
||||||
set "SrcRoot=%~dp0..\.."
|
|
||||||
|
|
||||||
set VS=14
|
|
||||||
set VSDATA=2015
|
|
||||||
set VSPLATFORM=Win64
|
|
||||||
set "BUILD_DIR=build-vs%VS%-%VSPLATFORM%"
|
|
||||||
set "OCCT3RDPARTY="
|
|
||||||
set "INSTALL_DIR=%SrcRoot%\install"
|
|
||||||
|
|
||||||
set BUILD_ADDITIONAL_TOOLKITS=
|
|
||||||
set BUILD_DOC_Overview=OFF
|
|
||||||
set BUILD_Inspector=OFF
|
|
||||||
set BUILD_LIBRARY_TYPE=Shared
|
|
||||||
set BUILD_PATCH=
|
|
||||||
set BUILD_RELEASE_DISABLE_EXCEPTIONS=ON
|
|
||||||
set BUILD_WITH_DEBUG=OFF
|
|
||||||
set BUILD_ENABLE_FPE_SIGNAL_HANDLER=ON
|
|
||||||
set BUILD_USE_PCH=OFF
|
|
||||||
set BUILD_FORCE_RelWithDebInfo=OFF
|
|
||||||
|
|
||||||
set BUILD_MODULE_ApplicationFramework=ON
|
|
||||||
set BUILD_MODULE_DataExchange=ON
|
|
||||||
set BUILD_MODULE_Draw=ON
|
|
||||||
set BUILD_MODULE_ModelingAlgorithms=ON
|
|
||||||
set BUILD_MODULE_ModelingData=ON
|
|
||||||
set BUILD_MODULE_Visualization=ON
|
|
||||||
|
|
||||||
set USE_D3D=OFF
|
|
||||||
set USE_FFMPEG=OFF
|
|
||||||
set USE_FREEIMAGE=OFF
|
|
||||||
set USE_GLES2=OFF
|
|
||||||
set USE_RAPIDJSON=OFF
|
|
||||||
set USE_DRACO=OFF
|
|
||||||
set USE_TBB=OFF
|
|
||||||
set USE_VTK=OFF
|
|
||||||
|
|
||||||
if exist "%~dp0cmake_custom.bat" call "%~dp0cmake_custom.bat"
|
|
||||||
|
|
||||||
if not "%VSPLATFORM%"=="" set "arch_compile=Visual Studio %VS% %VSDATA% %VSPLATFORM%"
|
|
||||||
if "%VSPLATFORM%"=="" set "arch_compile=Visual Studio %VS% %VSDATA%"
|
|
||||||
|
|
||||||
set "INSTALL_DIR=%INSTALL_DIR:\=/%"
|
|
||||||
set "OCCT3RDPARTY=%OCCT3RDPARTY:\=/%"
|
|
||||||
|
|
||||||
set "BUILD_DIR=%SrcRoot%\%BUILD_DIR%"
|
|
||||||
if not exist "%BUILD_DIR%" mkdir "%BUILD_DIR%"
|
|
||||||
pushd "%BUILD_DIR%"
|
|
||||||
|
|
||||||
cmake -G "%arch_compile%" ^
|
|
||||||
-D 3RDPARTY_DIR:STRING="%OCCT3RDPARTY%" ^
|
|
||||||
-D BUILD_ADDITIONAL_TOOLKITS:STRING="%BUILD_ADDITIONAL_TOOLKITS%" ^
|
|
||||||
-D BUILD_DOC_Overview:BOOL=%BUILD_DOC_Overview% ^
|
|
||||||
-D BUILD_Inspector:BOOL=%BUILD_Inspector% ^
|
|
||||||
-D BUILD_LIBRARY_TYPE:STRING=%BUILD_LIBRARY_TYPE% ^
|
|
||||||
-D BUILD_MODULE_ApplicationFramework:BOOL=%BUILD_MODULE_ApplicationFramework% ^
|
|
||||||
-D BUILD_MODULE_DataExchange:BOOL=%BUILD_MODULE_DataExchange% ^
|
|
||||||
-D BUILD_MODULE_Draw:BOOL=%BUILD_MODULE_Draw% ^
|
|
||||||
-D BUILD_MODULE_FoundationClasses:BOOL=ON ^
|
|
||||||
-D BUILD_MODULE_ModelingAlgorithms:BOOL=%BUILD_MODULE_ModelingAlgorithms% ^
|
|
||||||
-D BUILD_MODULE_ModelingData:BOOL=%BUILD_MODULE_ModelingData% ^
|
|
||||||
-D BUILD_MODULE_Visualization:BOOL=%BUILD_MODULE_Visualization% ^
|
|
||||||
-D BUILD_PATCH:PATH="%BUILD_PATCH%" ^
|
|
||||||
-D BUILD_RELEASE_DISABLE_EXCEPTIONS:BOOL=%BUILD_RELEASE_DISABLE_EXCEPTIONS% ^
|
|
||||||
-D BUILD_WITH_DEBUG:BOOL=%BUILD_WITH_DEBUG% ^
|
|
||||||
-D BUILD_ENABLE_FPE_SIGNAL_HANDLER:BOOL=%BUILD_ENABLE_FPE_SIGNAL_HANDLER% ^
|
|
||||||
-D BUILD_USE_PCH:BOOL=%BUILD_USE_PCH% ^
|
|
||||||
-D BUILD_FORCE_RelWithDebInfo:BOOL=%BUILD_FORCE_RelWithDebInfo% ^
|
|
||||||
-D INSTALL_DIR:PATH="%INSTALL_DIR%" ^
|
|
||||||
-D USE_D3D:BOOL=%USE_D3D% ^
|
|
||||||
-D USE_FFMPEG:BOOL=%USE_FFMPEG% ^
|
|
||||||
-D USE_FREEIMAGE:BOOL=%USE_FREEIMAGE% ^
|
|
||||||
-D USE_GLES2:BOOL=%USE_GLES2% ^
|
|
||||||
-D USE_RAPIDJSON:BOOL=%USE_RAPIDJSON% ^
|
|
||||||
-D USE_DRACO:BOOL=%USE_DRACO% ^
|
|
||||||
-D USE_TBB:BOOL=%USE_TBB% ^
|
|
||||||
-D USE_VTK:BOOL=%USE_VTK% ^
|
|
||||||
"%SrcRoot%"
|
|
||||||
|
|
||||||
popd
|
|
||||||
endlocal
|
|
@@ -1,88 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# Auxiliary script for semi-automated building of OCCT using cmake.
|
|
||||||
# cmake_custom.sh should be configured with path to 3rd-parties.
|
|
||||||
# OCCT3RDPARTY and FREETYPE_DIR must be specified as mandatory dependencies.
|
|
||||||
|
|
||||||
ScriptDir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
|
|
||||||
SrcRoot="${ScriptDir}/../.."
|
|
||||||
|
|
||||||
INSTALL_DIR="$SrcRoot/install"
|
|
||||||
|
|
||||||
BUILD_DIR=build
|
|
||||||
DEB=
|
|
||||||
CMAKE_BUILD_TYPE=Release
|
|
||||||
if [ "$1" = "-d" ]; then
|
|
||||||
DEB=d
|
|
||||||
BUILD_DIR=${BUILD_DIR}-deb
|
|
||||||
CMAKE_BUILD_TYPE=Debug
|
|
||||||
fi
|
|
||||||
INSTALL_DIR_BIN=lin64/gcc/bin$DEB
|
|
||||||
INSTALL_DIR_LIB=lin64/gcc/lib$DEB
|
|
||||||
|
|
||||||
BUILD_ADDITIONAL_TOOLKITS=
|
|
||||||
BUILD_DOC_Overview=OFF
|
|
||||||
BUILD_Inspector=OFF
|
|
||||||
BUILD_LIBRARY_TYPE=Shared
|
|
||||||
BUILD_PATCH=
|
|
||||||
BUILD_RELEASE_DISABLE_EXCEPTIONS=ON
|
|
||||||
BUILD_WITH_DEBUG=OFF
|
|
||||||
BUILD_ENABLE_FPE_SIGNAL_HANDLER=ON
|
|
||||||
|
|
||||||
BUILD_MODULE_ApplicationFramework=ON
|
|
||||||
BUILD_MODULE_DataExchange=ON
|
|
||||||
BUILD_MODULE_Draw=ON
|
|
||||||
BUILD_MODULE_ModelingAlgorithms=ON
|
|
||||||
BUILD_MODULE_ModelingData=ON
|
|
||||||
BUILD_MODULE_Visualization=ON
|
|
||||||
|
|
||||||
USE_FFMPEG=OFF
|
|
||||||
USE_FREEIMAGE=OFF
|
|
||||||
USE_GLES2=OFF
|
|
||||||
USE_RAPIDJSON=OFF
|
|
||||||
USE_DRACO=OFF
|
|
||||||
USE_TBB=OFF
|
|
||||||
USE_VTK=OFF
|
|
||||||
AUX_ARGS=
|
|
||||||
|
|
||||||
if [ -f "${ScriptDir}/cmake_custom.sh" ]; then
|
|
||||||
. "${ScriptDir}/cmake_custom.sh"
|
|
||||||
fi
|
|
||||||
|
|
||||||
BUILD_DIR="$SrcRoot/$BUILD_DIR"
|
|
||||||
if [ ! -d "$BUILD_DIR" ]; then mkdir -p "$BUILD_DIR"; fi
|
|
||||||
pushd "$BUILD_DIR"
|
|
||||||
|
|
||||||
cmake -G "Unix Makefiles" \
|
|
||||||
-D CMAKE_BUILD_TYPE=$CMAKE_BUILD_TYPE \
|
|
||||||
-D 3RDPARTY_DIR:PATH="$OCCT3RDPARTY" \
|
|
||||||
-D 3RDPARTY_FREETYPE_DIR:PATH="$FREETYPE_DIR" \
|
|
||||||
-D BUILD_ADDITIONAL_TOOLKITS:STRING="$BUILD_ADDITIONAL_TOOLKITS" \
|
|
||||||
-D BUILD_DOC_Overview:BOOL=$BUILD_DOC_Overview \
|
|
||||||
-D BUILD_Inspector:BOOL=$BUILD_Inspector \
|
|
||||||
-D BUILD_LIBRARY_TYPE:STRING=$BUILD_LIBRARY_TYPE \
|
|
||||||
-D BUILD_MODULE_ApplicationFramework:BOOL=$BUILD_MODULE_ApplicationFramework \
|
|
||||||
-D BUILD_MODULE_DataExchange:BOOL=$BUILD_MODULE_DataExchange \
|
|
||||||
-D BUILD_MODULE_Draw:BOOL=$BUILD_MODULE_Draw \
|
|
||||||
-D BUILD_MODULE_FoundationClasses:BOOL=ON \
|
|
||||||
-D BUILD_MODULE_ModelingAlgorithms:BOOL=$BUILD_MODULE_ModelingAlgorithms \
|
|
||||||
-D BUILD_MODULE_ModelingData:BOOL=$BUILD_MODULE_ModelingData \
|
|
||||||
-D BUILD_MODULE_Visualization:BOOL=$BUILD_MODULE_Visualization \
|
|
||||||
-D BUILD_PATCH:PATH="$BUILD_PATCH" \
|
|
||||||
-D BUILD_RELEASE_DISABLE_EXCEPTIONS:BOOL=$BUILD_RELEASE_DISABLE_EXCEPTIONS \
|
|
||||||
-D BUILD_WITH_DEBUG:BOOL=$BUILD_WITH_DEBUG \
|
|
||||||
-D BUILD_ENABLE_FPE_SIGNAL_HANDLER:BOOL=$BUILD_ENABLE_FPE_SIGNAL_HANDLER \
|
|
||||||
-D INSTALL_DIR:PATH="$INSTALL_DIR" \
|
|
||||||
-D INSTALL_DIR_LAYOUT:STRING=Windows \
|
|
||||||
-D INSTALL_DIR_BIN:STRING=$INSTALL_DIR_BIN \
|
|
||||||
-D INSTALL_DIR_LIB:STRING=$INSTALL_DIR_LIB \
|
|
||||||
-D USE_FFMPEG:BOOL=$USE_FFMPEG \
|
|
||||||
-D USE_FREEIMAGE:BOOL=$USE_FREEIMAGE \
|
|
||||||
-D USE_GLES2:BOOL=$USE_GLES2 \
|
|
||||||
-D USE_RAPIDJSON:BOOL=$USE_RAPIDJSON \
|
|
||||||
-D USE_DRACO:BOOL=$USE_DRACO \
|
|
||||||
-D USE_TBB:BOOL=$USE_TBB \
|
|
||||||
-D USE_VTK:BOOL=$USE_VTK \
|
|
||||||
$AUX_ARGS "$SrcRoot"
|
|
||||||
|
|
||||||
popd
|
|
@@ -1,201 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# Auxiliary script for semi-automated building of OCCT for iOS platform.
|
|
||||||
# macos_custom.sh should be configured with paths to CMake and other 3rd-parties.
|
|
||||||
# FreeType should be specified as mandatory dependency.
|
|
||||||
|
|
||||||
aScriptDir=${BASH_SOURCE%/*}
|
|
||||||
if [ -d "$aScriptDir" ]; then cd "$aScriptDir"; fi
|
|
||||||
aScriptDir="$PWD"
|
|
||||||
|
|
||||||
aCasSrc=${aScriptDir}/../..
|
|
||||||
aNbJobs="$(getconf _NPROCESSORS_ONLN)"
|
|
||||||
|
|
||||||
export aBuildRoot=work
|
|
||||||
|
|
||||||
# paths to pre-built 3rd-parties
|
|
||||||
export aFreeType=
|
|
||||||
export aFreeImage=
|
|
||||||
export aRapidJson=
|
|
||||||
export aDraco=
|
|
||||||
|
|
||||||
# build stages to perform
|
|
||||||
export toSimulator=0
|
|
||||||
export isStatic=1
|
|
||||||
export toCMake=1
|
|
||||||
export toClean=1
|
|
||||||
export toMake=1
|
|
||||||
export toInstall=1
|
|
||||||
export toPack=0
|
|
||||||
export toDebug=0
|
|
||||||
|
|
||||||
export BUILD_ModelingData=ON
|
|
||||||
export BUILD_ModelingAlgorithms=ON
|
|
||||||
export BUILD_Visualization=ON
|
|
||||||
export BUILD_ApplicationFramework=ON
|
|
||||||
export BUILD_DataExchange=ON
|
|
||||||
|
|
||||||
export USE_FREETYPE=ON
|
|
||||||
export USE_FREEIMAGE=OFF
|
|
||||||
export USE_RAPIDJSON=OFF
|
|
||||||
export USE_DRACO=OFF
|
|
||||||
|
|
||||||
export IPHONEOS_DEPLOYMENT_TARGET=8.0
|
|
||||||
export anAbi=arm64
|
|
||||||
#export anAbi=x86_64
|
|
||||||
|
|
||||||
if [[ -f "${aScriptDir}/ios_custom.sh" ]]; then
|
|
||||||
source "${aScriptDir}/ios_custom.sh"
|
|
||||||
fi
|
|
||||||
|
|
||||||
aBuildType="Release"
|
|
||||||
aBuildTypePrefix=
|
|
||||||
if [[ $toDebug == 1 ]]; then
|
|
||||||
aBuildType="Debug"
|
|
||||||
aBuildTypePrefix="-debug"
|
|
||||||
fi
|
|
||||||
aLibType="Shared"
|
|
||||||
if [[ $isStatic == 1 ]]; then
|
|
||||||
aLibType="Static"
|
|
||||||
fi
|
|
||||||
aPlatformAndCompiler=ios-${anAbi}${aBuildTypePrefix}-clang
|
|
||||||
aPlatformSdk="iphoneos"
|
|
||||||
aSysRoot="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk"
|
|
||||||
if [[ $toSimulator == 1 ]]; then
|
|
||||||
#anAbi=x86_64
|
|
||||||
aPlatformAndCompiler=ios-simulator64-${anAbi}${aBuildTypePrefix}-clang
|
|
||||||
aPlatformSdk="iphonesimulator"
|
|
||||||
aSysRoot="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk"
|
|
||||||
fi
|
|
||||||
|
|
||||||
aWorkDir="${aCasSrc}/${aBuildRoot}/${aPlatformAndCompiler}-make"
|
|
||||||
aDestDir="${aCasSrc}/${aBuildRoot}/${aPlatformAndCompiler}"
|
|
||||||
aLogFile="${aCasSrc}/${aBuildRoot}/build-${aPlatformAndCompiler}.log"
|
|
||||||
|
|
||||||
if [[ $toCMake == 1 ]] && [[ $toClean == 1 ]]; then
|
|
||||||
rm -r -f "$aWorkDir"
|
|
||||||
rm -r -f "$aDestDir"
|
|
||||||
fi
|
|
||||||
mkdir -p "$aWorkDir"
|
|
||||||
mkdir -p "$aDestDir"
|
|
||||||
rm -f "$aLogFile"
|
|
||||||
|
|
||||||
anOcctVerSuffix=`grep -e "#define OCC_VERSION_DEVELOPMENT" "$aCasSrc/src/Standard/Standard_Version.hxx" | awk '{print $3}' | xargs`
|
|
||||||
anOcctVersion=`grep -e "#define OCC_VERSION_COMPLETE" "$aCasSrc/src/Standard/Standard_Version.hxx" | awk '{print $3}' | xargs`
|
|
||||||
aGitBranch=`git symbolic-ref --short HEAD`
|
|
||||||
|
|
||||||
# include some information about OCCT into archive
|
|
||||||
echo \<pre\>> "${aWorkDir}/VERSION.html"
|
|
||||||
git status >> "${aWorkDir}/VERSION.html"
|
|
||||||
git log -n 100 >> "${aWorkDir}/VERSION.html"
|
|
||||||
echo \</pre\>>> "${aWorkDir}/VERSION.html"
|
|
||||||
|
|
||||||
pushd "$aWorkDir"
|
|
||||||
|
|
||||||
aTimeZERO=$SECONDS
|
|
||||||
set -o pipefail
|
|
||||||
|
|
||||||
function logDuration {
|
|
||||||
if [[ $1 == 1 ]]; then
|
|
||||||
aDur=$(($4 - $3))
|
|
||||||
echo $2 time: $aDur sec>> "$aLogFile"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
# (re)generate Make files
|
|
||||||
if [[ $toCMake == 1 ]]; then
|
|
||||||
echo Configuring OCCT for iOS...
|
|
||||||
cmake -G "Unix Makefiles" \
|
|
||||||
-D CMAKE_SYSTEM_NAME="iOS" \
|
|
||||||
-D CMAKE_OSX_ARCHITECTURES:STRING="$anAbi" \
|
|
||||||
-D CMAKE_OSX_DEPLOYMENT_TARGET:STRING="$IPHONEOS_DEPLOYMENT_TARGET" \
|
|
||||||
-D CMAKE_OSX_SYSROOT:PATH="$aSysRoot" \
|
|
||||||
-D ENABLE_VISIBILITY:BOOL="TRUE" \
|
|
||||||
-D CMAKE_C_USE_RESPONSE_FILE_FOR_OBJECTS:BOOL="OFF" \
|
|
||||||
-D CMAKE_CXX_USE_RESPONSE_FILE_FOR_OBJECTS:BOOL="OFF" \
|
|
||||||
-D CMAKE_BUILD_TYPE:STRING="$aBuildType" \
|
|
||||||
-D BUILD_LIBRARY_TYPE:STRING="$aLibType" \
|
|
||||||
-D INSTALL_DIR:PATH="$aDestDir" \
|
|
||||||
-D INSTALL_DIR_INCLUDE:STRING="inc" \
|
|
||||||
-D INSTALL_DIR_LIB:STRING="lib" \
|
|
||||||
-D INSTALL_DIR_RESOURCE:STRING="src" \
|
|
||||||
-D INSTALL_NAME_DIR:STRING="@executable_path/../Frameworks" \
|
|
||||||
-D USE_FREETYPE:BOOL="$USE_FREETYPE" \
|
|
||||||
-D 3RDPARTY_FREETYPE_DIR:PATH="$aFreeType" \
|
|
||||||
-D 3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2:FILEPATH="$aFreeType/include" \
|
|
||||||
-D 3RDPARTY_FREETYPE_INCLUDE_DIR_ft2build:FILEPATH="$aFreeType/include" \
|
|
||||||
-D 3RDPARTY_FREETYPE_LIBRARY_DIR:PATH="$aFreeType/lib" \
|
|
||||||
-D USE_RAPIDJSON:BOOL="$USE_RAPIDJSON" \
|
|
||||||
-D 3RDPARTY_RAPIDJSON_DIR:PATH="$aRapidJson" \
|
|
||||||
-D 3RDPARTY_RAPIDJSON_INCLUDE_DIR:PATH="$aRapidJson/include" \
|
|
||||||
-D USE_DRACO:BOOL="$USE_DRACO" \
|
|
||||||
-D 3RDPARTY_DRACO_DIR:PATH="$aDraco" \
|
|
||||||
-D 3RDPARTY_DRACO_INCLUDE_DIR:FILEPATH="$aDraco/include" \
|
|
||||||
-D 3RDPARTY_DRACO_LIBRARY_DIR:PATH="$aDraco/lib" \
|
|
||||||
-D USE_FREEIMAGE:BOOL="$USE_FREEIMAGE" \
|
|
||||||
-D 3RDPARTY_FREEIMAGE_DIR:PATH="$aFreeImage" \
|
|
||||||
-D 3RDPARTY_FREEIMAGE_INCLUDE_DIR:FILEPATH="$aFreeImage/include" \
|
|
||||||
-D 3RDPARTY_FREEIMAGE_LIBRARY_DIR:PATH="$aFreeImage/lib" \
|
|
||||||
-D 3RDPARTY_FREEIMAGE_LIBRARY:FILEPATH="$aFreeImage/lib/libfreeimage.a" \
|
|
||||||
-D BUILD_MODULE_FoundationClasses:BOOL="ON" \
|
|
||||||
-D BUILD_MODULE_ModelingData:BOOL="${BUILD_ModelingData}" \
|
|
||||||
-D BUILD_MODULE_ModelingAlgorithms:BOOL="${BUILD_ModelingAlgorithms}" \
|
|
||||||
-D BUILD_MODULE_Visualization:BOOL="${BUILD_Visualization}" \
|
|
||||||
-D BUILD_MODULE_ApplicationFramework:BOOL="${BUILD_ApplicationFramework}" \
|
|
||||||
-D BUILD_MODULE_DataExchange:BOOL="${BUILD_DataExchange}" \
|
|
||||||
-D BUILD_MODULE_Draw:BOOL="OFF" \
|
|
||||||
-D BUILD_DOC_Overview:BOOL="OFF" \
|
|
||||||
"$aCasSrc" 2>&1 | tee -a "$aLogFile"
|
|
||||||
aResult=$?; if [[ $aResult != 0 ]]; then exit $aResult; fi
|
|
||||||
fi
|
|
||||||
aTimeGEN=$SECONDS
|
|
||||||
logDuration $toCMake "Generation" $aTimeZERO $aTimeGEN
|
|
||||||
|
|
||||||
# clean up from previous build
|
|
||||||
if [[ $toClean == 1 ]]; then
|
|
||||||
make clean
|
|
||||||
fi
|
|
||||||
|
|
||||||
# build the project
|
|
||||||
if [[ $toMake == 1 ]]; then
|
|
||||||
echo Building...
|
|
||||||
make -j $aNbJobs 2>&1 | tee -a "$aLogFile"
|
|
||||||
aResult=$?; if [[ $aResult != 0 ]]; then exit $aResult; fi
|
|
||||||
fi
|
|
||||||
aTimeBUILD=$SECONDS
|
|
||||||
logDuration $toMake "Building" $aTimeGEN $aTimeBUILD
|
|
||||||
logDuration $toMake "Total building" $aTimeZERO $aTimeBUILD
|
|
||||||
|
|
||||||
# install the project
|
|
||||||
if [[ $toInstall == 1 ]]; then
|
|
||||||
echo Installing OCCT into $aDestDir...
|
|
||||||
make install 2>&1 | tee -a "$aLogFile"
|
|
||||||
cp -f "$aWorkDir/VERSION.html" "$aDestDir/VERSION.html"
|
|
||||||
fi
|
|
||||||
aTimeINSTALL=$SECONDS
|
|
||||||
logDuration $toInstall "Install" $aTimeBUILD $aTimeINSTALL
|
|
||||||
|
|
||||||
# create an archive
|
|
||||||
if [[ $toPack == 1 ]]; then
|
|
||||||
YEAR=$(date +"%Y")
|
|
||||||
MONTH=$(date +"%m")
|
|
||||||
DAY=$(date +"%d")
|
|
||||||
aRevision=-${YEAR}-${MONTH}-${DAY}
|
|
||||||
#aRevision=-${aGitBranch}
|
|
||||||
|
|
||||||
anArchName=occt-${anOcctVersion}${anOcctVerSuffix}${aRevision}-${aPlatformAndCompiler}.tar.bz2
|
|
||||||
echo Creating an archive ${aCasSrc}/${aBuildRoot}/${anArchName}...
|
|
||||||
rm ${aDestDir}/../${anArchName} &>/dev/null
|
|
||||||
pushd "$aDestDir"
|
|
||||||
tar -jcf ${aDestDir}/../${anArchName} *
|
|
||||||
popd
|
|
||||||
fi
|
|
||||||
aTimePACK=$SECONDS
|
|
||||||
logDuration $toPack "Packing archive" $aTimeINSTALL $aTimePACK
|
|
||||||
|
|
||||||
# finished
|
|
||||||
DURATION=$(($aTimePACK - $aTimeZERO))
|
|
||||||
echo Total time: $DURATION sec
|
|
||||||
logDuration 1 "Total" $aTimeZERO $aTimePACK
|
|
||||||
|
|
||||||
popd
|
|
@@ -1,30 +0,0 @@
|
|||||||
# environment configuration template for macos_build.sh (to be renamed as macos_custom_env.sh)
|
|
||||||
export PATH=/Applications/CMake.app/Contents/bin:$PATH
|
|
||||||
export aFreeType="$aSrcRoot/../3rdparty/freetype-2.10.4-ios"
|
|
||||||
export aFreeImage="$aSrcRoot/../3rdparty/freeimage-3.18-ios"
|
|
||||||
export aRapidJson="$aSrcRoot/../3rdparty/rapidjson-1.1.0"
|
|
||||||
export aDraco="$aSrcRoot/../3rdparty/draco-1.4.1-ios"
|
|
||||||
|
|
||||||
# Uncomment to customize building steps
|
|
||||||
#export toSimulator=0
|
|
||||||
#export isStatic=0
|
|
||||||
#export toCMake=1
|
|
||||||
#export toClean=1
|
|
||||||
#export toMake=1
|
|
||||||
#export toInstall=1
|
|
||||||
#export toPack=0
|
|
||||||
#export toDebug=0
|
|
||||||
|
|
||||||
#export BUILD_ModelingData=ON
|
|
||||||
#export BUILD_ModelingAlgorithms=ON
|
|
||||||
#export BUILD_Visualization=ON
|
|
||||||
#export BUILD_ApplicationFramework=ON
|
|
||||||
#export BUILD_DataExchange=ON
|
|
||||||
|
|
||||||
#export USE_RAPIDJSON=ON
|
|
||||||
#export USE_DRACO=ON
|
|
||||||
#export USE_FREEIMAGE=ON
|
|
||||||
|
|
||||||
#export IPHONEOS_DEPLOYMENT_TARGET=8.0
|
|
||||||
#export anAbi=arm64
|
|
||||||
#export anAbi=x86_64
|
|
@@ -1,181 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# Auxiliary script for semi-automated building of OCCT for macOS platform.
|
|
||||||
# macos_custom.sh should be configured with paths to CMake and other 3rd-parties.
|
|
||||||
# FreeType should be specified as mandatory dependency.
|
|
||||||
|
|
||||||
aScriptDir=${BASH_SOURCE%/*}
|
|
||||||
if [ -d "$aScriptDir" ]; then cd "$aScriptDir"; fi
|
|
||||||
aScriptDir="$PWD"
|
|
||||||
|
|
||||||
aCasSrc=${aScriptDir}/../..
|
|
||||||
aNbJobs="$(getconf _NPROCESSORS_ONLN)"
|
|
||||||
|
|
||||||
export aBuildRoot=work
|
|
||||||
|
|
||||||
# paths to pre-built 3rd-parties
|
|
||||||
export aFreeType=
|
|
||||||
export aFreeImage=
|
|
||||||
export aRapidJson=
|
|
||||||
export aDraco=
|
|
||||||
|
|
||||||
# build stages to perform
|
|
||||||
export toCMake=1
|
|
||||||
export toClean=1
|
|
||||||
export toMake=1
|
|
||||||
export toInstall=1
|
|
||||||
export toPack=0
|
|
||||||
export toDebug=0
|
|
||||||
|
|
||||||
export BUILD_ModelingData=ON
|
|
||||||
export BUILD_ModelingAlgorithms=ON
|
|
||||||
export BUILD_Visualization=ON
|
|
||||||
export BUILD_ApplicationFramework=ON
|
|
||||||
export BUILD_DataExchange=ON
|
|
||||||
export BUILD_Draw=ON
|
|
||||||
|
|
||||||
export USE_FREEIMAGE=ON
|
|
||||||
export USE_RAPIDJSON=OFF
|
|
||||||
export USE_DRACO=OFF
|
|
||||||
|
|
||||||
export MACOSX_DEPLOYMENT_TARGET=10.10
|
|
||||||
#export anAbi=arm64
|
|
||||||
export anAbi=x86_64
|
|
||||||
|
|
||||||
if [[ -f "${aScriptDir}/macos_custom.sh" ]]; then
|
|
||||||
source "${aScriptDir}/macos_custom.sh"
|
|
||||||
fi
|
|
||||||
|
|
||||||
aBuildType="Release"
|
|
||||||
aBuildTypePrefix=
|
|
||||||
if [[ $toDebug == 1 ]]; then
|
|
||||||
aBuildType="Debug"
|
|
||||||
aBuildTypePrefix="-debug"
|
|
||||||
fi
|
|
||||||
aPlatformAndCompiler=mac-${anAbi}${aBuildTypePrefix}-clang
|
|
||||||
|
|
||||||
aWorkDir="${aCasSrc}/${aBuildRoot}/${aPlatformAndCompiler}-make"
|
|
||||||
aDestDir="${aCasSrc}/${aBuildRoot}/${aPlatformAndCompiler}"
|
|
||||||
aLogFile="${aCasSrc}/${aBuildRoot}/build-${aPlatformAndCompiler}.log"
|
|
||||||
|
|
||||||
if [[ $toCMake == 1 ]] && [[ $toClean == 1 ]]; then
|
|
||||||
rm -r -f "$aWorkDir"
|
|
||||||
rm -r -f "$aDestDir"
|
|
||||||
fi
|
|
||||||
mkdir -p "$aWorkDir"
|
|
||||||
mkdir -p "$aDestDir"
|
|
||||||
rm -f "$aLogFile"
|
|
||||||
|
|
||||||
anOcctVerSuffix=`grep -e "#define OCC_VERSION_DEVELOPMENT" "$aCasSrc/src/Standard/Standard_Version.hxx" | awk '{print $3}' | xargs`
|
|
||||||
anOcctVersion=`grep -e "#define OCC_VERSION_COMPLETE" "$aCasSrc/src/Standard/Standard_Version.hxx" | awk '{print $3}' | xargs`
|
|
||||||
aGitBranch=`git symbolic-ref --short HEAD`
|
|
||||||
|
|
||||||
# include some information about OCCT into archive
|
|
||||||
echo \<pre\>> "${aWorkDir}/VERSION.html"
|
|
||||||
git status >> "${aWorkDir}/VERSION.html"
|
|
||||||
git log -n 100 >> "${aWorkDir}/VERSION.html"
|
|
||||||
echo \</pre\>>> "${aWorkDir}/VERSION.html"
|
|
||||||
|
|
||||||
pushd "$aWorkDir"
|
|
||||||
|
|
||||||
aTimeZERO=$SECONDS
|
|
||||||
set -o pipefail
|
|
||||||
|
|
||||||
function logDuration {
|
|
||||||
if [[ $1 == 1 ]]; then
|
|
||||||
aDur=$(($4 - $3))
|
|
||||||
echo $2 time: $aDur sec>> "$aLogFile"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
# (re)generate Make files
|
|
||||||
if [[ $toCMake == 1 ]]; then
|
|
||||||
echo Configuring OCCT for macOS...
|
|
||||||
cmake -G "Unix Makefiles" \
|
|
||||||
-D CMAKE_BUILD_TYPE:STRING="$aBuildType" \
|
|
||||||
-D BUILD_LIBRARY_TYPE:STRING="Shared" \
|
|
||||||
-D CMAKE_OSX_ARCHITECTURES:STRING="$anAbi" \
|
|
||||||
-D INSTALL_DIR:PATH="$aDestDir" \
|
|
||||||
-D INSTALL_DIR_INCLUDE:STRING="inc" \
|
|
||||||
-D INSTALL_DIR_LIB:STRING="lib" \
|
|
||||||
-D INSTALL_DIR_RESOURCE:STRING="src" \
|
|
||||||
-D INSTALL_NAME_DIR:STRING="@executable_path/../Frameworks" \
|
|
||||||
-D 3RDPARTY_FREETYPE_DIR:PATH="$aFreeType" \
|
|
||||||
-D 3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2:FILEPATH="$aFreeType/include" \
|
|
||||||
-D 3RDPARTY_FREETYPE_INCLUDE_DIR_ft2build:FILEPATH="$aFreeType/include" \
|
|
||||||
-D 3RDPARTY_FREETYPE_LIBRARY_DIR:PATH="$aFreeType/lib" \
|
|
||||||
-D 3RDPARTY_FREETYPE_LIBRARY:FILEPATH="$aFreeType/lib/libfreetype.dylib" \
|
|
||||||
-D USE_RAPIDJSON:BOOL="$USE_RAPIDJSON" \
|
|
||||||
-D 3RDPARTY_RAPIDJSON_DIR:PATH="$aRapidJson" \
|
|
||||||
-D 3RDPARTY_RAPIDJSON_INCLUDE_DIR:PATH="$aRapidJson/include" \
|
|
||||||
-D USE_DRACO:BOOL="$USE_DRACO" \
|
|
||||||
-D 3RDPARTY_DRACO_DIR:PATH="$aDraco" \
|
|
||||||
-D 3RDPARTY_DRACO_INCLUDE_DIR:FILEPATH="$aDraco/include" \
|
|
||||||
-D 3RDPARTY_DRACO_LIBRARY_DIR:PATH="$aDraco/lib" \
|
|
||||||
-D USE_FREEIMAGE:BOOL="$USE_FREEIMAGE" \
|
|
||||||
-D 3RDPARTY_FREEIMAGE_DIR:PATH="$aFreeImage" \
|
|
||||||
-D 3RDPARTY_FREEIMAGE_INCLUDE_DIR:FILEPATH="$aFreeImage/include" \
|
|
||||||
-D 3RDPARTY_FREEIMAGE_LIBRARY_DIR:PATH="$aFreeImage/lib" \
|
|
||||||
-D 3RDPARTY_FREEIMAGE_LIBRARY:FILEPATH="$aFreeImage/lib/libfreeimage.a" \
|
|
||||||
-D BUILD_MODULE_FoundationClasses:BOOL="ON" \
|
|
||||||
-D BUILD_MODULE_ModelingData:BOOL="${BUILD_ModelingData}" \
|
|
||||||
-D BUILD_MODULE_ModelingAlgorithms:BOOL="${BUILD_ModelingAlgorithms}" \
|
|
||||||
-D BUILD_MODULE_Visualization:BOOL="${BUILD_Visualization}" \
|
|
||||||
-D BUILD_MODULE_ApplicationFramework:BOOL="${BUILD_ApplicationFramework}" \
|
|
||||||
-D BUILD_MODULE_DataExchange:BOOL="${BUILD_DataExchange}" \
|
|
||||||
-D BUILD_MODULE_Draw:BOOL="${BUILD_Draw}" \
|
|
||||||
-D BUILD_DOC_Overview:BOOL="OFF" \
|
|
||||||
"$aCasSrc" 2>&1 | tee -a "$aLogFile"
|
|
||||||
aResult=$?; if [[ $aResult != 0 ]]; then exit $aResult; fi
|
|
||||||
fi
|
|
||||||
aTimeGEN=$SECONDS
|
|
||||||
logDuration $toCMake "Generation" $aTimeZERO $aTimeGEN
|
|
||||||
|
|
||||||
# clean up from previous build
|
|
||||||
if [[ $toClean == 1 ]]; then
|
|
||||||
make clean
|
|
||||||
fi
|
|
||||||
|
|
||||||
# build the project
|
|
||||||
if [[ $toMake == 1 ]]; then
|
|
||||||
echo Building OCCT...
|
|
||||||
make -j $aNbJobs 2>&1 | tee -a "$aLogFile"
|
|
||||||
aResult=$?; if [[ $aResult != 0 ]]; then exit $aResult; fi
|
|
||||||
fi
|
|
||||||
aTimeBUILD=$SECONDS
|
|
||||||
logDuration $toMake "Building" $aTimeGEN $aTimeBUILD
|
|
||||||
logDuration $toMake "Total building" $aTimeZERO $aTimeBUILD
|
|
||||||
|
|
||||||
# install the project
|
|
||||||
if [[ $toInstall == 1 ]]; then
|
|
||||||
echo Installing OCCT into $aDestDir...
|
|
||||||
make install 2>&1 | tee -a "$aLogFile"
|
|
||||||
cp -f "$aWorkDir/VERSION.html" "$aDestDir/VERSION.html"
|
|
||||||
fi
|
|
||||||
aTimeINSTALL=$SECONDS
|
|
||||||
logDuration $toInstall "Install" $aTimeBUILD $aTimeINSTALL
|
|
||||||
|
|
||||||
# create an archive
|
|
||||||
if [[ $toPack == 1 ]]; then
|
|
||||||
YEAR=$(date +"%Y")
|
|
||||||
MONTH=$(date +"%m")
|
|
||||||
DAY=$(date +"%d")
|
|
||||||
aRevision=-${YEAR}-${MONTH}-${DAY}
|
|
||||||
#aRevision=-${aGitBranch}
|
|
||||||
|
|
||||||
anArchName=occt-${anOcctVersion}${anOcctVerSuffix}${aRevision}-${aPlatformAndCompiler}.tar.bz2
|
|
||||||
echo Creating an archive ${aCasSrc}/${aBuildRoot}/${anArchName}...
|
|
||||||
rm ${aDestDir}/../${anArchName} &>/dev/null
|
|
||||||
pushd "$aDestDir"
|
|
||||||
tar -jcf ${aDestDir}/../${anArchName} *
|
|
||||||
popd
|
|
||||||
fi
|
|
||||||
aTimePACK=$SECONDS
|
|
||||||
logDuration $toPack "Packing archive" $aTimeINSTALL $aTimePACK
|
|
||||||
|
|
||||||
# finished
|
|
||||||
DURATION=$(($aTimePACK - $aTimeZERO))
|
|
||||||
echo Total time: $DURATION sec
|
|
||||||
logDuration 1 "Total" $aTimeZERO $aTimePACK
|
|
||||||
|
|
||||||
popd
|
|
@@ -1,29 +0,0 @@
|
|||||||
# environment configuration template for macos_build.sh (to be renamed as macos_custom_env.sh)
|
|
||||||
export PATH=/Applications/CMake.app/Contents/bin:$PATH
|
|
||||||
export aFreeType="$aSrcRoot/../3rdparty/freetype-2.10.4-macos"
|
|
||||||
export aFreeImage="$aSrcRoot/../3rdparty/freeimage-3.18-macos"
|
|
||||||
export aRapidJson="$aSrcRoot/../3rdparty/rapidjson-1.1.0"
|
|
||||||
export aDraco="$aSrcRoot/../3rdparty/draco-1.4.1-macos"
|
|
||||||
|
|
||||||
# Uncomment to customize building steps
|
|
||||||
#export aBuildRoot=work
|
|
||||||
#export toCMake=1
|
|
||||||
#export toClean=1
|
|
||||||
#export toMake=1
|
|
||||||
#export toInstall=1
|
|
||||||
#export toPack=1
|
|
||||||
|
|
||||||
#export BUILD_ModelingData=ON
|
|
||||||
#export BUILD_ModelingAlgorithms=ON
|
|
||||||
#export BUILD_Visualization=ON
|
|
||||||
#export BUILD_ApplicationFramework=ON
|
|
||||||
#export BUILD_DataExchange=ON
|
|
||||||
#export BUILD_Draw=ON
|
|
||||||
|
|
||||||
#export USE_RAPIDJSON=ON
|
|
||||||
#export USE_DRACO=ON
|
|
||||||
#export USE_FREEIMAGE=ON
|
|
||||||
|
|
||||||
#export MACOSX_DEPLOYMENT_TARGET=10.10
|
|
||||||
#export anAbi=arm64
|
|
||||||
#export anAbi=x86_64
|
|
@@ -1,267 +0,0 @@
|
|||||||
@echo OFF
|
|
||||||
|
|
||||||
rem Auxiliary script for semi-automated building of OCCT for Mingw-w64 platform.
|
|
||||||
rem mingw_custom.bat should be configured with paths to CMake, 3rd-parties and MinGW.
|
|
||||||
|
|
||||||
set "aCasSrc=%~dp0..\.."
|
|
||||||
set "aBuildRoot=%aCasSrc%\work"
|
|
||||||
|
|
||||||
set aNbJobs=%NUMBER_OF_PROCESSORS%
|
|
||||||
|
|
||||||
rem Paths to 3rd-party tools and libraries
|
|
||||||
set "aCmakeBin="
|
|
||||||
set "aMingwVars="
|
|
||||||
set "aFreeType="
|
|
||||||
set "aFreeImage="
|
|
||||||
set "aRapidJson="
|
|
||||||
set "aDraco="
|
|
||||||
set "aTclTk="
|
|
||||||
|
|
||||||
rem Build stages to perform
|
|
||||||
set "toCMake=1"
|
|
||||||
set "toClean=0"
|
|
||||||
set "toMake=1"
|
|
||||||
set "toInstall=1"
|
|
||||||
set "toPack=0"
|
|
||||||
set "toDebug=0"
|
|
||||||
set "isStatic=0"
|
|
||||||
|
|
||||||
rem OCCT Modules to build
|
|
||||||
set "BUILD_ModelingData=ON"
|
|
||||||
set "BUILD_ModelingAlgorithms=ON"
|
|
||||||
set "BUILD_Visualization=ON"
|
|
||||||
set "BUILD_ApplicationFramework=ON"
|
|
||||||
set "BUILD_DataExchange=ON"
|
|
||||||
set "BUILD_Draw=ON"
|
|
||||||
|
|
||||||
rem Optional 3rd-party libraries to enable
|
|
||||||
set "USE_FREETYPE=ON"
|
|
||||||
set "USE_RAPIDJSON=OFF"
|
|
||||||
set "USE_DRACO=OFF"
|
|
||||||
set "USE_FREEIMAGE=ON"
|
|
||||||
|
|
||||||
rem Archive tool
|
|
||||||
set "THE_7Z_PARAMS=-t7z -m0=lzma -mx=9 -mfb=64 -md=32m -ms=on"
|
|
||||||
set "THE_7Z_PATH=%ProgramW6432%\7-Zip\7z.exe"
|
|
||||||
|
|
||||||
rem Configuration file
|
|
||||||
if exist "%~dp0mingw_custom.bat" call "%~dp0mingw_custom.bat"
|
|
||||||
|
|
||||||
if not ["%aMingwVars%"] == [""] ( call "%aMingwVars%" )
|
|
||||||
if not ["%aCmakeBin%"] == [""] ( set "PATH=%aCmakeBin%;%PATH%" )
|
|
||||||
|
|
||||||
set "anOcctVerSuffix="
|
|
||||||
set "anOcctVersion=0.0.0"
|
|
||||||
set "aGitBranch="
|
|
||||||
for /f tokens^=2^ delims^=^" %%i in ('findstr /b /c:"#define OCC_VERSION_DEVELOPMENT" "%aCasSrc%\src\Standard\Standard_Version.hxx"') do ( set "anOcctVerSuffix=%%i" )
|
|
||||||
for /f tokens^=2^ delims^=^" %%i in ('findstr /b /c:"#define OCC_VERSION_COMPLETE" "%aCasSrc%\src\Standard\Standard_Version.hxx"') do ( set "anOcctVersion=%%i" )
|
|
||||||
for /f %%i in ('git symbolic-ref --short HEAD') do ( set "aGitBranch=%%i" )
|
|
||||||
|
|
||||||
set "aBuildType=Release"
|
|
||||||
set "aBuildTypePrefix="
|
|
||||||
set "aLibType=Shared"
|
|
||||||
if ["%isStatic%"] == ["1"] set "aLibType=Static"
|
|
||||||
if ["%toDebug%"] == ["1"] (
|
|
||||||
set "aBuildType=Debug"
|
|
||||||
set "aBuildTypePrefix=-debug"
|
|
||||||
)
|
|
||||||
|
|
||||||
call :cmakeGenerate
|
|
||||||
if errorlevel 1 (
|
|
||||||
if not ["%1"] == ["-nopause"] (
|
|
||||||
pause
|
|
||||||
)
|
|
||||||
exit /B 1
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
|
|
||||||
for /F "skip=1 delims=" %%F in ('
|
|
||||||
wmic PATH Win32_LocalTime GET Day^,Month^,Year /FORMAT:TABLE
|
|
||||||
') do (
|
|
||||||
for /F "tokens=1-3" %%L in ("%%F") do (
|
|
||||||
set DAY00=0%%L
|
|
||||||
set MONTH00=0%%M
|
|
||||||
set YEAR=%%N
|
|
||||||
)
|
|
||||||
)
|
|
||||||
set DAY00=%DAY00:~-2%
|
|
||||||
set MONTH00=%MONTH00:~-2%
|
|
||||||
set "aRevision=-%YEAR%-%MONTH00%-%DAY00%"
|
|
||||||
rem set "aRevision=-%aGitBranch%"
|
|
||||||
set "anArchName=occt-%anOcctVersion%%anOcctVerSuffix%%aRevision%-mingw64%aBuildTypePrefix%"
|
|
||||||
set "aTarget=%aBuildRoot%\%anArchName%"
|
|
||||||
if ["%toPack%"] == ["1"] (
|
|
||||||
echo Creating archive %anArchName%.7z
|
|
||||||
rmdir /S /Q "%aTarget%"
|
|
||||||
if not exist "%aTarget%" ( mkdir "%aTarget%" )
|
|
||||||
if exist "%aBuildRoot%/%anArchName%.7z" del "%aBuildRoot%/%anArchName%.7z"
|
|
||||||
xcopy /S /Y "%aDestDir%\*" "%aTarget%\"
|
|
||||||
|
|
||||||
echo Copying dependencies...
|
|
||||||
for %%i in (libstdc++-6.dll libwinpthread-1.dll libgcc_s_seh-1.dll) do (
|
|
||||||
if "%%~$PATH:i" == "" (
|
|
||||||
echo "Error: could not find %%i"
|
|
||||||
) else (
|
|
||||||
xcopy /Y "%%~$PATH:i" "%aTarget%\win64\gcc\bin"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
"%THE_7Z_PATH%" a -r %THE_7Z_PARAMS% "%aBuildRoot%/%anArchName%.7z" "%aTarget%"
|
|
||||||
)
|
|
||||||
if not ["%1"] == ["-nopause"] (
|
|
||||||
pause
|
|
||||||
)
|
|
||||||
|
|
||||||
goto :eof
|
|
||||||
|
|
||||||
:cmakeGenerate
|
|
||||||
set "aPlatformAndCompiler=mingw64%aBuildTypePrefix%"
|
|
||||||
set "aWorkDir=%aBuildRoot%\occt-%aPlatformAndCompiler%-make"
|
|
||||||
set "aDestDir=%aBuildRoot%\occt-%aPlatformAndCompiler%"
|
|
||||||
set "aLogFile=%aBuildRoot%\occt-%aPlatformAndCompiler%-build.log"
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
if ["%toClean%"] == ["1"] (
|
|
||||||
rmdir /S /Q %aWorkDir%"
|
|
||||||
rmdir /S /Q %aDestDir%"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
if not exist "%aWorkDir%" ( mkdir "%aWorkDir%" )
|
|
||||||
if exist "%aLogFile%" ( del "%aLogFile%" )
|
|
||||||
|
|
||||||
rem include some information about OCCT into archive
|
|
||||||
echo ^<pre^>> "%aWorkDir%\VERSION.html"
|
|
||||||
git status >> "%aWorkDir%\VERSION.html"
|
|
||||||
git log -n 100 >> "%aWorkDir%\VERSION.html"
|
|
||||||
echo ^</pre^>>> "%aWorkDir%\VERSION.html"
|
|
||||||
|
|
||||||
echo Start building OCCT for %aPlatformAndCompiler%
|
|
||||||
echo Start building OCCT for %aPlatformAndCompiler%>> %aLogFile%
|
|
||||||
|
|
||||||
pushd "%aWorkDir%"
|
|
||||||
|
|
||||||
set "aTimeZERO=%TIME%"
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
echo Configuring OCCT for MinGW-w64...
|
|
||||||
cmake -G "MinGW Makefiles" ^
|
|
||||||
-D CMAKE_BUILD_TYPE:STRING="%aBuildType%" ^
|
|
||||||
-D BUILD_LIBRARY_TYPE:STRING="%aLibType%" ^
|
|
||||||
-D INSTALL_DIR:PATH="%aDestDir%" ^
|
|
||||||
-D INSTALL_DIR_INCLUDE:STRING="inc" ^
|
|
||||||
-D INSTALL_DIR_RESOURCE:STRING="src" ^
|
|
||||||
-D BUILD_DOC_Overview:BOOL="OFF" ^
|
|
||||||
-D BUILD_MODULE_FoundationClasses:BOOL="ON" ^
|
|
||||||
-D BUILD_MODULE_ModelingData:BOOL="%BUILD_ModelingData%" ^
|
|
||||||
-D BUILD_MODULE_ModelingAlgorithms:BOOL="%BUILD_ModelingAlgorithms%" ^
|
|
||||||
-D BUILD_MODULE_Visualization:BOOL="%BUILD_Visualization%" ^
|
|
||||||
-D BUILD_MODULE_ApplicationFramework:BOOL="%BUILD_ApplicationFramework%" ^
|
|
||||||
-D BUILD_MODULE_DataExchange:BOOL="%BUILD_DataExchange%" ^
|
|
||||||
-D BUILD_MODULE_Draw:BOOL="%BUILD_Draw%" ^
|
|
||||||
-D 3RDPARTY_TCL_DIR:PATH="%aTclTk%" ^
|
|
||||||
-D 3RDPARTY_TCL_INCLUDE_DIR:FILEPATH="%aTclTk%/include" ^
|
|
||||||
-D 3RDPARTY_TCL_LIBRARY_DIR:PATH="%aTclTk%/lib" ^
|
|
||||||
-D 3RDPARTY_TCL_DLL_DIR:PATH="%aTclTk%/bin" ^
|
|
||||||
-D 3RDPARTY_TK_DIR:PATH="%aTclTk%" ^
|
|
||||||
-D 3RDPARTY_TK_INCLUDE_DIR:FILEPATH="%aTclTk%/include" ^
|
|
||||||
-D 3RDPARTY_TK_LIBRARY_DIR:PATH="%aTclTk%/lib" ^
|
|
||||||
-D 3RDPARTY_TK_DLL_DIR:PATH="%aTclTk%/bin" ^
|
|
||||||
-D USE_D3D:BOOL="ON" ^
|
|
||||||
-D USE_FREETYPE:BOOL="%USE_FREETYPE%" ^
|
|
||||||
-D 3RDPARTY_FREETYPE_DIR:PATH="%aFreeType%" ^
|
|
||||||
-D 3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2:FILEPATH="%aFreeType%/include" ^
|
|
||||||
-D 3RDPARTY_FREETYPE_INCLUDE_DIR_ft2build:FILEPATH="%aFreeType%/include" ^
|
|
||||||
-D 3RDPARTY_FREETYPE_LIBRARY_DIR:PATH="%aFreeType%/lib" ^
|
|
||||||
-D USE_FREEIMAGE:BOOL="%USE_FREEIMAGE%" ^
|
|
||||||
-D 3RDPARTY_FREEIMAGE_DIR:PATH="%aFreeImage%" ^
|
|
||||||
-D 3RDPARTY_FREEIMAGE_INCLUDE_DIR:FILEPATH="%aFreeImage%/include" ^
|
|
||||||
-D 3RDPARTY_FREEIMAGE_LIBRARY_DIR:PATH="%aFreeImage%/lib" ^
|
|
||||||
-D USE_RAPIDJSON:BOOL="%USE_RAPIDJSON%" ^
|
|
||||||
-D 3RDPARTY_RAPIDJSON_DIR:PATH="%aRapidJson%" ^
|
|
||||||
-D 3RDPARTY_RAPIDJSON_INCLUDE_DIR:PATH="%aRapidJson%/include" ^
|
|
||||||
-D USE_DRACO:BOOL="%USE_DRACO%" ^
|
|
||||||
-D 3RDPARTY_DRACO_DIR:PATH="%aDraco%" ^
|
|
||||||
-D 3RDPARTY_DRACO_INCLUDE_DIR:FILEPATH="%aDraco%/include" ^
|
|
||||||
-D 3RDPARTY_DRACO_LIBRARY_DIR:PATH="%aDraco%/lib" ^
|
|
||||||
"%aCasSrc%"
|
|
||||||
|
|
||||||
if errorlevel 1 (
|
|
||||||
popd
|
|
||||||
exit /B 1
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
)
|
|
||||||
set "aTimeGEN=%TIME%"
|
|
||||||
call :computeDuration %aTimeZERO% %aTimeGEN%
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
echo Generation time: %DURATION%
|
|
||||||
echo Generation time: %DURATION%>> "%aLogFile%"
|
|
||||||
)
|
|
||||||
|
|
||||||
if ["%toClean%"] == ["1"] (
|
|
||||||
mingw32-make clean
|
|
||||||
)
|
|
||||||
|
|
||||||
if ["%toMake%"] == ["1"] (
|
|
||||||
echo Building...
|
|
||||||
mingw32-make -j %aNbJobs% 2>> "%aLogFile%"
|
|
||||||
if errorlevel 1 (
|
|
||||||
type "%aLogFile%"
|
|
||||||
popd
|
|
||||||
exit /B 1
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
type "%aLogFile%"
|
|
||||||
)
|
|
||||||
set "aTimeBUILD=%TIME%"
|
|
||||||
call :computeDuration %aTimeGEN% %aTimeBUILD%
|
|
||||||
if ["%toMake%"] == ["1"] (
|
|
||||||
echo Building time: %DURATION%
|
|
||||||
echo Building time: %DURATION%>> "%aLogFile%"
|
|
||||||
)
|
|
||||||
call :computeDuration %aTimeZERO% %aTimeBUILD%
|
|
||||||
if ["%toMake%"] == ["1"] (
|
|
||||||
echo Total building time: %DURATION%
|
|
||||||
echo Total building time: %DURATION%>> "%aLogFile%"
|
|
||||||
)
|
|
||||||
|
|
||||||
if ["%toInstall%"] == ["1"] (
|
|
||||||
echo Installing into %aDestDir%...
|
|
||||||
mingw32-make install 2>> "%aLogFile%"
|
|
||||||
copy /Y "%aWorkDir%\VERSION.html" "%aDestDir%\VERSION.html"
|
|
||||||
)
|
|
||||||
set "aTimeINSTALL=%TIME%"
|
|
||||||
call :computeDuration "%aTimeBUILD%" "%aTimeINSTALL%"
|
|
||||||
if ["%toInstall%"] == ["1"] (
|
|
||||||
echo Install time: %DURATION%
|
|
||||||
echo Install time: %DURATION%>> "%aLogFile%"
|
|
||||||
)
|
|
||||||
|
|
||||||
call :computeDuration "%aTimeZERO%" "%aTimeINSTALL%"
|
|
||||||
echo Total time: %DURATION%
|
|
||||||
echo Total time: %DURATION%>> "%aLogFile%"
|
|
||||||
|
|
||||||
popd
|
|
||||||
goto :eof
|
|
||||||
|
|
||||||
:computeDuration
|
|
||||||
set "aTimeFrom=%~1"
|
|
||||||
set "aTimeEnd=%~2"
|
|
||||||
rem handle time before 10AM (win10 - remove empty space at the beginning)
|
|
||||||
if "%aTimeFrom:~0,1%"==" " set "aTimeFrom=%aTimeFrom:~1%"
|
|
||||||
if "%aTimeEnd:~0,1%"==" " set "aTimeEnd=%aTimeEnd:~1%"
|
|
||||||
rem handle time before 10AM (win7 - add 0 at the beginning)
|
|
||||||
if "%aTimeFrom:~1,1%"==":" set "aTimeFrom=0%aTimeFrom%"
|
|
||||||
if "%aTimeEnd:~1,1%"==":" set "aTimeEnd=0%aTimeEnd%"
|
|
||||||
rem convert hours:minutes:seconds:ms into duration
|
|
||||||
set /A aTimeFrom=(1%aTimeFrom:~0,2%-100)*360000 + (1%aTimeFrom:~3,2%-100)*6000 + (1%aTimeFrom:~6,2%-100)*100 + (1%aTimeFrom:~9,2%-100)
|
|
||||||
set /A aTimeEnd= (1%aTimeEnd:~0,2%-100)*360000 + (1%aTimeEnd:~3,2%-100)*6000 + (1%aTimeEnd:~6,2%-100)*100 + (1%aTimeEnd:~9,2%-100)
|
|
||||||
set /A aDurTotalSec=%aTimeEnd%-%aTimeFrom%
|
|
||||||
if %aTimeEnd% LSS %aTimeFrom% set set /A aDurTotalSec=%aTimeFrom%-%aTimeEnd%
|
|
||||||
set /A aDurHH=%aDurTotalSec% / 360000
|
|
||||||
set /A aDurMM=(%aDurTotalSec% - %aDurHH%*360000) / 6000
|
|
||||||
set /A aDurSS=(%aDurTotalSec% - %aDurHH%*360000 - %aDurMM%*6000) / 100
|
|
||||||
if %aDurHH% LSS 10 set aDurHH=0%aDurHH%
|
|
||||||
if %aDurMM% LSS 10 set aDurMM=0%aDurMM%
|
|
||||||
if %aDurSS% LSS 10 set aDurSS=0%aDurSS%
|
|
||||||
|
|
||||||
set "DURATION=%aDurHH%:%aDurMM%:%aDurSS%"
|
|
||||||
goto :eof
|
|
@@ -1,29 +0,0 @@
|
|||||||
rem Environment configuration template for mingw_build.bat (to be renamed as mingw_custom.bat)
|
|
||||||
set "aCmakeBin=%ProgramW6432%\CMake\bin"
|
|
||||||
set "aFreeType=%aCasSrc%/../3rdparty/freetype-2.6.3-mingw-64"
|
|
||||||
set "aTclTk=%aCasSrc%/../3rdparty/tcltk-8.6.4-mingw-64"
|
|
||||||
set "aFreeImage=%aCasSrc%/../3rdparty/freeimage-3.17-0-mingw-64"
|
|
||||||
set "aRapidJson=%aCasSrc%/../3rdparty/rapidjson-1.1.0"
|
|
||||||
set "aDraco=%aCasSrc%/../3rdparty/draco-1.4-1-mingw-64"
|
|
||||||
|
|
||||||
set "aMingwVars=c:\mingw-8.3.0-msys2\mingwvars.bat"
|
|
||||||
|
|
||||||
rem Uncomment to customize building steps
|
|
||||||
rem set "aBuildRoot=work"
|
|
||||||
rem set "toCMake=1"
|
|
||||||
rem set "toClean=1"
|
|
||||||
rem set "toMake=1"
|
|
||||||
rem set "toInstall=1"
|
|
||||||
rem set "toPack=1"
|
|
||||||
rem set "toDebug=0"
|
|
||||||
|
|
||||||
rem set "BUILD_ModelingData=ON"
|
|
||||||
rem set "BUILD_ModelingAlgorithms=ON"
|
|
||||||
rem set "BUILD_Visualization=ON"
|
|
||||||
rem set "BUILD_ApplicationFramework=ON"
|
|
||||||
rem set "BUILD_DataExchange=ON"
|
|
||||||
rem set "BUILD_Draw=ON"
|
|
||||||
|
|
||||||
rem set "USE_RAPIDJSON=ON"
|
|
||||||
rem set "USE_DRACO=ON"
|
|
||||||
rem set "USE_FREEIMAGE=ON"
|
|
@@ -1,333 +0,0 @@
|
|||||||
@echo OFF
|
|
||||||
|
|
||||||
rem Auxiliary script for semi-automated building of OCCT for WASM platform.
|
|
||||||
rem wasm_custom.bat should be configured with paths to CMake, 3rd-parties and Emscripten SDK.
|
|
||||||
rem FreeType should be specified as mandatory dependency.
|
|
||||||
|
|
||||||
set "aCasSrc=%~dp0..\.."
|
|
||||||
set "aBuildRoot=%aCasSrc%\work"
|
|
||||||
|
|
||||||
set aNbJobs=%NUMBER_OF_PROCESSORS%
|
|
||||||
|
|
||||||
rem Paths to 3rd-party tools and libraries
|
|
||||||
set "aCmakeBin="
|
|
||||||
set "aFreeType="
|
|
||||||
set "aRapidJson="
|
|
||||||
set "aDraco="
|
|
||||||
set "aTcl="
|
|
||||||
|
|
||||||
rem Build stages to perform
|
|
||||||
set "toCMake=1"
|
|
||||||
set "toClean=0"
|
|
||||||
set "toMake=1"
|
|
||||||
set "toInstall=1"
|
|
||||||
set "toPack=0"
|
|
||||||
set "toDebug=0"
|
|
||||||
set "toBuildSample=0"
|
|
||||||
set "sourceMapBase="
|
|
||||||
|
|
||||||
rem OCCT Modules to build
|
|
||||||
set "BUILD_ModelingData=ON"
|
|
||||||
set "BUILD_ModelingAlgorithms=ON"
|
|
||||||
set "BUILD_Visualization=ON"
|
|
||||||
set "BUILD_ApplicationFramework=ON"
|
|
||||||
set "BUILD_DataExchange=ON"
|
|
||||||
set "BUILD_Draw=OFF"
|
|
||||||
|
|
||||||
rem Optional 3rd-party libraries to enable
|
|
||||||
set "USE_FREETYPE=ON"
|
|
||||||
set "USE_RAPIDJSON=OFF"
|
|
||||||
set "USE_DRACO=OFF"
|
|
||||||
set "USE_PTHREADS=OFF"
|
|
||||||
|
|
||||||
rem Archive tool
|
|
||||||
set "THE_7Z_PARAMS=-t7z -m0=lzma -mx=9 -mfb=64 -md=32m -ms=on"
|
|
||||||
set "THE_7Z_PATH=%ProgramW6432%\7-Zip\7z.exe"
|
|
||||||
|
|
||||||
rem Configuration file
|
|
||||||
if exist "%~dp0wasm_custom.bat" call "%~dp0wasm_custom.bat"
|
|
||||||
|
|
||||||
call "%EMSDK_ROOT%\emsdk_env.bat"
|
|
||||||
set "aToolchain=%EMSDK%/upstream/emscripten/cmake/Modules/Platform/Emscripten.cmake"
|
|
||||||
if not ["%aCmakeBin%"] == [""] ( set "PATH=%aCmakeBin%;%PATH%" )
|
|
||||||
|
|
||||||
set "anOcctVerSuffix="
|
|
||||||
set "anOcctVersion=0.0.0"
|
|
||||||
set "aGitBranch="
|
|
||||||
for /f tokens^=2^ delims^=^" %%i in ('findstr /b /c:"#define OCC_VERSION_DEVELOPMENT" "%aCasSrc%\src\Standard\Standard_Version.hxx"') do ( set "anOcctVerSuffix=%%i" )
|
|
||||||
for /f tokens^=2^ delims^=^" %%i in ('findstr /b /c:"#define OCC_VERSION_COMPLETE" "%aCasSrc%\src\Standard\Standard_Version.hxx"') do ( set "anOcctVersion=%%i" )
|
|
||||||
for /f %%i in ('git symbolic-ref --short HEAD') do ( set "aGitBranch=%%i" )
|
|
||||||
|
|
||||||
set "aBuildType=Release"
|
|
||||||
set "aBuildTypePrefix="
|
|
||||||
set "anExtraCxxFlags="
|
|
||||||
if /I ["%USE_PTHREADS%"] == ["ON"] (
|
|
||||||
set "anExtraCxxFlags=-pthread"
|
|
||||||
set "aBuildTypePrefix=%aBuildTypePrefix%-pthread"
|
|
||||||
)
|
|
||||||
if ["%toDebug%"] == ["1"] (
|
|
||||||
set "aBuildType=Debug"
|
|
||||||
set "aBuildTypePrefix=%aBuildTypePrefix%-debug"
|
|
||||||
)
|
|
||||||
|
|
||||||
call :cmakeGenerate
|
|
||||||
if errorlevel 1 (
|
|
||||||
if not ["%1"] == ["-nopause"] (
|
|
||||||
pause
|
|
||||||
)
|
|
||||||
exit /B 1
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
|
|
||||||
for /F "skip=1 delims=" %%F in ('
|
|
||||||
wmic PATH Win32_LocalTime GET Day^,Month^,Year /FORMAT:TABLE
|
|
||||||
') do (
|
|
||||||
for /F "tokens=1-3" %%L in ("%%F") do (
|
|
||||||
set DAY00=0%%L
|
|
||||||
set MONTH00=0%%M
|
|
||||||
set YEAR=%%N
|
|
||||||
)
|
|
||||||
)
|
|
||||||
set DAY00=%DAY00:~-2%
|
|
||||||
set MONTH00=%MONTH00:~-2%
|
|
||||||
set "aRevision=-%YEAR%-%MONTH00%-%DAY00%"
|
|
||||||
rem set "aRevision=-%aGitBranch%"
|
|
||||||
set "anArchName=occt-%anOcctVersion%%anOcctVerSuffix%%aRevision%-wasm32%aBuildTypePrefix%"
|
|
||||||
set "aTarget=%aBuildRoot%\%anArchName%"
|
|
||||||
if ["%toPack%"] == ["1"] (
|
|
||||||
echo Creating archive %anArchName%.7z
|
|
||||||
rmdir /S /Q "%aTarget%"
|
|
||||||
if not exist "%aTarget%" ( mkdir "%aTarget%" )
|
|
||||||
if exist "%aBuildRoot%/%anArchName%.7z" del "%aBuildRoot%/%anArchName%.7z"
|
|
||||||
xcopy /S /Y "%aDestDir%\*" "%aTarget%\"
|
|
||||||
|
|
||||||
if ["%toBuildSample%"] == ["1"] (
|
|
||||||
if not exist "%aTarget%\sample" ( mkdir "%aTarget%\sample" )
|
|
||||||
xcopy /S /Y "%aDestDirSmpl%\*" "%aTarget%\sample\"
|
|
||||||
)
|
|
||||||
|
|
||||||
"%THE_7Z_PATH%" a -r %THE_7Z_PARAMS% "%aBuildRoot%/%anArchName%.7z" "%aTarget%"
|
|
||||||
)
|
|
||||||
if not ["%1"] == ["-nopause"] (
|
|
||||||
pause
|
|
||||||
)
|
|
||||||
|
|
||||||
goto :eof
|
|
||||||
|
|
||||||
:cmakeGenerate
|
|
||||||
set "aPlatformAndCompiler=wasm32%aBuildTypePrefix%"
|
|
||||||
set "aWorkDir=%aBuildRoot%\occt-%aPlatformAndCompiler%-make"
|
|
||||||
set "aDestDir=%aBuildRoot%\occt-%aPlatformAndCompiler%"
|
|
||||||
set "aLogFile=%aBuildRoot%\occt-%aPlatformAndCompiler%-build.log"
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
if ["%toClean%"] == ["1"] (
|
|
||||||
rmdir /S /Q %aWorkDir%"
|
|
||||||
rmdir /S /Q %aDestDir%"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
if not exist "%aWorkDir%" ( mkdir "%aWorkDir%" )
|
|
||||||
if exist "%aLogFile%" ( del "%aLogFile%" )
|
|
||||||
|
|
||||||
set "aSrcRootSmpl=%aCasSrc%\samples\webgl"
|
|
||||||
set "aWorkDirSmpl=%aBuildRoot%\sample-%aPlatformAndCompiler%-make"
|
|
||||||
set "aDestDirSmpl=%aBuildRoot%\sample-%aPlatformAndCompiler%"
|
|
||||||
set "aLogFileSmpl=%aBuildRoot%\sample-%aPlatformAndCompiler%-build.log"
|
|
||||||
if ["%toBuildSample%"] == ["1"] (
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
if ["%toClean%"] == ["1"] (
|
|
||||||
rmdir /S /Q %aWorkDirSmpl%"
|
|
||||||
rmdir /S /Q %aDestDirSmpl%"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
if not exist "%aWorkDirSmpl%" ( mkdir "%aWorkDirSmpl%" )
|
|
||||||
if exist "%aLogFileSmpl%" ( del "%aLogFileSmpl%" )
|
|
||||||
)
|
|
||||||
|
|
||||||
rem include some information about OCCT into archive
|
|
||||||
echo ^<pre^>> "%aWorkDir%\VERSION.html"
|
|
||||||
git status >> "%aWorkDir%\VERSION.html"
|
|
||||||
git log -n 100 >> "%aWorkDir%\VERSION.html"
|
|
||||||
echo ^</pre^>>> "%aWorkDir%\VERSION.html"
|
|
||||||
|
|
||||||
echo Start building OCCT for %aPlatformAndCompiler%
|
|
||||||
echo Start building OCCT for %aPlatformAndCompiler%>> %aLogFile%
|
|
||||||
|
|
||||||
echo --->> %aLogFile%
|
|
||||||
call emcc --version >> %aLogFile%
|
|
||||||
echo --->> %aLogFile%
|
|
||||||
|
|
||||||
pushd "%aWorkDir%"
|
|
||||||
|
|
||||||
set "aTimeZERO=%TIME%"
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
echo Configuring OCCT for WASM...
|
|
||||||
cmake -G "MinGW Makefiles" ^
|
|
||||||
-D CMAKE_TOOLCHAIN_FILE:FILEPATH="%aToolchain%" ^
|
|
||||||
-D CMAKE_BUILD_TYPE:STRING="%aBuildType%" ^
|
|
||||||
-D BUILD_LIBRARY_TYPE:STRING="Static" ^
|
|
||||||
-D CMAKE_CXX_FLAGS="%anExtraCxxFlags%" ^
|
|
||||||
-D INSTALL_DIR:PATH="%aDestDir%" ^
|
|
||||||
-D INSTALL_DIR_INCLUDE:STRING="inc" ^
|
|
||||||
-D INSTALL_DIR_RESOURCE:STRING="src" ^
|
|
||||||
-D BUILD_MODULE_FoundationClasses:BOOL="ON" ^
|
|
||||||
-D BUILD_MODULE_ModelingData:BOOL="%BUILD_ModelingData%" ^
|
|
||||||
-D BUILD_MODULE_ModelingAlgorithms:BOOL="%BUILD_ModelingAlgorithms%" ^
|
|
||||||
-D BUILD_MODULE_Visualization:BOOL="%BUILD_Visualization%" ^
|
|
||||||
-D BUILD_MODULE_ApplicationFramework:BOOL="%BUILD_ApplicationFramework%" ^
|
|
||||||
-D BUILD_MODULE_DataExchange:BOOL="%BUILD_DataExchange%" ^
|
|
||||||
-D BUILD_MODULE_Draw:BOOL="%BUILD_Draw%" ^
|
|
||||||
-D BUILD_DOC_Overview:BOOL="OFF" ^
|
|
||||||
-D USE_FREETYPE:BOOL="%USE_FREETYPE%" ^
|
|
||||||
-D 3RDPARTY_FREETYPE_DIR:PATH="%aFreeType%" ^
|
|
||||||
-D 3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2:FILEPATH="%aFreeType%/include" ^
|
|
||||||
-D 3RDPARTY_FREETYPE_INCLUDE_DIR_ft2build:FILEPATH="%aFreeType%/include" ^
|
|
||||||
-D USE_RAPIDJSON:BOOL="%USE_RAPIDJSON%" ^
|
|
||||||
-D 3RDPARTY_RAPIDJSON_DIR:PATH="%aRapidJson%" ^
|
|
||||||
-D 3RDPARTY_RAPIDJSON_INCLUDE_DIR:PATH="%aRapidJson%/include" ^
|
|
||||||
-D USE_DRACO:BOOL="%USE_DRACO%" ^
|
|
||||||
-D 3RDPARTY_DRACO_DIR:PATH="%aDraco%" ^
|
|
||||||
-D 3RDPARTY_DRACO_INCLUDE_DIR:FILEPATH="%aDraco%/include" ^
|
|
||||||
-D 3RDPARTY_DRACO_LIBRARY_DIR:PATH="%aDraco%/lib" ^
|
|
||||||
-D 3RDPARTY_DRACO_LIBRARY:FILEPATH="%aDraco%/lib/libdraco.a" ^
|
|
||||||
-D USE_TK:BOOL="OFF" ^
|
|
||||||
-D 3RDPARTY_TCL_DIR:PATH="%aTcl%" ^
|
|
||||||
-D 3RDPARTY_TCL_INCLUDE_DIR:PATH="%aTcl%/include" ^
|
|
||||||
-D 3RDPARTY_TCL_LIBRARY_DIR:PATH="%aTcl%/lib" ^
|
|
||||||
-D 3RDPARTY_TCL_LIBRARY:FILEPATH="%aTcl%/lib/libtcl.a" ^
|
|
||||||
"%aCasSrc%"
|
|
||||||
|
|
||||||
if errorlevel 1 (
|
|
||||||
popd
|
|
||||||
exit /B 1
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
)
|
|
||||||
set "aTimeGEN=%TIME%"
|
|
||||||
call :computeDuration %aTimeZERO% %aTimeGEN%
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
echo Generation time: %DURATION%
|
|
||||||
echo Generation time: %DURATION%>> "%aLogFile%"
|
|
||||||
)
|
|
||||||
|
|
||||||
if ["%toClean%"] == ["1"] (
|
|
||||||
mingw32-make clean
|
|
||||||
)
|
|
||||||
|
|
||||||
if ["%toMake%"] == ["1"] (
|
|
||||||
echo Building...
|
|
||||||
mingw32-make -j %aNbJobs% 2>> "%aLogFile%"
|
|
||||||
if errorlevel 1 (
|
|
||||||
type "%aLogFile%"
|
|
||||||
popd
|
|
||||||
exit /B 1
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
type "%aLogFile%"
|
|
||||||
)
|
|
||||||
set "aTimeBUILD=%TIME%"
|
|
||||||
call :computeDuration %aTimeGEN% %aTimeBUILD%
|
|
||||||
if ["%toMake%"] == ["1"] (
|
|
||||||
echo Building time: %DURATION%
|
|
||||||
echo Building time: %DURATION%>> "%aLogFile%"
|
|
||||||
)
|
|
||||||
call :computeDuration %aTimeZERO% %aTimeBUILD%
|
|
||||||
if ["%toMake%"] == ["1"] (
|
|
||||||
echo Total building time: %DURATION%
|
|
||||||
echo Total building time: %DURATION%>> "%aLogFile%"
|
|
||||||
)
|
|
||||||
|
|
||||||
if ["%toInstall%"] == ["1"] (
|
|
||||||
echo Installing into %aDestDir%...
|
|
||||||
mingw32-make install 2>> "%aLogFile%"
|
|
||||||
copy /Y "%aWorkDir%\VERSION.html" "%aDestDir%\VERSION.html"
|
|
||||||
)
|
|
||||||
set "aTimeINSTALL=%TIME%"
|
|
||||||
call :computeDuration "%aTimeBUILD%" "%aTimeINSTALL%"
|
|
||||||
if ["%toInstall%"] == ["1"] (
|
|
||||||
echo Install time: %DURATION%
|
|
||||||
echo Install time: %DURATION%>> "%aLogFile%"
|
|
||||||
)
|
|
||||||
|
|
||||||
call :computeDuration "%aTimeZERO%" "%aTimeINSTALL%"
|
|
||||||
echo Total time: %DURATION%
|
|
||||||
echo Total time: %DURATION%>> "%aLogFile%"
|
|
||||||
|
|
||||||
popd
|
|
||||||
if ["%toBuildSample%"] == ["0"] (
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
|
|
||||||
pushd "%aWorkDirSmpl%"
|
|
||||||
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
cmake -G "MinGW Makefiles" ^
|
|
||||||
-D CMAKE_TOOLCHAIN_FILE:FILEPATH="%aToolchain%" ^
|
|
||||||
-D CMAKE_BUILD_TYPE:STRING="%aBuildType%" ^
|
|
||||||
-D CMAKE_CXX_FLAGS="%anExtraCxxFlags%" ^
|
|
||||||
-D CMAKE_INSTALL_PREFIX:PATH="%aDestDirSmpl%" ^
|
|
||||||
-D SOURCE_MAP_BASE:STRING="%sourceMapBase%" ^
|
|
||||||
-D OpenCASCADE_DIR:PATH="%aDestDir%/lib/cmake/opencascade" ^
|
|
||||||
-D freetype_DIR:PATH="%aFreeType%/lib/cmake/freetype" ^
|
|
||||||
"%aSrcRootSmpl%"
|
|
||||||
|
|
||||||
if errorlevel 1 (
|
|
||||||
popd
|
|
||||||
pause
|
|
||||||
exit /B
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
)
|
|
||||||
if ["%toClean%"] == ["1"] (
|
|
||||||
mingw32-make clean
|
|
||||||
)
|
|
||||||
|
|
||||||
if ["%toMake%"] == ["1"] (
|
|
||||||
echo Building...
|
|
||||||
mingw32-make -j %aNbJobs% 2>> "%aLogFileSmpl%"
|
|
||||||
if errorlevel 1 (
|
|
||||||
type "%aLogFileSmpl%"
|
|
||||||
popd
|
|
||||||
pause
|
|
||||||
exit /B
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
type "%aLogFileSmpl%"
|
|
||||||
)
|
|
||||||
|
|
||||||
if ["%toInstall%"] == ["1"] (
|
|
||||||
mingw32-make install 2>> "%aLogFileSmpl%"
|
|
||||||
if errorlevel 1 (
|
|
||||||
type "%aLogFileSmpl%"
|
|
||||||
popd
|
|
||||||
pause
|
|
||||||
exit /B
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
)
|
|
||||||
popd
|
|
||||||
|
|
||||||
goto :eof
|
|
||||||
|
|
||||||
:computeDuration
|
|
||||||
set "aTimeFrom=%~1"
|
|
||||||
set "aTimeEnd=%~2"
|
|
||||||
rem handle time before 10AM (win10 - remove empty space at the beginning)
|
|
||||||
if "%aTimeFrom:~0,1%"==" " set "aTimeFrom=%aTimeFrom:~1%"
|
|
||||||
if "%aTimeEnd:~0,1%"==" " set "aTimeEnd=%aTimeEnd:~1%"
|
|
||||||
rem handle time before 10AM (win7 - add 0 at the beginning)
|
|
||||||
if "%aTimeFrom:~1,1%"==":" set "aTimeFrom=0%aTimeFrom%"
|
|
||||||
if "%aTimeEnd:~1,1%"==":" set "aTimeEnd=0%aTimeEnd%"
|
|
||||||
rem convert hours:minutes:seconds:ms into duration
|
|
||||||
set /A aTimeFrom=(1%aTimeFrom:~0,2%-100)*360000 + (1%aTimeFrom:~3,2%-100)*6000 + (1%aTimeFrom:~6,2%-100)*100 + (1%aTimeFrom:~9,2%-100)
|
|
||||||
set /A aTimeEnd= (1%aTimeEnd:~0,2%-100)*360000 + (1%aTimeEnd:~3,2%-100)*6000 + (1%aTimeEnd:~6,2%-100)*100 + (1%aTimeEnd:~9,2%-100)
|
|
||||||
set /A aDurTotalSec=%aTimeEnd%-%aTimeFrom%
|
|
||||||
if %aTimeEnd% LSS %aTimeFrom% set set /A aDurTotalSec=%aTimeFrom%-%aTimeEnd%
|
|
||||||
set /A aDurHH=%aDurTotalSec% / 360000
|
|
||||||
set /A aDurMM=(%aDurTotalSec% - %aDurHH%*360000) / 6000
|
|
||||||
set /A aDurSS=(%aDurTotalSec% - %aDurHH%*360000 - %aDurMM%*6000) / 100
|
|
||||||
if %aDurHH% LSS 10 set aDurHH=0%aDurHH%
|
|
||||||
if %aDurMM% LSS 10 set aDurMM=0%aDurMM%
|
|
||||||
if %aDurSS% LSS 10 set aDurSS=0%aDurSS%
|
|
||||||
|
|
||||||
set "DURATION=%aDurHH%:%aDurMM%:%aDurSS%"
|
|
||||||
goto :eof
|
|
@@ -1,126 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# Auxiliary script for semi-automated building of OCCT for WASM platform.
|
|
||||||
# wasm_custom.sh should be configured with paths to CMake, 3rd-parties and Emscripten SDK.
|
|
||||||
# FreeType should be specified as mandatory dependency.
|
|
||||||
|
|
||||||
export aScriptDir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
|
|
||||||
export aSrcRoot="${aScriptDir}/../.."
|
|
||||||
export aBuildRoot=work
|
|
||||||
|
|
||||||
export aNbJobs=${NUMBER_OF_PROCESSORS}
|
|
||||||
|
|
||||||
export toCMake=1
|
|
||||||
export toClean=0
|
|
||||||
export toMake=1
|
|
||||||
export toInstall=1
|
|
||||||
|
|
||||||
export BUILD_ModelingData=ON
|
|
||||||
export BUILD_ModelingAlgorithms=ON
|
|
||||||
export BUILD_Visualization=ON
|
|
||||||
export BUILD_ApplicationFramework=ON
|
|
||||||
export BUILD_DataExchange=ON
|
|
||||||
|
|
||||||
if [ -f "${aScriptDir}/wasm_custom.sh" ] ; then
|
|
||||||
. "${aScriptDir}/wasm_custom.sh"
|
|
||||||
fi
|
|
||||||
|
|
||||||
. "${EMSDK_ROOT}/emsdk_env.sh"
|
|
||||||
|
|
||||||
export aToolchain="${EMSDK}/upstream/emscripten/cmake/Modules/Platform/Emscripten.cmake"
|
|
||||||
|
|
||||||
export aGitBranch=`git symbolic-ref --short HEAD`
|
|
||||||
|
|
||||||
echo "Compilation OCCT branch : $aGitBranch"
|
|
||||||
|
|
||||||
export aPlatformAndCompiler=wasm
|
|
||||||
|
|
||||||
export aWorkDir="${aSrcRoot}/${aBuildRoot}/${aPlatformAndCompiler}-make"
|
|
||||||
if [ ! -d "${aWorkDir}" ]; then
|
|
||||||
mkdir -p "${aWorkDir}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
export aDestDir="${aSrcRoot}/${aBuildRoot}/${aPlatformAndCompiler}"
|
|
||||||
if [ ! -d "${aDestDir}" ]; then
|
|
||||||
mkdir -p "${aDestDir}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
export aLogFile="${aSrcRoot}/${aBuildRoot}/build-${aPlatformAndCompiler}.log"
|
|
||||||
if [ -f "${aLogFile}" ]; then
|
|
||||||
rm "${aLogFile}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo Start building OCCT for ${aPlatformAndCompiler}
|
|
||||||
echo Start building OCCT for ${aPlatformAndCompiler}>> "${aLogFile}"
|
|
||||||
|
|
||||||
pushd "${aWorkDir}"
|
|
||||||
pwd
|
|
||||||
echo toCMake=${toCMake}
|
|
||||||
if [ "${toCMake}" = "1" ]; then
|
|
||||||
|
|
||||||
echo "Configuring OCCT for WASM..."
|
|
||||||
echo cmake -G "Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE:FILEPATH="${aToolchain}" \
|
|
||||||
-DCMAKE_BUILD_TYPE:STRING="Release" \
|
|
||||||
-DBUILD_LIBRARY_TYPE:STRING="Static" \
|
|
||||||
-DINSTALL_DIR:PATH="${aDestDir}" \
|
|
||||||
-DINSTALL_DIR_INCLUDE:STRING="inc" \
|
|
||||||
-DINSTALL_DIR_RESOURCE:STRING="src" \
|
|
||||||
-D3RDPARTY_FREETYPE_DIR:PATH="$aFreeType" \
|
|
||||||
-D3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2:FILEPATH="$aFreeType/include" \
|
|
||||||
-D3RDPARTY_FREETYPE_INCLUDE_DIR_ft2build:FILEPATH="$aFreeType/include" \
|
|
||||||
-DBUILD_MODULE_FoundationClasses:BOOL="ON" \
|
|
||||||
-DBUILD_MODULE_ModelingData:BOOL="${BUILD_ModelingData}" \
|
|
||||||
-DBUILD_MODULE_ModelingAlgorithms:BOOL="${BUILD_ModelingAlgorithms}" \
|
|
||||||
-DBUILD_MODULE_Visualization:BOOL="${BUILD_Visualization}" \
|
|
||||||
-DBUILD_MODULE_ApplicationFramework:BOOL="${BUILD_ApplicationFramework}" \
|
|
||||||
-DBUILD_MODULE_DataExchange:BOOL="${BUILD_DataExchange}" \
|
|
||||||
-DBUILD_MODULE_Draw:BOOL="OFF" \
|
|
||||||
-DBUILD_DOC_Overview:BOOL="OFF" "${aSrcRoot}"
|
|
||||||
|
|
||||||
cmake -G "Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE:FILEPATH="${aToolchain}" \
|
|
||||||
-DCMAKE_BUILD_TYPE:STRING="Release" \
|
|
||||||
-DBUILD_LIBRARY_TYPE:STRING="Static" \
|
|
||||||
-DINSTALL_DIR:PATH="${aDestDir}" \
|
|
||||||
-DINSTALL_DIR_INCLUDE:STRING="inc" \
|
|
||||||
-DINSTALL_DIR_RESOURCE:STRING="src" \
|
|
||||||
-D3RDPARTY_FREETYPE_DIR:PATH="$aFreeType" \
|
|
||||||
-D3RDPARTY_FREETYPE_INCLUDE_DIR_freetype2:FILEPATH="$aFreeType/include" \
|
|
||||||
-D3RDPARTY_FREETYPE_INCLUDE_DIR_ft2build:FILEPATH="$aFreeType/include" \
|
|
||||||
-DBUILD_MODULE_FoundationClasses:BOOL="ON" \
|
|
||||||
-DBUILD_MODULE_ModelingData:BOOL="${BUILD_ModelingData}" \
|
|
||||||
-DBUILD_MODULE_ModelingAlgorithms:BOOL="${BUILD_ModelingAlgorithms}" \
|
|
||||||
-DBUILD_MODULE_Visualization:BOOL="${BUILD_Visualization}" \
|
|
||||||
-DBUILD_MODULE_ApplicationFramework:BOOL="${BUILD_ApplicationFramework}" \
|
|
||||||
-DBUILD_MODULE_DataExchange:BOOL="${BUILD_DataExchange}" \
|
|
||||||
-DBUILD_MODULE_Draw:BOOL="OFF" \
|
|
||||||
-DBUILD_DOC_Overview:BOOL="OFF" "${aSrcRoot}"
|
|
||||||
|
|
||||||
if [ $? -ne 0 ]; then
|
|
||||||
echo "Problem during configuration"
|
|
||||||
popd
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "${toClean}" = "1" ]; then
|
|
||||||
make clean
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "${toMake}" = "1" ]; then
|
|
||||||
echo Building...
|
|
||||||
make -j ${aNbJobs} 2>> "${aLogFile}"
|
|
||||||
if [ $? -ne 0 ]; then
|
|
||||||
echo "Problem during make operation"
|
|
||||||
popd
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
echo "${aLogFile}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "${toInstall}" = "1" ]; then
|
|
||||||
echo Installing into ${aDestDir}
|
|
||||||
make install 2>> "${aLogFile}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
popd
|
|
@@ -1,29 +0,0 @@
|
|||||||
rem Environment configuration template for wasm_build.bat (to be renamed as wasm_custom.bat)
|
|
||||||
set "EMSDK_ROOT=%aCasSrc%\..\emsdk"
|
|
||||||
set "aFreeType=%aCasSrc%\..\3rdparty\freetype-2.7.1-wasm32"
|
|
||||||
rem set "aRapidJson=%aCasSrc%\..\3rdparty\rapidjson-1.1.0"
|
|
||||||
rem set "aDraco=%aCasSrc%\..\3rdparty\draco-1.4.1-wasm32"
|
|
||||||
rem set "aCmakeBin=%ProgramW6432%\CMake\bin"
|
|
||||||
|
|
||||||
rem Uncomment to customize building steps
|
|
||||||
rem set "aBuildRoot=work"
|
|
||||||
rem set "toCMake=1"
|
|
||||||
rem set "toClean=1"
|
|
||||||
rem set "toMake=1"
|
|
||||||
rem set "toInstall=1"
|
|
||||||
rem set "toPack=1"
|
|
||||||
rem set "toDebug=1"
|
|
||||||
rem set "toBuildSample=1"
|
|
||||||
rem Source map base (should point to server where C++ sources will be copied)
|
|
||||||
rem enables -g4 debug building option for WebGL sample and allows navigating C++ source code within JavaScript debugger.
|
|
||||||
rem set "sourceMapBase=http://localhost:9090/"
|
|
||||||
|
|
||||||
rem set "BUILD_ModelingData=ON"
|
|
||||||
rem set "BUILD_ModelingAlgorithms=ON"
|
|
||||||
rem set "BUILD_Visualization=ON"
|
|
||||||
rem set "BUILD_ApplicationFramework=ON"
|
|
||||||
rem set "BUILD_DataExchange=ON"
|
|
||||||
|
|
||||||
rem set "USE_RAPIDJSON=ON"
|
|
||||||
rem set "USE_DRACO=ON"
|
|
||||||
rem set "USE_PTHREADS=ON"
|
|
@@ -1,16 +0,0 @@
|
|||||||
# environment configuration template for occ_build_wasm.sh (to be renamed as wasm_custom_env.sh)
|
|
||||||
export aFreeType="$aSrcRoot/../3rdparty/freetype-2.7.1-wasm"
|
|
||||||
export EMSDK_ROOT="$aSrcRoot/../emsdk"
|
|
||||||
|
|
||||||
# Uncomment to customize building steps
|
|
||||||
#export aBuildRoot=work
|
|
||||||
#export toCMake=1
|
|
||||||
#export toClean=0
|
|
||||||
#export toMake=1
|
|
||||||
#export toInstall=1
|
|
||||||
|
|
||||||
#export BUILD_ModelingData=ON
|
|
||||||
#export BUILD_ModelingAlgorithms=ON
|
|
||||||
#export BUILD_Visualization=ON
|
|
||||||
#export BUILD_ApplicationFramework=ON
|
|
||||||
#export BUILD_DataExchange=ON
|
|
@@ -1,117 +0,0 @@
|
|||||||
@echo OFF
|
|
||||||
|
|
||||||
rem Auxiliary script for semi-automated building of WebGL sample.
|
|
||||||
rem wasm_custom.bat should be configured with paths to CMake, 3rd-parties and Emscripten SDK.
|
|
||||||
rem FreeType should be specified as mandatory dependency.
|
|
||||||
|
|
||||||
set "aCasSrc=%~dp0..\.."
|
|
||||||
set "aBuildRoot=%aCasSrc%\work"
|
|
||||||
|
|
||||||
set aNbJobs=%NUMBER_OF_PROCESSORS%
|
|
||||||
|
|
||||||
rem Paths to 3rd-party tools and libraries
|
|
||||||
set "aCmakeBin="
|
|
||||||
set "aFreeType="
|
|
||||||
|
|
||||||
rem Build stages to perform
|
|
||||||
set "toCMake=1"
|
|
||||||
set "toClean=0"
|
|
||||||
set "toMake=1"
|
|
||||||
set "toInstall=1"
|
|
||||||
set "toDebug=0"
|
|
||||||
set "sourceMapBase="
|
|
||||||
|
|
||||||
set "USE_PTHREADS=OFF"
|
|
||||||
|
|
||||||
rem Configuration file
|
|
||||||
if exist "%~dp0wasm_custom.bat" call "%~dp0wasm_custom.bat"
|
|
||||||
|
|
||||||
call "%EMSDK_ROOT%\emsdk_env.bat"
|
|
||||||
set "aToolchain=%EMSDK%/upstream/emscripten/cmake/Modules/Platform/Emscripten.cmake"
|
|
||||||
if not ["%aCmakeBin%"] == [""] ( set "PATH=%aCmakeBin%;%PATH%" )
|
|
||||||
|
|
||||||
set "aBuildType=Release"
|
|
||||||
set "aBuildTypePrefix="
|
|
||||||
set "anExtraCxxFlags="
|
|
||||||
if /I ["%USE_PTHREADS%"] == ["ON"] (
|
|
||||||
set "anExtraCxxFlags=-pthread"
|
|
||||||
set "aBuildTypePrefix=%aBuildTypePrefix%-pthread"
|
|
||||||
)
|
|
||||||
if ["%toDebug%"] == ["1"] (
|
|
||||||
set "aBuildType=Debug"
|
|
||||||
set "aBuildTypePrefix=%aBuildTypePrefix%-debug"
|
|
||||||
)
|
|
||||||
|
|
||||||
call :cmakeGenerate
|
|
||||||
if not ["%1"] == ["-nopause"] (
|
|
||||||
pause
|
|
||||||
)
|
|
||||||
|
|
||||||
goto :eof
|
|
||||||
|
|
||||||
:cmakeGenerate
|
|
||||||
set "aPlatformAndCompiler=wasm32%aBuildTypePrefix%"
|
|
||||||
set "aDestDirOcct=%aBuildRoot%\occt-%aPlatformAndCompiler%"
|
|
||||||
set "aSrcRootSmpl=%aCasSrc%\samples\webgl"
|
|
||||||
set "aWorkDirSmpl=%aBuildRoot%\sample-%aPlatformAndCompiler%-make"
|
|
||||||
set "aDestDirSmpl=%aBuildRoot%\sample-%aPlatformAndCompiler%"
|
|
||||||
set "aLogFileSmpl=%aBuildRoot%\sample-%aPlatformAndCompiler%-build.log"
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
if ["%toClean%"] == ["1"] (
|
|
||||||
rmdir /S /Q %aWorkDirSmpl%"
|
|
||||||
rmdir /S /Q %aDestDirSmpl%"
|
|
||||||
)
|
|
||||||
)
|
|
||||||
if not exist "%aWorkDirSmpl%" ( mkdir "%aWorkDirSmpl%" )
|
|
||||||
if exist "%aLogFileSmpl%" ( del "%aLogFileSmpl%" )
|
|
||||||
|
|
||||||
pushd "%aWorkDirSmpl%"
|
|
||||||
|
|
||||||
if ["%toCMake%"] == ["1"] (
|
|
||||||
cmake -G "MinGW Makefiles" ^
|
|
||||||
-D CMAKE_TOOLCHAIN_FILE:FILEPATH="%aToolchain%" ^
|
|
||||||
-D CMAKE_BUILD_TYPE:STRING="%aBuildType%" ^
|
|
||||||
-D CMAKE_CXX_FLAGS="%anExtraCxxFlags%" ^
|
|
||||||
-D CMAKE_INSTALL_PREFIX:PATH="%aDestDirSmpl%" ^
|
|
||||||
-D SOURCE_MAP_BASE:STRING="%sourceMapBase%" ^
|
|
||||||
-D OpenCASCADE_DIR:PATH="%aDestDirOcct%/lib/cmake/opencascade" ^
|
|
||||||
-D freetype_DIR:PATH="%aFreeType%/lib/cmake/freetype" ^
|
|
||||||
"%aSrcRootSmpl%"
|
|
||||||
|
|
||||||
if errorlevel 1 (
|
|
||||||
popd
|
|
||||||
pause
|
|
||||||
exit /B
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
)
|
|
||||||
if ["%toClean%"] == ["1"] (
|
|
||||||
mingw32-make clean
|
|
||||||
)
|
|
||||||
|
|
||||||
if ["%toMake%"] == ["1"] (
|
|
||||||
echo Building...
|
|
||||||
mingw32-make -j %aNbJobs% 2>> "%aLogFileSmpl%"
|
|
||||||
if errorlevel 1 (
|
|
||||||
type "%aLogFileSmpl%"
|
|
||||||
popd
|
|
||||||
pause
|
|
||||||
exit /B
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
type "%aLogFileSmpl%"
|
|
||||||
)
|
|
||||||
|
|
||||||
if ["%toInstall%"] == ["1"] (
|
|
||||||
mingw32-make install 2>> "%aLogFileSmpl%"
|
|
||||||
if errorlevel 1 (
|
|
||||||
type "%aLogFileSmpl%"
|
|
||||||
popd
|
|
||||||
pause
|
|
||||||
exit /B
|
|
||||||
goto :eof
|
|
||||||
)
|
|
||||||
)
|
|
||||||
popd
|
|
||||||
|
|
||||||
goto :eof
|
|
@@ -21,7 +21,6 @@ set (OpenCASCADE_DEVELOPMENT_VERSION "@OCC_VERSION_DEVELOPMENT@")
|
|||||||
# This is made to support different locations of CMake files:
|
# This is made to support different locations of CMake files:
|
||||||
# - in UNIX style: $INSTALL_DIR/lib/cmake/opencascade-<version>
|
# - in UNIX style: $INSTALL_DIR/lib/cmake/opencascade-<version>
|
||||||
# - in Windows style: $INSTALL_DIR/cmake
|
# - in Windows style: $INSTALL_DIR/cmake
|
||||||
# - in Android style: $INSTALL_DIR/libs/$CMAKE_ANDROID_ARCH_ABI/cmake/opencascade-<version>
|
|
||||||
get_filename_component (OpenCASCADE_INSTALL_PREFIX "${CMAKE_CURRENT_LIST_FILE}" PATH)
|
get_filename_component (OpenCASCADE_INSTALL_PREFIX "${CMAKE_CURRENT_LIST_FILE}" PATH)
|
||||||
get_filename_component (OpenCASCADE_INSTALL_PREFIX "${OpenCASCADE_INSTALL_PREFIX}" PATH)
|
get_filename_component (OpenCASCADE_INSTALL_PREFIX "${OpenCASCADE_INSTALL_PREFIX}" PATH)
|
||||||
if (OpenCASCADE_INSTALL_PREFIX MATCHES "/cmake$")
|
if (OpenCASCADE_INSTALL_PREFIX MATCHES "/cmake$")
|
||||||
@@ -30,10 +29,6 @@ endif()
|
|||||||
if (OpenCASCADE_INSTALL_PREFIX MATCHES "/lib$")
|
if (OpenCASCADE_INSTALL_PREFIX MATCHES "/lib$")
|
||||||
get_filename_component (OpenCASCADE_INSTALL_PREFIX "${OpenCASCADE_INSTALL_PREFIX}" PATH)
|
get_filename_component (OpenCASCADE_INSTALL_PREFIX "${OpenCASCADE_INSTALL_PREFIX}" PATH)
|
||||||
endif()
|
endif()
|
||||||
if (OpenCASCADE_INSTALL_PREFIX MATCHES "/libs/${CMAKE_ANDROID_ARCH_ABI}$")
|
|
||||||
get_filename_component (OpenCASCADE_INSTALL_PREFIX "${OpenCASCADE_INSTALL_PREFIX}" PATH)
|
|
||||||
get_filename_component (OpenCASCADE_INSTALL_PREFIX "${OpenCASCADE_INSTALL_PREFIX}" PATH)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# Set OpenCASCADE paths to headers, binaries, libraries, resources, tests, samples, data
|
# Set OpenCASCADE paths to headers, binaries, libraries, resources, tests, samples, data
|
||||||
set (OpenCASCADE_BINARY_DIR "${OpenCASCADE_INSTALL_PREFIX}/@INSTALL_DIR_BIN@")
|
set (OpenCASCADE_BINARY_DIR "${OpenCASCADE_INSTALL_PREFIX}/@INSTALL_DIR_BIN@")
|
||||||
|
@@ -1,38 +0,0 @@
|
|||||||
@echo off
|
|
||||||
setlocal
|
|
||||||
|
|
||||||
rem Setup environment
|
|
||||||
call "%~dp0env.bat" %1 %2 %3
|
|
||||||
|
|
||||||
rem Define path to project file
|
|
||||||
set "PRJFILE=%~dp0OCCT.sln"
|
|
||||||
|
|
||||||
if "%VCVER%" == "vc8" (
|
|
||||||
call "%VS80COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc9" (
|
|
||||||
call "%VS90COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc10" (
|
|
||||||
call "%VS100COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc11" (
|
|
||||||
call "%VS110COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc12" (
|
|
||||||
call "%VS120COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc14" (
|
|
||||||
call "%VS140COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc141" (
|
|
||||||
call "%VS141COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc142" (
|
|
||||||
call "%VS142COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else (
|
|
||||||
echo Error: wrong VS identifier
|
|
||||||
exit /B
|
|
||||||
)
|
|
||||||
|
|
||||||
set BUILDCONFIG=Release
|
|
||||||
if "%CASDEB%"=="i" set BUILDCONFIG=RelWithDebInfo
|
|
||||||
if "%CASDEB%"=="d" set BUILDCONFIG=Debug
|
|
||||||
if "%ARCH%"=="32" set PLATFORM=win32
|
|
||||||
if "%ARCH%"=="64" set PLATFORM=x64
|
|
||||||
|
|
||||||
msbuild "%PRJFILE%" /m /fl /flp:LogFile="build_%BUILDCONFIG%.log" /p:Configuration=%BUILDCONFIG% /p:Platform=%PLATFORM% /p:BuildProjectReferences=false
|
|
||||||
endlocal
|
|
@@ -14,7 +14,6 @@ if /I "%VCVER%" == "@COMPILER@" (
|
|||||||
set "TBB_DIR=@3RDPARTY_TBB_DLL_DIR@"
|
set "TBB_DIR=@3RDPARTY_TBB_DLL_DIR@"
|
||||||
set "VTK_DIR=@3RDPARTY_VTK_DLL_DIR@"
|
set "VTK_DIR=@3RDPARTY_VTK_DLL_DIR@"
|
||||||
set "FFMPEG_DIR=@3RDPARTY_FFMPEG_DLL_DIR@"
|
set "FFMPEG_DIR=@3RDPARTY_FFMPEG_DLL_DIR@"
|
||||||
set "OPENVR_DIR=@3RDPARTY_OPENVR_DLL_DIRS@"
|
|
||||||
|
|
||||||
if not "@3RDPARTY_QT_DIR@" == "" (
|
if not "@3RDPARTY_QT_DIR@" == "" (
|
||||||
set "QTDIR=@3RDPARTY_QT_DIR@"
|
set "QTDIR=@3RDPARTY_QT_DIR@"
|
||||||
@@ -40,7 +39,7 @@ if /I "%VCVER%" == "@COMPILER@" (
|
|||||||
set "CSF_OCCTTestsPath=@CMAKE_SOURCE_DIR@/tests"
|
set "CSF_OCCTTestsPath=@CMAKE_SOURCE_DIR@/tests"
|
||||||
set "CSF_OCCTDocPath=@CMAKE_SOURCE_DIR@/doc"
|
set "CSF_OCCTDocPath=@CMAKE_SOURCE_DIR@/doc"
|
||||||
|
|
||||||
rem for compatibility with external application using CASROOT
|
rem for compatability with external application using CASROOT
|
||||||
set "CASROOT=@CMAKE_SOURCE_DIR@"
|
set "CASROOT=@CMAKE_SOURCE_DIR@"
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
@@ -29,7 +29,7 @@ if [ "$1" == "@BIN_LETTER@" ]; then
|
|||||||
export CSF_OCCTTestsPath="@CMAKE_SOURCE_DIR@/tests"
|
export CSF_OCCTTestsPath="@CMAKE_SOURCE_DIR@/tests"
|
||||||
export CSF_OCCTDocPath="@CMAKE_SOURCE_DIR@/doc"
|
export CSF_OCCTDocPath="@CMAKE_SOURCE_DIR@/doc"
|
||||||
|
|
||||||
# for compatibility with external application using CASROOT
|
# for compatability with external application using CASROOT
|
||||||
export CASROOT="@CMAKE_SOURCE_DIR@"
|
export CASROOT="@CMAKE_SOURCE_DIR@"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
@@ -10,13 +10,12 @@ if /I "%VCVER%" == "@COMPILER@" (
|
|||||||
set "TCL_DIR=@USED_3RDPARTY_TCL_DIR@"
|
set "TCL_DIR=@USED_3RDPARTY_TCL_DIR@"
|
||||||
set "TK_DIR=@USED_3RDPARTY_TK_DIR@"
|
set "TK_DIR=@USED_3RDPARTY_TK_DIR@"
|
||||||
set "FREETYPE_DIR=@USED_3RDPARTY_FREETYPE_DIR@"
|
set "FREETYPE_DIR=@USED_3RDPARTY_FREETYPE_DIR@"
|
||||||
set "FREEIMAGE_DIR=@USED_3RDPARTY_FREEIMAGE_DIR@"
|
set "FREEIMAGE_DIR=@USED_3RDPARTY_FREEIMAGE_DIRS@"
|
||||||
set "EGL_DIR=@USED_3RDPARTY_EGL_DIRS@"
|
set "EGL_DIR=@USED_3RDPARTY_EGL_DIRS@"
|
||||||
set "GLES2_DIR=@USED_3RDPARTY_GLES2_DIRS@"
|
set "GLES2_DIR=@USED_3RDPARTY_GLES2_DIRS@"
|
||||||
set "TBB_DIR=@USED_3RDPARTY_TBB_DIR@"
|
set "TBB_DIR=@USED_3RDPARTY_TBB_DIR@"
|
||||||
set "VTK_DIR=@USED_3RDPARTY_VTK_DIR@"
|
set "VTK_DIR=@USED_3RDPARTY_VTK_DIR@"
|
||||||
set "FFMPEG_DIR=@USED_3RDPARTY_FFMPEG_DIR@"
|
set "FFMPEG_DIR=@USED_3RDPARTY_FFMPEG_DIR@"
|
||||||
set "OPENVR_DIR=@USED_3RDPARTY_OPENVR_DIR@"
|
|
||||||
|
|
||||||
if not "@USED_3RDPARTY_QT_DIR@" == "" (
|
if not "@USED_3RDPARTY_QT_DIR@" == "" (
|
||||||
set "QTDIR=@USED_3RDPARTY_QT_DIR@"
|
set "QTDIR=@USED_3RDPARTY_QT_DIR@"
|
||||||
|
@@ -17,8 +17,6 @@ set "ARCH=64"
|
|||||||
set "VCVARS="
|
set "VCVARS="
|
||||||
set "HAVE_TBB=false"
|
set "HAVE_TBB=false"
|
||||||
set "HAVE_OPENCL=false"
|
set "HAVE_OPENCL=false"
|
||||||
set "HAVE_TK=true"
|
|
||||||
set "HAVE_FREETYPE=true"
|
|
||||||
set "HAVE_FREEIMAGE=false"
|
set "HAVE_FREEIMAGE=false"
|
||||||
set "HAVE_FFMPEG=false"
|
set "HAVE_FFMPEG=false"
|
||||||
set "HAVE_VTK=false"
|
set "HAVE_VTK=false"
|
||||||
@@ -27,22 +25,12 @@ set "HAVE_D3D=false"
|
|||||||
set "HAVE_ZLIB=false"
|
set "HAVE_ZLIB=false"
|
||||||
set "HAVE_LIBLZMA=false"
|
set "HAVE_LIBLZMA=false"
|
||||||
set "HAVE_RAPIDJSON=false"
|
set "HAVE_RAPIDJSON=false"
|
||||||
set "HAVE_DRACO=false"
|
|
||||||
set "HAVE_OPENVR=false"
|
|
||||||
set "HAVE_E57=false"
|
set "HAVE_E57=false"
|
||||||
set "CSF_OPT_INC="
|
set "CSF_OPT_INC="
|
||||||
set "CSF_OPT_LIB32="
|
set "CSF_OPT_LIB32="
|
||||||
set "CSF_OPT_LIB64="
|
set "CSF_OPT_LIB64="
|
||||||
set "CSF_OPT_BIN32="
|
set "CSF_OPT_BIN32="
|
||||||
set "CSF_OPT_BIN64="
|
set "CSF_OPT_BIN64="
|
||||||
set "CSF_OPT_LIB32D="
|
|
||||||
set "CSF_OPT_LIB64D="
|
|
||||||
set "CSF_OPT_BIN32D="
|
|
||||||
set "CSF_OPT_BIN64D="
|
|
||||||
set "CSF_OPT_LIB32I="
|
|
||||||
set "CSF_OPT_LIB64I="
|
|
||||||
set "CSF_OPT_BIN32I="
|
|
||||||
set "CSF_OPT_BIN64I="
|
|
||||||
set "CSF_DEFINES=%CSF_DEFINES_EXTRA%"
|
set "CSF_DEFINES=%CSF_DEFINES_EXTRA%"
|
||||||
|
|
||||||
if not ["%CASROOT%"] == [""] if exist "%SCRIPTROOT%\%CASROOT%" set "CASROOT=%SCRIPTROOT%\%CASROOT%"
|
if not ["%CASROOT%"] == [""] if exist "%SCRIPTROOT%\%CASROOT%" set "CASROOT=%SCRIPTROOT%\%CASROOT%"
|
||||||
@@ -67,9 +55,9 @@ rem Decode VCVER variable and define related ones:
|
|||||||
rem
|
rem
|
||||||
rem VCFMT - "vc" followed by full version number of Visual Studio toolset
|
rem VCFMT - "vc" followed by full version number of Visual Studio toolset
|
||||||
rem (same as VCVER without optional suffix "-uwp")
|
rem (same as VCVER without optional suffix "-uwp")
|
||||||
rem VCLIB - name of folder containing binaries
|
rem VCLIB - name of folder contining binaries
|
||||||
rem (same as VCVER except without third version in number)
|
rem (same as VCVER except without third version in number)
|
||||||
rem VCPROP - name of required Visual Studio Workload (starting with VS 2017)
|
rem VCPROP - name of required Visual Studion Workload (starting with VS 2017)
|
||||||
rem
|
rem
|
||||||
rem Note that for VS before 2015 (vc14) always
|
rem Note that for VS before 2015 (vc14) always
|
||||||
rem VCFMT=VCLIB=VCVER and VCPROP=NativeDesktop
|
rem VCFMT=VCLIB=VCVER and VCPROP=NativeDesktop
|
||||||
@@ -89,9 +77,6 @@ if "%VCVER:~-4%" == "-uwp" (
|
|||||||
set VCLIB=%VCLIB%-uwp
|
set VCLIB=%VCLIB%-uwp
|
||||||
set VCPROP=Universal
|
set VCPROP=Universal
|
||||||
)
|
)
|
||||||
if "%VCFMT%" == "vclang" (
|
|
||||||
set VCLIB=vc14
|
|
||||||
)
|
|
||||||
rem echo VCVER=%VCVER% VCFMT=%VCFMT% VCLIB=%VCLIB% VCPROP=%VCPROP%
|
rem echo VCVER=%VCVER% VCFMT=%VCFMT% VCLIB=%VCLIB% VCPROP=%VCPROP%
|
||||||
|
|
||||||
rem ----- Parsing of Visual Studio platform -----
|
rem ----- Parsing of Visual Studio platform -----
|
||||||
@@ -121,14 +106,6 @@ if not "%DevEnvDir%" == "" (
|
|||||||
for /f "usebackq delims=" %%i in (`vswhere.exe -version "[16.0,16.99]" -latest -requires Microsoft.VisualStudio.Workload.%VCPROP% -property installationPath`) do (
|
for /f "usebackq delims=" %%i in (`vswhere.exe -version "[16.0,16.99]" -latest -requires Microsoft.VisualStudio.Workload.%VCPROP% -property installationPath`) do (
|
||||||
set "DevEnvDir=%%i\Common7\IDE\"
|
set "DevEnvDir=%%i\Common7\IDE\"
|
||||||
)
|
)
|
||||||
) else if /I "%VCFMT%" == "vc143" (
|
|
||||||
for /f "usebackq delims=" %%i in (`vswhere.exe -version "[17.0,17.99]" -latest -requires Microsoft.VisualStudio.Workload.%VCPROP% -property installationPath`) do (
|
|
||||||
set "DevEnvDir=%%i\Common7\IDE\"
|
|
||||||
)
|
|
||||||
) else if /I "%VCFMT%" == "vclang" (
|
|
||||||
for /f "usebackq delims=" %%i in (`vswhere.exe -version "[16.0,17.99]" -latest -requires Microsoft.VisualStudio.Workload.%VCPROP% -property installationPath`) do (
|
|
||||||
set "DevEnvDir=%%i\Common7\IDE\"
|
|
||||||
)
|
|
||||||
) else if /I "%VCFMT%" == "gcc" (
|
) else if /I "%VCFMT%" == "gcc" (
|
||||||
rem MinGW
|
rem MinGW
|
||||||
) else (
|
) else (
|
||||||
@@ -141,8 +118,6 @@ if not "%DevEnvDir%" == "" (
|
|||||||
echo vc14 = VS 2015
|
echo vc14 = VS 2015
|
||||||
echo vc141 = VS 2017
|
echo vc141 = VS 2017
|
||||||
echo vc142 = VS 2019
|
echo vc142 = VS 2019
|
||||||
echo vc143 = VS 2022
|
|
||||||
echo vclang = VS 2019 with ClangCL toolset
|
|
||||||
exit /B
|
exit /B
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -172,16 +147,6 @@ if /I "%VCFMT%" == "vc9" (
|
|||||||
set "VCVARS=%%i\VC\Auxiliary\Build\vcvarsall.bat"
|
set "VCVARS=%%i\VC\Auxiliary\Build\vcvarsall.bat"
|
||||||
)
|
)
|
||||||
set "VCPlatformToolSet=v142"
|
set "VCPlatformToolSet=v142"
|
||||||
) else if /I "%VCFMT%" == "vc143" (
|
|
||||||
for /f "usebackq delims=" %%i in (`vswhere.exe -version "[17.0,17.99]" -latest -requires Microsoft.VisualStudio.Workload.%VCPROP% -property installationPath`) do (
|
|
||||||
set "VCVARS=%%i\VC\Auxiliary\Build\vcvarsall.bat"
|
|
||||||
)
|
|
||||||
set "VCPlatformToolSet=v143"
|
|
||||||
) else if /I "%VCFMT%" == "vclang" (
|
|
||||||
for /f "usebackq delims=" %%i in (`vswhere.exe -version "[16.0,17.99]" -latest -requires Microsoft.VisualStudio.Workload.%VCPROP% -property installationPath`) do (
|
|
||||||
set "VCVARS=%%i\VC\Auxiliary\Build\vcvarsall.bat"
|
|
||||||
)
|
|
||||||
set "VCPlatformToolSet=ClangCL"
|
|
||||||
) else if /I "%VCFMT%" == "gcc" (
|
) else if /I "%VCFMT%" == "gcc" (
|
||||||
rem MinGW
|
rem MinGW
|
||||||
) else (
|
) else (
|
||||||
@@ -189,32 +154,28 @@ if /I "%VCFMT%" == "vc9" (
|
|||||||
exit /B
|
exit /B
|
||||||
)
|
)
|
||||||
|
|
||||||
if ["%CSF_OPT_LIB32D%"] == [""] set "CSF_OPT_LIB32D=%CSF_OPT_LIB32%"
|
set "CSF_OPT_LIB32D=%CSF_OPT_LIB32%"
|
||||||
if ["%CSF_OPT_LIB64D%"] == [""] set "CSF_OPT_LIB64D=%CSF_OPT_LIB64%"
|
set "CSF_OPT_LIB64D=%CSF_OPT_LIB64%"
|
||||||
if ["%CSF_OPT_BIN32D%"] == [""] set "CSF_OPT_BIN32D=%CSF_OPT_BIN32%"
|
set "CSF_OPT_BIN32D=%CSF_OPT_BIN32%"
|
||||||
if ["%CSF_OPT_BIN64D%"] == [""] set "CSF_OPT_BIN64D=%CSF_OPT_BIN64%"
|
set "CSF_OPT_BIN64D=%CSF_OPT_BIN64%"
|
||||||
if ["%CSF_OPT_LIB32I%"] == [""] set "CSF_OPT_LIB32I=%CSF_OPT_LIB32%"
|
set "CSF_OPT_LIB32I=%CSF_OPT_LIB32%"
|
||||||
if ["%CSF_OPT_LIB64I%"] == [""] set "CSF_OPT_LIB64I=%CSF_OPT_LIB64%"
|
set "CSF_OPT_LIB64I=%CSF_OPT_LIB64%"
|
||||||
if ["%CSF_OPT_BIN32I%"] == [""] set "CSF_OPT_BIN32I=%CSF_OPT_BIN32%"
|
set "CSF_OPT_BIN32I=%CSF_OPT_BIN32%"
|
||||||
if ["%CSF_OPT_BIN64I%"] == [""] set "CSF_OPT_BIN64I=%CSF_OPT_BIN64%"
|
set "CSF_OPT_BIN64I=%CSF_OPT_BIN64%"
|
||||||
|
|
||||||
rem ----- Optional 3rd-parties should be enabled by HAVE macros -----
|
rem ----- Optional 3rd-parties should be enabled by HAVE macros -----
|
||||||
set "CSF_OPT_CMPL="
|
set "CSF_OPT_CMPL="
|
||||||
set "PRODUCTS_DEFINES="
|
set "PRODUCTS_DEFINES="
|
||||||
if ["%HAVE_TBB%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_TBB" & set "CSF_DEFINES=HAVE_TBB;%CSF_DEFINES%"
|
if ["%HAVE_TBB%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_TBB" & set "CSF_DEFINES=HAVE_TBB;%CSF_DEFINES%"
|
||||||
if ["%HAVE_OPENCL%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_OPENCL" & set "CSF_DEFINES=HAVE_OPENCL;%CSF_DEFINES%"
|
if ["%HAVE_OPENCL%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_OPENCL" & set "CSF_DEFINES=HAVE_OPENCL;%CSF_DEFINES%"
|
||||||
if ["%HAVE_TK%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_TK" & set "CSF_DEFINES=HAVE_TK;%CSF_DEFINES%"
|
|
||||||
if ["%HAVE_FREETYPE%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_FREEIMAGE" & set "CSF_DEFINES=HAVE_FREETYPE;%CSF_DEFINES%"
|
|
||||||
if ["%HAVE_FREEIMAGE%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_FREEIMAGE" & set "CSF_DEFINES=HAVE_FREEIMAGE;%CSF_DEFINES%"
|
if ["%HAVE_FREEIMAGE%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_FREEIMAGE" & set "CSF_DEFINES=HAVE_FREEIMAGE;%CSF_DEFINES%"
|
||||||
if ["%HAVE_FFMPEG%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_FFMPEG" & set "CSF_DEFINES=HAVE_FFMPEG;%CSF_DEFINES%"
|
if ["%HAVE_FFMPEG%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_FFMPEG" & set "CSF_DEFINES=HAVE_FFMPEG;%CSF_DEFINES%"
|
||||||
if ["%HAVE_VTK%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_VTK" & set "CSF_DEFINES=HAVE_VTK;%CSF_DEFINES%"
|
if ["%HAVE_VTK%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_VTK" & set "CSF_DEFINES=HAVE_VTK;%CSF_DEFINES%"
|
||||||
if ["%HAVE_GLES2%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_GLES2_EXT" & set "CSF_DEFINES=HAVE_GLES2_EXT;%CSF_DEFINES%"
|
if ["%HAVE_GLES2%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_GLES2" & set "CSF_DEFINES=HAVE_GLES2;%CSF_DEFINES%"
|
||||||
if ["%HAVE_D3D%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_D3D" & set "CSF_DEFINES=HAVE_D3D;%CSF_DEFINES%"
|
if ["%HAVE_D3D%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_D3D" & set "CSF_DEFINES=HAVE_D3D;%CSF_DEFINES%"
|
||||||
if ["%HAVE_ZLIB%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_ZLIB" & set "CSF_DEFINES=HAVE_ZLIB;%CSF_DEFINES%"
|
if ["%HAVE_ZLIB%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_ZLIB" & set "CSF_DEFINES=HAVE_ZLIB;%CSF_DEFINES%"
|
||||||
if ["%HAVE_LIBLZMA%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_LIBLZMA" & set "CSF_DEFINES=HAVE_LIBLZMA;%CSF_DEFINES%"
|
if ["%HAVE_LIBLZMA%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_LIBLZMA" & set "CSF_DEFINES=HAVE_LIBLZMA;%CSF_DEFINES%"
|
||||||
if ["%HAVE_RAPIDJSON%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_RAPIDJSON" & set "CSF_DEFINES=HAVE_RAPIDJSON;%CSF_DEFINES%"
|
if ["%HAVE_RAPIDJSON%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_RAPIDJSON" & set "CSF_DEFINES=HAVE_RAPIDJSON;%CSF_DEFINES%"
|
||||||
if ["%HAVE_DRACO%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_DRACO" & set "CSF_DEFINES=HAVE_DRACO;%CSF_DEFINES%"
|
|
||||||
if ["%HAVE_OPENVR%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_OPENVR" & set "CSF_DEFINES=HAVE_OPENVR;%CSF_DEFINES%"
|
|
||||||
if ["%HAVE_E57%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_E57" & set "CSF_DEFINES=HAVE_E57;%CSF_DEFINES%"
|
if ["%HAVE_E57%"] == ["true"] set "PRODUCTS_DEFINES=%PRODUCTS_DEFINES% -DHAVE_E57" & set "CSF_DEFINES=HAVE_E57;%CSF_DEFINES%"
|
||||||
|
|
||||||
rem Eliminate VS warning
|
rem Eliminate VS warning
|
||||||
@@ -223,20 +184,20 @@ if ["%CSF_DEFINES%"] == [""] set "CSF_DEFINES=;"
|
|||||||
rem ----- Optional 3rd-parties should be enabled by HAVE macros -----
|
rem ----- Optional 3rd-parties should be enabled by HAVE macros -----
|
||||||
if not ["%PRODUCTS_DEFINES%"] == [""] set "CSF_OPT_CMPL=%CSF_OPT_CMPL% %PRODUCTS_DEFINES%"
|
if not ["%PRODUCTS_DEFINES%"] == [""] set "CSF_OPT_CMPL=%CSF_OPT_CMPL% %PRODUCTS_DEFINES%"
|
||||||
|
|
||||||
rem ----- Collect 3rd-parties additional include paths into compiler options -----
|
rem ----- Colect 3rd-parties additional include paths into compiler options -----
|
||||||
for %%a in ("%CSF_OPT_INC:;=";"%") do (
|
for %%a in ("%CSF_OPT_INC:;=";"%") do (
|
||||||
set "anItem=%%~a"
|
set "anItem=%%~a"
|
||||||
if not ["%%~a"] == [""] call :concatCmplInc %%~a
|
if not ["%%~a"] == [""] call :concatCmplInc %%~a
|
||||||
)
|
)
|
||||||
|
|
||||||
rem ----- Collect 3rd-parties additional library paths (32-bit) into linker options -----
|
rem ----- Colect 3rd-parties additional library paths (32-bit) into linker options -----
|
||||||
set "OPT_LIB32="
|
set "OPT_LIB32="
|
||||||
for %%a in ("%CSF_OPT_LIB32:;=";"%") do (
|
for %%a in ("%CSF_OPT_LIB32:;=";"%") do (
|
||||||
set "anItem=%%~a"
|
set "anItem=%%~a"
|
||||||
if not ["%%~a"] == [""] call :concatLib32 %%~a
|
if not ["%%~a"] == [""] call :concatLib32 %%~a
|
||||||
)
|
)
|
||||||
|
|
||||||
rem ----- Collect 3rd-parties additional library paths (64-bit) into linker options -----
|
rem ----- Colect 3rd-parties additional library paths (64-bit) into linker options -----
|
||||||
set "OPT_LIB64="
|
set "OPT_LIB64="
|
||||||
for %%a in ("%CSF_OPT_LIB64:;=";"%") do (
|
for %%a in ("%CSF_OPT_LIB64:;=";"%") do (
|
||||||
set "anItem=%%~a"
|
set "anItem=%%~a"
|
||||||
@@ -268,7 +229,7 @@ if ["%CASDEB%"] == ["d"] if ["%ARCH%"] == ["64"] set "PATH=%CSF_OPT_BIN64D%;%PAT
|
|||||||
if ["%CASDEB%"] == ["i"] if ["%ARCH%"] == ["32"] set "PATH=%CSF_OPT_BIN32I%;%PATH%"
|
if ["%CASDEB%"] == ["i"] if ["%ARCH%"] == ["32"] set "PATH=%CSF_OPT_BIN32I%;%PATH%"
|
||||||
if ["%CASDEB%"] == ["i"] if ["%ARCH%"] == ["64"] set "PATH=%CSF_OPT_BIN64I%;%PATH%"
|
if ["%CASDEB%"] == ["i"] if ["%ARCH%"] == ["64"] set "PATH=%CSF_OPT_BIN64I%;%PATH%"
|
||||||
|
|
||||||
rem ----- Set environment variables used by OCCT -----
|
rem ----- Set envoronment variables used by OCCT -----
|
||||||
set CSF_LANGUAGE=us
|
set CSF_LANGUAGE=us
|
||||||
set MMGT_CLEAR=1
|
set MMGT_CLEAR=1
|
||||||
set "CSF_SHMessage=%CSF_OCCTResourcePath%\SHMessage"
|
set "CSF_SHMessage=%CSF_OCCTResourcePath%\SHMessage"
|
||||||
|
@@ -115,18 +115,16 @@ if /I "%VCFMT%" == "vc9" (
|
|||||||
exit
|
exit
|
||||||
)
|
)
|
||||||
|
|
||||||
rem ----- For compatibility with external application using CASROOT -----
|
rem ----- For compatability with external application using CASROOT -----
|
||||||
if ["%CASROOT%"] == [""] set "CASROOT=%SCRIPTROOT%"
|
if ["%CASROOT%"] == [""] set "CASROOT=%SCRIPTROOT%"
|
||||||
|
|
||||||
rem ----- Define path to 3rdparty products -----
|
rem ----- Define path to 3rdparty products -----
|
||||||
if ["%THIRDPARTY_DIR%"] == [""] set "THIRDPARTY_DIR=@3RDPARTY_DIR@"
|
set "THIRDPARTY_DIR=@3RDPARTY_DIR@"
|
||||||
|
|
||||||
if ["%ARCH%"] == ["32"] set VCARCH=x86
|
if ["%ARCH%"] == ["32"] set VCARCH=x86
|
||||||
if ["%ARCH%"] == ["64"] set VCARCH=amd64
|
if ["%ARCH%"] == ["64"] set VCARCH=amd64
|
||||||
|
|
||||||
if /I ["%1"] == ["vc141"] set "VCVER=vc14"
|
if /I ["%1"] == ["vc141"] set "VCVER=vc14"
|
||||||
if /I ["%1"] == ["vc142"] set "VCVER=vc14"
|
|
||||||
|
|
||||||
if exist "%CASROOT%\custom.bat" (
|
if exist "%CASROOT%\custom.bat" (
|
||||||
call "%CASROOT%\custom.bat" %VCVER% %ARCH% %CASDEB%
|
call "%CASROOT%\custom.bat" %VCVER% %ARCH% %CASDEB%
|
||||||
)
|
)
|
||||||
@@ -140,11 +138,7 @@ if not ["%GLES2_DIR%"] == [""] set "PATH=%GLES2_DIR%;%PATH%"
|
|||||||
if not ["%TBB_DIR%"] == [""] set "PATH=%TBB_DIR%;%PATH%"
|
if not ["%TBB_DIR%"] == [""] set "PATH=%TBB_DIR%;%PATH%"
|
||||||
if not ["%VTK_DIR%"] == [""] set "PATH=%VTK_DIR%;%PATH%"
|
if not ["%VTK_DIR%"] == [""] set "PATH=%VTK_DIR%;%PATH%"
|
||||||
if not ["%FFMPEG_DIR%"] == [""] set "PATH=%FFMPEG_DIR%;%PATH%"
|
if not ["%FFMPEG_DIR%"] == [""] set "PATH=%FFMPEG_DIR%;%PATH%"
|
||||||
if not ["%OPENVR_DIR%"] == [""] set "PATH=%OPENVR_DIR%;%PATH%"
|
if not ["%QTDIR%"] == [""] set "PATH=%QTDIR%/bin;%PATH%"
|
||||||
if not ["%QTDIR%"] == [""] (
|
|
||||||
set "PATH=%QTDIR%/bin;%PATH%"
|
|
||||||
set "QT_PLUGIN_PATH=%QTDIR%/plugins"
|
|
||||||
)
|
|
||||||
|
|
||||||
rem ----- Set path to 3rd party and OCCT libraries -----
|
rem ----- Set path to 3rd party and OCCT libraries -----
|
||||||
if not "%CSF_OCCTBinPath%" == "" (
|
if not "%CSF_OCCTBinPath%" == "" (
|
||||||
|
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
aScriptPath=${BASH_SOURCE%/*}; if [ -d "${aScriptPath}" ]; then cd "$aScriptPath"; fi; aScriptPath="$PWD";
|
aScriptPath=${BASH_SOURCE%/*}; if [ -d "${aScriptPath}" ]; then cd "$aScriptPath"; fi; aScriptPath="$PWD";
|
||||||
|
|
||||||
# ----- For compatibility with external application using CASROOT -----
|
# ----- For compatability with external application using CASROOT -----
|
||||||
if [ "${CASROOT}" == "" ]; then
|
if [ "${CASROOT}" == "" ]; then
|
||||||
export CASROOT="${aScriptPath}"
|
export CASROOT="${aScriptPath}"
|
||||||
fi
|
fi
|
||||||
|
@@ -2,15 +2,13 @@
|
|||||||
|
|
||||||
aScriptPath=${BASH_SOURCE%/*}; if [ -d "${aScriptPath}" ]; then cd "$aScriptPath"; fi; aScriptPath="$PWD";
|
aScriptPath=${BASH_SOURCE%/*}; if [ -d "${aScriptPath}" ]; then cd "$aScriptPath"; fi; aScriptPath="$PWD";
|
||||||
|
|
||||||
# ----- For compatibility with external application using CASROOT -----
|
# ----- For compatability with external application using CASROOT -----
|
||||||
if [ "${CASROOT}" == "" ]; then
|
if [ "${CASROOT}" == "" ]; then
|
||||||
export CASROOT="@INSTALL_DIR@"
|
export CASROOT="@INSTALL_DIR@"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# ----- Define path to 3rdparty products -----
|
# ----- Define path to 3rdparty products -----
|
||||||
if [ "${THIRDPARTY_DIR}" == "" ]; then
|
export THIRDPARTY_DIR="@3RDPARTY_DIR@"
|
||||||
export THIRDPARTY_DIR="@3RDPARTY_DIR@"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# ----- Read script arguments -----
|
# ----- Read script arguments -----
|
||||||
shopt -s nocasematch
|
shopt -s nocasematch
|
||||||
|
@@ -6,7 +6,6 @@ if exist "%~dp0custom.bat" (
|
|||||||
|
|
||||||
call "@INSTALL_DIR_ABSOLUTE@\@INSTALL_DIR_SCRIPT@\env.bat" %1 %2 %3
|
call "@INSTALL_DIR_ABSOLUTE@\@INSTALL_DIR_SCRIPT@\env.bat" %1 %2 %3
|
||||||
if /I ["%1"] == ["vc141"] set "VCVER=vc141"
|
if /I ["%1"] == ["vc141"] set "VCVER=vc141"
|
||||||
if /I ["%1"] == ["vc142"] set "VCVER=vc142"
|
|
||||||
set "BIN_DIR=win%ARCH%\%VCVER%\bind"
|
set "BIN_DIR=win%ARCH%\%VCVER%\bind"
|
||||||
set "LIB_DIR=win%ARCH%\%VCVER%\libd"
|
set "LIB_DIR=win%ARCH%\%VCVER%\libd"
|
||||||
|
|
||||||
@@ -27,5 +26,3 @@ if not "%QTDIR%" == "" (
|
|||||||
set "PATH=%QTDIR%/bin;%PATH%"
|
set "PATH=%QTDIR%/bin;%PATH%"
|
||||||
set "QT_QPA_PLATFORM_PLUGIN_PATH=%QTDIR%\plugins\platforms"
|
set "QT_QPA_PLATFORM_PLUGIN_PATH=%QTDIR%\plugins\platforms"
|
||||||
)
|
)
|
||||||
|
|
||||||
set "CSF_OCCTOverviewSampleCodePath=%~dp0..\..\OCCTOverview\code"
|
|
||||||
|
@@ -20,5 +20,3 @@ export STATION=$host
|
|||||||
export RES_DIR=${aSamplePath}/${STATION}/res
|
export RES_DIR=${aSamplePath}/${STATION}/res
|
||||||
|
|
||||||
export PATH=${QTDIR}/bin:${PATH}
|
export PATH=${QTDIR}/bin:${PATH}
|
||||||
|
|
||||||
export "CSF_OCCTOverviewSampleCodePath=${aSamplePath}/../../OCCTOverview/code"
|
|
||||||
|
@@ -3,16 +3,12 @@
|
|||||||
# go to the script directory
|
# go to the script directory
|
||||||
aScriptPath=${BASH_SOURCE%/*}; if [ -d "${aScriptPath}" ]; then cd "$aScriptPath"; fi; aScriptPath="$PWD";
|
aScriptPath=${BASH_SOURCE%/*}; if [ -d "${aScriptPath}" ]; then cd "$aScriptPath"; fi; aScriptPath="$PWD";
|
||||||
|
|
||||||
aSystem=`uname -s`
|
|
||||||
|
|
||||||
# Reset values
|
# Reset values
|
||||||
export CASROOT="__CASROOT__"
|
export CASROOT="__CASROOT__"
|
||||||
export CASDEB=""
|
export CASDEB=""
|
||||||
export PRJFMT="";
|
export PRJFMT="";
|
||||||
export HAVE_TBB="false";
|
export HAVE_TBB="false";
|
||||||
export HAVE_OPENCL="false";
|
export HAVE_OPENCL="false";
|
||||||
export HAVE_TK="true";
|
|
||||||
export HAVE_FREETYPE="true";
|
|
||||||
export HAVE_FREEIMAGE="false";
|
export HAVE_FREEIMAGE="false";
|
||||||
export HAVE_FFMPEG="false";
|
export HAVE_FFMPEG="false";
|
||||||
export HAVE_VTK="false";
|
export HAVE_VTK="false";
|
||||||
@@ -20,13 +16,8 @@ export HAVE_GLES2="false";
|
|||||||
export HAVE_ZLIB="false";
|
export HAVE_ZLIB="false";
|
||||||
export HAVE_LIBLZMA="false";
|
export HAVE_LIBLZMA="false";
|
||||||
export HAVE_RAPIDJSON="false";
|
export HAVE_RAPIDJSON="false";
|
||||||
export HAVE_DRACO="false";
|
|
||||||
export HAVE_OPENVR="false";
|
|
||||||
export HAVE_E57="false";
|
export HAVE_E57="false";
|
||||||
export HAVE_XLIB="true";
|
export MACOSX_USE_GLX="false";
|
||||||
if [ "$aSystem" == "Darwin" ]; then
|
|
||||||
export HAVE_XLIB="false";
|
|
||||||
fi
|
|
||||||
export CSF_OPT_INC=""
|
export CSF_OPT_INC=""
|
||||||
export CSF_OPT_LIB32=""
|
export CSF_OPT_LIB32=""
|
||||||
export CSF_OPT_LIB64=""
|
export CSF_OPT_LIB64=""
|
||||||
@@ -66,6 +57,7 @@ else
|
|||||||
export ARCH="64";
|
export ARCH="64";
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
aSystem=`uname -s`
|
||||||
if [ "$aSystem" == "Darwin" ]; then
|
if [ "$aSystem" == "Darwin" ]; then
|
||||||
export WOKSTATION="mac";
|
export WOKSTATION="mac";
|
||||||
export ARCH="64";
|
export ARCH="64";
|
||||||
@@ -107,19 +99,16 @@ export CSF_OPT_CMPL=""
|
|||||||
# Optiona 3rd-parties should be enabled by HAVE macros
|
# Optiona 3rd-parties should be enabled by HAVE macros
|
||||||
if [ "$HAVE_TBB" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_TBB"; fi
|
if [ "$HAVE_TBB" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_TBB"; fi
|
||||||
if [ "$HAVE_OPENCL" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_OPENCL"; fi
|
if [ "$HAVE_OPENCL" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_OPENCL"; fi
|
||||||
if [ "$HAVE_TK" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_TK"; fi
|
|
||||||
if [ "$HAVE_FREETYPE" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_FREETYPE"; fi
|
|
||||||
if [ "$HAVE_FREEIMAGE" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_FREEIMAGE"; fi
|
if [ "$HAVE_FREEIMAGE" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_FREEIMAGE"; fi
|
||||||
if [ "$HAVE_FFMPEG" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_FFMPEG"; fi
|
if [ "$HAVE_FFMPEG" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_FFMPEG"; fi
|
||||||
if [ "$HAVE_GLES2" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_GLES2_EXT"; fi
|
if [ "$HAVE_GLES2" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_GLES2"; fi
|
||||||
if [ "$HAVE_VTK" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_VTK"; fi
|
if [ "$HAVE_VTK" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_VTK"; fi
|
||||||
if [ "$HAVE_ZLIB" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_ZLIB"; fi
|
if [ "$HAVE_ZLIB" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_ZLIB"; fi
|
||||||
if [ "$HAVE_LIBLZMA" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_LIBLZMA"; fi
|
if [ "$HAVE_LIBLZMA" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_LIBLZMA"; fi
|
||||||
if [ "$HAVE_RAPIDJSON" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_RAPIDJSON"; fi
|
if [ "$HAVE_RAPIDJSON" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_RAPIDJSON"; fi
|
||||||
if [ "$HAVE_DRACO" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_DRACO"; fi
|
|
||||||
if [ "$HAVE_OPENVR" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_OPENVR"; fi
|
|
||||||
if [ "$HAVE_E57" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_E57"; fi
|
if [ "$HAVE_E57" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_E57"; fi
|
||||||
if [ "$HAVE_XLIB" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DHAVE_XLIB"; fi
|
# Option to compile OCCT with X11 libs on Mac OS X
|
||||||
|
if [ "$MACOSX_USE_GLX" == "true" ]; then export CSF_OPT_CMPL="${CSF_OPT_CMPL} -DMACOSX_USE_GLX"; fi
|
||||||
|
|
||||||
# To split string into array
|
# To split string into array
|
||||||
aDelimBack=$IFS
|
aDelimBack=$IFS
|
||||||
|
@@ -1,38 +0,0 @@
|
|||||||
@echo off
|
|
||||||
setlocal
|
|
||||||
|
|
||||||
rem Setup environment
|
|
||||||
call "%~dp0env.bat" %1 %2 %3
|
|
||||||
|
|
||||||
rem Define path to project file
|
|
||||||
set "PRJFILE=%~dp0INSTALL.vcxproj"
|
|
||||||
|
|
||||||
if "%VCVER%" == "vc8" (
|
|
||||||
call "%VS80COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc9" (
|
|
||||||
call "%VS90COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc10" (
|
|
||||||
call "%VS100COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc11" (
|
|
||||||
call "%VS110COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc12" (
|
|
||||||
call "%VS120COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc14" (
|
|
||||||
call "%VS140COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc141" (
|
|
||||||
call "%VS141COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else if "%VCVER%" == "vc142" (
|
|
||||||
call "%VS142COMNTOOLS%/vsvars32.bat" > nul
|
|
||||||
) else (
|
|
||||||
echo Error: wrong VS identifier
|
|
||||||
exit /B
|
|
||||||
)
|
|
||||||
|
|
||||||
set BUILDCONFIG=Release
|
|
||||||
if "%CASDEB%"=="i" set BUILDCONFIG=RelWithDebInfo
|
|
||||||
if "%CASDEB%"=="d" set BUILDCONFIG=Debug
|
|
||||||
if "%ARCH%"=="32" set PLATFORM=win32
|
|
||||||
if "%ARCH%"=="64" set PLATFORM=x64
|
|
||||||
|
|
||||||
msbuild "%PRJFILE%" /m /fl /flp:LogFile="install_%BUILDCONFIG%.log" /p:Configuration=%BUILDCONFIG% /p:Platform=%PLATFORM% /p:BuildProjectReferences=false
|
|
||||||
endlocal
|
|
@@ -19,7 +19,6 @@ if ["%1"] == [""] (
|
|||||||
echo AndroidQt
|
echo AndroidQt
|
||||||
echo FuncDemo
|
echo FuncDemo
|
||||||
echo IESample
|
echo IESample
|
||||||
echo OCCTOverview
|
|
||||||
echo Tutorial
|
echo Tutorial
|
||||||
PAUSE
|
PAUSE
|
||||||
exit /B
|
exit /B
|
||||||
@@ -36,8 +35,5 @@ if not exist "%EXE_PATH%" (
|
|||||||
exit /B
|
exit /B
|
||||||
)
|
)
|
||||||
|
|
||||||
rem Set path to location where sample code is installed
|
|
||||||
set "CSF_OCCTOverviewSampleCodePath=%CSF_OCCTSamplesPath%\OCCTOverview\code"
|
|
||||||
|
|
||||||
"%EXE_PATH%"
|
"%EXE_PATH%"
|
||||||
|
|
||||||
|
@@ -8,7 +8,6 @@ if [ "$1" == "" ]; then
|
|||||||
echo available samples:
|
echo available samples:
|
||||||
echo FuncDemo
|
echo FuncDemo
|
||||||
echo IESample
|
echo IESample
|
||||||
echo OCCTOverview
|
|
||||||
echo Tutorial
|
echo Tutorial
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -32,7 +31,5 @@ if [ ! -f "$EXE_PATH" ]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
export CSF_OCCTOverviewSampleCodePath="${CSF_OCCTSamplesPath}/OCCTOverview/code"
|
|
||||||
|
|
||||||
cd ${aCurrentPath}
|
cd ${aCurrentPath}
|
||||||
"$EXE_PATH"
|
"$EXE_PATH"
|
@@ -90,7 +90,7 @@
|
|||||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||||
<Optimization>MaxSpeed</Optimization>
|
<Optimization>MaxSpeed</Optimization>
|
||||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||||
<PreprocessorDefinitions>NDEBUG;No_Exception;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>NDEBUG;No_Exception;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<StringPooling>true</StringPooling>
|
<StringPooling>true</StringPooling>
|
||||||
<ExceptionHandling>Async</ExceptionHandling>
|
<ExceptionHandling>Async</ExceptionHandling>
|
||||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||||
@@ -107,7 +107,7 @@
|
|||||||
</ClCompile>
|
</ClCompile>
|
||||||
<ResourceCompile>
|
<ResourceCompile>
|
||||||
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>NDEBUG;No_Exception;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>NDEBUG;No_Exception;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
<Link>
|
<Link>
|
||||||
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
||||||
@@ -138,7 +138,7 @@
|
|||||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||||
<Optimization>Disabled</Optimization>
|
<Optimization>Disabled</Optimization>
|
||||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||||
<PreprocessorDefinitions>_DEBUG;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>_DEBUG;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<ExceptionHandling>Async</ExceptionHandling>
|
<ExceptionHandling>Async</ExceptionHandling>
|
||||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||||
<AssemblerListingLocation>.\..\..\..\win32\__VCVER__\objd\__TKNAM__/</AssemblerListingLocation>
|
<AssemblerListingLocation>.\..\..\..\win32\__VCVER__\objd\__TKNAM__/</AssemblerListingLocation>
|
||||||
@@ -156,10 +156,10 @@
|
|||||||
</ClCompile>
|
</ClCompile>
|
||||||
<ResourceCompile>
|
<ResourceCompile>
|
||||||
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>_DEBUG;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>_DEBUG;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
<Link>
|
<Link>
|
||||||
<AdditionalDependencies>__TKDEP_DEBUG__</AdditionalDependencies>
|
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
||||||
<OutputFile>.\..\..\..\win32\__VCVER__\bind\__TKNAM__.dll</OutputFile>
|
<OutputFile>.\..\..\..\win32\__VCVER__\bind\__TKNAM__.dll</OutputFile>
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||||
<AdditionalLibraryDirectories>..\..\..\win32\__VCVER__\libd;$(CSF_OPT_LIB32D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
<AdditionalLibraryDirectories>..\..\..\win32\__VCVER__\libd;$(CSF_OPT_LIB32D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||||
@@ -186,7 +186,7 @@
|
|||||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||||
<Optimization>MaxSpeed</Optimization>
|
<Optimization>MaxSpeed</Optimization>
|
||||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||||
<PreprocessorDefinitions>NDEBUG;No_Exception;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>NDEBUG;No_Exception;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<StringPooling>true</StringPooling>
|
<StringPooling>true</StringPooling>
|
||||||
<ExceptionHandling>Async</ExceptionHandling>
|
<ExceptionHandling>Async</ExceptionHandling>
|
||||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||||
@@ -203,7 +203,7 @@
|
|||||||
</ClCompile>
|
</ClCompile>
|
||||||
<ResourceCompile>
|
<ResourceCompile>
|
||||||
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>NDEBUG;No_Exception;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>NDEBUG;No_Exception;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
<Link>
|
<Link>
|
||||||
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
||||||
@@ -234,7 +234,7 @@
|
|||||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||||
<Optimization>Disabled</Optimization>
|
<Optimization>Disabled</Optimization>
|
||||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||||
<PreprocessorDefinitions>_DEBUG;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>_DEBUG;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<ExceptionHandling>Async</ExceptionHandling>
|
<ExceptionHandling>Async</ExceptionHandling>
|
||||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||||
<AssemblerListingLocation>.\..\..\..\win64\__VCVER__\objd\__TKNAM__/</AssemblerListingLocation>
|
<AssemblerListingLocation>.\..\..\..\win64\__VCVER__\objd\__TKNAM__/</AssemblerListingLocation>
|
||||||
@@ -252,10 +252,10 @@
|
|||||||
</ClCompile>
|
</ClCompile>
|
||||||
<ResourceCompile>
|
<ResourceCompile>
|
||||||
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>_DEBUG;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>_DEBUG;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
<Link>
|
<Link>
|
||||||
<AdditionalDependencies>__TKDEP_DEBUG__</AdditionalDependencies>
|
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
||||||
<OutputFile>.\..\..\..\win64\__VCVER__\bind\__TKNAM__.dll</OutputFile>
|
<OutputFile>.\..\..\..\win64\__VCVER__\bind\__TKNAM__.dll</OutputFile>
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||||
<AdditionalLibraryDirectories>..\..\..\win64\__VCVER__\libd;$(CSF_OPT_LIB64D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
<AdditionalLibraryDirectories>..\..\..\win64\__VCVER__\libd;$(CSF_OPT_LIB64D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||||
|
@@ -85,7 +85,7 @@
|
|||||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||||
<Optimization>MaxSpeed</Optimization>
|
<Optimization>MaxSpeed</Optimization>
|
||||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||||
<PreprocessorDefinitions>NDEBUG;No_Exception;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>NDEBUG;No_Exception;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<StringPooling>true</StringPooling>
|
<StringPooling>true</StringPooling>
|
||||||
<ExceptionHandling>Async</ExceptionHandling>
|
<ExceptionHandling>Async</ExceptionHandling>
|
||||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||||
@@ -100,7 +100,7 @@
|
|||||||
</ClCompile>
|
</ClCompile>
|
||||||
<ResourceCompile>
|
<ResourceCompile>
|
||||||
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>NDEBUG;No_Exception;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>NDEBUG;No_Exception;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
<Link>
|
<Link>
|
||||||
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
||||||
@@ -130,7 +130,7 @@
|
|||||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||||
<Optimization>Disabled</Optimization>
|
<Optimization>Disabled</Optimization>
|
||||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||||
<PreprocessorDefinitions>_DEBUG;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>_DEBUG;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<ExceptionHandling>Async</ExceptionHandling>
|
<ExceptionHandling>Async</ExceptionHandling>
|
||||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||||
<AssemblerListingLocation>.\..\..\..\win32\__VCVER__\objd\__XQTNAM__/</AssemblerListingLocation>
|
<AssemblerListingLocation>.\..\..\..\win32\__VCVER__\objd\__XQTNAM__/</AssemblerListingLocation>
|
||||||
@@ -146,10 +146,10 @@
|
|||||||
</ClCompile>
|
</ClCompile>
|
||||||
<ResourceCompile>
|
<ResourceCompile>
|
||||||
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>_DEBUG;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>_DEBUG;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
<Link>
|
<Link>
|
||||||
<AdditionalDependencies>__TKDEP_DEBUG__</AdditionalDependencies>
|
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||||
<AdditionalLibraryDirectories>..\..\..\win32\__VCVER__\libd;$(CSF_OPT_LIB32D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
<AdditionalLibraryDirectories>..\..\..\win32\__VCVER__\libd;$(CSF_OPT_LIB32D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||||
@@ -175,7 +175,7 @@
|
|||||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||||
<Optimization>MaxSpeed</Optimization>
|
<Optimization>MaxSpeed</Optimization>
|
||||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||||
<PreprocessorDefinitions>NDEBUG;No_Exception;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>NDEBUG;No_Exception;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<StringPooling>true</StringPooling>
|
<StringPooling>true</StringPooling>
|
||||||
<ExceptionHandling>Async</ExceptionHandling>
|
<ExceptionHandling>Async</ExceptionHandling>
|
||||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||||
@@ -190,7 +190,7 @@
|
|||||||
</ClCompile>
|
</ClCompile>
|
||||||
<ResourceCompile>
|
<ResourceCompile>
|
||||||
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>NDEBUG;No_Exception;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>NDEBUG;No_Exception;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
<Link>
|
<Link>
|
||||||
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
||||||
@@ -219,7 +219,7 @@
|
|||||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||||
<Optimization>Disabled</Optimization>
|
<Optimization>Disabled</Optimization>
|
||||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||||
<PreprocessorDefinitions>_DEBUG;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>_DEBUG;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<ExceptionHandling>Async</ExceptionHandling>
|
<ExceptionHandling>Async</ExceptionHandling>
|
||||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||||
<AssemblerListingLocation>.\..\..\..\win64\__VCVER__\objd\__XQTNAM__/</AssemblerListingLocation>
|
<AssemblerListingLocation>.\..\..\..\win64\__VCVER__\objd\__XQTNAM__/</AssemblerListingLocation>
|
||||||
@@ -235,10 +235,10 @@
|
|||||||
</ClCompile>
|
</ClCompile>
|
||||||
<ResourceCompile>
|
<ResourceCompile>
|
||||||
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>..\..\..\inc;$(CSF_OPT_INC);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>_DEBUG;__TKDEFINES__;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>_DEBUG;$(CSF_DEFINES);%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
</ResourceCompile>
|
</ResourceCompile>
|
||||||
<Link>
|
<Link>
|
||||||
<AdditionalDependencies>__TKDEP_DEBUG__</AdditionalDependencies>
|
<AdditionalDependencies>__TKDEP__</AdditionalDependencies>
|
||||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||||
<AdditionalLibraryDirectories>..\..\..\win64\__VCVER__\libd;$(CSF_OPT_LIB64D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
<AdditionalLibraryDirectories>..\..\..\win64\__VCVER__\libd;$(CSF_OPT_LIB64D);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||||
|
@@ -71,30 +71,6 @@ BOPTools::MapShapesAndAncestors TopExp::MapShapesAndAncestors
|
|||||||
BOPCol_Box2DBndTreeSelector BOPTools_BoxSelector<Bnd_Box2d>
|
BOPCol_Box2DBndTreeSelector BOPTools_BoxSelector<Bnd_Box2d>
|
||||||
BiTgte_DataMapOfShapeBox TopTools_DataMapOfShapeBox
|
BiTgte_DataMapOfShapeBox TopTools_DataMapOfShapeBox
|
||||||
CDM_MessageDriver Message_Messenger
|
CDM_MessageDriver Message_Messenger
|
||||||
Message_ProgressSentry Message_ProgressScope
|
|
||||||
Adaptor2d_HCurve2d Adaptor2d_Curve2d
|
|
||||||
Adaptor2d_HLine2d Adaptor2d_Line2d
|
|
||||||
Adaptor2d_HOffsetCurve Adaptor2d_OffsetCurve
|
|
||||||
Adaptor3d_HCurve Adaptor3d_Curve
|
|
||||||
Adaptor3d_HCurveOnSurface Adaptor3d_CurveOnSurface
|
|
||||||
Adaptor3d_HIsoCurve Adaptor3d_IsoCurve
|
|
||||||
Adaptor3d_HSurface Adaptor3d_Surface
|
|
||||||
BRepAdaptor_HCompCurve BRepAdaptor_CompCurve
|
|
||||||
BRepAdaptor_HCurve BRepAdaptor_Curve
|
|
||||||
BRepAdaptor_HCurve2d BRepAdaptor_Curve2d
|
|
||||||
BRepAdaptor_HSurface BRepAdaptor_Surface
|
|
||||||
BiTgte_HCurveOnEdge BiTgte_CurveOnEdge
|
|
||||||
BiTgte_HCurveOnVertex BiTgte_CurveOnVertex
|
|
||||||
ChFiDS_HElSpine ChFiDS_ElSpine
|
|
||||||
Geom2dAdaptor_GHCurve Geom2dAdaptor_Curve
|
|
||||||
Geom2dAdaptor_HCurve Geom2dAdaptor_Curve
|
|
||||||
GeomAdaptor_GHCurve GeomAdaptor_Curve
|
|
||||||
GeomAdaptor_GHSurface GeomAdaptor_Surface
|
|
||||||
GeomAdaptor_HCurve GeomAdaptor_Curve
|
|
||||||
GeomAdaptor_HSurface GeomAdaptor_Surface
|
|
||||||
GeomAdaptor_HSurfaceOfLinearExtrusion GeomAdaptor_SurfaceOfLinearExtrusion
|
|
||||||
GeomAdaptor_HSurfaceOfRevolution GeomAdaptor_SurfaceOfRevolution
|
|
||||||
PrsMgr_PresentationManager3d PrsMgr_PresentationManager
|
|
||||||
|
|
||||||
[tcollection]
|
[tcollection]
|
||||||
AdvApp2Var_SequenceOfNode
|
AdvApp2Var_SequenceOfNode
|
||||||
|
@@ -52,7 +52,7 @@ proc HelpInformation {} {
|
|||||||
loginfo " -$ArgName(Rename) - apply renaming of classes"
|
loginfo " -$ArgName(Rename) - apply renaming of classes"
|
||||||
loginfo ""
|
loginfo ""
|
||||||
loginfo "Advanced options:"
|
loginfo "Advanced options:"
|
||||||
loginfo " -$ArgName(CompatibleMode) - preserve old RTTI macros for compatibility with OCCT 6.x"
|
loginfo " -$ArgName(CompatibleMode) - preserve old RTTI macros for compatability with OCCT 6.x"
|
||||||
loginfo " -$ArgName(CheckOnly) - do check only, no modifications will be made"
|
loginfo " -$ArgName(CheckOnly) - do check only, no modifications will be made"
|
||||||
loginfo " -$ArgName(WLog) - show gui log of upgrade process"
|
loginfo " -$ArgName(WLog) - show gui log of upgrade process"
|
||||||
loginfo " -$ArgName(Log)=<file path> - put the log into a file"
|
loginfo " -$ArgName(Log)=<file path> - put the log into a file"
|
||||||
@@ -370,7 +370,7 @@ proc upgrade {args} {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
# search and rename the indices (old names) of @theNewNames with their values (new ones)
|
# search and rename the indeces (old names) of @theNewNames with their values (new ones)
|
||||||
# processes files that have @theExtensions only in @thePath folder
|
# processes files that have @theExtensions only in @thePath folder
|
||||||
proc Rename {thePath theExtensions theNewNames theCheckMode} {
|
proc Rename {thePath theExtensions theNewNames theCheckMode} {
|
||||||
upvar $theNewNames aNewNames
|
upvar $theNewNames aNewNames
|
||||||
|
@@ -5,56 +5,54 @@
|
|||||||
# The order of files in this list determines order of top-level pages
|
# The order of files in this list determines order of top-level pages
|
||||||
# in the generated documentation.
|
# in the generated documentation.
|
||||||
|
|
||||||
introduction/introduction.md
|
overview/overview.md
|
||||||
|
|
||||||
samples/samples.md
|
|
||||||
../samples/mfc/standard/ReadMe.md
|
../samples/mfc/standard/ReadMe.md
|
||||||
../samples/CSharp/ReadMe.md
|
../samples/CSharp/ReadMe.md
|
||||||
../samples/CSharp/ReadMe_D3D.md
|
../samples/CSharp/ReadMe_D3D.md
|
||||||
|
|
||||||
../samples/qt/AndroidQt/ReadMe.md
|
../samples/qt/AndroidQt/ReadMe.md
|
||||||
../samples/qt/OCCTOverview/ReadMe.md
|
|
||||||
../samples/java/jniviewer/ReadMe.md
|
../samples/java/jniviewer/ReadMe.md
|
||||||
../samples/ios/UIKitSample/ReadMe.md
|
../samples/ios/UIKitSample/ReadMe.md
|
||||||
../samples/webgl/ReadMe.md
|
|
||||||
samples/ocaf.md
|
|
||||||
samples/ocaf_func.md
|
|
||||||
samples/draw_scripts.md
|
|
||||||
|
|
||||||
tutorial/tutorial.md
|
tutorial/tutorial.md
|
||||||
|
|
||||||
build/build_upgrade.md
|
technical_overview/technical_overview.md
|
||||||
build/build_occt/building_occt.md
|
|
||||||
build/build_3rdparty/building_3rdparty.md
|
|
||||||
build/build_documentation/building_documentation.md
|
|
||||||
|
|
||||||
debug/debug.md
|
|
||||||
upgrade/upgrade.md
|
|
||||||
|
|
||||||
user_guides/user_guides.md
|
user_guides/user_guides.md
|
||||||
user_guides/foundation_classes/foundation_classes.md
|
user_guides/foundation_classes/foundation_classes.md
|
||||||
user_guides/modeling_data/modeling_data.md
|
user_guides/modeling_data/modeling_data.md
|
||||||
user_guides/modeling_algos/modeling_algos.md
|
user_guides/modeling_algos/modeling_algos.md
|
||||||
user_guides/mesh/mesh.md
|
user_guides/boolean_operations/boolean_operations.md
|
||||||
user_guides/shape_healing/shape_healing.md
|
user_guides/shape_healing/shape_healing.md
|
||||||
user_guides/visualization/visualization.md
|
user_guides/visualization/visualization.md
|
||||||
user_guides/iges/iges.md
|
user_guides/iges/iges.md
|
||||||
user_guides/step/step.md
|
user_guides/step/step.md
|
||||||
user_guides/xde/xde.md
|
user_guides/xde/xde.md
|
||||||
user_guides/ocaf/ocaf.md
|
user_guides/ocaf/ocaf.md
|
||||||
|
user_guides/tobj/tobj.md
|
||||||
user_guides/draw_test_harness/draw_test_harness.md
|
user_guides/draw_test_harness/draw_test_harness.md
|
||||||
user_guides/inspector/inspector.md
|
user_guides/inspector/inspector.md
|
||||||
|
user_guides/brep_wp/brep_wp.md
|
||||||
user_guides/vis/vis.md
|
user_guides/vis/vis.md
|
||||||
|
|
||||||
specification/specification.md
|
dev_guides/dev_guides.md
|
||||||
specification/boolean_operations/boolean_operations.md
|
dev_guides/documentation/documentation.md
|
||||||
specification/brep_format.md
|
dev_guides/contribution/coding_rules.md
|
||||||
specification/pbr_math.md
|
dev_guides/contribution_workflow/contribution_workflow.md
|
||||||
|
dev_guides/git_guide/git_guide.md
|
||||||
|
dev_guides/tests/tests.md
|
||||||
|
dev_guides/debug/debug.md
|
||||||
|
dev_guides/upgrade/upgrade.md
|
||||||
|
|
||||||
contribution/contribution.md
|
dev_guides/building/building.md
|
||||||
contribution/documentation/documentation.md
|
dev_guides/building/3rdparty/3rdparty_windows.md
|
||||||
contribution/coding_rules.md
|
dev_guides/building/3rdparty/3rdparty_linux.md
|
||||||
contribution/contribution_workflow/contribution_workflow.md
|
dev_guides/building/3rdparty/3rdparty_osx.md
|
||||||
contribution/git_guide/git_guide.md
|
dev_guides/building/cmake/cmake.md
|
||||||
contribution/tests/tests.md
|
dev_guides/building/android/android.md
|
||||||
|
dev_guides/building/code_blocks.md
|
||||||
|
dev_guides/building/msvc.md
|
||||||
|
dev_guides/building/xcode.md
|
||||||
|
|
||||||
license.md
|
license.md
|
||||||
|
@@ -4,29 +4,27 @@
|
|||||||
# Empty spaces are allowed.
|
# Empty spaces are allowed.
|
||||||
# Strings starting with '#' are treated as comments and ignored.
|
# Strings starting with '#' are treated as comments and ignored.
|
||||||
|
|
||||||
tutorial/tutorial.md
|
user_guides/brep_wp/brep_wp.md
|
||||||
|
|
||||||
upgrade/upgrade.md
|
|
||||||
|
|
||||||
user_guides/foundation_classes/foundation_classes.md
|
user_guides/foundation_classes/foundation_classes.md
|
||||||
|
user_guides/iges/iges.md
|
||||||
user_guides/modeling_data/modeling_data.md
|
user_guides/modeling_data/modeling_data.md
|
||||||
user_guides/modeling_algos/modeling_algos.md
|
user_guides/modeling_algos/modeling_algos.md
|
||||||
user_guides/mesh/mesh.md
|
user_guides/boolean_operations/boolean_operations.md
|
||||||
|
user_guides/shape_healing/shape_healing.md
|
||||||
user_guides/ocaf/ocaf.md
|
user_guides/ocaf/ocaf.md
|
||||||
user_guides/visualization/visualization.md
|
|
||||||
user_guides/vis/vis.md
|
|
||||||
user_guides/iges/iges.md
|
|
||||||
user_guides/step/step.md
|
user_guides/step/step.md
|
||||||
user_guides/xde/xde.md
|
|
||||||
user_guides/inspector/inspector.md
|
|
||||||
user_guides/draw_test_harness/draw_test_harness.md
|
user_guides/draw_test_harness/draw_test_harness.md
|
||||||
|
user_guides/inspector/inspector.md
|
||||||
|
user_guides/tobj/tobj.md
|
||||||
|
user_guides/visualization/visualization.md
|
||||||
|
user_guides/xde/xde.md
|
||||||
|
user_guides/vis/vis.md
|
||||||
|
|
||||||
contribution/contribution_workflow/contribution_workflow.md
|
dev_guides/contribution_workflow/contribution_workflow.md
|
||||||
contribution/documentation/documentation.md
|
dev_guides/documentation/documentation.md
|
||||||
contribution/coding_rules.md
|
dev_guides/contribution/coding_rules.md
|
||||||
contribution/git_guide/git_guide.md
|
dev_guides/git_guide/git_guide.md
|
||||||
contribution/tests/tests.md
|
dev_guides/tests/tests.md
|
||||||
|
dev_guides/upgrade/upgrade.md
|
||||||
|
|
||||||
specification/boolean_operations/boolean_operations.md
|
tutorial/tutorial.md
|
||||||
specification/brep_format.md
|
|
||||||
specification/pbr_math.md
|
|
||||||
|
627
dox/build/build_3rdparty/building_3rdparty.md
vendored
@@ -1,627 +0,0 @@
|
|||||||
Build 3rd-parties {#build_upgrade_building_3rdparty}
|
|
||||||
==============================================
|
|
||||||
@tableofcontents
|
|
||||||
|
|
||||||
On Windows, the easiest way to install third-party libraries is to download archive with pre-built binaries from https://opencascade.com/content/3rd-party-components.
|
|
||||||
On Linux and OS X, it is recommended to use the version installed in the system natively.
|
|
||||||
|
|
||||||
@section dev_guides__building_3rdparty_win_1 Windows
|
|
||||||
|
|
||||||
This document presents guidelines for building third-party products used by Open CASCADE Technology (OCCT) and samples on Windows platform. It is assumed that you are already familiar with MS Visual Studio / Visual C++.
|
|
||||||
|
|
||||||
You need to use the same version of MS Visual Studio for building all third-party products and OCCT itself, in order to receive a consistent set of run-time binaries.
|
|
||||||
|
|
||||||
The links for downloading the third-party products are available at https://opencascade.com/content/3rd-party-components.
|
|
||||||
|
|
||||||
There are two types of third-party products used by OCCT:
|
|
||||||
|
|
||||||
* Mandatory products:
|
|
||||||
* Tcl/Tk 8.5 -- 8.6;
|
|
||||||
* FreeType 2.4.10 -- 2.5.3.
|
|
||||||
* Optional products:
|
|
||||||
* TBB 3.x -- 4.x;
|
|
||||||
* FreeImage 3.14.1 -- 3.16.0;
|
|
||||||
* VTK 6.1.0.
|
|
||||||
|
|
||||||
It is recommended to create a separate new folder on your workstation, where you will unpack the downloaded archives of the third-party products, and where you will build these products (for example, *c:\\occ3rdparty*).
|
|
||||||
|
|
||||||
Further in this document, this folder is referred to as *3rdparty*.
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_win_2 Tcl/Tk
|
|
||||||
|
|
||||||
Tcl/Tk is required for DRAW test harness.
|
|
||||||
|
|
||||||
**Installation from sources: Tcl**
|
|
||||||
|
|
||||||
Download the necessary archive from https://www.tcl.tk/software/tcltk/download.html and unpack it.
|
|
||||||
|
|
||||||
1. In the *win* sub-directory, edit file *buildall.vc.bat*:
|
|
||||||
|
|
||||||
* Edit the line "call ... vcvars32.bat" to have correct path to the version of Visual Studio to be used for building, for instance:
|
|
||||||
|
|
||||||
call "%VS80COMNTOOLS%\vsvars32.bat"
|
|
||||||
|
|
||||||
If you are building 64-bit version, set environment accordingly, e.g.:
|
|
||||||
|
|
||||||
call "%VS80COMNTOOLS%\..\..\VC\vcvarsall.bat" amd64
|
|
||||||
|
|
||||||
* Define variable *INSTALLDIR* pointing to directory where Tcl/Tk will be installed, e.g.:
|
|
||||||
|
|
||||||
set INSTALLDIR=D:\OCCT\3rdparty\tcltk-86-32
|
|
||||||
|
|
||||||
* Add option *install* to the first command line calling *nmake*:
|
|
||||||
|
|
||||||
nmake -nologo -f makefile.vc release htmlhelp install %1
|
|
||||||
|
|
||||||
* Remove second call to *nmake* (building statically linked executable)
|
|
||||||
|
|
||||||
2. Edit file *rules.vc* replacing line
|
|
||||||
|
|
||||||
SUFX = tsgx
|
|
||||||
|
|
||||||
by
|
|
||||||
|
|
||||||
SUFX = sgx
|
|
||||||
|
|
||||||
This is to avoid extra prefix 't' in the library name, which is not recognized by default by OCCT build tools.
|
|
||||||
|
|
||||||
|
|
||||||
3. By default, Tcl uses dynamic version of run-time library (MSVCRT), which must be installed on the system where Tcl will be used.
|
|
||||||
You may wish to link Tcl library with static version of run-time to avoid this dependency.
|
|
||||||
For that:
|
|
||||||
|
|
||||||
* Edit file *makefile.vc* replacing strings "crt = -MD" by "crt = -MT"
|
|
||||||
|
|
||||||
* Edit source file *tclMain.c* (located in folder *generic*) commenting out forward declaration of function *isatty()*.
|
|
||||||
|
|
||||||
|
|
||||||
4. In the command prompt, run *buildall.vc.bat*
|
|
||||||
|
|
||||||
You might need to run this script twice to have *tclsh* executable installed; check subfolder *bin* of specified installation path to verify this.
|
|
||||||
|
|
||||||
5. For convenience of use, we recommend making a copy of *tclsh* executable created in subfolder *bin* of *INSTALLDIR* and named with Tcl version number suffix, as *tclsh.exe* (with no suffix)
|
|
||||||
|
|
||||||
> cd D:\OCCT\3rdparty\tcltk-86-32\bin
|
|
||||||
> cp tclsh86.exe tclsh.exe
|
|
||||||
|
|
||||||
**Installation from sources: Tk**
|
|
||||||
|
|
||||||
Download the necessary archive from https://www.tcl.tk/software/tcltk/download.html and unpack it.
|
|
||||||
|
|
||||||
Apply the same steps as described for building Tcl above, with the same INSTALLDIR.
|
|
||||||
Note that Tk produces its own executable, called *wish*.
|
|
||||||
|
|
||||||
You might need to edit default value of *TCLDIR* variable defined in *buildall.vc.bat* (should be not necessary if you unpack both Tcl and Tk sources in the same folder).
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_win_2_2 FreeType
|
|
||||||
|
|
||||||
FreeType is required for text display in a 3D viewer. You can download its sources from https://sourceforge.net/projects/freetype/files/
|
|
||||||
|
|
||||||
### The building procedure
|
|
||||||
|
|
||||||
1. Unpack the downloaded archive of FreeType product into the *3rdparty* folder. As a result, you will get a folder named, for example, *3rdparty\\freetype-2.4.10*. Further in this document, this folder is referred to as *freetype*.
|
|
||||||
|
|
||||||
2. Open the solution file *freetype\\builds\\win32\\vc20xx\\freetype.sln* in Visual Studio. Here *vc20xx* stands for your version of Visual Studio.
|
|
||||||
|
|
||||||
3. Select the configuration to build: either Debug or Release.
|
|
||||||
|
|
||||||
4. Build the *freetype* project.
|
|
||||||
|
|
||||||
As a result, you will get a freetype import library (.lib) in the *freetype\\obj\\win32\\vc20xx* folder.
|
|
||||||
|
|
||||||
|
|
||||||
5. If you build FreeType for a 64 bit platform, select in the main menu **Build - Configuration Manager** and add *x64* platform to the solution configuration by copying the settings from Win32 platform:
|
|
||||||
|
|
||||||
@figure{/build/build_3rdparty/images/3rdparty_image001.png}
|
|
||||||
|
|
||||||
Update the value of the Output File for x64 configuration:
|
|
||||||
|
|
||||||
@figure{/build/build_3rdparty/images/3rdparty_image003.png}
|
|
||||||
|
|
||||||
Build the *freetype* project.
|
|
||||||
|
|
||||||
As a result, you will obtain a 64 bit import library (.lib) file in the *freetype\\x64\\vc20xx* folder.
|
|
||||||
|
|
||||||
To build FreeType as a dynamic library (.dll) follow steps 6, 7 and 8 of this procedure.
|
|
||||||
|
|
||||||
6. Open menu Project-> Properties-> Configuration Properties-> General and change option **Configuration Type** to *Dynamic Library (.dll)*.
|
|
||||||
7. Edit file *freetype\\include\\freetype\\config\\ftoption.h*:
|
|
||||||
|
|
||||||
in line 255, uncomment the definition of macro *FT_EXPORT* and change it as follows:
|
|
||||||
|
|
||||||
#define FT_EXPORT(x) __declspec(dllexport) x
|
|
||||||
|
|
||||||
8. Build the *freetype* project.
|
|
||||||
|
|
||||||
As a result, you will obtain the files of the import library (.lib) and the dynamic library (.dll) in folders <i>freetype \\objs\\release</i> or <i>\\objs\\debug </i>.
|
|
||||||
|
|
||||||
If you build for a 64 bit platform, follow step 5 of the procedure.
|
|
||||||
|
|
||||||
To facilitate the use of FreeType libraries in OCCT with minimal adjustment of build procedures, it is recommended to copy the include files and libraries of FreeType into a separate folder, named according to the pattern: *freetype-compiler-bitness-building mode*, where:
|
|
||||||
* **compiler** is *vc8* or *vc9* or *vc10* or *vc11*;
|
|
||||||
* **bitness** is *32* or *64*;
|
|
||||||
* **building mode** is *opt* (for Release) or *deb* (for Debug).
|
|
||||||
|
|
||||||
The *include* subfolder should be copied as is, while libraries should be renamed to *freetype.lib* and *freetype.dll* (suffixes removed) and placed to subdirectories *lib *and *bin*, respectively. If the Debug configuration is built, the Debug libraries should be put into subdirectories *libd* and *bind*.
|
|
||||||
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_win_3_1 TBB
|
|
||||||
|
|
||||||
This third-party product is installed with binaries
|
|
||||||
from the archive that can be downloaded from https://github.com/intel/tbb.
|
|
||||||
Go to the **Download** page, find the release version you need (e.g. *tbb30_018oss*) and pick the archive for Windows platform.
|
|
||||||
|
|
||||||
Unpack the downloaded archive of TBB product into the *3rdparty* folder.
|
|
||||||
|
|
||||||
Further in this document, this folder is referred to as *tbb*.
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_win_3_3 FreeImage
|
|
||||||
|
|
||||||
This third-party product should be built as a dynamically loadable library (.dll file).
|
|
||||||
You can download its sources from
|
|
||||||
https://sourceforge.net/projects/freeimage/files/Source%20Distribution/
|
|
||||||
|
|
||||||
### The building procedure:
|
|
||||||
|
|
||||||
1. Unpack the downloaded archive of FreeImage product into *3rdparty* folder.
|
|
||||||
|
|
||||||
As a result, you should have a folder named *3rdparty\\FreeImage*.
|
|
||||||
|
|
||||||
Rename it according to the rule: *freeimage-platform-compiler-building mode*, where
|
|
||||||
|
|
||||||
* **platform** is *win32* or *win64*;
|
|
||||||
* **compiler** is *vc8* or *vc9* or *vc10* or *vc11*;
|
|
||||||
* **building mode** is *opt* (for release) or *deb* (for debug)
|
|
||||||
|
|
||||||
Further in this document, this folder is referred to as *freeimage*.
|
|
||||||
|
|
||||||
2. Open the solution file *freeimage\\FreeImage.*.sln* in your Visual Studio.
|
|
||||||
|
|
||||||
If you use a Visual Studio version higher than VC++ 2008, apply conversion of the workspace.
|
|
||||||
Such conversion should be suggested automatically by Visual Studio.
|
|
||||||
|
|
||||||
3. Select a configuration to build.
|
|
||||||
|
|
||||||
- Choose **Release** if you are building Release binaries.
|
|
||||||
- Choose **Debug** if you are building Debug binaries.
|
|
||||||
|
|
||||||
*Note:*
|
|
||||||
|
|
||||||
If you want to build a debug version of FreeImage binaries then you need to rename the following files in FreeImage and FreeimagePlus projects:
|
|
||||||
|
|
||||||
Project -> Properties -> Configuration Properties -> Linker -> General -> Output File
|
|
||||||
|
|
||||||
FreeImage*d*.dll to FreeImage.dll
|
|
||||||
FreeImagePlus*d*.dll to FreeImagePlus.dll
|
|
||||||
|
|
||||||
Project -> Properties -> Configuration Properties -> Linker -> Debugging-> Generate Program Database File
|
|
||||||
|
|
||||||
FreeImage*d*.pdb to FreeImage.pdb
|
|
||||||
FreeImagePlus*d*.pdb to FreeImagePlus.pdb
|
|
||||||
|
|
||||||
Project -> Properties -> Configuration Properties -> Linker -> Advanced-Import Library
|
|
||||||
|
|
||||||
FreeImage*d*.lib to FreeImage.lib
|
|
||||||
FreeImagePlus*d*.lib to FreeImagePlus.lib
|
|
||||||
|
|
||||||
Project -> Properties -> Configuration Properties -> Build Events -> Post -> Build Event -> Command Line
|
|
||||||
|
|
||||||
FreeImage*d*.dll to FreeImage.dll
|
|
||||||
FreeImage*d*.lib to FreeImage.lib
|
|
||||||
FreeImagePlus*d*.dll to FreeImagePlus.dll
|
|
||||||
FreeImagePlus*d*.lib to FreeImagePlus.lib
|
|
||||||
|
|
||||||
Additionally, rename in project FreeImagePlus
|
|
||||||
|
|
||||||
Project -> Properties -> Configuration Properties -> Linker -> Input -> Additional Dependencies
|
|
||||||
|
|
||||||
from FreeImage*d*.lib to FreeImage.lib
|
|
||||||
|
|
||||||
4. Select a platform to build.
|
|
||||||
|
|
||||||
- Choose *Win32* if you are building for a 32 bit platform.
|
|
||||||
- Choose *x64* if you are building for a 64 bit platform.
|
|
||||||
|
|
||||||
5. Start the building process.
|
|
||||||
|
|
||||||
As a result, you should have the library files of FreeImage product in *freeimage\\Dist* folder (*FreeImage.dll* and *FreeImage.lib*) and in *freeimage\\Wrapper\\FreeImagePlus\\dist* folder (*FreeImagePlus.dll* and *FreeImagePlus.lib*).
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_win_3_4 VTK
|
|
||||||
|
|
||||||
VTK is an open-source, freely available software system for 3D computer graphics, image processing and visualization. VTK Integration Services component provides adaptation functionality for visualization of OCCT topological shapes by means of VTK library.
|
|
||||||
|
|
||||||
### The building procedure:
|
|
||||||
|
|
||||||
1. Download the necessary archive from https://www.vtk.org/VTK/resources/software.html and unpack it into *3rdparty* folder.
|
|
||||||
|
|
||||||
As a result, you will get a folder named, for example, <i>3rdparty\VTK-6.1.0.</i>
|
|
||||||
|
|
||||||
Further in this document, this folder is referred to as *VTK*.
|
|
||||||
|
|
||||||
2. Use CMake to generate VS projects for building the library:
|
|
||||||
- Start CMake-GUI and select VTK folder as source path, and the folder of your choice for VS project and intermediate build data.
|
|
||||||
- Click **Configure**.
|
|
||||||
- Select the VS version to be used from the ones you have installed (we recommend using VS 2010) and the architecture (32 or 64-bit).
|
|
||||||
- Generate VS projects with default CMake options. The open solution *VTK.sln* will be generated in the build folder.
|
|
||||||
|
|
||||||
3. Build project VTK in Release mode.
|
|
||||||
|
|
||||||
|
|
||||||
@section build_3rdparty_linux Linux
|
|
||||||
|
|
||||||
This document presents additional guidelines for building third-party
|
|
||||||
products used by Open CASCADE Technology and samples on Linux platform.
|
|
||||||
|
|
||||||
The links for downloading the third-party products are available on the web site at
|
|
||||||
https://opencascade.com/content/3rd-party-components.
|
|
||||||
|
|
||||||
There are two types of third-party products, which are necessary to build OCCT:
|
|
||||||
|
|
||||||
* Mandatory products:
|
|
||||||
* Tcl/Tk 8.5 - 8.6;
|
|
||||||
* FreeType 2.4.10 - 2.5.3;
|
|
||||||
* Optional products:
|
|
||||||
* TBB 3.x - 4.x;
|
|
||||||
* FreeImage 3.14.1 - 3.16.0;
|
|
||||||
* VTK 6.1.0.
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_linux_4 Installation From Official Repositories
|
|
||||||
|
|
||||||
**Debian-based distributives**
|
|
||||||
|
|
||||||
All 3rd-party products required for building of OCCT could be installed
|
|
||||||
from official repositories. You may install them from console using apt-get utility:
|
|
||||||
|
|
||||||
sudo apt-get install tcllib tklib tcl-dev tk-dev libfreetype-dev libx11-dev libgl1-mesa-dev libfreeimage-dev rapidjson-dev
|
|
||||||
|
|
||||||
Building is possible with C++ compliant compiler:
|
|
||||||
|
|
||||||
sudo apt-get install g++
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_linux_2_1 Tcl/Tk
|
|
||||||
|
|
||||||
Tcl/Tk is required for DRAW test harness.
|
|
||||||
|
|
||||||
**Installation from sources: Tcl**
|
|
||||||
|
|
||||||
Download the necessary archive from https://www.tcl.tk/software/tcltk/download.html and unpack it.
|
|
||||||
|
|
||||||
1. Enter the unix sub-directory of the directory where the Tcl source files are located <i>(TCL_SRC_DIR)</i>.
|
|
||||||
|
|
||||||
cd TCL_SRC_DIR/unix
|
|
||||||
|
|
||||||
2. Run the *configure* command:
|
|
||||||
|
|
||||||
configure --enable-gcc --enable-shared --enable-threads --prefix=TCL_INSTALL_DIR
|
|
||||||
|
|
||||||
For a 64 bit platform also add <i>--enable-64bit</i> option to the command line.
|
|
||||||
|
|
||||||
3. If the configure command has finished successfully, start the building process:
|
|
||||||
|
|
||||||
make
|
|
||||||
|
|
||||||
4. If building is finished successfully, start the installation of Tcl.
|
|
||||||
All binary and service files of the product will be copied to the directory defined by *TCL_INSTALL_DIR*
|
|
||||||
|
|
||||||
make install
|
|
||||||
|
|
||||||
**Installation from sources: Tk**
|
|
||||||
|
|
||||||
Download the necessary archive from https://www.tcl.tk/software/tcltk/download.html and unpack it.
|
|
||||||
|
|
||||||
1. Enter the unix sub-directory of the directory where the Tk source files are located <i>(TK_SRC_DIR)</i>
|
|
||||||
|
|
||||||
cd TK_SRC_DIR/unix
|
|
||||||
|
|
||||||
2. Run the configure command, where <i>TCL_LIB_DIR</i> is *TCL_INSTALL_DIR/lib*.
|
|
||||||
|
|
||||||
configure --enable-gcc --enable-shared --enable-threads --with-tcl=TCL_LIB_DIR --prefix=TK_INSTALL_DIR
|
|
||||||
|
|
||||||
For a 64 bit platform also add <i>--enable-64bit</i> option to the command line.
|
|
||||||
|
|
||||||
3. If the configure command has finished successfully, start the building process:
|
|
||||||
|
|
||||||
make
|
|
||||||
|
|
||||||
4. If the building has finished successfully, start the installation of Tk.
|
|
||||||
All binary and service files of the product will be copied
|
|
||||||
to the directory defined by *TK_INSTALL_DIR* (usually it is *TCL_INSTALL_DIR*)
|
|
||||||
|
|
||||||
make install
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_linux_2_2 FreeType
|
|
||||||
|
|
||||||
FreeType is required for text display in the 3D viewer.
|
|
||||||
Download the necessary archive from https://sourceforge.net/projects/freetype/files/ and unpack it.
|
|
||||||
|
|
||||||
1. Enter the directory where the source files of FreeType are located <i>(FREETYPE_SRC_DIR)</i>.
|
|
||||||
|
|
||||||
cd FREETYPE_SRC_DIR
|
|
||||||
|
|
||||||
2. Run the *configure* command:
|
|
||||||
|
|
||||||
configure --prefix=FREETYPE_INSTALL_DIR
|
|
||||||
|
|
||||||
For a 64 bit platform also add <i>CFLAGS='-m64 -fPIC' CPPFLAGS='-m64 -fPIC'</i> option to the command line.
|
|
||||||
|
|
||||||
3. If the *configure* command has finished successfully, start the building process:
|
|
||||||
|
|
||||||
make
|
|
||||||
|
|
||||||
4. If the building has finished successfully, start the installation of FreeType.
|
|
||||||
All binary and service files of the product will be copied to the directory defined by *FREETYPE_INSTALL_DIR*
|
|
||||||
|
|
||||||
make install
|
|
||||||
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_linux_3_1 TBB
|
|
||||||
|
|
||||||
This third-party product is installed with binaries from the archive that can be downloaded from https://github.com/intel/tbb.
|
|
||||||
Go to the **Download** page, find the release version you need and pick the archive for Linux platform.
|
|
||||||
To install, unpack the downloaded archive of TBB product.
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_linux_3_3 FreeImage
|
|
||||||
|
|
||||||
Download the necessary archive from https://sourceforge.net/projects/freeimage/files/Source%20Distribution/
|
|
||||||
and unpack it. The directory with unpacked sources is further referred to as *FREEIMAGE_SRC_DIR*.
|
|
||||||
|
|
||||||
1. Modify *FREEIMAGE_SRC_DIR/Source/OpenEXR/Imath/ImathMatrix.h*:
|
|
||||||
In line 60 insert the following:
|
|
||||||
|
|
||||||
#include string.h
|
|
||||||
|
|
||||||
2. Enter the directory where the source files of FreeImage are located <i>(FREEIMAGE_SRC_DIR)</i>.
|
|
||||||
|
|
||||||
cd FREEIMAGE_SRC_DIR
|
|
||||||
|
|
||||||
3. Run the building process
|
|
||||||
|
|
||||||
make
|
|
||||||
|
|
||||||
4. Run the installation process
|
|
||||||
|
|
||||||
a. If you have the permission to write into directories <i>/usr/include</i> and <i>/usr/lib</i>, run the following command:
|
|
||||||
|
|
||||||
make install
|
|
||||||
b. If you do not have this permission, you need to modify file *FREEIMAGE_SRC_DIR/Makefile.gnu*:
|
|
||||||
|
|
||||||
Change lines 7-9 from:
|
|
||||||
|
|
||||||
DESTDIR ?= /
|
|
||||||
INCDIR ?= $(DESTDIR)/usr/include
|
|
||||||
INSTALLDIR ?= $(DESTDIR)/usr/lib
|
|
||||||
|
|
||||||
to:
|
|
||||||
|
|
||||||
DESTDIR ?= $(DESTDIR)
|
|
||||||
INCDIR ?= $(DESTDIR)/include
|
|
||||||
INSTALLDIR ?= $(DESTDIR)/lib
|
|
||||||
|
|
||||||
Change lines 65-67 from:
|
|
||||||
|
|
||||||
install -m 644 -o root -g root $(HEADER) $(INCDIR)
|
|
||||||
install -m 644 -o root -g root $(STATICLIB) $(INSTALLDIR)
|
|
||||||
install -m 755 -o root -g root $(SHAREDLIB) $(INSTALLDIR)
|
|
||||||
|
|
||||||
to:
|
|
||||||
|
|
||||||
install -m 755 $(HEADER) $(INCDIR)
|
|
||||||
install -m 755 $(STATICLIB) $(INSTALLDIR)
|
|
||||||
install -m 755 $(SHAREDLIB) $(INSTALLDIR)
|
|
||||||
|
|
||||||
Change line 70 from:
|
|
||||||
|
|
||||||
ldconfig
|
|
||||||
|
|
||||||
to:
|
|
||||||
|
|
||||||
\#ldconfig
|
|
||||||
|
|
||||||
Then run the installation process by the following command:
|
|
||||||
|
|
||||||
make DESTDIR=FREEIMAGE_INSTALL_DIR install
|
|
||||||
|
|
||||||
5. Clean temporary files
|
|
||||||
|
|
||||||
make clean
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_linux_3_4 VTK
|
|
||||||
|
|
||||||
You can download VTK sources from https://www.vtk.org/VTK/resources/software.html
|
|
||||||
|
|
||||||
### The building procedure:
|
|
||||||
|
|
||||||
Download the necessary archive from https://www.vtk.org/VTK/resources/software.html and unpack it.
|
|
||||||
|
|
||||||
1. Install or build *cmake* product from the source file.
|
|
||||||
2. Start *cmake* in GUI mode with the directory where the source files of *VTK* are located:
|
|
||||||
|
|
||||||
ccmake VTK_SRC_DIR
|
|
||||||
|
|
||||||
* Press <i>[c]</i> to make the initial configuration
|
|
||||||
* Define the necessary options in *VTK_INSTALL_PREFIX*
|
|
||||||
* Press <i>[c]</i> to make the final configuration
|
|
||||||
* Press <i>[g]</i> to generate Makefile and exit
|
|
||||||
|
|
||||||
3. Start the building of VTK:
|
|
||||||
|
|
||||||
make
|
|
||||||
|
|
||||||
4. Start the installation of VTK. Binaries will be installed according to the *VTK_INSTALL_PREFIX* option.
|
|
||||||
|
|
||||||
make install
|
|
||||||
|
|
||||||
@section build_3rdparty_macos Mac OS X
|
|
||||||
|
|
||||||
This document presents additional guidelines for building third-party products
|
|
||||||
used by Open CASCADE Technology and samples on Mac OS X platform (10.6.4 and later).
|
|
||||||
|
|
||||||
The links for downloading the third-party products are available at https://opencascade.com/content/3rd-party-components.
|
|
||||||
|
|
||||||
There are two types of third-party products, which are necessary to build OCCT:
|
|
||||||
|
|
||||||
* Mandatory products:
|
|
||||||
* Tcl/Tk 8.5 - 8.6;
|
|
||||||
* FreeType 2.4.10 - 2.5.3.
|
|
||||||
* Optional products:
|
|
||||||
* TBB 3.x - 4.x;
|
|
||||||
* FreeImage 3.14.1 - 3.16.0
|
|
||||||
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_osx_2_1 Tcl/Tk 8.5
|
|
||||||
|
|
||||||
Tcl/Tk is required for DRAW test harness. Version 8.5 or 8.6 can be used with OCCT.
|
|
||||||
|
|
||||||
**Installation from sources: Tcl 8.5**
|
|
||||||
|
|
||||||
Download the necessary archive from https://www.tcl.tk/software/tcltk/download.html and unpack it.
|
|
||||||
|
|
||||||
1. Enter the *macosx* sub-directory of the directory where the Tcl source files are located <i>(TCL_SRC_DIR)</i>.
|
|
||||||
|
|
||||||
cd TCL_SRC_DIR/macosx
|
|
||||||
|
|
||||||
2. Run the *configure* command
|
|
||||||
|
|
||||||
configure --enable-gcc --enable-shared --enable-threads --prefix=TCL_INSTALL_DIR
|
|
||||||
|
|
||||||
For a 64 bit platform also add <i>--enable-64bit</i> option to the command line.
|
|
||||||
|
|
||||||
3. If the *configure* command has finished successfully, start the building process
|
|
||||||
|
|
||||||
make
|
|
||||||
|
|
||||||
4. If building is finished successfully, start the installation of Tcl.
|
|
||||||
All binary and service files of the product will be copied to the directory defined by *TCL_INSTALL_DIR*.
|
|
||||||
|
|
||||||
make install
|
|
||||||
|
|
||||||
**Installation from sources: Tk 8.5**
|
|
||||||
|
|
||||||
Download the necessary archive from https://www.tcl.tk/software/tcltk/download.html and unpack it.
|
|
||||||
|
|
||||||
1. Enter the *macosx* sub-directory of the directory where the source files of Tk are located <i>(TK_SRC_DIR)</i>.
|
|
||||||
|
|
||||||
cd TK_SRC_DIR/macosx
|
|
||||||
|
|
||||||
2. Run the *configure* command, where TCL_LIB_DIR is TCL_INSTALL_DIR/lib
|
|
||||||
|
|
||||||
configure --enable-gcc --enable-shared --enable-threads --with-tcl=TCL_LIB_DIR --prefix=TK_INSTALL_DIR
|
|
||||||
|
|
||||||
For a 64 bit platform also add <i>--enable-64bit</i> option to the command line.
|
|
||||||
|
|
||||||
3. If the *configure* command has finished successfully, start the building process:
|
|
||||||
|
|
||||||
make
|
|
||||||
|
|
||||||
4. If the building has finished successfully, start the installation of Tk. All binary and service files of the product will be copied to the directory defined by *TK_INSTALL_DIR* (usually it is TCL_INSTALL_DIR)
|
|
||||||
|
|
||||||
make install
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_osx_2_2 FreeType 2.4.10
|
|
||||||
|
|
||||||
FreeType is required for text display in the 3D viewer.
|
|
||||||
|
|
||||||
Download the necessary archive from https://sourceforge.net/projects/freetype/files/ and unpack it.
|
|
||||||
|
|
||||||
1. Enter the directory where the source files of FreeType are located <i>(FREETYPE_SRC_DIR)</i>.
|
|
||||||
|
|
||||||
cd FREETYPE_SRC_DIR
|
|
||||||
|
|
||||||
2. Run the *configure* command
|
|
||||||
|
|
||||||
configure --prefix=FREETYPE_INSTALL_DIR
|
|
||||||
|
|
||||||
For a 64 bit platform also add <i>CFLAGS='-m64 -fPIC' CPPFLAGS='-m64 -fPIC'</i> option to the command line.
|
|
||||||
|
|
||||||
3. If the *configure* command has finished successfully, start the building process
|
|
||||||
|
|
||||||
make
|
|
||||||
|
|
||||||
4. If building has finished successfully, start the installation of FreeType.
|
|
||||||
All binary and service files of the product will be copied to the directory defined by *FREETYPE_INSTALL_DIR*.
|
|
||||||
|
|
||||||
make install
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_osx_3_1 TBB 3.x or 4.x
|
|
||||||
|
|
||||||
This third-party product is installed with binaries from the archive
|
|
||||||
that can be downloaded from https://github.com/intel/tbb.
|
|
||||||
Go to the **Download** page, find the release version you need (e.g. *tbb30_018oss*)
|
|
||||||
and pick the archive for Mac OS X platform.
|
|
||||||
To install, unpack the downloaded archive of TBB 3.0 product (*tbb30_018oss_osx.tgz*).
|
|
||||||
|
|
||||||
@subsection dev_guides__building_3rdparty_osx_3_3 FreeImage 3.14.1 or 3.15.x
|
|
||||||
|
|
||||||
Download the necessary archive from
|
|
||||||
https://sourceforge.net/projects/freeimage/files/Source%20Distribution/
|
|
||||||
and unpack it. The directory with unpacked sources is further referred to as *FREEIMAGE_SRC_DIR*.
|
|
||||||
|
|
||||||
Note that for building FreeImage on Mac OS X 10.7 you should replace *Makefile.osx*
|
|
||||||
in *FREEIMAGE_SRC_DIR* by the corrected file, which you can find in attachment to issue #22811 in OCCT Mantis bug tracker
|
|
||||||
(https://tracker.dev.opencascade.org/file_download.php?file_id=6937&type=bug).
|
|
||||||
|
|
||||||
1. If you build FreeImage 3.15.x you can skip this step.
|
|
||||||
Modify <i>FREEIMAGE_SRC_DIR/Source/OpenEXR/Imath/ImathMatrix.h:</i>
|
|
||||||
|
|
||||||
In line 60 insert the following:
|
|
||||||
|
|
||||||
#include string.h
|
|
||||||
|
|
||||||
Modify <i>FREEIMAGE_SRC_DIR/Source/FreeImage/PluginTARGA.cpp:</i>
|
|
||||||
|
|
||||||
In line 320 replace:
|
|
||||||
|
|
||||||
SwapShort(value);
|
|
||||||
|
|
||||||
with:
|
|
||||||
|
|
||||||
SwapShort(&value);
|
|
||||||
|
|
||||||
2. Enter the directory where the source files of FreeImage are located <i>(FREEIMAGE_SRC_DIR)</i>.
|
|
||||||
|
|
||||||
cd FREEIMAGE_SRC_DIR
|
|
||||||
|
|
||||||
3. Run the building process
|
|
||||||
|
|
||||||
make
|
|
||||||
|
|
||||||
4. Run the installation process
|
|
||||||
|
|
||||||
1. If you have the permission to write into <i>/usr/local/include</i> and <i>/usr/local/lib</i> directories, run the following command:
|
|
||||||
|
|
||||||
make install
|
|
||||||
|
|
||||||
2. If you do not have this permission, you need to modify file *FREEIMAGE_SRC_DIR/Makefile.osx*:
|
|
||||||
|
|
||||||
Change line 49 from:
|
|
||||||
|
|
||||||
PREFIX ?= /usr/local
|
|
||||||
|
|
||||||
to:
|
|
||||||
|
|
||||||
PREFIX ?= $(PREFIX)
|
|
||||||
|
|
||||||
Change lines 65-69 from:
|
|
||||||
|
|
||||||
install -d -m 755 -o root -g wheel $(INCDIR) $(INSTALLDIR)
|
|
||||||
install -m 644 -o root -g wheel $(HEADER) $(INCDIR)
|
|
||||||
install -m 644 -o root -g wheel $(SHAREDLIB) $(STATICLIB) $(INSTALLDIR)
|
|
||||||
ranlib -sf $(INSTALLDIR)/$(STATICLIB)
|
|
||||||
ln -sf $(SHAREDLIB) $(INSTALLDIR)/$(LIBNAME)
|
|
||||||
|
|
||||||
to:
|
|
||||||
|
|
||||||
install -d $(INCDIR) $(INSTALLDIR)
|
|
||||||
install -m 755 $(HEADER) $(INCDIR)
|
|
||||||
install -m 755 $(STATICLIB) $(INSTALLDIR)
|
|
||||||
install -m 755 $(SHAREDLIB) $(INSTALLDIR)
|
|
||||||
ln -sf $(SHAREDLIB) $(INSTALLDIR)/$(VERLIBNAME)
|
|
||||||
ln -sf $(VERLIBNAME) $(INSTALLDIR)/$(LIBNAME)
|
|
||||||
|
|
||||||
Then run the installation process by the following command:
|
|
||||||
|
|
||||||
make PREFIX=FREEIMAGE_INSTALL_DIR install
|
|
||||||
|
|
||||||
5. Clean temporary files
|
|
||||||
|
|
||||||
make clean
|
|
BIN
dox/build/build_3rdparty/images/genconf_linux.png
vendored
Before Width: | Height: | Size: 42 KiB |
BIN
dox/build/build_3rdparty/images/genconf_windows.png
vendored
Before Width: | Height: | Size: 60 KiB |
@@ -1,19 +0,0 @@
|
|||||||
Build Documentation {#build_upgrade__building_documentation}
|
|
||||||
=================
|
|
||||||
|
|
||||||
To generate HTML documentation from sources contained in *dox* subdirectory,
|
|
||||||
you need to have Tcl and Doxygen 1.8.5 (or above) installed on your system.
|
|
||||||
|
|
||||||
Use script **gendoc** (batch file on Windows, shell script on Linux / Mac OSX) to generate documentation.
|
|
||||||
|
|
||||||
To generate Overview documentation:
|
|
||||||
|
|
||||||
cmd> gendoc -overview
|
|
||||||
|
|
||||||
To generate Reference manual:
|
|
||||||
|
|
||||||
cmd> gendoc -refman
|
|
||||||
|
|
||||||
Run this command without arguments to get help on supported options.
|
|
||||||
|
|
||||||
See @ref occt_contribution__documentation for prerequisites and details on OCCT documentation system.
|
|
@@ -1,409 +0,0 @@
|
|||||||
Build OCCT {#build_upgrade__building_occt}
|
|
||||||
===================
|
|
||||||
|
|
||||||
@tableofcontents
|
|
||||||
|
|
||||||
Before building OCCT, make sure to have all required third-party libraries installed.
|
|
||||||
The list of required libraries depends on what OCCT modules will be used, and your preferences.
|
|
||||||
The typical minimum is **FreeType** (necessary for Visualization) and **Tcl/Tk** (for DRAW).
|
|
||||||
See @ref intro_req "requirements on 3rdparty libraries" for a full list.
|
|
||||||
|
|
||||||
The easiest way to install third-party libraries is to download archive with pre-built binaries, corresponding to your target configuration,
|
|
||||||
from [Development Portal](https://dev.opencascade.org/resources/download/3rd-party-components).
|
|
||||||
You can also build third-party libraries from their sources, see @ref build_upgrade_building_3rdparty for instructions.
|
|
||||||
|
|
||||||
On Linux and macOS we recommend to use libraries maintained by distributive developers, when possible.
|
|
||||||
|
|
||||||
@section build_occt_win_cmake Building with CMake tool
|
|
||||||
|
|
||||||
This chapter describes the [CMake](https://cmake.org/download/)-based build process, which is now suggested as a standard way to produce the binaries of Open CASCADE Technology from sources.
|
|
||||||
OCCT requires CMake version 2.8.12 or later.
|
|
||||||
|
|
||||||
CMake is a tool that generates the actual project files for the selected target build system (e.g. Unix makefiles) or IDE (e.g. Visual Studio 2010).
|
|
||||||
Here we describe the build procedure on the example of Windows platform with Visual Studio 2010.
|
|
||||||
However, CMake is cross-platform and can be used to build OCCT on Linux and macOS in essentially the same way.
|
|
||||||
|
|
||||||
CMake deals with three directories: source, build or binary and installation.
|
|
||||||
|
|
||||||
* The source directory is where the sources of OCCT are located in your file system;
|
|
||||||
* The build or binary directory is where all files created during CMake configuration and generation process will be located. The mentioned process will be described below.
|
|
||||||
* The installation directory is where binaries will be installed after building the *INSTALL* project that is created by CMake generation process, along with header files and resources required for OCCT use in applications.
|
|
||||||
|
|
||||||
The good practice is not to use the source directory as a build one.
|
|
||||||
Different configurations should be built in different build directories to avoid conflicts.
|
|
||||||
It is however possible to choose one installation directory for several configurations of OCCT (differentiated by platform, bitness, compiler and build type), for example:
|
|
||||||
|
|
||||||
d:/occt/ - the source directory
|
|
||||||
d:/tmp/occt-build-vc10-x64 - the build directory with the generated
|
|
||||||
solution and other intermediate files created during a CMake tool working
|
|
||||||
d:/occt-install - the installation directory that is
|
|
||||||
able to contain several OCCT configurations
|
|
||||||
|
|
||||||
@subsection build_cmake_conf Configuration process
|
|
||||||
|
|
||||||
For unexperienced users we recommend to start with *cmake-gui* -- a cross-platform GUI tool provided by CMake on Windows, Mac and Linux.
|
|
||||||
A command-line alternative, *ccmake* can also be used.
|
|
||||||
|
|
||||||
If the command-line tool is used, run the tool from the build directory with a single argument indicating the source (relative or absolute path) directory, and press *c* to configure:
|
|
||||||
|
|
||||||
cd d:/tmp/occt-build-vc10-x64
|
|
||||||
ccmake d:/occt
|
|
||||||
|
|
||||||
@figure{/build/build_occt/images/cmake_image000.png}
|
|
||||||
|
|
||||||
If the GUI tool is used, run this tool without additional arguments and after that specify the source directory by clicking **Browse Source** and the build (binary) one by clicking **Browse Build**:
|
|
||||||
|
|
||||||
@figure{/build/build_occt/images/cmake_image001.png}
|
|
||||||
|
|
||||||
@note Each configuration of the project should be built in its own directory.
|
|
||||||
When building multiple configurations it is suggested to indicate in the name of build directories the system, bitness and compiler (e.g., <i>d:/occt/build/win32-vc10</i>).
|
|
||||||
|
|
||||||
Once the source and build directories are selected, "Configure" button should be pressed in order to start manual configuration process.
|
|
||||||
It begins with selection of a target configurator. It is "Visual Studio 10 2010 Win64" in our example.
|
|
||||||
|
|
||||||
@figure{/build/build_occt/images/cmake_image002.png}
|
|
||||||
|
|
||||||
@note To build OCCT for **Universal Windows Platform (UWP)** specify the path to toolchain file for cross-compiling <i>d:/occt/adm/templates/uwp.toolchain.config.cmake</i>.
|
|
||||||
Alternatively, if you are using CMake from the command line add options `-DCMAKE_SYSTEM_NAME=WindowsStore -DCMAKE_SYSTEM_VERSION=10.0`.
|
|
||||||
Universal Windows Platform (UWP) is supported only on "Visual Studio 14 2015".
|
|
||||||
File `CASROOT/samples/xaml/ReadMe.md` describes the building procedure of XAML (UWP) sample.
|
|
||||||
|
|
||||||
Once "Finish" button is pressed, the first pass of the configuration process is executed.
|
|
||||||
At the end of the process, CMake outputs the list of environment variables, which have to be properly specified for successful configuration.
|
|
||||||
|
|
||||||
@figure{/build/build_occt/images/cmake_image003.png}
|
|
||||||
|
|
||||||
The error message provides some information about these variables.
|
|
||||||
This message will appear after each pass of the process until all required variables are specified correctly.
|
|
||||||
|
|
||||||
The change of the state of some variables can lead to the appearance of new variables.
|
|
||||||
The new variables appeared after the pass of the configuration process are highlighted with red color by CMake GUI tool.
|
|
||||||
|
|
||||||
@note There is "grouped" option, which groups variables with a common prefix.
|
|
||||||
|
|
||||||
The following table gives the full list of environment variables used at the configuration stage:
|
|
||||||
|
|
||||||
| Variable | Type | Purpose |
|
|
||||||
|----------|------|---------|
|
|
||||||
| CMAKE_BUILD_TYPE | String | Specifies the build type on single-configuration generators (such as make). Possible values are Debug, Release and RelWithDebInfo |
|
|
||||||
| USE_FREETYPE | Boolean | Indicates whether FreeType product should be used in OCCT for text rendering |
|
|
||||||
| USE_FREEIMAGE | Boolean | Indicates whether FreeImage product should be used in OCCT visualization module for support of popular graphics image formats (PNG, BMP, etc.) |
|
|
||||||
| USE_OPENVR | Boolean | Indicates whether OpenVR product should be used in OCCT visualization module for support of Virtual Reality |
|
|
||||||
| USE_OPENGL | Boolean | Indicates whether TKOpenGl graphic driver using OpenGL library (desktop) should be built within OCCT visualization module |
|
|
||||||
| USE_GLES2 | Boolean | Indicates whether TKOpenGles graphic driver using OpenGL ES library (embedded OpenGL) should be built within OCCT visualization module |
|
|
||||||
| USE_RAPIDJSON | Boolean | Indicates whether RapidJSON product should be used in OCCT Data Exchange module for support of glTF mesh file format |
|
|
||||||
| USE_DRACO | Boolean | Indicates whether Draco product should be used in OCCT Data Exchange module for support of Draco compression in glTF mesh file format |
|
|
||||||
| USE_TK | Boolean | Indicates whether Tcl/Tk product should be used in OCCT Draw Harness module for user interface (in addition to Tcl, which is mandatory for Draw Harness) |
|
|
||||||
| USE_TBB | Boolean | Indicates whether TBB (Threading Building Blocks) 3rd party is used or not. Note that OCCT remains parallel even without TBB product |
|
|
||||||
| USE_VTK | Boolean | Indicates whether VTK 3rd party is used or not. OCCT comes with a bridge between CAD data representation and VTK by means of its dedicated VIS component (VTK Integration Services). You may skip this 3rd party unless you are planning to use VTK visualization for OCCT geometry. See the official documentation @ref occt_user_guides__vis for the details on VIS |
|
|
||||||
| 3RDPARTY_DIR | Path | Defines the root directory where all required 3rd party products will be searched. Once you define this path it is very convenient to click "Configure" button in order to let CMake automatically detect all necessary products|
|
|
||||||
| 3RDPARTY_FREETYPE_* | Path | Path to FreeType binaries |
|
|
||||||
| 3RDPARTY_TCL_* 3RDPARTY_TK_* | Path | Path to Tcl/Tk binaries |
|
|
||||||
| 3RDPARTY_FREEIMAGE* | Path | Path to FreeImage binaries |
|
|
||||||
| 3RDPARTY_TBB* | Path | Path to TBB binaries |
|
|
||||||
| 3RDPARTY_VTK_* | Path | Path to VTK binaries |
|
|
||||||
| BUILD_MODULE_<MODULE>| Boolean | Indicates whether the corresponding OCCT module should be built or not. It should be noted that some toolkits of a module can be built even if this module is not checked (this happens if some other modules depend on these toolkits). The main modules and their descriptions can be found in @ref user_guides |
|
|
||||||
| BUILD_LIBRARY_TYPE | String | Specifies the type of library to be created. "Shared" libraries are linked dynamically and loaded at runtime. "Static" libraries are archives of object files used when linking other targets. Note that Draw Harness plugin system is incompatible with "Static" builds, and therefore it is disabled for these builds.|
|
|
||||||
| BUILD_ADDITIONAL_TOOLKITS | String | Semicolon-separated individual toolkits to include into build process. If you want to build some particular libraries (toolkits) only, then you may uncheck all modules in the corresponding *BUILD_MODUE_\<MODULE\>* options and provide the list of necessary libraries here. Of course, all dependencies will be resolved automatically |
|
|
||||||
| BUILD_YACCLEX | Boolean | Enables Flex/Bison lexical analyzers. OCCT source files relating to STEP reader and ExprIntrp functionality are generated automatically with Flex/Bison. Checking this option leads to automatic search of Flex/Bison binaries and regeneration of the mentioned files |
|
|
||||||
| BUILD_SAMPLES_MFC | Boolean | Indicates whether MFC samples should be built together with OCCT. This option is only relevant to Windows platforms |
|
|
||||||
| BUILD_SAMPLES_QT | Boolean | Indicates whether QT samples should be built together with OCCT. |
|
|
||||||
| BUILD_Inspector | Boolean | Indicates whether Inspector should be built together with OCCT. |
|
|
||||||
| BUILD_DOC_Overview | Boolean | Indicates whether OCCT overview documentation project should be created together with OCCT. It is not built together with OCCT. Checking this option leads to automatic search of Doxygen binaries. Its building calls Doxygen command to generate the documentation in HTML format |
|
|
||||||
| BUILD_PATCH | Path | Points to the directory recognized as a "patch" for OCCT. If specified, the files from this directory take precedence over the corresponding native OCCT sources. This way you are able to introduce patches to Open CASCADE Technology not affecting the original source distribution |
|
|
||||||
| BUILD_WITH_DEBUG | Boolean | Enables extended messages of many OCCT algorithms, usually printed to cout. These include messages on internal errors and special cases encountered, timing, etc. |
|
|
||||||
| BUILD_ENABLE_FPE_SIGNAL_HANDLER | Boolean | Enable/Disable the floating point exceptions (FPE) during DRAW execution only. Corresponding environment variable (CSF_FPE) can be changed manually in custom.bat/sh scripts without regeneration by CMake. |
|
|
||||||
| CMAKE_CONFIGURATION_TYPES | String | Semicolon-separated CMake configurations |
|
|
||||||
| INSTALL_DIR | Path | Points to the installation directory. *INSTALL_DIR* is a synonym of *CMAKE_INSTALL_PREFIX*. The user can specify both *INSTALL_DIR* or *CMAKE_INSTALL_PREFIX* |
|
|
||||||
| INSTALL_DIR_BIN | Path | Relative path to the binaries installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_BIN}) |
|
|
||||||
| INSTALL_DIR_SCRIPT | Path | Relative path to the scripts installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_SCRIPT}) |
|
|
||||||
| INSTALL_DIR_LIB | Path | Relative path to the libraries installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_LIB}) |
|
|
||||||
| INSTALL_DIR_INCLUDE | Path | Relative path to the includes installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_INCLUDE}) |
|
|
||||||
| INSTALL_DIR_RESOURCE | Path | Relative path to the resources installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_RESOURCE}) |
|
|
||||||
| INSTALL_DIR_LAYOUT | String | Defines the structure of OCCT files (binaries, resources, headers, etc.) for the install directory. Two variants are predefined: for Windows (standard OCCT layout) and for Unix operating systems (standard Linux layout). If needed, the layout can be customized with INSTALL_DIR_* variables |
|
|
||||||
| INSTALL_DIR_DATA | Path | Relative path to the data files installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_DATA}) |
|
|
||||||
| INSTALL_DIR_SAMPLES | Path | Relative path to the samples installation directory. Note that only "samples/tcl" folder will be installed. (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_SAMPLES}) |
|
|
||||||
| INSTALL_DIR_TESTS | Path | Relative path to the tests installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_TESTS}) |
|
|
||||||
| INSTALL_DIR_DOC | Path | Relative path to the documentation installation directory (absolute path is ${INSTALL_DIR}/${INSTALL_DIR_DOC}) |
|
|
||||||
| INSTALL_FREETYPE | Boolean | Indicates whether FreeType binaries should be installed into the installation directory |
|
|
||||||
| INSTALL_FREEIMAGE | Boolean | Indicates whether FreeImage binaries should be installed into the installation directory |
|
|
||||||
| INSTALL_TBB | Boolean | Indicates whether TBB binaries should be installed into the installation directory |
|
|
||||||
| INSTALL_VTK | Boolean | Indicates whether VTK binaries should be installed into the installation directory |
|
|
||||||
| INSTALL_TCL | Boolean | Indicates whether TCL binaries should be installed into the installation directory |
|
|
||||||
| INSTALL_TEST_CASES | Boolean | Indicates whether non-regression OCCT test scripts should be installed into the installation directory |
|
|
||||||
| INSTALL_DOC_Overview | Boolean | Indicates whether OCCT overview documentation should be installed into the installation directory |
|
|
||||||
|
|
||||||
@note Only the forward slashes ("/") are acceptable in the CMake options defining paths.
|
|
||||||
|
|
||||||
@subsubsection build_cmake_3rdparty 3rd party search mechanism
|
|
||||||
|
|
||||||
If `3RDPARTY_DIR` directory is defined, then required 3rd party binaries are sought in it, and default system folders are ignored.
|
|
||||||
The procedure expects to find binary and header files of each 3rd party product in its own sub-directory: *bin*, *lib* and *include*.
|
|
||||||
The results of the search (achieved on the next pass of the configuration process) are recorded in the corresponding variables:
|
|
||||||
|
|
||||||
* `3RDPARTY_<PRODUCT>_DIR` -- path to the 3rdparty directory (with directory name) (e.g. <i>D:/3rdparty/tcltk-86-32</i>);
|
|
||||||
* `3RDPARTY_<PRODUCT>_LIBRARY_DIR` -- path to the directory containing a library (e.g. <i>D:/3rdparty/tcltk-86-32/lib</i>);
|
|
||||||
* `3RDPARTY_<PRODUCT>_INCLUDE_DIR` -- path to the directory containing a header file (e.g., <i>D:/3rdparty/tcltk-86-32/include</i>);
|
|
||||||
* `3RDPARTY_<PRODUCT>_DLL_DIR` -- path to the directory containing a shared library (e.g., <i>D:/3rdparty/tcltk-86-32/bin</i>) This variable is only relevant to Windows platforms.
|
|
||||||
|
|
||||||
@note Each library and include directory should be children of the product directory if the last one is defined.
|
|
||||||
|
|
||||||
The search process is as follows:
|
|
||||||
|
|
||||||
1. Common path: `3RDPARTY_DIR`
|
|
||||||
2. Path to a particular 3rd-party library: `3RDPARTY_<PRODUCT>_DIR`
|
|
||||||
3. Paths to headers and binaries:
|
|
||||||
1. `3RDPARTY_<PRODUCT>_INCLUDE_DIR`
|
|
||||||
2. `3RDPARTY_<PRODUCT>_LIBRARY_DIR`
|
|
||||||
3. `3RDPARTY_<PRODUCT>_DLL_DIR`
|
|
||||||
|
|
||||||
If a variable of any level is not defined (empty or `<variable name>-NOTFOUND`) and the upper level variable is defined, the content of the non-defined variable will be sought at the next configuration step.
|
|
||||||
If the search process at level 3 does not find the required files, it seeks in default places.
|
|
||||||
|
|
||||||
If a search result (include path, or library path, or dll path) does not meet your expectations, you can change `3RDPARTY_<PRODUCT>_*_DIR` variable,
|
|
||||||
clear (if they are not empty) `3RDPARTY_<PRODUCT>_DLL_DIR`, `3RDPARTY_<PRODUCT>_INCLUDE_DIR` and `3RDPARTY_<PRODUCT>_LIBRARY_DIR` variables (or clear one of them) and run the configuration process again.
|
|
||||||
|
|
||||||
At this time the search will be performed in the newly identified directory and the result will be recorded to corresponding variables (replace old value if it is necessary).
|
|
||||||
For example, `3RDPARTY_FREETYPE_DIR` variable
|
|
||||||
|
|
||||||
d:/3rdparty/freetype-2.4.10
|
|
||||||
|
|
||||||
can be changed to
|
|
||||||
|
|
||||||
d:/3rdparty/freetype-2.5.3
|
|
||||||
|
|
||||||
During the configuration process the related variables (`3RDPARTY_FREETYPE_DLL_DIR`, `3RDPARTY_FREETYPE_INCLUDE_DIR` and `3RDPARTY_FREETYPE_LIBRARY_DIR`) will be filled with new found values.
|
|
||||||
|
|
||||||
@note The names of searched libraries and header files are hard-coded.
|
|
||||||
If there is the need to change their names, change appropriate CMake variables (edit CMakeCache.txt file or edit in cmake-gui in advance mode) without reconfiguration:
|
|
||||||
`3RDPARTY_<PRODUCT>_INCLUDE` for include, `3RDPARTY_<PRODUCT>_LIB` for library and `3RDPARTY_<PRODUCT>_DLL` for shared library.
|
|
||||||
|
|
||||||
@subsection build_cmake_gen Projects generation
|
|
||||||
|
|
||||||
Once the configuration process is done, the "Generate" button is used to prepare project files for the target IDE.
|
|
||||||
In our exercise the Visual Studio solution will be automatically created in the build directory.
|
|
||||||
|
|
||||||
@subsection build_cmake_build Building
|
|
||||||
|
|
||||||
Go to the build folder, start the Visual Studio solution *OCCT.sln* and build it by clicking **Build -> Build Solution**.
|
|
||||||
|
|
||||||
@figure{/build/build_occt/images/cmake_image004.png}
|
|
||||||
|
|
||||||
By default, the build solution process skips the building of the INSTALL and Overview projects.
|
|
||||||
When the building process is finished build:
|
|
||||||
* *Overview* project to generate OCCT overview documentation (if `BUILD_DOC_Overview` variable is checked)
|
|
||||||
* the *INSTALL* project to run the **installation process**
|
|
||||||
|
|
||||||
For this, right-click on the *Overview/INSTALL* project and select **Project Only -> Build Only** -> *Overview/INSTALL* in the solution explorer.
|
|
||||||
|
|
||||||
@subsection build_cmake_install Installation
|
|
||||||
|
|
||||||
Installation is a process of extracting redistributable resources (binaries, include files etc) from the build directory into the installation one.
|
|
||||||
The installation directory will be free of project files, intermediate object files and any other information related to the build routines.
|
|
||||||
|
|
||||||
Normally you use the installation directory of OCCT to link against your specific application.
|
|
||||||
The directory structure is as follows:
|
|
||||||
|
|
||||||
data - data files for OCCT (brep, iges, stp)
|
|
||||||
doc - OCCT overview documentation in HTML format
|
|
||||||
inc - header files
|
|
||||||
samples - samples
|
|
||||||
src - all required source files for OCCT
|
|
||||||
tests - OCCT test suite
|
|
||||||
win32\vc10\bind - binary files (installed 3rdparties and occt)
|
|
||||||
\libd - libraries (installed 3rdparties and occt)
|
|
||||||
|
|
||||||
@note The above example is given for debug configuration.
|
|
||||||
However, it is generally safe to use the same installation directory for the release build.
|
|
||||||
In the latter case the contents of install directory will be enriched with subdirectories and files related to the release configuration.
|
|
||||||
In particular, the binaries directory win64 will be expanded as follows:
|
|
||||||
|
|
||||||
\win32\vc10\bind
|
|
||||||
\libd
|
|
||||||
\bin
|
|
||||||
\lib
|
|
||||||
|
|
||||||
If CMake installation flags are enabled for the 3rd party products (e.g. `INSTALL_FREETYPE`), then the corresponding binaries will be copied to the same bin(d) and lib(d) directories together with the native binaries of OCCT.
|
|
||||||
Such organization of libraries can be especially helpful if your OCCT-based software does not use itself the 3rd parties of Open CASCADE Technology (thus, there is no sense to pack them into dedicated directories).
|
|
||||||
|
|
||||||
The installation folder contains the scripts to run *DRAWEXE* (*draw.bat* or *draw.sh*), samples (if they were installed) and overview.html (short-cut for installed OCCT overview documentation).
|
|
||||||
|
|
||||||
@subsection build_occt_crossplatform_cmake Cross-compiling (Android)
|
|
||||||
|
|
||||||
This section describes the steps to build OCCT libraries for Android from a complete source package with GNU make (makefiles).
|
|
||||||
The steps on Windows 7 and Ubuntu 15.10 are similar. There is the only one difference: makefiles are built with mingw32-make on Windows and native GNU make on Ubuntu.
|
|
||||||
|
|
||||||
Required tools (download and install if it is required):
|
|
||||||
- CMake 3.0+
|
|
||||||
- [Cross-compilation toolchain for CMake](https://github.com/taka-no-me/android-cmake)
|
|
||||||
- [Android NDK r12+](https://developer.android.com/ndk/downloads)
|
|
||||||
- GNU Make: MinGW v4.82+ for [Windows](https://www.mingw-w64.org/), GNU Make 4.0 for Ubuntu.
|
|
||||||
|
|
||||||
Run GUI tool provided by CMake and:
|
|
||||||
- Specify the root folder of OCCT (`$CASROOT`, which contains *CMakelists.txt* file) by clicking **Browse Source**.
|
|
||||||
- Specify the location (build folder) for CMake generated project files by clicking **Browse Build**.
|
|
||||||
|
|
||||||
@figure{/build/build_occt/images/android_image001.png}
|
|
||||||
|
|
||||||
Click **Configure** button. It opens the window with a drop-down list of generators supported by CMake project.
|
|
||||||
Select "MinGW MakeFiles" item from the list
|
|
||||||
- Choose "Specify toolchain file for cross-compiling", and click "Next".
|
|
||||||
@figure{/build/build_occt/images/android_image002.png}
|
|
||||||
|
|
||||||
- Specify a toolchain file at the next dialog to `android.toolchain.cmake`, and click "Finish".
|
|
||||||
@figure{/build/build_occt/images/android_image003.png}
|
|
||||||
|
|
||||||
If `ANDROID_NDK` environment variable is not defined in current OS, add cache entry `ANDROID_NDK` (entry type is `PATH`) -- path to the NDK folder ("Add Entry" button):
|
|
||||||
@figure{/build/build_occt/images/android_image004.png}
|
|
||||||
|
|
||||||
If on Windows the message is appeared:
|
|
||||||
"CMake Error: CMake was unable to find a build program corresponding to "MinGW Makefiles" CMAKE_MAKE_PROGRAM is not set. You probably need to select a different build tool.",
|
|
||||||
specify `CMAKE_MAKE_PROGRAM` to mingw32-make executable.
|
|
||||||
@figure{/build/build_occt/images/android_image005.png}
|
|
||||||
|
|
||||||
How to configure OCCT, see @ref build_cmake_conf "Configure" section taking into account the specific configuration variables for Android:
|
|
||||||
- `ANDROID_ABI` = `armeabi-v7a`
|
|
||||||
- `ANDROID_NATIVE_API_LEVEL` = `15`
|
|
||||||
- `ANDROID_NDK_LAYOUT` is equal to `CMAKE_BUILD_TYPE` variable
|
|
||||||
- `BUILD_MODULE_Draw` = `OFF`
|
|
||||||
|
|
||||||
@figure{/build/build_occt/images/android_image006.png}
|
|
||||||
|
|
||||||
Click **Generate** button and wait until the generation process is finished.
|
|
||||||
Then makefiles will appear in the build folder (e.g. <i> D:/tmp/occt-android </i>).
|
|
||||||
|
|
||||||
Open console and go to the build folder. Type "mingw32-make" (Windows) or "make" (Ubuntu) to start build process:
|
|
||||||
> mingw32-make
|
|
||||||
or
|
|
||||||
> make
|
|
||||||
|
|
||||||
Parallel building can be started with using `-jN` argument of "mingw32-make/make", where `N` is the number of building threads:
|
|
||||||
> mingw32-make -j4
|
|
||||||
or
|
|
||||||
> make -j4
|
|
||||||
|
|
||||||
Type "mingw32-make/make" with argument "install" to place the libraries to the install folder:
|
|
||||||
> mingw32-make install
|
|
||||||
or
|
|
||||||
> make install
|
|
||||||
|
|
||||||
@section build_occt_genproj Building with Genproj tool
|
|
||||||
|
|
||||||
**genproj** is a legacy tool (originated from command "wgenproj" in WOK) for generation of Visual Studio, Code::Blocks, Qt Creator (qmake), and XCode project files for building Open CASCADE Technology.
|
|
||||||
These project files are placed inside OCCT directory (in *adm* subfolder) and use relative paths, thus can be moved together with sources.
|
|
||||||
The project files included in official distribution of OCCT are generated by this tool.
|
|
||||||
|
|
||||||
@note If you have official distribution with project files included, you can use them directly without a need to call **genproj**.
|
|
||||||
|
|
||||||
**genproj** is a less flexible alternative to use of CMake build system (see @ref build_occt_win_cmake), but still has some small features useful for OCCT development.
|
|
||||||
|
|
||||||
@subsection build_genproj Configuration process
|
|
||||||
|
|
||||||
The environment is defined in the file *custom.sh* (on Linux and macOS) or *custom.bat* (on Windows) which can be edited directly:
|
|
||||||
|
|
||||||
* `ARCH` -- architecture (32 or 64), affects only `PATH` variable for execution
|
|
||||||
* `HAVE_*` -- flags to enable or disable use of optional third-party products
|
|
||||||
* `CSF_OPT_*` -- paths to search for includes and binaries of all used third-party products
|
|
||||||
* `SHORTCUT_HEADERS` -- defines method for population of folder *inc* by header files. Supported methods are:
|
|
||||||
* *Copy* - headers will be copied from *src*;
|
|
||||||
* *ShortCut* - short-cut header files will be created, redirecting to same-named header located in *src*;
|
|
||||||
* *HardLink* - hard links to headers located in *src* will be created.
|
|
||||||
* `VCVER` -- specification of format of project files, defining also version of Visual Studio to be used, and default name of the sub-folder for binaries:
|
|
||||||
* Add paths to includes of used third-party libraries in variable `CSF_OPT_INC`.
|
|
||||||
* Add paths to their binary libraries in variable `CSF_OPT_LIB64`.
|
|
||||||
* For optional third-party libraries, set corresponding environment variable `HAVE_<LIBRARY_NAME>` to either *false*, e.g. `export HAVE_FREEIMAGE=false`.
|
|
||||||
|
|
||||||
| VCVER | Visual Studio version | Windows Platform | Binaries folder name |
|
|
||||||
|-----------|-----------------------|----------------------------------|----------------------|
|
|
||||||
| vc10 | 2010 (10) | Desktop (Windows API) | vc10 |
|
|
||||||
| vc11 | 2012 (11) | Desktop (Windows API) | vc11 |
|
|
||||||
| vc12 | 2013 (12) | Desktop (Windows API) | vc12 |
|
|
||||||
| vc14 | 2015 (14) | Desktop (Windows API) | vc14 |
|
|
||||||
| vc14-uwp | 2015 (14) | UWP (Universal Windows Platform) | vc14-uwp |
|
|
||||||
| vc141 | 2017 (15) | Desktop (Windows API) | vc14 |
|
|
||||||
| vc141-uwp | 2017 (15) | UWP (Universal Windows Platform) | vc14-uwp |
|
|
||||||
| vc142 | 2019 (16) | Desktop (Windows API) | vc14 |
|
|
||||||
| vc142-uwp | 2019 (16) | UWP (Universal Windows Platform) | vc14-uwp |
|
|
||||||
|
|
||||||
Alternatively, you can launch **genconf**, a GUI tool allowing to configure build options interactively.
|
|
||||||
That tool will analyze your environment and propose you to choose available options:
|
|
||||||
|
|
||||||
* Type and version of project files to generate (from the list of installed ones, detected by presence of environment variables like `VS100COMNTOOLS` on Windows platform).
|
|
||||||
* Method to populate folder *inc* (short-cuts by default).
|
|
||||||
* Location of third-party libraries (usually downloaded from OCCT web site, see above).
|
|
||||||
* Path to common directory where third-party libraries are located (optional).
|
|
||||||
* Paths to headers and binaries of the third-party libraries (found automatically basing on previous options; click button "Reset" to update).
|
|
||||||
* Generation of PDB files within Release build ("Release with Debug info", false by default).
|
|
||||||
|
|
||||||
Below are screenshots of **genconf** tool on various platforms (Windows and Linux):
|
|
||||||
@figure{/build/build_occt/images/genconf_windows.png}
|
|
||||||
@figure{/build/build_occt/images/genconf_linux.png}
|
|
||||||
|
|
||||||
Click "Save" to store the specified configuration in *custom.bat* (Windows) or *custom.sh* (other systems) file.
|
|
||||||
|
|
||||||
@subsection build_genproj_generate Projects generation
|
|
||||||
|
|
||||||
Launch **genproj** to update content of *inc* folder and generate project files after changes in OCCT code affecting layout or composition of source files.
|
|
||||||
|
|
||||||
@note To use **genproj** and **genconf** tools you need to have Tcl installed and accessible by `PATH`.
|
|
||||||
If Tcl is not found, the tool may prompt you to enter the path to directory where Tcl can be found.
|
|
||||||
|
|
||||||
~~~~
|
|
||||||
$ genproj.bat
|
|
||||||
~~~~
|
|
||||||
|
|
||||||
Note that if *custom.bat* is not present, **genproj** will start **genconf** to configure environment.
|
|
||||||
|
|
||||||
@subsection build_genproj_build Building
|
|
||||||
|
|
||||||
@subsubsection build_msvc_build Visual Studio
|
|
||||||
|
|
||||||
Launch *msvc.bat* to start Visual Studio with all necessary environment variables defined, and build the whole solution or required toolkits.
|
|
||||||
|
|
||||||
The MSVC project files are located in folders <i>adm\\msvc\\vc...</i>.
|
|
||||||
Binaries are produced in *win32* or *win64* folders.
|
|
||||||
|
|
||||||
To start DRAW, launch *draw.bat*.
|
|
||||||
|
|
||||||
@subsubsection build_codeblocks_build Code::Blocks
|
|
||||||
|
|
||||||
Code::Blocks is a cross-platform IDE which can be used for building OCCT on Linux, macOS and Windows platforms.
|
|
||||||
The generated Code::Blocks project could be found within subfolder *adm/<OS>/cbp*.
|
|
||||||
|
|
||||||
To start **Code::Blocks**, launch script *codeblocks.sh*.
|
|
||||||
To build all toolkits, click **Build->Build workspace** in the menu bar.
|
|
||||||
|
|
||||||
To start *DRAWEXE*, which has been built with **Code::Blocks** on Mac OS X, run the script
|
|
||||||
~~~~
|
|
||||||
./draw.sh cbp [d]
|
|
||||||
~~~~
|
|
||||||
Option *d* is used if OCCT has been built in **Debug** mode.
|
|
||||||
|
|
||||||
@subsubsection build_occt_macos_xcode XCode
|
|
||||||
|
|
||||||
XCode is an IDE for development on macOS platform and targeting macOS and iOS platforms.
|
|
||||||
**genproj** tool comes with a legacy XCode project files generator, but CMake is a preferred way for building OCCT on macOS platform.
|
|
||||||
|
|
||||||
To start **XCode**, launch script *xcode.sh*.
|
|
||||||
To build a certain toolkit, select it in **Scheme** drop-down list in XCode toolbar, press **Product** in the menu and click **Build** button.
|
|
||||||
|
|
||||||
To build the entire OCCT:
|
|
||||||
* Create a new empty project (select **File -> New -> Project -> Empty project** in the menu; input the project name, e.g. *OCCT*; then click **Next** and **Create**).
|
|
||||||
* Drag and drop the *OCCT* folder in the created *OCCT* project in the Project navigator.
|
|
||||||
* Select **File -> New -> Target -> Aggregate** in the menu.
|
|
||||||
* Enter the project name (e.g. *OCCT*) and click **Finish**. The **Build Phases** tab will open.
|
|
||||||
* Click "+" button to add the necessary toolkits to the target project. It is possible to select all toolkits by pressing **Command+A** combination.
|
|
||||||
|
|
||||||
To start *DRAWEXE*, which has been built with XCode on Mac OS X, perform the following steps:
|
|
||||||
|
|
||||||
1.Open Terminal application
|
|
||||||
2.Enter `<OCCT_ROOT_DIR>`:
|
|
||||||
~~~~
|
|
||||||
cd \<OCCT_ROOT_DIR\>
|
|
||||||
~~~~
|
|
||||||
3.Run the script
|
|
||||||
~~~~
|
|
||||||
./draw.sh xcd [d]
|
|
||||||
~~~~
|
|
||||||
|
|
||||||
Option *d* is used if OCCT has been built in **Debug** mode.
|
|
Before Width: | Height: | Size: 57 KiB |
Before Width: | Height: | Size: 32 KiB |
Before Width: | Height: | Size: 46 KiB |
Before Width: | Height: | Size: 25 KiB |
Before Width: | Height: | Size: 66 KiB |
Before Width: | Height: | Size: 80 KiB |
Before Width: | Height: | Size: 42 KiB |
Before Width: | Height: | Size: 60 KiB |
@@ -1,10 +0,0 @@
|
|||||||
Build, Debug and Upgrade {#build_upgrade}
|
|
||||||
=================
|
|
||||||
|
|
||||||
This chapter contains the detailed information about building, debugging and upgrade procedures:
|
|
||||||
|
|
||||||
* @subpage build_upgrade__building_occt
|
|
||||||
* @subpage build_upgrade_building_3rdparty
|
|
||||||
* @subpage build_upgrade__building_documentation
|
|
||||||
* @subpage occt__debug
|
|
||||||
* @subpage occt__upgrade
|
|
@@ -1,10 +0,0 @@
|
|||||||
Contribution {#contribution}
|
|
||||||
============
|
|
||||||
|
|
||||||
This chapter contains the detailed information about contribution procedure:
|
|
||||||
|
|
||||||
* @subpage occt_contribution__contribution_workflow
|
|
||||||
* @subpage occt_contribution__git_guide
|
|
||||||
* @subpage occt_contribution__coding_rules
|
|
||||||
* @subpage occt_contribution__tests
|
|
||||||
* @subpage occt_contribution__documentation
|
|
217
dox/dev_guides/building/3rdparty/3rdparty_linux.md
vendored
Normal file
@@ -0,0 +1,217 @@
|
|||||||
|
Building 3rd-party libraries on Linux {#occt_dev_guides__building_3rdparty_linux}
|
||||||
|
=========
|
||||||
|
|
||||||
|
@tableofcontents
|
||||||
|
|
||||||
|
@section dev_guides__building_3rdparty_linux_1 Introduction
|
||||||
|
|
||||||
|
This document presents additional guidelines for building third-party
|
||||||
|
products used by Open CASCADE Technology and samples on Linux platform.
|
||||||
|
|
||||||
|
The links for downloading the third-party products are available on the web site
|
||||||
|
of OPEN CASCADE SAS at
|
||||||
|
https://www.opencascade.com/content/3rd-party-components.
|
||||||
|
|
||||||
|
There are two types of third-party products, which are necessary to build OCCT:
|
||||||
|
|
||||||
|
* Mandatory products:
|
||||||
|
* Tcl/Tk 8.5 - 8.6;
|
||||||
|
* FreeType 2.4.10 - 2.5.3;
|
||||||
|
* Optional products:
|
||||||
|
* TBB 3.x - 4.x;
|
||||||
|
* FreeImage 3.14.1 - 3.16.0;
|
||||||
|
* VTK 6.1.0.
|
||||||
|
|
||||||
|
@section dev_guides__building_3rdparty_linux_2 Building Mandatory Third-party Products
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_linux_2_1 Tcl/Tk
|
||||||
|
|
||||||
|
Tcl/Tk is required for DRAW test harness.
|
||||||
|
|
||||||
|
@subsubsection dev_guides__building_3rdparty_linux_2_1_2 Installation from sources: Tcl
|
||||||
|
|
||||||
|
Download the necessary archive from https://www.tcl.tk/software/tcltk/download.html and unpack it.
|
||||||
|
|
||||||
|
1. Enter the unix sub-directory of the directory where the Tcl source files are located <i>(TCL_SRC_DIR)</i>.
|
||||||
|
|
||||||
|
cd TCL_SRC_DIR/unix
|
||||||
|
|
||||||
|
2. Run the *configure* command:
|
||||||
|
|
||||||
|
configure --enable-gcc --enable-shared --enable-threads --prefix=TCL_INSTALL_DIR
|
||||||
|
|
||||||
|
For a 64 bit platform also add <i>--enable-64bit</i> option to the command line.
|
||||||
|
|
||||||
|
3. If the configure command has finished successfully, start the building process:
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
4. If building is finished successfully, start the installation of Tcl.
|
||||||
|
All binary and service files of the product will be copied to the directory defined by *TCL_INSTALL_DIR*
|
||||||
|
|
||||||
|
make install
|
||||||
|
|
||||||
|
@subsubsection dev_guides__building_3rdparty_linux_2_1_3 Installation from sources: Tk
|
||||||
|
|
||||||
|
Download the necessary archive from https://www.tcl.tk/software/tcltk/download.html and unpack it.
|
||||||
|
|
||||||
|
1. Enter the unix sub-directory of the directory where the Tk source files are located <i>(TK_SRC_DIR)</i>
|
||||||
|
|
||||||
|
cd TK_SRC_DIR/unix
|
||||||
|
|
||||||
|
2. Run the configure command, where <i>TCL_LIB_DIR</i> is *TCL_INSTALL_DIR/lib*.
|
||||||
|
|
||||||
|
configure --enable-gcc --enable-shared --enable-threads --with-tcl=TCL_LIB_DIR --prefix=TK_INSTALL_DIR
|
||||||
|
|
||||||
|
For a 64 bit platform also add <i>--enable-64bit</i> option to the command line.
|
||||||
|
|
||||||
|
3. If the configure command has finished successfully, start the building process:
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
4. If the building has finished successfully, start the installation of Tk.
|
||||||
|
All binary and service files of the product will be copied
|
||||||
|
to the directory defined by *TK_INSTALL_DIR* (usually it is *TCL_INSTALL_DIR*)
|
||||||
|
|
||||||
|
make install
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_linux_2_2 FreeType
|
||||||
|
|
||||||
|
FreeType is required for text display in the 3D viewer.
|
||||||
|
Download the necessary archive from https://sourceforge.net/projects/freetype/files/ and unpack it.
|
||||||
|
|
||||||
|
1. Enter the directory where the source files of FreeType are located <i>(FREETYPE_SRC_DIR)</i>.
|
||||||
|
|
||||||
|
cd FREETYPE_SRC_DIR
|
||||||
|
|
||||||
|
2. Run the *configure* command:
|
||||||
|
|
||||||
|
configure --prefix=FREETYPE_INSTALL_DIR
|
||||||
|
|
||||||
|
For a 64 bit platform also add <i>CFLAGS='-m64 -fPIC' CPPFLAGS='-m64 -fPIC'</i> option to the command line.
|
||||||
|
|
||||||
|
3. If the *configure* command has finished successfully, start the building process:
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
4. If the building has finished successfully, start the installation of FreeType.
|
||||||
|
All binary and service files of the product will be copied to the directory defined by *FREETYPE_INSTALL_DIR*
|
||||||
|
|
||||||
|
make install
|
||||||
|
|
||||||
|
@section dev_guides__building_3rdparty_linux_3 Building Optional Third-party Products
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_linux_3_1 TBB
|
||||||
|
|
||||||
|
This third-party product is installed with binaries from the archive that can be downloaded from https://github.com/intel/tbb.
|
||||||
|
Go to the **Download** page, find the release version you need and pick the archive for Linux platform.
|
||||||
|
To install, unpack the downloaded archive of TBB product.
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_linux_3_3 FreeImage
|
||||||
|
|
||||||
|
Download the necessary archive from https://sourceforge.net/projects/freeimage/files/Source%20Distribution/
|
||||||
|
and unpack it. The directory with unpacked sources is further referred to as *FREEIMAGE_SRC_DIR*.
|
||||||
|
|
||||||
|
1. Modify *FREEIMAGE_SRC_DIR/Source/OpenEXR/Imath/ImathMatrix.h*:
|
||||||
|
In line 60 insert the following:
|
||||||
|
|
||||||
|
#include string.h
|
||||||
|
|
||||||
|
2. Enter the directory where the source files of FreeImage are located <i>(FREEIMAGE_SRC_DIR)</i>.
|
||||||
|
|
||||||
|
cd FREEIMAGE_SRC_DIR
|
||||||
|
|
||||||
|
3. Run the building process
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
4. Run the installation process
|
||||||
|
|
||||||
|
a. If you have the permission to write into directories <i>/usr/include</i> and <i>/usr/lib</i>, run the following command:
|
||||||
|
|
||||||
|
make install
|
||||||
|
b. If you do not have this permission, you need to modify file *FREEIMAGE_SRC_DIR/Makefile.gnu*:
|
||||||
|
|
||||||
|
Change lines 7-9 from:
|
||||||
|
|
||||||
|
DESTDIR ?= /
|
||||||
|
INCDIR ?= $(DESTDIR)/usr/include
|
||||||
|
INSTALLDIR ?= $(DESTDIR)/usr/lib
|
||||||
|
|
||||||
|
to:
|
||||||
|
|
||||||
|
DESTDIR ?= $(DESTDIR)
|
||||||
|
INCDIR ?= $(DESTDIR)/include
|
||||||
|
INSTALLDIR ?= $(DESTDIR)/lib
|
||||||
|
|
||||||
|
Change lines 65-67 from:
|
||||||
|
|
||||||
|
install -m 644 -o root -g root $(HEADER) $(INCDIR)
|
||||||
|
install -m 644 -o root -g root $(STATICLIB) $(INSTALLDIR)
|
||||||
|
install -m 755 -o root -g root $(SHAREDLIB) $(INSTALLDIR)
|
||||||
|
|
||||||
|
to:
|
||||||
|
|
||||||
|
install -m 755 $(HEADER) $(INCDIR)
|
||||||
|
install -m 755 $(STATICLIB) $(INSTALLDIR)
|
||||||
|
install -m 755 $(SHAREDLIB) $(INSTALLDIR)
|
||||||
|
|
||||||
|
Change line 70 from:
|
||||||
|
|
||||||
|
ldconfig
|
||||||
|
|
||||||
|
to:
|
||||||
|
|
||||||
|
\#ldconfig
|
||||||
|
|
||||||
|
Then run the installation process by the following command:
|
||||||
|
|
||||||
|
make DESTDIR=FREEIMAGE_INSTALL_DIR install
|
||||||
|
|
||||||
|
5. Clean temporary files
|
||||||
|
|
||||||
|
make clean
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_linux_3_4 VTK
|
||||||
|
|
||||||
|
You can download VTK sources from https://www.vtk.org/VTK/resources/software.html
|
||||||
|
|
||||||
|
### The building procedure:
|
||||||
|
|
||||||
|
Download the necessary archive from https://www.vtk.org/VTK/resources/software.html and unpack it.
|
||||||
|
|
||||||
|
1. Install or build *cmake* product from the source file.
|
||||||
|
2. Start *cmake* in GUI mode with the directory where the source files of *VTK* are located:
|
||||||
|
|
||||||
|
ccmake VTK_SRC_DIR
|
||||||
|
|
||||||
|
* Press <i>[c]</i> to make the initial configuration
|
||||||
|
* Define the necessary options in *VTK_INSTALL_PREFIX*
|
||||||
|
* Press <i>[c]</i> to make the final configuration
|
||||||
|
* Press <i>[g]</i> to generate Makefile and exit
|
||||||
|
|
||||||
|
3. Start the building of VTK:
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
4. Start the installation of VTK. Binaries will be installed according to the *VTK_INSTALL_PREFIX* option.
|
||||||
|
|
||||||
|
make install
|
||||||
|
|
||||||
|
@section dev_guides__building_3rdparty_linux_4 Installation From Official Repositories
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_linux_4_1 Debian-based distributives
|
||||||
|
|
||||||
|
All 3rd-party products required for building of OCCT could be installed
|
||||||
|
from official repositories. You may install them from console using apt-get utility:
|
||||||
|
|
||||||
|
sudo apt-get install tcllib tklib tcl-dev tk-dev libfreetype-dev libxt-dev libxmu-dev libxi-dev libgl1-mesa-dev libglu1-mesa-dev libfreeimage-dev libtbb-dev
|
||||||
|
|
||||||
|
To launch binaries built with WOK you need to install C shell and 32-bit libraries on x86_64 distributives:
|
||||||
|
|
||||||
|
# you may need to add i386 if not done already by command "dpkg --add-architecture i386"
|
||||||
|
sudo apt-get install csh libstdc++6:i386 libxt6:i386 libxext6:i386 libxmu6:i386
|
||||||
|
|
||||||
|
Building is possible with C++ compliant compiler:
|
||||||
|
|
||||||
|
sudo apt-get install g++
|
182
dox/dev_guides/building/3rdparty/3rdparty_osx.md
vendored
Normal file
@@ -0,0 +1,182 @@
|
|||||||
|
Building 3rd-party libraries on MacOS X {#occt_dev_guides__building_3rdparty_osx}
|
||||||
|
==============================================
|
||||||
|
@tableofcontents
|
||||||
|
|
||||||
|
@section dev_guides__building_3rdparty_osx_1 Introduction
|
||||||
|
|
||||||
|
This document presents additional guidelines for building third-party products
|
||||||
|
used by Open CASCADE Technology and samples on Mac OS X platform (10.6.4 and later).
|
||||||
|
|
||||||
|
The links for downloading the third-party products are available
|
||||||
|
on the web site of OPEN CASCADE SAS at https://www.opencascade.com/content/3rd-party-components.
|
||||||
|
|
||||||
|
There are two types of third-party products, which are necessary to build OCCT:
|
||||||
|
|
||||||
|
* Mandatory products:
|
||||||
|
* Tcl/Tk 8.5 - 8.6;
|
||||||
|
* FreeType 2.4.10 - 2.5.3.
|
||||||
|
* Optional products:
|
||||||
|
* TBB 3.x - 4.x;
|
||||||
|
* FreeImage 3.14.1 - 3.16.0
|
||||||
|
|
||||||
|
@section dev_guides__building_3rdparty_osx_2 Building Mandatory Third-party Products
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_osx_2_1 Tcl/Tk 8.5
|
||||||
|
|
||||||
|
Tcl/Tk is required for DRAW test harness. Version 8.5 or 8.6 can be used with OCCT.
|
||||||
|
|
||||||
|
@subsubsection dev_guides__building_3rdparty_osx_2_1_2 Installation from sources: Tcl 8.5
|
||||||
|
|
||||||
|
Download the necessary archive from https://www.tcl.tk/software/tcltk/download.html and unpack it.
|
||||||
|
|
||||||
|
1. Enter the *macosx* sub-directory of the directory where the Tcl source files are located <i>(TCL_SRC_DIR)</i>.
|
||||||
|
|
||||||
|
cd TCL_SRC_DIR/macosx
|
||||||
|
|
||||||
|
2. Run the *configure* command
|
||||||
|
|
||||||
|
configure --enable-gcc --enable-shared --enable-threads --prefix=TCL_INSTALL_DIR
|
||||||
|
|
||||||
|
For a 64 bit platform also add <i>--enable-64bit</i> option to the command line.
|
||||||
|
|
||||||
|
3. If the *configure* command has finished successfully, start the building process
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
4. If building is finished successfully, start the installation of Tcl.
|
||||||
|
All binary and service files of the product will be copied to the directory defined by *TCL_INSTALL_DIR*.
|
||||||
|
|
||||||
|
make install
|
||||||
|
|
||||||
|
@subsubsection dev_guides__building_3rdparty_osx_2_1_3 Installation from sources: Tk 8.5
|
||||||
|
|
||||||
|
Download the necessary archive from https://www.tcl.tk/software/tcltk/download.html and unpack it.
|
||||||
|
|
||||||
|
1. Enter the *macosx* sub-directory of the directory where the source files of Tk are located <i>(TK_SRC_DIR)</i>.
|
||||||
|
|
||||||
|
cd TK_SRC_DIR/macosx
|
||||||
|
|
||||||
|
2. Run the *configure* command, where TCL_LIB_DIR is TCL_INSTALL_DIR/lib
|
||||||
|
|
||||||
|
configure --enable-gcc --enable-shared --enable-threads --with-tcl=TCL_LIB_DIR --prefix=TK_INSTALL_DIR
|
||||||
|
|
||||||
|
For a 64 bit platform also add <i>--enable-64bit</i> option to the command line.
|
||||||
|
|
||||||
|
3. If the *configure* command has finished successfully, start the building process:
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
4. If the building has finished successfully, start the installation of Tk. All binary and service files of the product will be copied to the directory defined by *TK_INSTALL_DIR* (usually it is TCL_INSTALL_DIR)
|
||||||
|
|
||||||
|
make install
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_osx_2_2 FreeType 2.4.10
|
||||||
|
|
||||||
|
FreeType is required for text display in the 3D viewer.
|
||||||
|
|
||||||
|
Download the necessary archive from https://sourceforge.net/projects/freetype/files/ and unpack it.
|
||||||
|
|
||||||
|
1. Enter the directory where the source files of FreeType are located <i>(FREETYPE_SRC_DIR)</i>.
|
||||||
|
|
||||||
|
cd FREETYPE_SRC_DIR
|
||||||
|
|
||||||
|
2. Run the *configure* command
|
||||||
|
|
||||||
|
configure --prefix=FREETYPE_INSTALL_DIR
|
||||||
|
|
||||||
|
For a 64 bit platform also add <i>CFLAGS='-m64 -fPIC' CPPFLAGS='-m64 -fPIC'</i> option to the command line.
|
||||||
|
|
||||||
|
3. If the *configure* command has finished successfully, start the building process
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
4. If building has finished successfully, start the installation of FreeType.
|
||||||
|
All binary and service files of the product will be copied to the directory defined by *FREETYPE_INSTALL_DIR*.
|
||||||
|
|
||||||
|
make install
|
||||||
|
|
||||||
|
@section dev_guides__building_3rdparty_osx_3 Building Optional Third-party Products
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_osx_3_1 TBB 3.x or 4.x
|
||||||
|
|
||||||
|
This third-party product is installed with binaries from the archive
|
||||||
|
that can be downloaded from https://github.com/intel/tbb.
|
||||||
|
Go to the **Download** page, find the release version you need (e.g. *tbb30_018oss*)
|
||||||
|
and pick the archive for Mac OS X platform.
|
||||||
|
To install, unpack the downloaded archive of TBB 3.0 product (*tbb30_018oss_osx.tgz*).
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_osx_3_3 FreeImage 3.14.1 or 3.15.x
|
||||||
|
|
||||||
|
Download the necessary archive from
|
||||||
|
https://sourceforge.net/projects/freeimage/files/Source%20Distribution/
|
||||||
|
and unpack it. The directory with unpacked sources is further referred to as *FREEIMAGE_SRC_DIR*.
|
||||||
|
|
||||||
|
Note that for building FreeImage on Mac OS X 10.7 you should replace *Makefile.osx*
|
||||||
|
in *FREEIMAGE_SRC_DIR* by the corrected file, which you can find in attachment to issue #22811 in OCCT Mantis bug tracker
|
||||||
|
(https://tracker.dev.opencascade.org/file_download.php?file_id=6937&type=bug).
|
||||||
|
|
||||||
|
1. If you build FreeImage 3.15.x you can skip this step.
|
||||||
|
Modify <i>FREEIMAGE_SRC_DIR/Source/OpenEXR/Imath/ImathMatrix.h:</i>
|
||||||
|
|
||||||
|
In line 60 insert the following:
|
||||||
|
|
||||||
|
#include string.h
|
||||||
|
|
||||||
|
Modify <i>FREEIMAGE_SRC_DIR/Source/FreeImage/PluginTARGA.cpp:</i>
|
||||||
|
|
||||||
|
In line 320 replace:
|
||||||
|
|
||||||
|
SwapShort(value);
|
||||||
|
|
||||||
|
with:
|
||||||
|
|
||||||
|
SwapShort(&value);
|
||||||
|
|
||||||
|
2. Enter the directory where the source files of FreeImage are located <i>(FREEIMAGE_SRC_DIR)</i>.
|
||||||
|
|
||||||
|
cd FREEIMAGE_SRC_DIR
|
||||||
|
|
||||||
|
3. Run the building process
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
4. Run the installation process
|
||||||
|
|
||||||
|
1. If you have the permission to write into <i>/usr/local/include</i> and <i>/usr/local/lib</i> directories, run the following command:
|
||||||
|
|
||||||
|
make install
|
||||||
|
|
||||||
|
2. If you do not have this permission, you need to modify file *FREEIMAGE_SRC_DIR/Makefile.osx*:
|
||||||
|
|
||||||
|
Change line 49 from:
|
||||||
|
|
||||||
|
PREFIX ?= /usr/local
|
||||||
|
|
||||||
|
to:
|
||||||
|
|
||||||
|
PREFIX ?= $(PREFIX)
|
||||||
|
|
||||||
|
Change lines 65-69 from:
|
||||||
|
|
||||||
|
install -d -m 755 -o root -g wheel $(INCDIR) $(INSTALLDIR)
|
||||||
|
install -m 644 -o root -g wheel $(HEADER) $(INCDIR)
|
||||||
|
install -m 644 -o root -g wheel $(SHAREDLIB) $(STATICLIB) $(INSTALLDIR)
|
||||||
|
ranlib -sf $(INSTALLDIR)/$(STATICLIB)
|
||||||
|
ln -sf $(SHAREDLIB) $(INSTALLDIR)/$(LIBNAME)
|
||||||
|
|
||||||
|
to:
|
||||||
|
|
||||||
|
install -d $(INCDIR) $(INSTALLDIR)
|
||||||
|
install -m 755 $(HEADER) $(INCDIR)
|
||||||
|
install -m 755 $(STATICLIB) $(INSTALLDIR)
|
||||||
|
install -m 755 $(SHAREDLIB) $(INSTALLDIR)
|
||||||
|
ln -sf $(SHAREDLIB) $(INSTALLDIR)/$(VERLIBNAME)
|
||||||
|
ln -sf $(VERLIBNAME) $(INSTALLDIR)/$(LIBNAME)
|
||||||
|
|
||||||
|
Then run the installation process by the following command:
|
||||||
|
|
||||||
|
make PREFIX=FREEIMAGE_INSTALL_DIR install
|
||||||
|
|
||||||
|
5. Clean temporary files
|
||||||
|
|
||||||
|
make clean
|
247
dox/dev_guides/building/3rdparty/3rdparty_windows.md
vendored
Normal file
@@ -0,0 +1,247 @@
|
|||||||
|
Building 3rd-party libraries on Windows {#occt_dev_guides__building_3rdparty_windows}
|
||||||
|
==============================================
|
||||||
|
@tableofcontents
|
||||||
|
|
||||||
|
@section dev_guides__building_3rdparty_win_1 Introduction
|
||||||
|
|
||||||
|
This document presents guidelines for building third-party products used by Open CASCADE Technology (OCCT) and samples on Windows platform. It is assumed that you are already familiar with MS Visual Studio / Visual C++.
|
||||||
|
|
||||||
|
You need to use the same version of MS Visual Studio for building all third-party products and OCCT itself, in order to receive a consistent set of run-time binaries.
|
||||||
|
|
||||||
|
The links for downloading the third-party products are available on the web site of OPEN CASCADE SAS at https://www.opencascade.com/content/3rd-party-components.
|
||||||
|
|
||||||
|
There are two types of third-party products used by OCCT:
|
||||||
|
|
||||||
|
* Mandatory products:
|
||||||
|
* Tcl/Tk 8.5 -- 8.6;
|
||||||
|
* FreeType 2.4.10 -- 2.5.3.
|
||||||
|
* Optional products:
|
||||||
|
* TBB 3.x -- 4.x;
|
||||||
|
* FreeImage 3.14.1 -- 3.16.0;
|
||||||
|
* VTK 6.1.0.
|
||||||
|
|
||||||
|
It is recommended to create a separate new folder on your workstation, where you will unpack the downloaded archives of the third-party products, and where you will build these products (for example, *c:\\occ3rdparty*).
|
||||||
|
|
||||||
|
Further in this document, this folder is referred to as *3rdparty*.
|
||||||
|
|
||||||
|
@section dev_guides__building_3rdparty_win_2 Building Mandatory Third-party Products
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_win_2_1 Tcl/Tk
|
||||||
|
|
||||||
|
Tcl/Tk is required for DRAW test harness.
|
||||||
|
|
||||||
|
@subsubsection dev_guides__building_3rdparty_win_2_1_1 Installation from sources: Tcl
|
||||||
|
|
||||||
|
Download the necessary archive from https://www.tcl.tk/software/tcltk/download.html and unpack it.
|
||||||
|
|
||||||
|
1. In the *win* sub-directory, edit file *buildall.vc.bat*:
|
||||||
|
|
||||||
|
* Edit the line "call ... vcvars32.bat" to have correct path to the version of Visual Studio to be used for building, for instance:
|
||||||
|
|
||||||
|
call "%VS80COMNTOOLS%\vsvars32.bat"
|
||||||
|
|
||||||
|
If you are building 64-bit version, set environment accordingly, e.g.:
|
||||||
|
|
||||||
|
call "%VS80COMNTOOLS%\..\..\VC\vcvarsall.bat" amd64
|
||||||
|
|
||||||
|
* Define variable *INSTALLDIR* pointing to directory where Tcl/Tk will be installed, e.g.:
|
||||||
|
|
||||||
|
set INSTALLDIR=D:\OCCT\3rdparty\tcltk-86-32
|
||||||
|
|
||||||
|
* Add option *install* to the first command line calling *nmake*:
|
||||||
|
|
||||||
|
nmake -nologo -f makefile.vc release htmlhelp install %1
|
||||||
|
|
||||||
|
* Remove second call to *nmake* (building statically linked executable)
|
||||||
|
|
||||||
|
2. Edit file *rules.vc* replacing line
|
||||||
|
|
||||||
|
SUFX = tsgx
|
||||||
|
|
||||||
|
by
|
||||||
|
|
||||||
|
SUFX = sgx
|
||||||
|
|
||||||
|
This is to avoid extra prefix 't' in the library name, which is not recognized by default by OCCT build tools.
|
||||||
|
|
||||||
|
|
||||||
|
3. By default, Tcl uses dynamic version of run-time library (MSVCRT), which must be installed on the system where Tcl will be used.
|
||||||
|
You may wish to link Tcl library with static version of run-time to avoid this dependency.
|
||||||
|
For that:
|
||||||
|
|
||||||
|
* Edit file *makefile.vc* replacing strings "crt = -MD" by "crt = -MT"
|
||||||
|
|
||||||
|
* Edit source file *tclMain.c* (located in folder *generic*) commenting out forward declaration of function *isatty()*.
|
||||||
|
|
||||||
|
|
||||||
|
4. In the command prompt, run *buildall.vc.bat*
|
||||||
|
|
||||||
|
You might need to run this script twice to have *tclsh* executable installed; check subfolder *bin* of specified installation path to verify this.
|
||||||
|
|
||||||
|
5. For convenience of use, we recommend making a copy of *tclsh* executable created in subfolder *bin* of *INSTALLDIR* and named with Tcl version number suffix, as *tclsh.exe* (with no suffix)
|
||||||
|
|
||||||
|
> cd D:\OCCT\3rdparty\tcltk-86-32\bin
|
||||||
|
> cp tclsh86.exe tclsh.exe
|
||||||
|
|
||||||
|
@subsubsection dev_guides__building_3rdparty_win_2_1_2 Installation from sources: Tk
|
||||||
|
|
||||||
|
Download the necessary archive from https://www.tcl.tk/software/tcltk/download.html and unpack it.
|
||||||
|
|
||||||
|
Apply the same steps as described for building Tcl above, with the same INSTALLDIR.
|
||||||
|
Note that Tk produces its own executable, called *wish*.
|
||||||
|
|
||||||
|
You might need to edit default value of *TCLDIR* variable defined in *buildall.vc.bat* (should be not necessary if you unpack both Tcl and Tk sources in the same folder).
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_win_2_2 FreeType
|
||||||
|
|
||||||
|
FreeType is required for text display in a 3D viewer. You can download its sources from https://sourceforge.net/projects/freetype/files/
|
||||||
|
|
||||||
|
### The building procedure
|
||||||
|
|
||||||
|
1. Unpack the downloaded archive of FreeType product into the *3rdparty* folder. As a result, you will get a folder named, for example, *3rdparty\\freetype-2.4.10*. Further in this document, this folder is referred to as *freetype*.
|
||||||
|
|
||||||
|
2. Open the solution file *freetype\\builds\\win32\\vc20xx\\freetype.sln* in Visual Studio. Here *vc20xx* stands for your version of Visual Studio.
|
||||||
|
|
||||||
|
3. Select the configuration to build: either Debug or Release.
|
||||||
|
|
||||||
|
4. Build the *freetype* project.
|
||||||
|
|
||||||
|
As a result, you will get a freetype import library (.lib) in the *freetype\\obj\\win32\\vc20xx* folder.
|
||||||
|
|
||||||
|
|
||||||
|
5. If you build FreeType for a 64 bit platform, select in the main menu **Build - Configuration Manager** and add *x64* platform to the solution configuration by copying the settings from Win32 platform:
|
||||||
|
|
||||||
|
@figure{/dev_guides/building/3rdparty/images/3rdparty_image001.png}
|
||||||
|
|
||||||
|
Update the value of the Output File for x64 configuration:
|
||||||
|
|
||||||
|
@figure{/dev_guides/building/3rdparty/images/3rdparty_image003.png}
|
||||||
|
|
||||||
|
Build the *freetype* project.
|
||||||
|
|
||||||
|
As a result, you will obtain a 64 bit import library (.lib) file in the *freetype\\x64\\vc20xx* folder.
|
||||||
|
|
||||||
|
To build FreeType as a dynamic library (.dll) follow steps 6, 7 and 8 of this procedure.
|
||||||
|
|
||||||
|
6. Open menu Project-> Properties-> Configuration Properties-> General and change option **Configuration Type** to *Dynamic Library (.dll)*.
|
||||||
|
7. Edit file *freetype\\include\\freetype\\config\\ftoption.h*:
|
||||||
|
|
||||||
|
in line 255, uncomment the definition of macro *FT_EXPORT* and change it as follows:
|
||||||
|
|
||||||
|
#define FT_EXPORT(x) __declspec(dllexport) x
|
||||||
|
|
||||||
|
8. Build the *freetype* project.
|
||||||
|
|
||||||
|
As a result, you will obtain the files of the import library (.lib) and the dynamic library (.dll) in folders <i>freetype \\objs\\release</i> or <i>\\objs\\debug </i>.
|
||||||
|
|
||||||
|
If you build for a 64 bit platform, follow step 5 of the procedure.
|
||||||
|
|
||||||
|
To facilitate the use of FreeType libraries in OCCT with minimal adjustment of build procedures, it is recommended to copy the include files and libraries of FreeType into a separate folder, named according to the pattern: *freetype-compiler-bitness-building mode*, where:
|
||||||
|
* **compiler** is *vc8* or *vc9* or *vc10* or *vc11*;
|
||||||
|
* **bitness** is *32* or *64*;
|
||||||
|
* **building mode** is *opt* (for Release) or *deb* (for Debug).
|
||||||
|
|
||||||
|
The *include* subfolder should be copied as is, while libraries should be renamed to *freetype.lib* and *freetype.dll* (suffixes removed) and placed to subdirectories *lib *and *bin*, respectively. If the Debug configuration is built, the Debug libraries should be put into subdirectories *libd* and *bind*.
|
||||||
|
|
||||||
|
@section dev_guides__building_3rdparty_win_3 Building Optional Third-party Products
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_win_3_1 TBB
|
||||||
|
|
||||||
|
This third-party product is installed with binaries
|
||||||
|
from the archive that can be downloaded from https://github.com/intel/tbb.
|
||||||
|
Go to the **Download** page, find the release version you need (e.g. *tbb30_018oss*) and pick the archive for Windows platform.
|
||||||
|
|
||||||
|
Unpack the downloaded archive of TBB product into the *3rdparty* folder.
|
||||||
|
|
||||||
|
Further in this document, this folder is referred to as *tbb*.
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_win_3_3 FreeImage
|
||||||
|
|
||||||
|
This third-party product should be built as a dynamically loadable library (.dll file).
|
||||||
|
You can download its sources from
|
||||||
|
https://sourceforge.net/projects/freeimage/files/Source%20Distribution/
|
||||||
|
|
||||||
|
### The building procedure:
|
||||||
|
|
||||||
|
1. Unpack the downloaded archive of FreeImage product into *3rdparty* folder.
|
||||||
|
|
||||||
|
As a result, you should have a folder named *3rdparty\\FreeImage*.
|
||||||
|
|
||||||
|
Rename it according to the rule: *freeimage-platform-compiler-building mode*, where
|
||||||
|
|
||||||
|
* **platform** is *win32* or *win64*;
|
||||||
|
* **compiler** is *vc8* or *vc9* or *vc10* or *vc11*;
|
||||||
|
* **building mode** is *opt* (for release) or *deb* (for debug)
|
||||||
|
|
||||||
|
Further in this document, this folder is referred to as *freeimage*.
|
||||||
|
|
||||||
|
2. Open the solution file *freeimage\\FreeImage.*.sln* in your Visual Studio.
|
||||||
|
|
||||||
|
If you use a Visual Studio version higher than VC++ 2008, apply conversion of the workspace.
|
||||||
|
Such conversion should be suggested automatically by Visual Studio.
|
||||||
|
|
||||||
|
3. Select a configuration to build.
|
||||||
|
|
||||||
|
- Choose **Release** if you are building Release binaries.
|
||||||
|
- Choose **Debug** if you are building Debug binaries.
|
||||||
|
|
||||||
|
*Note:*
|
||||||
|
|
||||||
|
If you want to build a debug version of FreeImage binaries then you need to rename the following files in FreeImage and FreeimagePlus projects:
|
||||||
|
|
||||||
|
Project -> Properties -> Configuration Properties -> Linker -> General -> Output File
|
||||||
|
|
||||||
|
FreeImage*d*.dll to FreeImage.dll
|
||||||
|
FreeImagePlus*d*.dll to FreeImagePlus.dll
|
||||||
|
|
||||||
|
Project -> Properties -> Configuration Properties -> Linker -> Debugging-> Generate Program Database File
|
||||||
|
|
||||||
|
FreeImage*d*.pdb to FreeImage.pdb
|
||||||
|
FreeImagePlus*d*.pdb to FreeImagePlus.pdb
|
||||||
|
|
||||||
|
Project -> Properties -> Configuration Properties -> Linker -> Advanced-Import Library
|
||||||
|
|
||||||
|
FreeImage*d*.lib to FreeImage.lib
|
||||||
|
FreeImagePlus*d*.lib to FreeImagePlus.lib
|
||||||
|
|
||||||
|
Project -> Properties -> Configuration Properties -> Build Events -> Post -> Build Event -> Command Line
|
||||||
|
|
||||||
|
FreeImage*d*.dll to FreeImage.dll
|
||||||
|
FreeImage*d*.lib to FreeImage.lib
|
||||||
|
FreeImagePlus*d*.dll to FreeImagePlus.dll
|
||||||
|
FreeImagePlus*d*.lib to FreeImagePlus.lib
|
||||||
|
|
||||||
|
Additionally, rename in project FreeImagePlus
|
||||||
|
|
||||||
|
Project -> Properties -> Configuration Properties -> Linker -> Input -> Additional Dependencies
|
||||||
|
|
||||||
|
from FreeImage*d*.lib to FreeImage.lib
|
||||||
|
|
||||||
|
4. Select a platform to build.
|
||||||
|
|
||||||
|
- Choose *Win32* if you are building for a 32 bit platform.
|
||||||
|
- Choose *x64* if you are building for a 64 bit platform.
|
||||||
|
|
||||||
|
5. Start the building process.
|
||||||
|
|
||||||
|
As a result, you should have the library files of FreeImage product in *freeimage\\Dist* folder (*FreeImage.dll* and *FreeImage.lib*) and in *freeimage\\Wrapper\\FreeImagePlus\\dist* folder (*FreeImagePlus.dll* and *FreeImagePlus.lib*).
|
||||||
|
|
||||||
|
@subsection dev_guides__building_3rdparty_win_3_4 VTK
|
||||||
|
|
||||||
|
VTK is an open-source, freely available software system for 3D computer graphics, image processing and visualization. VTK Integration Services component provides adaptation functionality for visualization of OCCT topological shapes by means of VTK library.
|
||||||
|
|
||||||
|
### The building procedure:
|
||||||
|
|
||||||
|
1. Download the necessary archive from https://www.vtk.org/VTK/resources/software.html and unpack it into *3rdparty* folder.
|
||||||
|
|
||||||
|
As a result, you will get a folder named, for example, <i>3rdparty\VTK-6.1.0.</i>
|
||||||
|
|
||||||
|
Further in this document, this folder is referred to as *VTK*.
|
||||||
|
|
||||||
|
2. Use CMake to generate VS projects for building the library:
|
||||||
|
- Start CMake-GUI and select VTK folder as source path, and the folder of your choice for VS project and intermediate build data.
|
||||||
|
- Click **Configure**.
|
||||||
|
- Select the VS version to be used from the ones you have installed (we recommend using VS 2010) and the architecture (32 or 64-bit).
|
||||||
|
- Generate VS projects with default CMake options. The open solution *VTK.sln* will be generated in the build folder.
|
||||||
|
|
||||||
|
3. Build project VTK in Release mode.
|
Before Width: | Height: | Size: 123 KiB After Width: | Height: | Size: 123 KiB |
Before Width: | Height: | Size: 84 KiB After Width: | Height: | Size: 84 KiB |
Before Width: | Height: | Size: 106 KiB After Width: | Height: | Size: 106 KiB |
Before Width: | Height: | Size: 65 KiB After Width: | Height: | Size: 65 KiB |
Before Width: | Height: | Size: 206 KiB After Width: | Height: | Size: 206 KiB |
Before Width: | Height: | Size: 236 KiB After Width: | Height: | Size: 236 KiB |