Skip to content

Commit

Permalink
(.gitlab-ci.yml) Detect MSVC build errors
Browse files Browse the repository at this point in the history
  • Loading branch information
jdgleaver authored and m4xw committed Sep 24, 2021
1 parent f52fbd3 commit 50bb7af
Showing 1 changed file with 84 additions and 63 deletions.
147 changes: 84 additions & 63 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -104,36 +104,43 @@ build-retroarch-windows-msvc10-x64:
SDK_BIN_DIR: C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin
RCEDIT_BIN_DIR: C:\Program Files\rcedit
PEDEPS_BIN_DIR: C:\Program Files\pedeps-0.1.9-win64\bin
MSVC_PLATFORM: windows_msvc2010_x64
before_script:
- $Env:HOME = "."
- $Env:Path += -join(";", "$Env:SDK_BIN_DIR", ";", "$Env:RCEDIT_BIN_DIR", ";", "$Env:PEDEPS_BIN_DIR")
- $Env:Path += -join(";", "$Env:MSYS_BIN_DIR", ";", "$Env:SDK_BIN_DIR", ";", "$Env:RCEDIT_BIN_DIR", ";", "$Env:PEDEPS_BIN_DIR")
artifacts:
paths:
- retroarch.exe
- ${MEDIA_PATH}
expire_in: 10 min
dependencies: []
script:
# Build RetroArch
- $Script:MakeCmd = "$Env:MSYS_BIN_DIR\env.exe $Env:MSYS_BIN_DIR\bash.exe -l -c 'make -f Makefile.griffin platform=windows_msvc2010_x64'"
- Invoke-Expression $Script:MakeCmd
- mt.exe -nologo -manifest "retroarch.exe.manifest" -outputresource:"retroarch.exe;#1"
- rcedit-x64.exe "retroarch.exe" --set-icon "media\retroarch.ico"
# Create .media subdirectories
- New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/audio" -ItemType Directory
- New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/video" -ItemType Directory
- New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/pkg" -ItemType Directory
- New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist" -ItemType Directory
# Copy audio/video filters
- Get-ChildItem -Path "libretro-common/audio/dsp_filters/*" -Include *.dsp | Copy-Item -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/audio"
- Get-ChildItem -Path "gfx/video_filters/*" -Include *.filt | Copy-Item -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/video"
# Copy default config file
- Copy-Item -Path "retroarch.cfg" -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/pkg/retroarch.default.cfg"
# Copy dll dependencies
# (note that msvc10 build should not have any, but this
# may change in the future)
- copypedeps.exe -r retroarch.exe "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist"
- Remove-Item "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist/retroarch.exe" -ErrorAction Ignore
- |
$ErrorActionPreference = 'Stop'
# Build RetroArch
env.exe
bash.exe -l -c "make -f Makefile.griffin platform=$Env:MSVC_PLATFORM"
if ($LastExitCode -ne 0){throw "Failed to build RetroArch"}
mt.exe -nologo -manifest "retroarch.exe.manifest" -outputresource:"retroarch.exe;#1"
if ($LastExitCode -ne 0){throw "Failed to add manifest to RetroArch binary"}
rcedit-x64.exe "retroarch.exe" --set-icon "media\retroarch.ico"
if ($LastExitCode -ne 0){throw "Failed to set icon of RetroArch binary"}
# Create .media subdirectories
New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/audio" -ItemType Directory
New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/video" -ItemType Directory
New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/pkg" -ItemType Directory
New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist" -ItemType Directory
# Copy audio/video filters
Get-ChildItem -Path "libretro-common/audio/dsp_filters/*" -Include *.dsp | Copy-Item -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/audio"
Get-ChildItem -Path "gfx/video_filters/*" -Include *.filt | Copy-Item -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/video"
# Copy default config file
Copy-Item -Path "retroarch.cfg" -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/pkg/retroarch.default.cfg"
# Copy dll dependencies
# (note that msvc builds should not have any, but this
# may change in the future)
copypedeps.exe -r retroarch.exe "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist"
if ($LastExitCode -ne 0){throw "Failed to copy RetroArch dependencies"}
Remove-Item "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist/retroarch.exe" -ErrorAction Ignore
build-retroarch-windows-msvc10-i686:
tags:
Expand All @@ -147,36 +154,43 @@ build-retroarch-windows-msvc10-i686:
SDK_BIN_DIR: C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin
RCEDIT_BIN_DIR: C:\Program Files\rcedit
PEDEPS_BIN_DIR: C:\Program Files\pedeps-0.1.9-win64\bin
MSVC_PLATFORM: windows_msvc2010_x86
before_script:
- $Env:HOME = "."
- $Env:Path += -join(";", "$Env:SDK_BIN_DIR", ";", "$Env:RCEDIT_BIN_DIR", ";", "$Env:PEDEPS_BIN_DIR")
- $Env:Path += -join(";", "$Env:MSYS_BIN_DIR", ";", "$Env:SDK_BIN_DIR", ";", "$Env:RCEDIT_BIN_DIR", ";", "$Env:PEDEPS_BIN_DIR")
artifacts:
paths:
- retroarch.exe
- ${MEDIA_PATH}
expire_in: 10 min
dependencies: []
script:
# Build RetroArch
- $Script:MakeCmd = "$Env:MSYS_BIN_DIR\env.exe $Env:MSYS_BIN_DIR\bash.exe -l -c 'make -f Makefile.griffin platform=windows_msvc2010_x86'"
- Invoke-Expression $Script:MakeCmd
- mt.exe -nologo -manifest "retroarch.exe.manifest" -outputresource:"retroarch.exe;#1"
- rcedit-x64.exe "retroarch.exe" --set-icon "media\retroarch.ico"
# Create .media subdirectories
- New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/audio" -ItemType Directory
- New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/video" -ItemType Directory
- New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/pkg" -ItemType Directory
- New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist" -ItemType Directory
# Copy audio/video filters
- Get-ChildItem -Path "libretro-common/audio/dsp_filters/*" -Include *.dsp | Copy-Item -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/audio"
- Get-ChildItem -Path "gfx/video_filters/*" -Include *.filt | Copy-Item -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/video"
# Copy default config file
- Copy-Item -Path "retroarch.cfg" -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/pkg/retroarch.default.cfg"
# Copy dll dependencies
# (note that msvc10 build should not have any, but this
# may change in the future)
- copypedeps.exe -r retroarch.exe "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist"
- Remove-Item "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist/retroarch.exe" -ErrorAction Ignore
- |
$ErrorActionPreference = 'Stop'
# Build RetroArch
env.exe
bash.exe -l -c "make -f Makefile.griffin platform=$Env:MSVC_PLATFORM"
if ($LastExitCode -ne 0){throw "Failed to build RetroArch"}
mt.exe -nologo -manifest "retroarch.exe.manifest" -outputresource:"retroarch.exe;#1"
if ($LastExitCode -ne 0){throw "Failed to add manifest to RetroArch binary"}
rcedit-x64.exe "retroarch.exe" --set-icon "media\retroarch.ico"
if ($LastExitCode -ne 0){throw "Failed to set icon of RetroArch binary"}
# Create .media subdirectories
New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/audio" -ItemType Directory
New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/video" -ItemType Directory
New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/pkg" -ItemType Directory
New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist" -ItemType Directory
# Copy audio/video filters
Get-ChildItem -Path "libretro-common/audio/dsp_filters/*" -Include *.dsp | Copy-Item -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/audio"
Get-ChildItem -Path "gfx/video_filters/*" -Include *.filt | Copy-Item -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/video"
# Copy default config file
Copy-Item -Path "retroarch.cfg" -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/pkg/retroarch.default.cfg"
# Copy dll dependencies
# (note that msvc builds should not have any, but this
# may change in the future)
copypedeps.exe -r retroarch.exe "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist"
if ($LastExitCode -ne 0){throw "Failed to copy RetroArch dependencies"}
Remove-Item "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist/retroarch.exe" -ErrorAction Ignore
build-retroarch-windows-msvc05-i686:
tags:
Expand All @@ -191,36 +205,43 @@ build-retroarch-windows-msvc05-i686:
RCEDIT_BIN_DIR: C:\Program Files\rcedit
PEDEPS_BIN_DIR: C:\Program Files\pedeps-0.1.9-win64\bin
VS80COMNTOOLS: C:\Program Files (x86)\Microsoft Visual Studio 8\Common7\Tools\
MSVC_PLATFORM: windows_msvc2005_x86
before_script:
- $Env:HOME = "."
- $Env:Path += -join(";", "$Env:SDK_BIN_DIR", ";", "$Env:RCEDIT_BIN_DIR", ";", "$Env:PEDEPS_BIN_DIR")
- $Env:Path += -join(";", "$Env:MSYS_BIN_DIR", ";", "$Env:SDK_BIN_DIR", ";", "$Env:RCEDIT_BIN_DIR", ";", "$Env:PEDEPS_BIN_DIR")
artifacts:
paths:
- retroarch.exe
- ${MEDIA_PATH}
expire_in: 10 min
dependencies: []
script:
# Build RetroArch
- $Script:MakeCmd = "$Env:MSYS_BIN_DIR\env.exe $Env:MSYS_BIN_DIR\bash.exe -l -c 'make -f Makefile.griffin platform=windows_msvc2005_x86'"
- Invoke-Expression $Script:MakeCmd
- mt.exe -nologo -manifest "retroarch.exe.manifest" -outputresource:"retroarch.exe;#1"
- rcedit-x64.exe "retroarch.exe" --set-icon "media\retroarch.ico"
# Create .media subdirectories
- New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/audio" -ItemType Directory
- New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/video" -ItemType Directory
- New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/pkg" -ItemType Directory
- New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist" -ItemType Directory
# Copy audio/video filters
- Get-ChildItem -Path "libretro-common/audio/dsp_filters/*" -Include *.dsp | Copy-Item -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/audio"
- Get-ChildItem -Path "gfx/video_filters/*" -Include *.filt | Copy-Item -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/video"
# Copy default config file
- Copy-Item -Path "retroarch.cfg" -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/pkg/retroarch.default.cfg"
# Copy dll dependencies
# (note that msvc05 build should not have any, but this
# may change in the future)
- copypedeps.exe -r retroarch.exe "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist"
- Remove-Item "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist/retroarch.exe" -ErrorAction Ignore
- |
$ErrorActionPreference = 'Stop'
# Build RetroArch
env.exe
bash.exe -l -c "make -f Makefile.griffin platform=$Env:MSVC_PLATFORM"
if ($LastExitCode -ne 0){throw "Failed to build RetroArch"}
mt.exe -nologo -manifest "retroarch.exe.manifest" -outputresource:"retroarch.exe;#1"
if ($LastExitCode -ne 0){throw "Failed to add manifest to RetroArch binary"}
rcedit-x64.exe "retroarch.exe" --set-icon "media\retroarch.ico"
if ($LastExitCode -ne 0){throw "Failed to set icon of RetroArch binary"}
# Create .media subdirectories
New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/audio" -ItemType Directory
New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/video" -ItemType Directory
New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/pkg" -ItemType Directory
New-Item -Path "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist" -ItemType Directory
# Copy audio/video filters
Get-ChildItem -Path "libretro-common/audio/dsp_filters/*" -Include *.dsp | Copy-Item -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/audio"
Get-ChildItem -Path "gfx/video_filters/*" -Include *.filt | Copy-Item -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/filters/video"
# Copy default config file
Copy-Item -Path "retroarch.cfg" -Destination "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/pkg/retroarch.default.cfg"
# Copy dll dependencies
# (note that msvc builds should not have any, but this
# may change in the future)
copypedeps.exe -r retroarch.exe "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist"
if ($LastExitCode -ne 0){throw "Failed to copy RetroArch dependencies"}
Remove-Item "$Env:MEDIA_PATH/$Env:CI_PROJECT_NAME/redist/retroarch.exe" -ErrorAction Ignore
build-retroarch-linux-x64:
image: $CI_SERVER_HOST:5050/libretro-infrastructure/libretro-build-amd64-ubuntu:xenial-gcc9
Expand Down

0 comments on commit 50bb7af

Please sign in to comment.