forked from openai/retro
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
261216d
commit e44ff7b
Showing
15 changed files
with
1,052 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -53,6 +53,11 @@ jobs: | |
- name: Build environment information | ||
run: 'echo "Matrix OS: ${{ matrix.os }} on $HOSTNAME with $(getconf _NPROCESSORS_ONLN) cores"' | ||
|
||
- name: Set git credentials | ||
run: | | ||
git config --global user.name "GitHub Action" | ||
git config --global user.email "[email protected]" | ||
# Check-out the repository under $GITHUB_WORKSPACE, so the job can | ||
# access it | ||
- name: Checkout main repo | ||
|
@@ -66,7 +71,7 @@ jobs: | |
frontend/src/generated | ||
tools/dist | ||
tools/repos/emsdk | ||
key: restore-depends-${{ matrix.os }}-${{ hashFiles('tools/depends/native/emscripten/*', 'tools/depends/wasm/ade/*', 'tools/depends/wasm/opencv/*') }} | ||
key: restore-depends-${{ matrix.os }}-${{ hashFiles('tools/depends/native/emscripten/*', 'tools/depends/wasm/ade/*', 'tools/depends/wasm/codecbox.js/*', 'tools/depends/wasm/ffmpeg/*', 'tools/depends/wasm/libvpx/*', 'tools/depends/wasm/opencv/*', 'tools/depends/wasm/x264/*') }} | ||
|
||
- name: Build depends | ||
if: steps.restore-depends.outputs.cache-hit != 'true' | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
35 changes: 35 additions & 0 deletions
35
tools/depends/wasm/codecbox.js/0001-Fix-error-building-OpenH264.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
From 4e97a5d5673d8e496634da9b2ba3b9ed1513c04e Mon Sep 17 00:00:00 2001 | ||
From: juztamau5 <[email protected]> | ||
Date: Sat, 11 Jul 2020 11:03:54 -0700 | ||
Subject: [PATCH 1/2] Fix error building OpenH264 | ||
|
||
Error was: | ||
|
||
codec/common/mips/copy_mb_mmi.c:94:35: error: invalid use of a cast in | ||
a inline asm context requiring an l-value: remove the cast or build | ||
with -fheinous-gnu-extensions | ||
|
||
: [pDst]"+&r"((unsigned char *)pDst), [pSrc]"+&r"((unsigned char *)pSrc) | ||
~~~~~~~~~~~~~~~~~^~~~ | ||
--- | ||
Gruntfile.js | 4 ++-- | ||
1 file changed, 2 insertions(+), 2 deletions(-) | ||
|
||
diff --git a/Gruntfile.js b/Gruntfile.js | ||
index 7f0d90d..123f403 100644 | ||
--- a/Gruntfile.js | ||
+++ b/Gruntfile.js | ||
@@ -251,8 +251,8 @@ module.exports = function (grunt) { | ||
}, | ||
openh264: { | ||
repo: 'https://github.com/cisco/openh264.git', | ||
- make: 'emmake make SHELL="/bin/bash -x" ARCH=mips CFLAGS="-O3 -fno-stack-protector" -j' + 1, //paraMake, | ||
- install: 'emmake make ARCH=mips PREFIX=' + distPath + ' install-headers install-shared', | ||
+ make: 'emmake make USE_ASM=No SHELL="/bin/bash -x" ARCH=mips CFLAGS="-O3 -fno-stack-protector" -j' + 1, //paraMake, | ||
+ install: 'emmake make USE_ASM=No ARCH=mips PREFIX=' + distPath + ' install-headers install-shared', | ||
}, | ||
zlib: { | ||
repo: 'https://github.com/madler/zlib.git', | ||
-- | ||
2.20.1 | ||
|
43 changes: 43 additions & 0 deletions
43
tools/depends/wasm/codecbox.js/0002-Fix-errors-building-with-latest-llvm.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
From e7df34d0fcb6f2f3ebd924fd5afa372181a4e4c1 Mon Sep 17 00:00:00 2001 | ||
From: juztamau5 <[email protected]> | ||
Date: Sun, 12 Jul 2020 20:16:28 -0700 | ||
Subject: [PATCH 2/2] Fix errors building with latest llvm | ||
|
||
Errors were: | ||
|
||
[lame] | ||
|
||
>> error: undefined symbol: popen (referenced by top-level compiled C/C++ code) | ||
|
||
[openh264] | ||
|
||
>> error: undefined symbol: pthread_attr_setscope (referenced by top-level compiled C/C++ code) | ||
--- | ||
Gruntfile.js | 4 ++-- | ||
1 file changed, 2 insertions(+), 2 deletions(-) | ||
|
||
diff --git a/Gruntfile.js b/Gruntfile.js | ||
index 123f403..35de85c 100644 | ||
--- a/Gruntfile.js | ||
+++ b/Gruntfile.js | ||
@@ -231,7 +231,7 @@ module.exports = function (grunt) { | ||
}, | ||
lame: { | ||
repo: 'https://github.com/rbrito/lame.git', | ||
- configure: 'emconfigure ./configure CFLAGS=-O3 --prefix=' + distPath + ' --enable-shared=no --disable-gtktest ' + | ||
+ configure: 'emconfigure ./configure CFLAGS="-O3 -s ERROR_ON_UNDEFINED_SYMBOLS=0" --prefix=' + distPath + ' --enable-shared=no --disable-gtktest ' + | ||
' --disable-decoder --disable-cpml', | ||
}, | ||
libvpx: { | ||
@@ -251,7 +251,7 @@ module.exports = function (grunt) { | ||
}, | ||
openh264: { | ||
repo: 'https://github.com/cisco/openh264.git', | ||
- make: 'emmake make USE_ASM=No SHELL="/bin/bash -x" ARCH=mips CFLAGS="-O3 -fno-stack-protector" -j' + 1, //paraMake, | ||
+ make: 'emmake make USE_ASM=No SHELL="/bin/bash -x" ARCH=mips CFLAGS="-O3 -fno-stack-protector -s ERROR_ON_UNDEFINED_SYMBOLS=0" LDFLAGS="-s ERROR_ON_UNDEFINED_SYMBOLS=0" -j' + 1, //paraMake, | ||
install: 'emmake make USE_ASM=No ARCH=mips PREFIX=' + distPath + ' install-headers install-shared', | ||
}, | ||
zlib: { | ||
-- | ||
2.20.1 | ||
|
24 changes: 24 additions & 0 deletions
24
tools/depends/wasm/codecbox.js/0003-Enable-select-filter.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
From 2b2406260b117af9dc08b66de42f1990c48cd842 Mon Sep 17 00:00:00 2001 | ||
From: juztamau5 <[email protected]> | ||
Date: Sun, 26 Jul 2020 13:26:54 -0700 | ||
Subject: [PATCH 3/3] Enable select filter | ||
|
||
--- | ||
Gruntfile.js | 1 + | ||
1 file changed, 1 insertion(+) | ||
|
||
diff --git a/Gruntfile.js b/Gruntfile.js | ||
index 35de85c..e1f615d 100644 | ||
--- a/Gruntfile.js | ||
+++ b/Gruntfile.js | ||
@@ -176,6 +176,7 @@ module.exports = function (grunt) { | ||
'pad', | ||
'rotate', | ||
'scale', | ||
+ 'select', | ||
'setdar', | ||
'setsar', | ||
'showinfo', | ||
-- | ||
2.17.1 | ||
|
46 changes: 46 additions & 0 deletions
46
tools/depends/wasm/codecbox.js/0004-Don-t-call-bash-with-x.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
From e74a69bac5b0861ac22ce0b105a8457d66729a3b Mon Sep 17 00:00:00 2001 | ||
From: juztamau5 <[email protected]> | ||
Date: Fri, 31 Jul 2020 20:43:59 -0700 | ||
Subject: [PATCH 4/4] Don't call bash with -x | ||
|
||
--- | ||
Gruntfile.js | 8 ++++---- | ||
1 file changed, 4 insertions(+), 4 deletions(-) | ||
|
||
diff --git a/Gruntfile.js b/Gruntfile.js | ||
index e1f615d..1357ebe 100644 | ||
--- a/Gruntfile.js | ||
+++ b/Gruntfile.js | ||
@@ -240,7 +240,7 @@ module.exports = function (grunt) { | ||
needPatch: false, | ||
configure: 'emconfigure ./configure --prefix=' + distPath + ' --disable-examples --disable-docs ' + | ||
' --disable-runtime-cpu-detect --disable-multithread --target=generic-gnu --extra-cflags=-O3', | ||
- make: 'emmake make SHELL="/bin/bash -x" -j' + paraMake, | ||
+ make: 'emmake make SHELL="/bin/bash" -j' + paraMake, | ||
postMake: 'emranlib libvpx.a', // https://github.com/emscripten-core/emscripten/issues/9705 | ||
}, | ||
x264: { | ||
@@ -248,17 +248,17 @@ module.exports = function (grunt) { | ||
needPatch: false, | ||
configure: 'emconfigure ./configure --disable-thread --disable-asm --disable-opencl ' + | ||
' --host=i686-pc-linux-gnu --disable-cli --enable-shared --disable-gpl --prefix=' + distPath, | ||
- make: 'emmake make SHELL="/bin/bash -x" -j' + paraMake | ||
+ make: 'emmake make SHELL="/bin/bash" -j' + paraMake | ||
}, | ||
openh264: { | ||
repo: 'https://github.com/cisco/openh264.git', | ||
- make: 'emmake make USE_ASM=No SHELL="/bin/bash -x" ARCH=mips CFLAGS="-O3 -fno-stack-protector -s ERROR_ON_UNDEFINED_SYMBOLS=0" LDFLAGS="-s ERROR_ON_UNDEFINED_SYMBOLS=0" -j' + 1, //paraMake, | ||
+ make: 'emmake make USE_ASM=No SHELL="/bin/bash" ARCH=mips CFLAGS="-O3 -fno-stack-protector -s ERROR_ON_UNDEFINED_SYMBOLS=0" LDFLAGS="-s ERROR_ON_UNDEFINED_SYMBOLS=0" -j' + 1, //paraMake, | ||
install: 'emmake make USE_ASM=No ARCH=mips PREFIX=' + distPath + ' install-headers install-shared', | ||
}, | ||
zlib: { | ||
repo: 'https://github.com/madler/zlib.git', | ||
configure: 'emconfigure ./configure --prefix=' + distPath + ' --static', | ||
- make: 'emmake make CFLAGS="-O3" SHELL="/bin/bash -x" -j' + paraMake, | ||
+ make: 'emmake make CFLAGS="-O3" SHELL="/bin/bash" -j' + paraMake, | ||
}, | ||
ffmpeg: { | ||
repo: 'https://github.com/FFmpeg/FFmpeg.git', | ||
-- | ||
2.17.1 | ||
|
29 changes: 29 additions & 0 deletions
29
tools/depends/wasm/codecbox.js/0005-Don-t-download-FFmpeg.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
From 031f2a2b50a187a68b130bf6da1f8d0d39de445e Mon Sep 17 00:00:00 2001 | ||
From: juztamau5 <[email protected]> | ||
Date: Sat, 1 Aug 2020 12:33:14 -0700 | ||
Subject: [PATCH 5/5] Don't download FFmpeg | ||
|
||
--- | ||
Gruntfile.js | 6 ------ | ||
1 file changed, 6 deletions(-) | ||
|
||
diff --git a/Gruntfile.js b/Gruntfile.js | ||
index 1357ebe..e60efa9 100644 | ||
--- a/Gruntfile.js | ||
+++ b/Gruntfile.js | ||
@@ -260,12 +260,6 @@ module.exports = function (grunt) { | ||
configure: 'emconfigure ./configure --prefix=' + distPath + ' --static', | ||
make: 'emmake make CFLAGS="-O3" SHELL="/bin/bash" -j' + paraMake, | ||
}, | ||
- ffmpeg: { | ||
- repo: 'https://github.com/FFmpeg/FFmpeg.git', | ||
- // select your ffmpeg config | ||
- configure: ffmpegCustomConfig, | ||
- //configure: ffmpegFullConfig, | ||
- }, | ||
}; | ||
|
||
var cloneDepth = 50; | ||
-- | ||
2.17.1 | ||
|
Oops, something went wrong.