mirror of
https://github.com/riegera2412/UVtools.git
synced 2026-07-08 17:42:31 +02:00
Update build scripts
This commit is contained in:
+6
-1
@@ -12,6 +12,7 @@
|
||||
$libFolder = 'emgucv'
|
||||
$buildFile = "platforms\windows\Build_Binary_x86.bat"
|
||||
$buildArgs = '64 mini commercial no-openni no-doc no-package build'
|
||||
$customBuild = '-DWITH_FFMPEG:BOOL=FALSE -DWITH_MSMF:BOOL=FALSE -DWITH_DSHOW:BOOL=FALSE'
|
||||
|
||||
if ($args.Count -gt 0){
|
||||
if($args[0] -eq 'clean'){
|
||||
@@ -44,7 +45,11 @@ Option"
|
||||
Set-Location "$libFolder"
|
||||
|
||||
Write-Output "Configuring"
|
||||
(Get-Content -Path "$buildFile") -replace '-DBUILD_opencv_video:BOOL=FALSE', '-DBUILD_opencv_video:BOOL=FALSE -DWITH_TIFF:BOOL=FALSE -DEMGU_CV_WITH_TIFF:BOOL=FALSE' | Set-Content -Path "$buildFile"
|
||||
$search = (Get-Content -Path "$buildFile" | Select-String -Pattern "$customBuild").Matches.Success
|
||||
if(-not $search){
|
||||
$searchKeyword = '%CMAKE% %EMGU_CV_CMAKE_CONFIG_FLAGS%'
|
||||
(Get-Content -Path "$buildFile") -replace "$searchKeyword", "$searchKeyword $customBuild" | Set-Content -Path "$buildFile"
|
||||
}
|
||||
|
||||
Write-Output "Building"
|
||||
cmd.exe /c "$buildFile $buildArgs"
|
||||
|
||||
@@ -165,9 +165,11 @@ fi
|
||||
echo "- Bulding"
|
||||
if [ osVariant == "macOS" ]; then
|
||||
sed -i '' "s/-DBUILD_TIFF:BOOL=TRUE/-DBUILD_TIFF:BOOL=FALSE/g" "$directory/platforms/macos/configure" 2>/dev/null
|
||||
sed -i "s/\$FREETYPE_OPTION/\$FREETYPE_OPTION -DWITH_AVFOUNDATION:BOOL=FALSE -DWITH_FFMPEG:BOOL=FALSE -DWITH_GSTREAMER:BOOL=FALSE/g" "$directory/platforms/ubuntu/22.04/cmake_configure" 2>/dev/null
|
||||
"$directory/platforms/macos/configure" $arch $build_package
|
||||
else # Linux
|
||||
sed -i "s/-DBUILD_TIFF:BOOL=TRUE/-DBUILD_TIFF:BOOL=FALSE/g" "$directory/platforms/ubuntu/22.04/cmake_configure" 2>/dev/null
|
||||
sed -i "s/-DWITH_EIGEN:BOOL=TRUE/-DWITH_EIGEN:BOOL=TRUE -DWITH_V4L:BOOL=FALSE -DWITH_FFMPEG:BOOL=FALSE -DWITH_GSTREAMER:BOOL=FALSE/g" "$directory/platforms/ubuntu/22.04/cmake_configure" 2>/dev/null
|
||||
"$directory/platforms/ubuntu/22.04/cmake_configure" $build_package
|
||||
fi
|
||||
|
||||
|
||||
Reference in New Issue
Block a user