2023-10-08 16:19:26 +00:00
|
|
|
@REM OcarSlicer build script for Windows
|
|
|
|
@echo off
|
2023-07-14 15:56:55 +00:00
|
|
|
set WP=%CD%
|
2023-10-08 16:19:26 +00:00
|
|
|
|
|
|
|
@REM Pack deps
|
|
|
|
if "%1"=="pack" (
|
|
|
|
setlocal ENABLEDELAYEDEXPANSION
|
|
|
|
cd %WP%/deps/build
|
|
|
|
for /f "tokens=2-4 delims=/ " %%a in ('date /t') do set build_date=%%c%%b%%a
|
|
|
|
echo packing deps: OrcaSlicer_dep_win64_!build_date!_vs2022.zip
|
|
|
|
|
|
|
|
%WP%/tools/7z.exe a OrcaSlicer_dep_win64_!build_date!_vs2022.zip OrcaSlicer_dep
|
|
|
|
exit /b 0
|
|
|
|
)
|
|
|
|
|
|
|
|
setlocal DISABLEDELAYEDEXPANSION
|
2023-07-14 15:56:55 +00:00
|
|
|
cd deps
|
|
|
|
mkdir build
|
|
|
|
cd build
|
|
|
|
set DEPS=%CD%/OrcaSlicer_dep
|
2023-10-08 16:19:26 +00:00
|
|
|
|
2023-08-10 02:51:44 +00:00
|
|
|
if "%1"=="slicer" (
|
|
|
|
GOTO :slicer
|
2023-07-14 15:56:55 +00:00
|
|
|
)
|
|
|
|
echo "building deps.."
|
2023-10-08 16:19:26 +00:00
|
|
|
|
|
|
|
|
2023-07-14 15:56:55 +00:00
|
|
|
cmake ../ -G "Visual Studio 17 2022" -A x64 -DDESTDIR="%CD%/OrcaSlicer_dep" -DCMAKE_BUILD_TYPE=Release
|
2023-08-10 02:51:44 +00:00
|
|
|
cmake --build . --config Release --target deps -- -m
|
2023-07-14 15:56:55 +00:00
|
|
|
|
|
|
|
if "%1"=="deps" exit /b 0
|
|
|
|
|
2023-08-10 02:51:44 +00:00
|
|
|
:slicer
|
|
|
|
echo "building Orca Slicer..."
|
2023-07-14 15:56:55 +00:00
|
|
|
cd %WP%
|
|
|
|
mkdir build
|
|
|
|
cd build
|
|
|
|
|
2023-10-08 16:19:26 +00:00
|
|
|
echo cmake .. -G "Visual Studio 17 2022" -A x64 -DBBL_RELEASE_TO_PUBLIC=1 -DCMAKE_PREFIX_PATH="%DEPS%/usr/local" -DCMAKE_INSTALL_PREFIX="./OrcaSlicer" -DCMAKE_BUILD_TYPE=Release
|
|
|
|
cmake .. -G "Visual Studio 17 2022" -A x64 -DBBL_RELEASE_TO_PUBLIC=1 -DCMAKE_PREFIX_PATH="%DEPS%/usr/local" -DCMAKE_INSTALL_PREFIX="./OrcaSlicer" -DCMAKE_BUILD_TYPE=Release -DWIN10SDK_PATH="C:/Program Files (x86)/Windows Kits/10/Include/10.0.22000.0"
|
2023-07-14 15:56:55 +00:00
|
|
|
cmake --build . --config Release --target ALL_BUILD -- -m
|
2023-09-05 14:36:29 +00:00
|
|
|
cd ..
|
2023-09-07 15:50:35 +00:00
|
|
|
call run_gettext.bat
|
2023-09-05 14:36:29 +00:00
|
|
|
cd build
|
2023-10-08 16:19:26 +00:00
|
|
|
cmake --build . --target install --config Release
|