set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DPARAVIEW_USE_PYTHON:BOOL=ON
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DVTK_WRAP_PYTHON:BOOL=ON
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DPython3_INCLUDE_DIR:STRING=%PYTHON_ROOT_DIR:\=/%/include
-set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DPython3_LIBRARY:STRING=%PYTHON_ROOT_DIR:\=/%/libs/python%PYTHON_VERSION:.=%.lib
+if %SAT_DEBUG% == 0 (
+ set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DPython3_LIBRARY:STRING=%PYTHON_ROOT_DIR:\=/%/libs/python%PYTHON_VERSION:.=%.lib
+) else (
+ set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DPython3_LIBRARY:STRING=%PYTHON_ROOT_DIR:\=/%/libs/python%PYTHON_VERSION:.=%_d.lib
+)
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DVTK_PYTHON_FULL_THREADSAFE:BOOL=ON
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DVTK_NO_PYTHON_THREADS:BOOL=OFF
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DVTK_PYTHON_VERSION:STRING=3
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DVTK_MODULE_USE_EXTERNAL_VTK_freetype:BOOL=ON
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DFREETYPE_INCLUDE_DIRS:PATH=%FREETYPE_ROOT_DIR:\=/%/include
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DFREETYPE_INCLUDE_DIR_freetype2:PATH=%FREETYPE_ROOT_DIR:\=/%/include/freetype2
-set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DFREETYPE_LIBRARY:STRING=%FREETYPE_ROOT_DIR:\=/%/lib/freetype.lib
-
+if %SAT_DEBUG% == 0 (
+ set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DFREETYPE_LIBRARY:STRING=%FREETYPE_ROOT_DIR:\=/%/lib/freetype.lib
+) else (
+ set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DFREETYPE_LIBRARY:STRING=%FREETYPE_ROOT_DIR:\=/%/lib/freetyped.lib
+)
REM ZLIB settings
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DVTK_MODULE_USE_EXTERNAL_VTK_zlib:BOOL=ON
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DZLIB_INCLUDE_DIR:STRING=%ZLIB_ROOT_DIR:\=/%/include
-set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DZLIB_LIBRARY:STRING=%ZLIB_ROOT_DIR:\=/%/bin/zlib1.lib
+if %SAT_DEBUG% == 0 (
+ set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DZLIB_LIBRARY:STRING=%ZLIB_ROOT_DIR:\=/%/lib/zlib.lib
+) else (
+ set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DZLIB_LIBRARY:STRING=%ZLIB_ROOT_DIR:\=/%/lib/zlibd.lib
+)
REM Extra options (switch off non-used Paraview plug-ins)
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DPARAVIEW_PLUGINS_DEFAULT:BOOL=ON
exit 1
)
+REM
+REM see https://gitlab.kitware.com/paraview/paraview/-/issues/19488
+if %SAT_DEBUG% == 1 (
+ del /Q Directory.Build.props
+ echo > Directory.Build.props
+ echo ^<Project^> > Directory.Build.props
+ echo ^<ItemDefinitionGroup^> >> Directory.Build.props
+ echo ^<Link^> >> Directory.Build.props
+ echo ^<AdditionalLibraryDirectories^>%PYTHON_ROOT_DIR:\=/%/libs^;%%(AdditionalLibraryDirectories)^</AdditionalLibraryDirectories^> >> Directory.Build.props
+ echo ^</Link^> >> Directory.Build.props
+ echo ^</ItemDefinitionGroup^> >> Directory.Build.props
+ echo ^</Project^> >> Directory.Build.props
+)
+
echo.
echo --------------------------------------------------------------------------
echo *** msbuild %MAKE_OPTIONS% ALL_BUILD.vcxproj /p:Configuration=%PRODUCT_BUILD_TYPE% /p:Platform=x64
REM move
set MSBUILDDISABLENODEREUSE=1
+REM In debug mode, we need to rename all .pyd to _d.pyd... don't ask why. Seems like a known bug in OmniORB.
+if %SAT_DEBUG% == 1 (
+ cd %PRODUCT_INSTALL%\bin\Lib\site-packages
+ powershell -Command "Get-ChildItem -File -Recurse *.pyd| ForEach-Object {if ((!$_.Name.EndsWith('_d.pyd'))) { $_ | Copy-Item -Destination {$_.Name -replace '.pyd','_d.pyd'}}}"
+)
+
echo.
echo --------------------------------------------------------------------------
echo *** Post processing
exit 3
)
+REM In debug mode, we need to rename all .pyd to _d.pyd.
+if %SAT_DEBUG% == 1 (
+ cd %PRODUCT_INSTALL%\lib\%python_name%\site-packages\PyQt5
+ powershell -Command "Get-ChildItem -File -Recurse *.pyd| ForEach-Object {if ((!$_.Name.EndsWith('_d.pyd'))) { $_ | Copy-Item -Destination {$_.Name -replace '.pyd','_d.pyd'}}}"
+ powershell -Command "Get-ChildItem -File -Recurse *_d.pyd| ForEach-Object {if (($_.Name.EndsWith('_d.pyd'))) { $_ | Copy-Item -Destination {$_.Name -replace '_d.pyd','.pyd'}}}"
+)
+
echo.
echo ########## END
:NORMALIZEPATH
SET RETVAL=%~dpfn1
- EXIT /B
\ No newline at end of file
+ EXIT /B
%PRODUCT_INSTALL%\python.exe %SOURCE_DIR%\externals\pip-19.1.1\get-pip.py --force-reinstall --no-setuptools --no-wheel --no-index --find-links=%SOURCE_DIR%\externals\pip-19.1.1
+REM In debug mode, we need to rename all _d.pyd to .pyd... don't ask why. Seems like a known bug in OmniORB.
+if %SAT_DEBUG% == 1 (
+ cd %PRODUCT_INSTALL%
+ powershell -Command "Get-ChildItem -File -Recurse *.pyd| ForEach-Object {if ((!$_.Name.EndsWith('_d.pyd'))) { $_ | Copy-Item -Destination {$_.Name -replace '.pyd','_d.pyd'}}}"
+ cd %PRODUCT_INSTALL%\lib\site-packages
+ powershell -Command "Get-ChildItem -File -Recurse *.pyd| ForEach-Object {if ((!$_.Name.EndsWith('_d.pyd'))) { $_ | Copy-Item -Destination {$_.Name -replace '.pyd','_d.pyd'}}}"
+)
+
+
taskkill /F /IM "mspdbsrv.exe"
echo.
SET PRODUCT_BUILD_TYPE=Release
REM TODO: NGH: not Tested yet
-REM if %SAT_DEBUG% == 1 (
-REM set PRODUCT_BUILD_TYPE=Debug
-REM )
+if %SAT_DEBUG% == 1 (
+ set PRODUCT_BUILD_TYPE=Debug
+)
if NOT exist "%PRODUCT_INSTALL%" mkdir %PRODUCT_INSTALL%
if %INSTALL_CENTRALLY% == 1 (\r
%PYTHON_ROOT_DIR%\python.exe setup.py install \r
) else (\r
- %PYTHON_ROOT_DIR%\python setup.py install --single-version-externally-managed --root=/ --prefix=%PRODUCT_INSTALL% --install-lib=%PRODUCT_INSTALL%\lib\python%PYTHON_VERSION%\site-packages\r
+ %PYTHON_ROOT_DIR%\python.exe setup.py install --single-version-externally-managed --root=/ --prefix=%PRODUCT_INSTALL% --install-lib=%PRODUCT_INSTALL%\lib\python%PYTHON_VERSION%\site-packages\r
)\r
if NOT %ERRORLEVEL% == 0 (\r
echo "ERROR on setup install"\r
exit 3\r
)\r
\r
+REM In debug mode, we need to rename all .pyd to _d.pyd... don't ask why. Seems like a known bug in OmniORB.\r
+if %SAT_DEBUG% == 1 (\r
+ cd %PYTHON_ROOT_DIR%\lib\site-packages\Cython-0.29.12-py3.6-win-amd64.egg\r
+ powershell -Command "Get-ChildItem -File -Recurse *.pyd| ForEach-Object {if ((!$_.Name.EndsWith('_d.pyd'))) { $_ | Copy-Item -Destination {$_.Name -replace '.pyd','_d.pyd'}}}"\r
+ cd %PYTHON_ROOT_DIR%lib\site-packages\Cython-0.29.12-py3.6-win-amd64.egg\Cython\Runtime\r
+ powershell -Command "Get-ChildItem -File -Recurse *.pyd| ForEach-Object {if ((!$_.Name.EndsWith('_d.pyd'))) { $_ | Copy-Item -Destination {$_.Name -replace '.pyd','_d.pyd'}}}"\r
+)\r
+\r
echo.\r
echo Product %PRODUCT_NAME% version: %VERSION%> %PRODUCT_INSTALL%\README.txt\r
echo Installation folder: %PYTHON_ROOT_DIR%>> %PRODUCT_INSTALL%\README.txt\r
if %SAT_DEBUG% == 1 (
copy /Y %BUILD_DIR%\Dist\x64\*.dll %PRODUCT_INSTALL%\bin\
copy /Y %BUILD_DIR%\Dist\x64\*.lib %PRODUCT_INSTALL%\lib\
+ copy /Y %BUILD_DIR%\Dist\x64\*.pdb %PRODUCT_INSTALL%\lib\
copy /Y %BUILD_DIR%\Dist\x64\*.h %PRODUCT_INSTALL%\include\
copy /Y %BUILD_DIR%\Wrapper\FreeImagePlus\dist\x64\*.dll %PRODUCT_INSTALL%\bin\
copy /Y %BUILD_DIR%\Wrapper\FreeImagePlus\dist\x64\*.lib %PRODUCT_INSTALL%\lib\
+ copy /Y %BUILD_DIR%\Wrapper\FreeImagePlus\dist\x64\*.pdb %PRODUCT_INSTALL%\lib\
copy /Y %BUILD_DIR%\Wrapper\FreeImagePlus\dist\x64\*.h %PRODUCT_INSTALL%\include\
+ copy /Y %BUILD_DIR%\Wrapper\FreeImagePlus\dist\x64\FreeImagePlusd.dll %PRODUCT_INSTALL%\bin\FreeImagePlus.dll
+ copy /Y %BUILD_DIR%\Wrapper\FreeImagePlus\dist\x64\FreeImagePlusd.lib %PRODUCT_INSTALL%\lib\FreeImagePlus.lib
+ copy /Y %BUILD_DIR%\Dist\x64\FreeImaged.dll %PRODUCT_INSTALL%\bin\FreeImage.dll
+ copy /Y %BUILD_DIR%\Dist\x64\FreeImaged.lib %PRODUCT_INSTALL%\lib\FreeImage.lib
) else (
copy /Y %BUILD_DIR%\Dist\x64\FreeImage.dll %PRODUCT_INSTALL%\bin\FreeImage.dll
copy /Y %BUILD_DIR%\Dist\x64\FreeImage.lib %PRODUCT_INSTALL%\lib\FreeImage.lib
if %SAT_DEBUG% == 0 (\r
copy /Y %BUILD_DIR%\%PRODUCT_BUILD_TYPE%\Freetype.dll %PRODUCT_INSTALL%\bin\Freetype.dll\r
) else (\r
+ copy /Y %BUILD_DIR%\%PRODUCT_BUILD_TYPE%\*.lib %PRODUCT_INSTALL%\lib\\r
copy /Y %BUILD_DIR%\%PRODUCT_BUILD_TYPE%\*.dll %PRODUCT_INSTALL%\bin\\r
+ copy /Y %BUILD_DIR%\%PRODUCT_BUILD_TYPE%\Freetyped.dll %PRODUCT_INSTALL%\bin\Freetype.dll\r
+ copy /Y %BUILD_DIR%\%PRODUCT_BUILD_TYPE%\Freetyped.lib %PRODUCT_INSTALL%\lib\Freetype.lib\r
)\r
if NOT %ERRORLEVEL% == 0 (\r
echo ERROR when copying Freetype DLL\r
)
SET PRODUCT_BUILD_TYPE=Release
-if %SAT_DEBUG% == 1 (
- set PRODUCT_BUILD_TYPE=Debug
-)
+REM Building ISPC in DEBUG mode is definitely not relevant.
+REM if %SAT_DEBUG% == 1 (
+REM set PRODUCT_BUILD_TYPE=Debug
+REM )
if NOT exist "%PRODUCT_INSTALL%" mkdir %PRODUCT_INSTALL%
REM clean BUILD directory
echo NETGEN %VERSION%
echo ##########################################################################
+IF NOT DEFINED SAT_DEBUG (
+ SET SAT_DEBUG=0
+)
+
+SET PRODUCT_BUILD_TYPE=Release
+if %SAT_DEBUG% == 1 (
+ set PRODUCT_BUILD_TYPE=Debug
+)
+
dos2unix -q %SOURCE_DIR%/libsrc/occ/*
dos2unix -q %SOURCE_DIR%/libsrc/nglib/*
if exist "%BUILD_DIR%" rmdir /Q /S %BUILD_DIR%
mkdir %BUILD_DIR%
-set CMAKE_OPTIONS=-DCMAKE_INSTALL_PREFIX:STRING=%PRODUCT_INSTALL:\=/%
-if defined CMAKE_GENERATOR (
- set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DCMAKE_GENERATOR=%CMAKE_GENERATOR%
-) else (
- set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DCMAKE_GENERATOR="Visual Studio 15 2017 Win64"
-)
-set MSBUILDDISABLENODEREUSE=1
-
+set CMAKE_OPTIONS=
+set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DCMAKE_INSTALL_PREFIX=%PRODUCT_INSTALL%
+set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DCMAKE_BUILD_TYPE=%PRODUCT_BUILD_TYPE%
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DZLIB_ROOT_DIR=%ZLIB_DIR%
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DCASROOT=%CASROOT%
+set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DCMAKE_GENERATOR="Visual Studio 15 2017 Win64"
+
+set MSBUILDDISABLENODEREUSE=1
cd %BUILD_DIR%
echo.
echo *********************************************************************
-echo *** msbuild %MAKE_OPTIONS% /p:Configuration=Release ALL_BUILD.vcxproj"
+echo *** msbuild %MAKE_OPTIONS% /p:Configuration=%PRODUCT_BUILD_TYPE% ALL_BUILD.vcxproj
echo *********************************************************************
echo.
-msbuild %MAKE_OPTIONS% /p:Configuration=Release ALL_BUILD.vcxproj
+msbuild %MAKE_OPTIONS% /p:Configuration=%PRODUCT_BUILD_TYPE% ALL_BUILD.vcxproj
if NOT %ERRORLEVEL% == 0 (
echo ERROR on msbuild ALL_BUILD.vcxproj
exit 2
echo.
echo *********************************************************************
-echo *** installation... msbuild %MAKE_OPTIONS% /p:Configuration=Release INSTALL.vcxproj
+echo *** installation... msbuild %MAKE_OPTIONS% /p:Configuration=%PRODUCT_BUILD_TYPE% INSTALL.vcxproj
echo *********************************************************************
echo.
-msbuild %MAKE_OPTIONS% /p:Configuration=Release INSTALL.vcxproj
+msbuild %MAKE_OPTIONS% /p:Configuration=%PRODUCT_BUILD_TYPE% INSTALL.vcxproj
if NOT %ERRORLEVEL% == 0 (
echo ERROR on msbuild INSTALL.vcxproj
exit 3
sed "s/#platform = x86_win32_vs_15/platform = x86_win32_vs_15/g" < %CONFIG_REF% > %CONFIG_MK%\r
if %SAT_DEBUG% == 1 (\r
copy %CONFIG_MK% %CONFIG_DBG%\r
-)\r
-if %SAT_DEBUG% == 1 (\r
sed "s/#BuildDebugBinary = 1/BuildDebugBinary = 1/g" < %CONFIG_DBG% > %CONFIG_MK% \r
+ sed -i '199s/\.lib/\_d\.lib/' %BUILD_DIR%\src\tool\omniidl\cxx\dir.mk\r
)\r
\r
REM target our Python in the configuration file\r
exit 2\r
)\r
\r
+if %SAT_DEBUG% == 1 (\r
+ cd %PRODUCT_INSTALL%\r
+ powershell -Command "Get-ChildItem -File -Recurse *.pyd| ForEach-Object {if ((!$_.Name.EndsWith('_d.pyd'))) { $_ | Copy-Item -Destination {$_.Name -replace '.pyd','_d.pyd'}}}"\r
+)\r
echo.\r
-echo ########## END
\ No newline at end of file
+echo ########## END\r
SET CMAKE_OPTIONS=%CMAKE_OPTIONS% -DSTATIC_LIBRARY_FLAGS:STRING="/machine:x64"\r
SET CMAKE_OPTIONS=%CMAKE_OPTIONS% -DPYTHON_EXECUTABLE=%PYTHON_ROOT_DIR:\=/%/python.exe\r
set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DPYTHON_INCLUDE_DIR:STRING=%PYTHON_ROOT_DIR:\=/%/include\r
-SET CMAKE_OPTIONS=%CMAKE_OPTIONS% -DPYTHON_LIBRARY=%PYTHON_ROOT_DIR:\=/%/libs/python%PYTHON_VERSION:.=%.lib\r
+if %SAT_DEBUG% == 0 (\r
+ set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DPYTHON_LIBRARY:STRING=%PYTHON_ROOT_DIR:\=/%/libs/python%PYTHON_VERSION:.=%.lib\r
+) else (\r
+ set CMAKE_OPTIONS=%CMAKE_OPTIONS% -DPYTHON_LIBRARY:STRING=%PYTHON_ROOT_DIR:\=/%/libs/python%PYTHON_VERSION:.=%_d.lib\r
+)\r
SET CMAKE_OPTIONS=%CMAKE_OPTIONS% -DBUILD_opencv_java:STRING=OFF\r
SET CMAKE_OPTIONS=%CMAKE_OPTIONS% -DCMAKE_GENERATOR="Visual Studio 15 2017 Win64"\r
\r
taskkill /F /IM "mspdbsrv.exe"\r
\r
echo.\r
-echo ########## END
\ No newline at end of file
+echo ########## END\r
exit 3
)
+REM In debug mode, we need to rename all _d.pyd to .pyd... don't ask why. Seems like a known bug in OmniORB.
+if %SAT_DEBUG% == 1 (
+ cd %PRODUCT_INSTALL%\lib\%python_name%\site-packages
+ powershell -Command "Get-ChildItem *_d.pyd| Rename-Item -newname { $_.name -replace '_d.pyd','.pyd' }"
+ powershell -Command "Get-ChildItem *.pyd| Rename-Item -newname { $_.name -replace '.pyd','_d.pyd' }"
+)
+
echo.
echo ########## END
pip : "no"
}
}
+
+version_0_4_3_win_dbg:
+{
+ name : "sphinx_rtd_theme"
+ build_source : "script"
+ compil_script : "sphinx_rtd_theme.bat"
+ get_source : "archive"
+ archive_info : {archive_name : "sphinx_rtd_theme-0.4.3.tar.gz"}
+ environ :
+ {
+ env_script : "sphinx_rtd_theme.py"
+ }
+ depend : ['Python', 'Sphinx']
+ patches : []
+ source_dir : $APPLICATION.workdir + $VARS.sep + 'SOURCES' + $VARS.sep + $name
+ build_dir : $APPLICATION.workdir + $VARS.sep + 'BUILD' + $VARS.sep + $name
+ install_dir : 'base'
+ properties:
+ {
+ incremental : "yes"
+ pip : "no"
+ }
+}