-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbzip2.cmd
More file actions
28 lines (23 loc) · 774 Bytes
/
bzip2.cmd
File metadata and controls
28 lines (23 loc) · 774 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
@echo off
setlocal
set BASEDIR=%~dp0
echo %BASEDIR%
SET "ROOT=%BASEDIR:\=/%"
echo %ROOT%
set VERSION=1ea1ac188ad4b9cb662e3f8314673c63df95a589
if not exist build\bzip2 (
git clone -b master --single-branch https://gitlab.com/bzip2/bzip2.git build\bzip2
if errorlevel 1 exit /b 1
) else (
cd build\bzip2
git fetch --all --unshallow
git checkout -b temp %VERSION%
git reset --hard %VERSION%
git clean -fdx
cd "%BASEDIR%"
)
if exist build\bzip2 (
cmake -A x64 --install-prefix "%ROOT%stage" -S build/bzip2 -B build/bzip2_build -D CMAKE_BUILD_TYPE="Release" -D ENABLE_LIB_ONLY=ON -D ENABLE_SHARED_LIB=OFF -D ENABLE_STATIC_LIB=ON
cmake --build build/bzip2_build --target INSTALL --config Release
)
endlocal