mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-03 17:56:21 +03:00
0032536: Configuration - extend adm/scripts with USE_DRACO option
This commit is contained in:
parent
7b5f784419
commit
91428b468b
@ -13,6 +13,7 @@ rem Paths to 3rd-party tools and libraries
|
||||
set "anNdkPath="
|
||||
set "aFreeType="
|
||||
set "aRapidJson="
|
||||
set "aDraco="
|
||||
|
||||
rem Build stages to perform
|
||||
set "toCMake=1"
|
||||
@ -34,7 +35,9 @@ 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"
|
||||
@ -162,6 +165,7 @@ if ["%toCMake%"] == ["1"] (
|
||||
-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" ^
|
||||
@ -170,6 +174,11 @@ if ["%toCMake%"] == ["1"] (
|
||||
-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%/libs/%anAbi%" ^
|
||||
-D 3RDPARTY_DRACO_LIBRARY:FILEPATH="%aDraco%/libs/%anAbi%/libfreetype.so" ^
|
||||
"%aCasSrc%"
|
||||
|
||||
if errorlevel 1 (
|
||||
|
@ -6,6 +6,7 @@ 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"
|
||||
@ -28,4 +29,5 @@ 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_RAPIDJSON=ON"
|
||||
rem set "USE_DRACO=ON"
|
||||
|
@ -42,5 +42,6 @@ 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
|
||||
|
@ -35,6 +35,7 @@ FREETYPE_DIR="$OCCT3RDPARTY/freetype-2.7.1"
|
||||
#USE_FREEIMAGE=OFF
|
||||
#USE_GLES2=OFF
|
||||
#USE_RAPIDJSON=OFF
|
||||
#USE_DRACO=OFF
|
||||
#USE_TBB=OFF
|
||||
#USE_VTK=OFF
|
||||
|
||||
|
@ -37,6 +37,7 @@ 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
|
||||
|
||||
@ -76,6 +77,7 @@ cmake -G "%arch_compile%" ^
|
||||
-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%"
|
||||
|
@ -40,6 +40,7 @@ USE_FFMPEG=OFF
|
||||
USE_FREEIMAGE=OFF
|
||||
USE_GLES2=OFF
|
||||
USE_RAPIDJSON=OFF
|
||||
USE_DRACO=OFF
|
||||
USE_TBB=OFF
|
||||
USE_VTK=OFF
|
||||
AUX_ARGS=
|
||||
@ -79,6 +80,7 @@ cmake -G "Unix Makefiles" \
|
||||
-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"
|
||||
|
@ -17,6 +17,7 @@ export aBuildRoot=work
|
||||
export aFreeType=
|
||||
export aFreeImage=
|
||||
export aRapidJson=
|
||||
export aDraco=
|
||||
|
||||
# build stages to perform
|
||||
export toSimulator=0
|
||||
@ -34,8 +35,10 @@ 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
|
||||
@ -117,13 +120,18 @@ if [[ $toCMake == 1 ]]; then
|
||||
-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="ON" \
|
||||
-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" \
|
||||
|
@ -3,6 +3,7 @@ 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
|
||||
@ -21,6 +22,7 @@ export aRapidJson="$aSrcRoot/../3rdparty/rapidjson-1.1.0"
|
||||
#export BUILD_DataExchange=ON
|
||||
|
||||
#export USE_RAPIDJSON=ON
|
||||
#export USE_DRACO=ON
|
||||
#export USE_FREEIMAGE=ON
|
||||
|
||||
#export IPHONEOS_DEPLOYMENT_TARGET=8.0
|
||||
|
@ -17,6 +17,7 @@ export aBuildRoot=work
|
||||
export aFreeType=
|
||||
export aFreeImage=
|
||||
export aRapidJson=
|
||||
export aDraco=
|
||||
|
||||
# build stages to perform
|
||||
export toCMake=1
|
||||
@ -35,6 +36,7 @@ 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
|
||||
@ -106,6 +108,10 @@ if [[ $toCMake == 1 ]]; then
|
||||
-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" \
|
||||
|
@ -3,6 +3,7 @@ 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
|
||||
@ -20,6 +21,7 @@ export aRapidJson="$aSrcRoot/../3rdparty/rapidjson-1.1.0"
|
||||
#export BUILD_Draw=ON
|
||||
|
||||
#export USE_RAPIDJSON=ON
|
||||
#export USE_DRACO=ON
|
||||
#export USE_FREEIMAGE=ON
|
||||
|
||||
#export MACOSX_DEPLOYMENT_TARGET=10.10
|
||||
|
@ -14,6 +14,7 @@ set "aMingwVars="
|
||||
set "aFreeType="
|
||||
set "aFreeImage="
|
||||
set "aRapidJson="
|
||||
set "aDraco="
|
||||
set "aTclTk="
|
||||
|
||||
rem Build stages to perform
|
||||
@ -34,7 +35,9 @@ 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
|
||||
@ -162,7 +165,7 @@ if ["%toCMake%"] == ["1"] (
|
||||
-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="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" ^
|
||||
@ -174,6 +177,10 @@ if ["%toCMake%"] == ["1"] (
|
||||
-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 (
|
||||
|
@ -4,6 +4,7 @@ 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"
|
||||
|
||||
@ -24,4 +25,5 @@ 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"
|
||||
|
@ -13,6 +13,7 @@ rem Paths to 3rd-party tools and libraries
|
||||
set "aCmakeBin="
|
||||
set "aFreeType="
|
||||
set "aRapidJson="
|
||||
set "aDraco="
|
||||
set "aTcl="
|
||||
|
||||
rem Build stages to perform
|
||||
@ -34,7 +35,9 @@ 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"
|
||||
|
||||
rem Archive tool
|
||||
set "THE_7Z_PARAMS=-t7z -m0=lzma -mx=9 -mfb=64 -md=32m -ms=on"
|
||||
@ -159,9 +162,6 @@ if ["%toCMake%"] == ["1"] (
|
||||
-D INSTALL_DIR:PATH="%aDestDir%" ^
|
||||
-D INSTALL_DIR_INCLUDE:STRING="inc" ^
|
||||
-D INSTALL_DIR_RESOURCE:STRING="src" ^
|
||||
-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 BUILD_MODULE_FoundationClasses:BOOL="ON" ^
|
||||
-D BUILD_MODULE_ModelingData:BOOL="%BUILD_ModelingData%" ^
|
||||
-D BUILD_MODULE_ModelingAlgorithms:BOOL="%BUILD_ModelingAlgorithms%" ^
|
||||
@ -170,14 +170,23 @@ if ["%toCMake%"] == ["1"] (
|
||||
-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" ^
|
||||
-D USE_TK:BOOL="OFF" ^
|
||||
"%aCasSrc%"
|
||||
|
||||
if errorlevel 1 (
|
||||
|
@ -1,7 +1,8 @@
|
||||
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-wasm"
|
||||
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
|
||||
@ -24,3 +25,4 @@ rem set "BUILD_ApplicationFramework=ON"
|
||||
rem set "BUILD_DataExchange=ON"
|
||||
|
||||
rem set "USE_RAPIDJSON=OFF"
|
||||
rem set "USE_DRACO=ON"
|
||||
|
@ -60,6 +60,7 @@ CSF_OpenGlesLibs
|
||||
CSF_FFmpeg
|
||||
CSF_FreeImagePlus
|
||||
CSF_FREETYPE
|
||||
CSF_Draco
|
||||
CSF_user32
|
||||
CSF_advapi32
|
||||
CSF_XwLibs
|
||||
|
@ -22,7 +22,9 @@
|
||||
#include <Standard_ReadBuffer.hxx>
|
||||
|
||||
#ifdef HAVE_DRACO
|
||||
#include <Standard_WarningsDisable.hxx>
|
||||
#include <draco/compression/decode.h>
|
||||
#include <Standard_WarningsRestore.hxx>
|
||||
#endif
|
||||
|
||||
namespace
|
||||
|
Loading…
x
Reference in New Issue
Block a user