Run Cmake without changing to the build folder.
This commit is contained in:
parent
1f02dae022
commit
3eb15f58ef
6 changed files with 45 additions and 59 deletions
|
@ -23,65 +23,63 @@ echo Building x64 virtual camera driver
|
|||
echo.
|
||||
|
||||
mkdir build-x64
|
||||
cd build-x64
|
||||
setlocal
|
||||
|
||||
if "%CMAKE_GENERATOR%" == "MSYS Makefiles" set PATH=C:\msys64\mingw64\bin;C:\msys64\usr\bin;%PATH%
|
||||
if "%CMAKE_GENERATOR%" == "MSYS Makefiles" (
|
||||
cmake ^
|
||||
-S . ^
|
||||
-B build-x64 ^
|
||||
-G "%CMAKE_GENERATOR%" ^
|
||||
-DCMAKE_BUILD_TYPE=Release ^
|
||||
-DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%" ^
|
||||
..
|
||||
cmake --build .
|
||||
cmake --build . --target install
|
||||
-DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%"
|
||||
cmake --build build-x64
|
||||
cmake --build build-x64 --target install
|
||||
)
|
||||
|
||||
endlocal
|
||||
|
||||
if "%CMAKE_GENERATOR:~0,13%" == "Visual Studio" (
|
||||
cmake ^
|
||||
-S . ^
|
||||
-B build-x64 ^
|
||||
-G "%CMAKE_GENERATOR%" ^
|
||||
-A x64 ^
|
||||
-DCMAKE_BUILD_TYPE=Release ^
|
||||
-DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%" ^
|
||||
..
|
||||
cmake --build . --config Release
|
||||
cmake --build . --config Release --target install
|
||||
-DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%"
|
||||
cmake --build build-x64 --config Release
|
||||
cmake --build build-x64 --config Release --target install
|
||||
)
|
||||
|
||||
cd ..
|
||||
|
||||
echo.
|
||||
echo Building x86 virtual camera driver
|
||||
echo.
|
||||
|
||||
mkdir build-x86
|
||||
cd build-x86
|
||||
setlocal
|
||||
|
||||
if "%CMAKE_GENERATOR%" == "MSYS Makefiles" set PATH=C:\msys64\mingw32\bin;C:\msys64\usr\bin;%PATH%
|
||||
if "%CMAKE_GENERATOR%" == "MSYS Makefiles" (
|
||||
cmake ^
|
||||
-S . ^
|
||||
-B build-x86 ^
|
||||
-G "%CMAKE_GENERATOR%" ^
|
||||
-DCMAKE_BUILD_TYPE=Release ^
|
||||
-DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%" ^
|
||||
..
|
||||
cmake --build .
|
||||
cmake --build . --target install
|
||||
-DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%"
|
||||
cmake --build build-x86
|
||||
cmake --build build-x86 --target install
|
||||
)
|
||||
|
||||
endlocal
|
||||
|
||||
if "%CMAKE_GENERATOR:~0,13%" == "Visual Studio" (
|
||||
cmake ^
|
||||
-S . ^
|
||||
-B build-x86 ^
|
||||
-G "%CMAKE_GENERATOR%" ^
|
||||
-A Win32 ^
|
||||
-DCMAKE_BUILD_TYPE=Release ^
|
||||
-DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%" ^
|
||||
..
|
||||
cmake --build . --config Release
|
||||
cmake --build . --config Release --target install
|
||||
-DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%"
|
||||
cmake --build build-x86 --config Release
|
||||
cmake --build build-x86 --config Release --target install
|
||||
)
|
||||
|
||||
cd ..
|
||||
|
|
|
@ -34,23 +34,25 @@ echo
|
|||
echo "Building x64 virtual camera driver"
|
||||
echo
|
||||
mkdir build-x64
|
||||
cd build-x64
|
||||
x86_64-w64-mingw32-cmake \
|
||||
-S . \
|
||||
-B build-x64 \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_INSTALL_PREFIX="${INSTALL_PREFIX}" \
|
||||
..
|
||||
cmake --build .
|
||||
cd ..
|
||||
-DCMAKE_INSTALL_PREFIX="${INSTALL_PREFIX}"
|
||||
cmake --build build-x64
|
||||
cmake --build build-x64 --target install
|
||||
echo
|
||||
echo "Building x86 virtual camera driver"
|
||||
echo
|
||||
mkdir build-x86
|
||||
cd build-x86
|
||||
i686-w64-mingw32-cmake \
|
||||
-S . \
|
||||
-B build-x86 \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_INSTALL_PREFIX="${INSTALL_PREFIX}" \
|
||||
..
|
||||
cmake --build .
|
||||
-DCMAKE_INSTALL_PREFIX="${INSTALL_PREFIX}"
|
||||
cmake --build build-x86
|
||||
cmake --build build-x86 --target install
|
||||
EOF
|
||||
chmod +x ${BUILDSCRIPT}
|
||||
sudo cp -vf ${BUILDSCRIPT} "root.x86_64/$HOME/"
|
||||
|
|
|
@ -54,13 +54,6 @@ EOF
|
|||
fi
|
||||
|
||||
cat << EOF >> ${DEPLOYSCRIPT}
|
||||
cd build-x64
|
||||
cmake --build . --target install
|
||||
cd ..
|
||||
cd build-x86
|
||||
cmake --build . --target install
|
||||
cd ..
|
||||
|
||||
i686-w64-mingw32-strip \${INSTALL_PREFIX}/x86/*
|
||||
x86_64-w64-mingw32-strip \${INSTALL_PREFIX}/x64/*
|
||||
|
||||
|
|
|
@ -22,9 +22,10 @@ SOURCES_DIR=${PWD}
|
|||
INSTALL_PREFIX=${SOURCES_DIR}/webcamoid-data
|
||||
|
||||
mkdir build
|
||||
cd build
|
||||
cmake \
|
||||
-S . \
|
||||
-B build \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_INSTALL_PREFIX="${INSTALL_PREFIX}" \
|
||||
..
|
||||
cmake --build .
|
||||
-DCMAKE_INSTALL_PREFIX="${INSTALL_PREFIX}"
|
||||
cmake --build build
|
||||
cmake --build build --target install
|
||||
|
|
|
@ -22,10 +22,6 @@ SOURCES_DIR=${PWD}
|
|||
|
||||
git clone https://github.com/webcamoid/DeployTools.git
|
||||
|
||||
cd build
|
||||
cmake --build . --target install
|
||||
cd ..
|
||||
|
||||
export INSTALL_PREFIX="${SOURCES_DIR}/webcamoid-data"
|
||||
export PACKAGES_DIR="${SOURCES_DIR}/webcamoid-packages"
|
||||
export PYTHONPATH="${SOURCES_DIR}/DeployTools"
|
||||
|
|
|
@ -24,33 +24,29 @@ echo Building x64 virtual camera driver
|
|||
echo.
|
||||
|
||||
mkdir build-x64
|
||||
cd build-x64
|
||||
|
||||
cmake ^
|
||||
-S . ^
|
||||
-B build-x64 ^
|
||||
-G "%CMAKE_GENERATOR%" ^
|
||||
-A x64 ^
|
||||
-DCMAKE_BUILD_TYPE=Release ^
|
||||
-DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%" ^
|
||||
..
|
||||
cmake --build . --config Release
|
||||
cmake --build . --config Release --target install
|
||||
|
||||
cd ..
|
||||
-DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%"
|
||||
cmake --build build-x64 --config Release
|
||||
cmake --build build-x64 --config Release --target install
|
||||
|
||||
echo.
|
||||
echo Building x86 virtual camera driver
|
||||
echo.
|
||||
|
||||
mkdir build-x86
|
||||
cd build-x86
|
||||
|
||||
cmake ^
|
||||
-S . ^
|
||||
-B build-x86 ^
|
||||
-G "%CMAKE_GENERATOR%" ^
|
||||
-A Win32 ^
|
||||
-DCMAKE_BUILD_TYPE=Release ^
|
||||
-DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%" ^
|
||||
..
|
||||
cmake --build . --config Release
|
||||
cmake --build . --config Release --target install
|
||||
|
||||
cd ..
|
||||
-DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%"
|
||||
cmake --build build-x86 --config Release
|
||||
cmake --build build-x86 --config Release --target install
|
||||
|
|
Loading…
Reference in a new issue