Merge pull request #31 from jroweboy/fix-deploy
Build/Deploy Updates to Setup Nightly Builds
This commit is contained in:
commit
f53dc4c9d6
9 changed files with 67 additions and 50 deletions
3
.gitmodules
vendored
3
.gitmodules
vendored
|
@ -19,3 +19,6 @@
|
||||||
[submodule "lz4"]
|
[submodule "lz4"]
|
||||||
path = externals/lz4
|
path = externals/lz4
|
||||||
url = http://github.com/lz4/lz4.git
|
url = http://github.com/lz4/lz4.git
|
||||||
|
[submodule "unicorn"]
|
||||||
|
path = externals/unicorn
|
||||||
|
url = https://github.com/yuzu-emu/unicorn
|
||||||
|
|
|
@ -32,7 +32,7 @@ matrix:
|
||||||
deploy:
|
deploy:
|
||||||
provider: releases
|
provider: releases
|
||||||
api_key:
|
api_key:
|
||||||
secure: Mck15DIWaJdxDiS3aYVlM9N3G6y8VKUI1rnwII7/iolfm1s94U+tgvbheZDmT7SSbFyaGaYO/E8HrV/uZR9Vvs7ev20sHsTN1u60OTWfDIIyHs9SqjhcGbtq95m9/dMFschOYqTOR+gAs5BsxjuoeAotHdhpQEwvkO2oo5oR0zhGy45gjFnVvtcxT/IfpZBIpVgcK3aLb9zT6ekcJbSiPmEB15iLq3xXd0nFUNtEZdX3D6Veye4n5jB6n72qN8JVoKvPZAwaC2K0pZxpcGJaXDchLsw1q+4eCvdz6UJfUemeQ/uMAmjfeQ3wrzYGXe3nCM3WmX5wosCsB0mw4zYatzl3si6CZ1W+0GkV4Rwlx03dfp7v3EeFhTsXYCaXqhwuLZnWOLUik8t9vaSoFUx4nUIRwfO9kAMUJQSpLuHNO2nT01s3GxvqxzczuLQ9he5nGSi0RRodUzDwek1qUp6I4uV3gRHKz4B07YIc1i2fK88NLXjyQ0uLVZ+7Oq1+kgDp6+N7vvXXZ5qZ17tdaysSbKEE0Y8zsoXw7Rk1tPN19vrCS+TSpomNMyQyne1k+I5iZ/qkxPTLAS5qI6Utc2dL3GJdxWRAEfGNO9AIX3GV/jmmKfdcvwGsCYP8hxqs5vLYfgacw3D8NLf1941lQUwavC17jm9EV9g5G3Pn1Cp516E=
|
secure: IuTT8DjxzNgOtaEsyOpz1JaSmtDtHSsWZnJKmSBwXAzgP2ZU4Ja3/q0z5PwbC5Ql7kuFahuYTE5oi7lbJBuu2P3y1Wj2zvFozGUkA3JUvEXDNOPS9QTJ1EYd6O+wenZoj7d/Pn+ZeIgyEafnnZsGBb8lMQnV9MfIHgYlZQ5EyF3n4XikT2h1UbDBYx74ciXZIxFEulx68kDr9Q4/U+zIYQmYv2N+lgXSLDkFrCJ046gRcujPYGPqE6jVw0kKni80CTTpuDF5prU8yIBeiffjkJ3Qx1a17G07eZ4r83P4XUOlaHbRBmA/8ywZvLF2Gep3wGKfSFgMWbPxBJk5ZSYcOOAgMsEcg0+gBK9gLTwO4pbmc2GvqP21yRQBzgtbFoEtAHLu5lVPBkZU7kZuRMJtRdqvFIwOLhpnRS8IknFOD5vjtaFiNdGWaK9ePdsGvplijnXcPafkumakc4+eVEiXb6/KzdX1zXdur5tuUPFytm0Oy6IJcGIf8FHXGvUlmWsnPzwfusij9JgeQOP+uegc9PdBfL+h7L5rk+ilELt3cXD5K7wgov/4hkl5istNJ2bm0IioIstWss8QQQTkyscGoeh/oXmUpOL4FdsTvsWhDR3QKeq8nSzgDkqLe0iSbplQGnC7o7ytNbldmxJvf3nylwglA8w3HlqLHtZLkUOcuQ0=
|
||||||
file_glob: true
|
file_glob: true
|
||||||
file: "artifacts/*"
|
file: "artifacts/*"
|
||||||
skip_cleanup: true
|
skip_cleanup: true
|
||||||
|
|
|
@ -1,22 +1,16 @@
|
||||||
#!/bin/bash -ex
|
#!/bin/bash -ex
|
||||||
|
|
||||||
apt-get update
|
apt-get update
|
||||||
apt-get install -y build-essential git libcurl4-openssl-dev libqt5opengl5-dev libsdl2-dev libssl-dev python qtbase5-dev wget
|
apt-get install -y build-essential git libqt5opengl5-dev libsdl2-dev libssl-dev python qtbase5-dev wget
|
||||||
|
|
||||||
# Get a recent version of CMake
|
# Get a recent version of CMake
|
||||||
wget https://cmake.org/files/v3.10/cmake-3.10.1-Linux-x86_64.sh
|
wget https://cmake.org/files/v3.10/cmake-3.10.1-Linux-x86_64.sh
|
||||||
sh cmake-3.10.1-Linux-x86_64.sh --exclude-subdir --prefix=/ --skip-license
|
sh cmake-3.10.1-Linux-x86_64.sh --exclude-subdir --prefix=/ --skip-license
|
||||||
|
|
||||||
mkdir /unicorn
|
|
||||||
cd /unicorn
|
|
||||||
git clone https://github.com/yuzu-emu/unicorn .
|
|
||||||
UNICORN_ARCHS=aarch64 ./make.sh
|
|
||||||
./make.sh install
|
|
||||||
|
|
||||||
cd /yuzu
|
cd /yuzu
|
||||||
|
|
||||||
mkdir build && cd build
|
mkdir build && cd build
|
||||||
cmake .. -DUSE_SYSTEM_CURL=ON -DCMAKE_BUILD_TYPE=Release
|
cmake .. -DYUZU_BUILD_UNICORN=ON -DCMAKE_BUILD_TYPE=Release
|
||||||
make -j4
|
make -j4
|
||||||
|
|
||||||
ctest -VV -C Release
|
ctest -VV -C Release
|
||||||
|
|
|
@ -8,7 +8,7 @@ export UNICORNDIR=$(pwd)/externals/unicorn
|
||||||
|
|
||||||
mkdir build && cd build
|
mkdir build && cd build
|
||||||
cmake --version
|
cmake --version
|
||||||
cmake .. -DUSE_SYSTEM_CURL=ON -DCMAKE_OSX_ARCHITECTURES="x86_64;x86_64h" -DCMAKE_BUILD_TYPE=Release
|
cmake .. -DYUZU_BUILD_UNICORN=ON -DCMAKE_OSX_ARCHITECTURES="x86_64;x86_64h" -DCMAKE_BUILD_TYPE=Release
|
||||||
make -j4
|
make -j4
|
||||||
|
|
||||||
ctest -VV -C Release
|
ctest -VV -C Release
|
||||||
|
|
|
@ -2,9 +2,3 @@
|
||||||
|
|
||||||
brew update
|
brew update
|
||||||
brew install dylibbundler p7zip qt5 sdl2
|
brew install dylibbundler p7zip qt5 sdl2
|
||||||
|
|
||||||
mkdir externals/unicorn
|
|
||||||
pushd externals/unicorn
|
|
||||||
git clone https://github.com/yuzu-emu/unicorn .
|
|
||||||
UNICORN_ARCHS=aarch64 ./make.sh macos-universal-no
|
|
||||||
popd
|
|
||||||
|
|
|
@ -12,8 +12,6 @@ option(YUZU_USE_BUNDLED_SDL2 "Download bundled SDL2 binaries" OFF)
|
||||||
option(ENABLE_QT "Enable the Qt frontend" ON)
|
option(ENABLE_QT "Enable the Qt frontend" ON)
|
||||||
option(YUZU_USE_BUNDLED_QT "Download bundled Qt binaries" OFF)
|
option(YUZU_USE_BUNDLED_QT "Download bundled Qt binaries" OFF)
|
||||||
|
|
||||||
option(YUZU_USE_BUNDLED_UNICORN "Download bundled Unicorn binaries" OFF)
|
|
||||||
|
|
||||||
if(NOT EXISTS ${CMAKE_SOURCE_DIR}/.git/hooks/pre-commit)
|
if(NOT EXISTS ${CMAKE_SOURCE_DIR}/.git/hooks/pre-commit)
|
||||||
message(STATUS "Copying pre-commit hook")
|
message(STATUS "Copying pre-commit hook")
|
||||||
file(COPY hooks/pre-commit
|
file(COPY hooks/pre-commit
|
||||||
|
@ -29,7 +27,7 @@ function(check_submodules_present)
|
||||||
foreach(module ${gitmodules})
|
foreach(module ${gitmodules})
|
||||||
string(REGEX REPLACE "path *= *" "" module ${module})
|
string(REGEX REPLACE "path *= *" "" module ${module})
|
||||||
if (NOT EXISTS "${CMAKE_SOURCE_DIR}/${module}/.git")
|
if (NOT EXISTS "${CMAKE_SOURCE_DIR}/${module}/.git")
|
||||||
message(SEND_ERROR "Git submodule ${module} not found."
|
message(FATAL_ERROR "Git submodule ${module} not found. "
|
||||||
"Please run: git submodule update --init --recursive")
|
"Please run: git submodule update --init --recursive")
|
||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
@ -204,7 +202,11 @@ else()
|
||||||
set(SDL2_FOUND NO)
|
set(SDL2_FOUND NO)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (YUZU_USE_BUNDLED_UNICORN)
|
# If unicorn isn't found, msvc -> download bundled unicorn; everyone else -> build external
|
||||||
|
find_package(Unicorn QUIET)
|
||||||
|
if (NOT UNICORN_FOUND)
|
||||||
|
if (MSVC)
|
||||||
|
message(STATUS "unicorn not found, falling back to bundled")
|
||||||
# Detect toolchain and platform
|
# Detect toolchain and platform
|
||||||
if (MSVC14 AND ARCHITECTURE_x86_64)
|
if (MSVC14 AND ARCHITECTURE_x86_64)
|
||||||
set(UNICORN_VER "unicorn-yuzu")
|
set(UNICORN_VER "unicorn-yuzu")
|
||||||
|
@ -221,17 +223,42 @@ if (YUZU_USE_BUNDLED_UNICORN)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set(UNICORN_FOUND YES)
|
set(UNICORN_FOUND YES)
|
||||||
set(LIBUNICORN_INCLUDE_DIR "${UNICORN_PREFIX}/include" CACHE PATH "Path to Unicorn headers")
|
set(LIBUNICORN_INCLUDE_DIR "${UNICORN_PREFIX}/include" CACHE PATH "Path to Unicorn headers" FORCE)
|
||||||
set(LIBUNICORN_LIBRARY "${UNICORN_PREFIX}/lib/x64/unicorn_dynload.lib" CACHE PATH "Path to Unicorn library")
|
set(LIBUNICORN_LIBRARY "${UNICORN_PREFIX}/lib/x64/unicorn_dynload.lib" CACHE PATH "Path to Unicorn library" FORCE)
|
||||||
set(UNICORN_DLL_DIR "${UNICORN_PREFIX}/lib/x64/" CACHE PATH "Path to unicorn.dll")
|
set(UNICORN_DLL_DIR "${UNICORN_PREFIX}/lib/x64/" CACHE PATH "Path to unicorn.dll" FORCE)
|
||||||
else()
|
else()
|
||||||
find_package(Unicorn REQUIRED)
|
message(STATUS "unicorn not found, falling back to externals")
|
||||||
|
if (MINGW)
|
||||||
|
set(UNICORN_LIB_NAME "unicorn.a")
|
||||||
|
else()
|
||||||
|
set(UNICORN_LIB_NAME "libunicorn.a")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
set(UNICORN_FOUND YES)
|
||||||
|
set(UNICORN_PREFIX ${CMAKE_SOURCE_DIR}/externals/unicorn)
|
||||||
|
set(LIBUNICORN_LIBRARY "${UNICORN_PREFIX}/${UNICORN_LIB_NAME}" CACHE PATH "Path to Unicorn library" FORCE)
|
||||||
|
set(LIBUNICORN_INCLUDE_DIR "${UNICORN_PREFIX}/include" CACHE PATH "Path to Unicorn headers" FORCE)
|
||||||
|
set(UNICORN_DLL_DIR "${UNICORN_PREFIX}/" CACHE PATH "Path to unicorn dynamic library" FORCE)
|
||||||
|
|
||||||
|
add_custom_command(OUTPUT ${LIBUNICORN_LIBRARY}
|
||||||
|
COMMAND ${CMAKE_COMMAND} -E env UNICORN_ARCHS="aarch64" /bin/sh make.sh
|
||||||
|
WORKING_DIRECTORY ${UNICORN_PREFIX}
|
||||||
|
)
|
||||||
|
# ALL makes this custom target build every time
|
||||||
|
# but it won't actually build if LIBUNICORN_LIBRARY is up to date
|
||||||
|
add_custom_target(unicorn-build ALL
|
||||||
|
DEPENDS ${LIBUNICORN_LIBRARY}
|
||||||
|
)
|
||||||
|
unset(UNICORN_LIB_NAME)
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (UNICORN_FOUND)
|
if (UNICORN_FOUND)
|
||||||
add_library(unicorn INTERFACE)
|
add_library(unicorn INTERFACE)
|
||||||
target_link_libraries(unicorn INTERFACE "${LIBUNICORN_LIBRARY}")
|
target_link_libraries(unicorn INTERFACE "${LIBUNICORN_LIBRARY}")
|
||||||
target_include_directories(unicorn INTERFACE "${LIBUNICORN_INCLUDE_DIR}")
|
target_include_directories(unicorn INTERFACE "${LIBUNICORN_INCLUDE_DIR}")
|
||||||
|
else()
|
||||||
|
message(FATAL_ERROR "Could not find or build unicorn which is required.")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (ENABLE_QT)
|
if (ENABLE_QT)
|
||||||
|
|
22
appveyor.yml
22
appveyor.yml
|
@ -28,7 +28,6 @@ install:
|
||||||
if ($env:BUILD_TYPE -eq 'mingw') {
|
if ($env:BUILD_TYPE -eq 'mingw') {
|
||||||
$dependencies = "mingw64/mingw-w64-x86_64-cmake",
|
$dependencies = "mingw64/mingw-w64-x86_64-cmake",
|
||||||
"mingw64/mingw-w64-x86_64-qt5",
|
"mingw64/mingw-w64-x86_64-qt5",
|
||||||
"mingw64/mingw-w64-x86_64-curl",
|
|
||||||
"mingw64/mingw-w64-x86_64-SDL2"
|
"mingw64/mingw-w64-x86_64-SDL2"
|
||||||
# redirect err to null to prevent warnings from becoming errors
|
# redirect err to null to prevent warnings from becoming errors
|
||||||
# workaround to prevent pacman from failing due to cyclical dependencies
|
# workaround to prevent pacman from failing due to cyclical dependencies
|
||||||
|
@ -42,9 +41,9 @@ before_build:
|
||||||
- ps: |
|
- ps: |
|
||||||
if ($env:BUILD_TYPE -eq 'msvc') {
|
if ($env:BUILD_TYPE -eq 'msvc') {
|
||||||
# redirect stderr and change the exit code to prevent powershell from cancelling the build if cmake prints a warning
|
# redirect stderr and change the exit code to prevent powershell from cancelling the build if cmake prints a warning
|
||||||
cmd /C 'cmake -G "Visual Studio 15 2017 Win64" -DYUZU_USE_BUNDLED_QT=1 -DYUZU_USE_BUNDLED_SDL2=1 -DYUZU_USE_BUNDLED_UNICORN=1 -DCMAKE_USE_OPENSSL=0 .. 2>&1 && exit 0'
|
cmd /C 'cmake -G "Visual Studio 15 2017 Win64" -DYUZU_USE_BUNDLED_QT=1 -DYUZU_USE_BUNDLED_SDL2=1 -DYUZU_USE_BUNDLED_UNICORN=1 .. 2>&1 && exit 0'
|
||||||
} else {
|
} else {
|
||||||
C:\msys64\usr\bin\bash.exe -lc "cmake -G 'MSYS Makefiles' -DUSE_SYSTEM_CURL=1 -DYUZU_USE_BUNDLED_CURL=1 -DCMAKE_BUILD_TYPE=Release .. 2>&1"
|
C:\msys64\usr\bin\bash.exe -lc "cmake -G 'MSYS Makefiles' -DYUZU_BUILD_UNICORN=1 -DCMAKE_BUILD_TYPE=Release .. 2>&1"
|
||||||
}
|
}
|
||||||
- cd ..
|
- cd ..
|
||||||
|
|
||||||
|
@ -81,11 +80,12 @@ after_build:
|
||||||
$env:BUILD_SYMBOLS = $MSVC_BUILD_PDB
|
$env:BUILD_SYMBOLS = $MSVC_BUILD_PDB
|
||||||
$env:BUILD_UPDATE = $MSVC_SEVENZIP
|
$env:BUILD_UPDATE = $MSVC_SEVENZIP
|
||||||
|
|
||||||
7z a -tzip $MSVC_BUILD_PDB .\msvc_build\bin\release\*.pdb
|
mkdir pdb
|
||||||
rm .\msvc_build\bin\release\*.pdb
|
Get-ChildItem ".\msvc_build\bin\" -Recurse -Filter "*.pdb" | Copy-Item -destination .\pdb
|
||||||
|
7z a -tzip $MSVC_BUILD_PDB .\pdb\*.pdb
|
||||||
|
|
||||||
mkdir $RELEASE_DIST
|
mkdir $RELEASE_DIST
|
||||||
Copy-Item .\msvc_build\bin\release\* -Destination $RELEASE_DIST -Recurse
|
Get-ChildItem ".\msvc_build\bin\" -Recurse -Filter "yuzu*.exe" | Copy-Item -destination $RELEASE_DIST
|
||||||
Copy-Item .\license.txt -Destination $RELEASE_DIST
|
Copy-Item .\license.txt -Destination $RELEASE_DIST
|
||||||
Copy-Item .\README.md -Destination $RELEASE_DIST
|
Copy-Item .\README.md -Destination $RELEASE_DIST
|
||||||
7z a -tzip $MSVC_BUILD_ZIP $RELEASE_DIST\*
|
7z a -tzip $MSVC_BUILD_ZIP $RELEASE_DIST\*
|
||||||
|
@ -104,16 +104,14 @@ after_build:
|
||||||
$env:BUILD_UPDATE = $MINGW_SEVENZIP
|
$env:BUILD_UPDATE = $MINGW_SEVENZIP
|
||||||
|
|
||||||
$CMAKE_SOURCE_DIR = "$env:APPVEYOR_BUILD_FOLDER"
|
$CMAKE_SOURCE_DIR = "$env:APPVEYOR_BUILD_FOLDER"
|
||||||
$CMAKE_BINARY_DIR = "$CMAKE_SOURCE_DIR/mingw_build"
|
$CMAKE_BINARY_DIR = "$CMAKE_SOURCE_DIR/mingw_build/bin"
|
||||||
$RELEASE_DIST = $RELEASE_DIST + "-mingw"
|
$RELEASE_DIST = $RELEASE_DIST + "-mingw"
|
||||||
|
|
||||||
mkdir $RELEASE_DIST
|
mkdir $RELEASE_DIST
|
||||||
mkdir $RELEASE_DIST/platforms
|
mkdir $RELEASE_DIST/platforms
|
||||||
|
|
||||||
# copy the compiled binaries and other release files to the release folder
|
# copy the compiled binaries and other release files to the release folder
|
||||||
Get-ChildItem "$CMAKE_BINARY_DIR" -Recurse -Filter "yuzu*.exe" | Copy-Item -destination $RELEASE_DIST
|
Get-ChildItem "$CMAKE_BINARY_DIR" -Filter "yuzu*.exe" | Copy-Item -destination $RELEASE_DIST
|
||||||
# copy the libcurl dll
|
|
||||||
Get-ChildItem "$CMAKE_BINARY_DIR" -Recurse -Filter "libcurl.dll" | Copy-Item -destination $RELEASE_DIST
|
|
||||||
Copy-Item -path "$CMAKE_SOURCE_DIR/license.txt" -destination $RELEASE_DIST
|
Copy-Item -path "$CMAKE_SOURCE_DIR/license.txt" -destination $RELEASE_DIST
|
||||||
Copy-Item -path "$CMAKE_SOURCE_DIR/README.md" -destination $RELEASE_DIST
|
Copy-Item -path "$CMAKE_SOURCE_DIR/README.md" -destination $RELEASE_DIST
|
||||||
# copy all the dll dependencies to the release folder
|
# copy all the dll dependencies to the release folder
|
||||||
|
@ -122,7 +120,7 @@ after_build:
|
||||||
# QT dll dependencies
|
# QT dll dependencies
|
||||||
"libbz2-*.dll","libicudt*.dll","libicuin*.dll","libicuuc*.dll","libffi-*.dll",
|
"libbz2-*.dll","libicudt*.dll","libicuin*.dll","libicuuc*.dll","libffi-*.dll",
|
||||||
"libfreetype-*.dll","libglib-*.dll","libgobject-*.dll","libgraphite2.dll","libiconv-*.dll",
|
"libfreetype-*.dll","libglib-*.dll","libgobject-*.dll","libgraphite2.dll","libiconv-*.dll",
|
||||||
"libharfbuzz-*.dll","libintl-*.dll","libpcre-*.dll","libpcre16-*.dll","libpng16-*.dll",
|
"libharfbuzz-*.dll","libintl-*.dll","libpcre-*.dll","libpcre2-16-*.dll","libpcre16-*.dll","libpng16-*.dll",
|
||||||
# Runtime/Other dependencies
|
# Runtime/Other dependencies
|
||||||
"libgcc_s_seh-*.dll","libstdc++-*.dll","libwinpthread-*.dll","SDL2.dll","zlib1.dll"
|
"libgcc_s_seh-*.dll","libstdc++-*.dll","libwinpthread-*.dll","SDL2.dll","zlib1.dll"
|
||||||
foreach ($file in $MingwDLLs) {
|
foreach ($file in $MingwDLLs) {
|
||||||
|
@ -165,7 +163,7 @@ deploy:
|
||||||
provider: GitHub
|
provider: GitHub
|
||||||
release: $(appveyor_repo_tag_name)
|
release: $(appveyor_repo_tag_name)
|
||||||
auth_token:
|
auth_token:
|
||||||
secure: "dbpsMC/MgPKWFNJCXpQl4cR8FYhepkPLjgNp/pRMktZ8oLKTqPYErfreaIxb/4P1"
|
secure: "argb6oi2TYLB4wDy+HoCC8PuGAmsnocSk12CQ5614XAPO+NVPndlkLv1utnDFfg2"
|
||||||
artifact: update,build
|
artifact: update,build
|
||||||
draft: false
|
draft: false
|
||||||
prerelease: false
|
prerelease: false
|
||||||
|
|
1
externals/unicorn
vendored
Submodule
1
externals/unicorn
vendored
Submodule
|
@ -0,0 +1 @@
|
||||||
|
Subproject commit 73f45735354396766a4bfb26d0b96b06e5cf31b2
|
|
@ -11,7 +11,7 @@
|
||||||
#include "core/hle/kernel/svc.h"
|
#include "core/hle/kernel/svc.h"
|
||||||
|
|
||||||
// Load Unicorn DLL once on Windows using RAII
|
// Load Unicorn DLL once on Windows using RAII
|
||||||
#ifdef _WIN32
|
#ifdef _MSC_VER
|
||||||
#include <unicorn_dynload.h>
|
#include <unicorn_dynload.h>
|
||||||
struct LoadDll {
|
struct LoadDll {
|
||||||
private:
|
private:
|
||||||
|
|
Loading…
Reference in a new issue