summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Morph2021-10-12 13:26:12 -0400
committerGravatar GitHub2021-10-12 13:26:12 -0400
commitb97f340f012a9d86366cfc8107b4beb70b1a2e26 (patch)
tree7747029dadf9e39051cafcfec9420c703b1e6e1d
parentcommon/fs/path_util: Slightly refactor PathManagerImpl's constructor (diff)
parentBuild system: remove references to travis (diff)
downloadyuzu-b97f340f012a9d86366cfc8107b4beb70b1a2e26.tar.gz
yuzu-b97f340f012a9d86366cfc8107b4beb70b1a2e26.tar.xz
yuzu-b97f340f012a9d86366cfc8107b4beb70b1a2e26.zip
Merge pull request #7166 from FearlessTobi/port-5811
Port citra-emu/citra#5811: "Build system: remove references to travis"
Diffstat (limited to '')
-rw-r--r--.travis.yml59
-rwxr-xr-x.travis/clang-format/build.sh3
-rwxr-xr-x.travis/clang-format/deps.sh3
-rwxr-xr-x.travis/clang-format/docker.sh5
-rwxr-xr-x.travis/clang-format/script.sh37
-rwxr-xr-x.travis/common/post-upload.sh25
-rwxr-xr-x.travis/common/pre-upload.sh6
-rw-r--r--.travis/common/travis-ci.env18
-rwxr-xr-x.travis/linux-mingw/build.sh3
-rwxr-xr-x.travis/linux-mingw/deps.sh3
-rwxr-xr-x.travis/linux-mingw/docker.sh42
-rw-r--r--.travis/linux-mingw/scan_dll.py106
-rwxr-xr-x.travis/linux-mingw/upload.sh13
-rwxr-xr-x.travis/linux/build.sh4
-rwxr-xr-x.travis/linux/deps.sh3
-rwxr-xr-x.travis/linux/docker.sh11
-rwxr-xr-x.travis/linux/upload.sh14
-rwxr-xr-x.travis/macos/build.sh17
-rwxr-xr-x.travis/macos/deps.sh6
-rwxr-xr-x.travis/macos/upload.sh28
20 files changed, 0 insertions, 406 deletions
diff --git a/.travis.yml b/.travis.yml
deleted file mode 100644
index 93fda1dfa..000000000
--- a/.travis.yml
+++ /dev/null
@@ -1,59 +0,0 @@
1language: cpp
2matrix:
3 include:
4 - os: linux
5 env: NAME="clang-format"
6 sudo: required
7 dist: trusty
8 services: docker
9 install: "./.travis/clang-format/deps.sh"
10 script: "./.travis/clang-format/build.sh"
11 - os: linux
12 env: NAME="linux build"
13 sudo: required
14 dist: trusty
15 services: docker
16 addons:
17 apt:
18 packages:
19 - p7zip-full
20 install: "./.travis/linux/deps.sh"
21 script: "./.travis/linux/build.sh"
22 after_success: "./.travis/linux/upload.sh"
23 cache: ccache
24 - os: osx
25 env: NAME="macos build"
26 sudo: false
27 osx_image: xcode10.2
28 install: "./.travis/macos/deps.sh"
29 script: "./.travis/macos/build.sh"
30 after_success: "./.travis/macos/upload.sh"
31 cache: ccache
32 - os: linux
33 env: NAME="MinGW build"
34 sudo: required
35 dist: trusty
36 services: docker
37 addons:
38 apt:
39 packages:
40 - p7zip-full
41 install: "./.travis/linux-mingw/deps.sh"
42 script: "./.travis/linux-mingw/build.sh"
43 after_success: "./.travis/linux-mingw/upload.sh"
44 cache: ccache
45
46deploy:
47 provider: releases
48 api_key:
49 secure: ElsIAlbvVXBNKsP31nVPysh+mf0GQA4DiL/y5iJeQxKQYR6iRoNo+RfzOBmdswdo0bE/PGeBAlfzCkp15gjhWf6Je0N6dRpczmcmLq6SSQFn1Mpq00xMJB2AgQIlaHs6KFgoUA173EBKbPwgU/NubTFpJFm/Wa+NcSWAHQXKL9KT2M3qKpxNkPl3mKEVsbch4REP+T/46vsa+ikw0VE0kIs6V93LqUQZpI2F0Dhihx8Cxr5iedkE1QsNK+QSX9iItMHbfek9OH980gP7L3lkZltyAA1Pk0c37OAgz2PwczwNKwCT8jg9PMzdcKmWouvLyAkZFuA806ElzwHY3oEd91Zm6+Bk5n24yBKZ9027AZzw38NK2Z2m9Akb8+ar8PdsKU6N5pDutX9qSLayr0oMgJ0s7/xnGBGdL3gfkPCFc50xO/2DxlsOR+zAhPNM9Y76hhGy6A7/40+9uzrJvd4nAuDvIXRzi2Yl2L7mKBE4suMKbFLtk2LlgM0qY5JMVTQ8NliaEtqopfPur2KWFVJUpWDNLtNX8xGqhfwg7cLjIiGmnxSaJBTDuZI6dpEjkWkU0n1xYhGqEqit8DbehYzazozMJ+Vsr8hku7jGlUtlw+U6HG1e19O2y4aGeSwYPROcCNz+BLwmVM8oZE3Roy3qoaa2yiFf+sy6rUHznrhsfEM=
50 file_glob: true
51 file: "artifacts/*"
52 skip_cleanup: true
53 on:
54 tags: true
55
56notifications:
57 webhooks:
58 urls:
59 - https://api.yuzu-emu.org/code/travis/notify
diff --git a/.travis/clang-format/build.sh b/.travis/clang-format/build.sh
deleted file mode 100755
index 36c276c43..000000000
--- a/.travis/clang-format/build.sh
+++ /dev/null
@@ -1,3 +0,0 @@
1#!/bin/bash -ex
2
3docker run --env-file .travis/common/travis-ci.env -v $(pwd):/yuzu -v "$HOME/.ccache":/root/.ccache citraemu/build-environments:linux-clang-format /bin/bash -ex /yuzu/.travis/clang-format/docker.sh
diff --git a/.travis/clang-format/deps.sh b/.travis/clang-format/deps.sh
deleted file mode 100755
index a15d164c7..000000000
--- a/.travis/clang-format/deps.sh
+++ /dev/null
@@ -1,3 +0,0 @@
1#!/bin/sh -ex
2
3docker pull citraemu/build-environments:linux-clang-format
diff --git a/.travis/clang-format/docker.sh b/.travis/clang-format/docker.sh
deleted file mode 100755
index b519ab40e..000000000
--- a/.travis/clang-format/docker.sh
+++ /dev/null
@@ -1,5 +0,0 @@
1#!/bin/bash -ex
2
3# Run clang-format
4cd /yuzu
5./.travis/clang-format/script.sh
diff --git a/.travis/clang-format/script.sh b/.travis/clang-format/script.sh
deleted file mode 100755
index 56a785fe0..000000000
--- a/.travis/clang-format/script.sh
+++ /dev/null
@@ -1,37 +0,0 @@
1#!/bin/bash -ex
2
3if grep -nrI '\s$' src *.yml *.txt *.md Doxyfile .gitignore .gitmodules .travis* dist/*.desktop \
4 dist/*.svg dist/*.xml; then
5 echo Trailing whitespace found, aborting
6 exit 1
7fi
8
9# Default clang-format points to default 3.5 version one
10CLANG_FORMAT=clang-format-10.0
11$CLANG_FORMAT --version
12
13if [ "$TRAVIS_EVENT_TYPE" = "pull_request" ]; then
14 # Get list of every file modified in this pull request
15 files_to_lint="$(git diff --name-only --diff-filter=ACMRTUXB $TRAVIS_COMMIT_RANGE | grep '^src/[^.]*[.]\(cpp\|h\)$' || true)"
16else
17 # Check everything for branch pushes
18 files_to_lint="$(find src/ -name '*.cpp' -or -name '*.h')"
19fi
20
21# Turn off tracing for this because it's too verbose
22set +x
23
24for f in $files_to_lint; do
25 d=$(diff -u "$f" <($CLANG_FORMAT "$f") || true)
26 if ! [ -z "$d" ]; then
27 echo "!!! $f not compliant to coding style, here is the fix:"
28 echo "$d"
29 fail=1
30 fi
31done
32
33set -x
34
35if [ "$fail" = 1 ]; then
36 exit 1
37fi
diff --git a/.travis/common/post-upload.sh b/.travis/common/post-upload.sh
deleted file mode 100755
index 28735a9cf..000000000
--- a/.travis/common/post-upload.sh
+++ /dev/null
@@ -1,25 +0,0 @@
1#!/bin/bash -ex
2
3# Copy documentation
4cp license.txt "$REV_NAME"
5cp README.md "$REV_NAME"
6
7tar $COMPRESSION_FLAGS "$ARCHIVE_NAME" "$REV_NAME"
8
9# Find out what release we are building
10if [ -z $TRAVIS_TAG ]; then
11 RELEASE_NAME=head
12else
13 RELEASE_NAME=$(echo $TRAVIS_TAG | cut -d- -f1)
14 if [ "$NAME" = "MinGW build" ]; then
15 RELEASE_NAME="${RELEASE_NAME}-mingw"
16 fi
17fi
18
19mv "$REV_NAME" $RELEASE_NAME
20
217z a "$REV_NAME.7z" $RELEASE_NAME
22
23# move the compiled archive into the artifacts directory to be uploaded by travis releases
24mv "$ARCHIVE_NAME" artifacts/
25mv "$REV_NAME.7z" artifacts/
diff --git a/.travis/common/pre-upload.sh b/.travis/common/pre-upload.sh
deleted file mode 100755
index 3c2fc79a2..000000000
--- a/.travis/common/pre-upload.sh
+++ /dev/null
@@ -1,6 +0,0 @@
1#!/bin/bash -ex
2
3GITDATE="`git show -s --date=short --format='%ad' | sed 's/-//g'`"
4GITREV="`git show -s --format='%h'`"
5
6mkdir -p artifacts
diff --git a/.travis/common/travis-ci.env b/.travis/common/travis-ci.env
deleted file mode 100644
index cffeb2e2b..000000000
--- a/.travis/common/travis-ci.env
+++ /dev/null
@@ -1,18 +0,0 @@
1# List of environment variables to be shared with Docker containers
2CI
3TRAVIS
4CONTINUOUS_INTEGRATION
5TRAVIS_BRANCH
6TRAVIS_BUILD_ID
7TRAVIS_BUILD_NUMBER
8TRAVIS_COMMIT
9TRAVIS_COMMIT_RANGE
10TRAVIS_EVENT_TYPE
11TRAVIS_JOB_ID
12TRAVIS_JOB_NUMBER
13TRAVIS_REPO_SLUG
14TRAVIS_TAG
15
16# yuzu specific flags
17ENABLE_COMPATIBILITY_REPORTING
18USE_DISCORD_PRESENCE
diff --git a/.travis/linux-mingw/build.sh b/.travis/linux-mingw/build.sh
deleted file mode 100755
index b12d70b12..000000000
--- a/.travis/linux-mingw/build.sh
+++ /dev/null
@@ -1,3 +0,0 @@
1#!/bin/bash -ex
2mkdir "$HOME/.ccache" || true
3docker run --env-file .travis/common/travis-ci.env -v $(pwd):/yuzu -v "$HOME/.ccache":/root/.ccache yuzuemu/build-environments:linux-mingw /bin/bash -ex /yuzu/.travis/linux-mingw/docker.sh
diff --git a/.travis/linux-mingw/deps.sh b/.travis/linux-mingw/deps.sh
deleted file mode 100755
index 55b5d6006..000000000
--- a/.travis/linux-mingw/deps.sh
+++ /dev/null
@@ -1,3 +0,0 @@
1#!/bin/sh -ex
2
3docker pull yuzuemu/build-environments:linux-mingw
diff --git a/.travis/linux-mingw/docker.sh b/.travis/linux-mingw/docker.sh
deleted file mode 100755
index 80d7dfe9b..000000000
--- a/.travis/linux-mingw/docker.sh
+++ /dev/null
@@ -1,42 +0,0 @@
1#!/bin/bash -ex
2
3cd /yuzu
4# override Travis CI unreasonable ccache size
5echo 'max_size = 3.0G' > "$HOME/.ccache/ccache.conf"
6
7mkdir build && cd build
8cmake .. -G Ninja -DCMAKE_TOOLCHAIN_FILE="$(pwd)/../CMakeModules/MinGWCross.cmake" -DUSE_CCACHE=ON -DENABLE_COMPATIBILITY_LIST_DOWNLOAD=ON -DCMAKE_BUILD_TYPE=Release
9ninja
10
11# Clean up the dirty hacks
12rm /bin/uname && mv /bin/uname1 /bin/uname
13rm /bin/cmd
14
15ccache -s
16
17echo "Tests skipped"
18#ctest -VV -C Release
19
20echo 'Prepare binaries...'
21cd ..
22mkdir package
23
24QT_PLATFORM_DLL_PATH='/usr/x86_64-w64-mingw32/lib/qt5/plugins/platforms/'
25find build/ -name "yuzu*.exe" -exec cp {} 'package' \;
26
27# copy Qt plugins
28mkdir package/platforms
29cp "${QT_PLATFORM_DLL_PATH}/qwindows.dll" package/platforms/
30cp -rv "${QT_PLATFORM_DLL_PATH}/../mediaservice/" package/
31cp -rv "${QT_PLATFORM_DLL_PATH}/../imageformats/" package/
32rm -f package/mediaservice/*d.dll
33
34for i in package/*.exe; do
35 # we need to process pdb here, however, cv2pdb
36 # does not work here, so we just simply strip all the debug symbols
37 x86_64-w64-mingw32-strip "${i}"
38done
39
40pip3 install pefile
41python3 .travis/linux-mingw/scan_dll.py package/*.exe "package/"
42python3 .travis/linux-mingw/scan_dll.py package/imageformats/*.dll "package/"
diff --git a/.travis/linux-mingw/scan_dll.py b/.travis/linux-mingw/scan_dll.py
deleted file mode 100644
index 163183f2e..000000000
--- a/.travis/linux-mingw/scan_dll.py
+++ /dev/null
@@ -1,106 +0,0 @@
1import pefile
2import sys
3import re
4import os
5import queue
6import shutil
7
8# constant definitions
9KNOWN_SYS_DLLS = ['WINMM.DLL', 'MSVCRT.DLL', 'VERSION.DLL', 'MPR.DLL',
10 'DWMAPI.DLL', 'UXTHEME.DLL', 'DNSAPI.DLL', 'IPHLPAPI.DLL']
11# below is for Ubuntu 18.04 with specified PPA enabled, if you are using
12# other distro or different repositories, change the following accordingly
13DLL_PATH = [
14 '/usr/x86_64-w64-mingw32/bin/',
15 '/usr/x86_64-w64-mingw32/lib/',
16 '/usr/lib/gcc/x86_64-w64-mingw32/7.3-posix/'
17]
18
19missing = []
20
21
22def parse_imports(file_name):
23 results = []
24 pe = pefile.PE(file_name, fast_load=True)
25 pe.parse_data_directories()
26
27 for entry in pe.DIRECTORY_ENTRY_IMPORT:
28 current = entry.dll.decode()
29 current_u = current.upper() # b/c Windows is often case insensitive
30 # here we filter out system dlls
31 # dll w/ names like *32.dll are likely to be system dlls
32 if current_u.upper() not in KNOWN_SYS_DLLS and not re.match(string=current_u, pattern=r'.*32\.DLL'):
33 results.append(current)
34
35 return results
36
37
38def parse_imports_recursive(file_name, path_list=[]):
39 q = queue.Queue() # create a FIFO queue
40 # file_name can be a string or a list for the convience
41 if isinstance(file_name, str):
42 q.put(file_name)
43 elif isinstance(file_name, list):
44 for i in file_name:
45 q.put(i)
46 full_list = []
47 while q.qsize():
48 current = q.get_nowait()
49 print('> %s' % current)
50 deps = parse_imports(current)
51 # if this dll does not have any import, ignore it
52 if not deps:
53 continue
54 for dep in deps:
55 # the dependency already included in the list, skip
56 if dep in full_list:
57 continue
58 # find the requested dll in the provided paths
59 full_path = find_dll(dep)
60 if not full_path:
61 missing.append(dep)
62 continue
63 full_list.append(dep)
64 q.put(full_path)
65 path_list.append(full_path)
66 return full_list
67
68
69def find_dll(name):
70 for path in DLL_PATH:
71 for root, _, files in os.walk(path):
72 for f in files:
73 if name.lower() == f.lower():
74 return os.path.join(root, f)
75
76
77def deploy(name, dst, dry_run=False):
78 dlls_path = []
79 parse_imports_recursive(name, dlls_path)
80 for dll_entry in dlls_path:
81 if not dry_run:
82 shutil.copy(dll_entry, dst)
83 else:
84 print('[Dry-Run] Copy %s to %s' % (dll_entry, dst))
85 print('Deploy completed.')
86 return dlls_path
87
88
89def main():
90 if len(sys.argv) < 3:
91 print('Usage: %s [files to examine ...] [target deploy directory]')
92 return 1
93 to_deploy = sys.argv[1:-1]
94 tgt_dir = sys.argv[-1]
95 if not os.path.isdir(tgt_dir):
96 print('%s is not a directory.' % tgt_dir)
97 return 1
98 print('Scanning dependencies...')
99 deploy(to_deploy, tgt_dir)
100 if missing:
101 print('Following DLLs are not found: %s' % ('\n'.join(missing)))
102 return 0
103
104
105if __name__ == '__main__':
106 main()
diff --git a/.travis/linux-mingw/upload.sh b/.travis/linux-mingw/upload.sh
deleted file mode 100755
index 66e896bc4..000000000
--- a/.travis/linux-mingw/upload.sh
+++ /dev/null
@@ -1,13 +0,0 @@
1#!/bin/bash -ex
2
3. .travis/common/pre-upload.sh
4
5REV_NAME="yuzu-windows-mingw-${GITDATE}-${GITREV}"
6ARCHIVE_NAME="${REV_NAME}.tar.gz"
7COMPRESSION_FLAGS="-czvf"
8
9mkdir "$REV_NAME"
10# get around the permission issues
11cp -r package/* "$REV_NAME"
12
13. .travis/common/post-upload.sh
diff --git a/.travis/linux/build.sh b/.travis/linux/build.sh
deleted file mode 100755
index 0c7fb8c9d..000000000
--- a/.travis/linux/build.sh
+++ /dev/null
@@ -1,4 +0,0 @@
1#!/bin/bash -ex
2
3mkdir -p "$HOME/.ccache"
4docker run -e ENABLE_COMPATIBILITY_REPORTING --env-file .travis/common/travis-ci.env -v $(pwd):/yuzu -v "$HOME/.ccache":/home/yuzu/.ccache yuzuemu/build-environments:linux-fresh /bin/bash /yuzu/.travis/linux/docker.sh
diff --git a/.travis/linux/deps.sh b/.travis/linux/deps.sh
deleted file mode 100755
index 8d23c517d..000000000
--- a/.travis/linux/deps.sh
+++ /dev/null
@@ -1,3 +0,0 @@
1#!/bin/sh -ex
2
3docker pull yuzuemu/build-environments:linux-fresh
diff --git a/.travis/linux/docker.sh b/.travis/linux/docker.sh
deleted file mode 100755
index 166fb6d4c..000000000
--- a/.travis/linux/docker.sh
+++ /dev/null
@@ -1,11 +0,0 @@
1#!/bin/bash -ex
2
3cd /yuzu
4
5mkdir build && cd build
6cmake .. -G Ninja -DYUZU_USE_QT_WEB_ENGINE=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=/usr/lib/ccache/gcc -DCMAKE_CXX_COMPILER=/usr/lib/ccache/g++ -DYUZU_ENABLE_COMPATIBILITY_REPORTING=${ENABLE_COMPATIBILITY_REPORTING:-"OFF"} -DENABLE_COMPATIBILITY_LIST_DOWNLOAD=ON -DUSE_DISCORD_PRESENCE=ON
7ninja
8
9ccache -s
10
11ctest -VV -C Release
diff --git a/.travis/linux/upload.sh b/.travis/linux/upload.sh
deleted file mode 100755
index 61842be12..000000000
--- a/.travis/linux/upload.sh
+++ /dev/null
@@ -1,14 +0,0 @@
1#!/bin/bash -ex
2
3. .travis/common/pre-upload.sh
4
5REV_NAME="yuzu-linux-${GITDATE}-${GITREV}"
6ARCHIVE_NAME="${REV_NAME}.tar.xz"
7COMPRESSION_FLAGS="-cJvf"
8
9mkdir "$REV_NAME"
10
11cp build/bin/yuzu-cmd "$REV_NAME"
12cp build/bin/yuzu "$REV_NAME"
13
14. .travis/common/post-upload.sh
diff --git a/.travis/macos/build.sh b/.travis/macos/build.sh
deleted file mode 100755
index db1c7cae7..000000000
--- a/.travis/macos/build.sh
+++ /dev/null
@@ -1,17 +0,0 @@
1#!/bin/bash -ex
2
3set -o pipefail
4
5export MACOSX_DEPLOYMENT_TARGET=10.14
6export Qt5_DIR=$(brew --prefix)/opt/qt5
7export PATH="/usr/local/opt/ccache/libexec:$PATH"
8
9# TODO: Build using ninja instead of make
10mkdir build && cd build
11cmake --version
12cmake .. -DYUZU_USE_QT_WEB_ENGINE=ON -DCMAKE_BUILD_TYPE=Release -DENABLE_COMPATIBILITY_LIST_DOWNLOAD=ON -DYUZU_ENABLE_COMPATIBILITY_REPORTING=${ENABLE_COMPATIBILITY_REPORTING:-"OFF"} -DUSE_DISCORD_PRESENCE=ON
13make -j4
14
15ccache -s
16
17ctest -VV -C Release
diff --git a/.travis/macos/deps.sh b/.travis/macos/deps.sh
deleted file mode 100755
index faeafa216..000000000
--- a/.travis/macos/deps.sh
+++ /dev/null
@@ -1,6 +0,0 @@
1#!/bin/sh -ex
2
3brew update
4brew install p7zip qt5 sdl2 ccache
5brew outdated cmake || brew upgrade cmake
6pip3 install macpack
diff --git a/.travis/macos/upload.sh b/.travis/macos/upload.sh
deleted file mode 100755
index c2f43a906..000000000
--- a/.travis/macos/upload.sh
+++ /dev/null
@@ -1,28 +0,0 @@
1#!/bin/bash -ex
2
3. .travis/common/pre-upload.sh
4
5REV_NAME="yuzu-osx-${GITDATE}-${GITREV}"
6ARCHIVE_NAME="${REV_NAME}.tar.gz"
7COMPRESSION_FLAGS="-czvf"
8
9mkdir "$REV_NAME"
10
11cp build/bin/yuzu-cmd "$REV_NAME"
12cp -r build/bin/yuzu.app "$REV_NAME"
13
14# move libs into folder for deployment
15macpack "${REV_NAME}/yuzu.app/Contents/MacOS/yuzu" -d "../Frameworks"
16# move qt frameworks into app bundle for deployment
17$(brew --prefix)/opt/qt5/bin/macdeployqt "${REV_NAME}/yuzu.app" -executable="${REV_NAME}/yuzu.app/Contents/MacOS/yuzu"
18
19# move libs into folder for deployment
20macpack "${REV_NAME}/yuzu-cmd" -d "libs"
21
22# Make the launching script executable
23chmod +x ${REV_NAME}/yuzu.app/Contents/MacOS/yuzu
24
25# Verify loader instructions
26find "$REV_NAME" -exec otool -L {} \;
27
28. .travis/common/post-upload.sh