16
16
default : main
17
17
18
18
jobs :
19
+ archive :
20
+ runs-on : ubuntu-latest
21
+
22
+ container :
23
+ image : docker.io/library/debian
24
+
25
+ strategy :
26
+ fail-fast : false
27
+ matrix :
28
+ include :
29
+ - host-arch : x64
30
+
31
+ steps :
32
+ - name : Install build tools
33
+ run : |
34
+ apt-get update
35
+ apt-get install --no-install-recommends -y ca-certificates curl git python3
36
+
37
+ - name : Fetch Dart SDK
38
+ run : |
39
+ git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
40
+ export DEPOT_TOOLS_UPDATE=0 PATH=$PWD/depot_tools:$PATH
41
+
42
+ mkdir dart-sdk
43
+ cd dart-sdk
44
+ gclient config --name sdk https://dart.googlesource.com/sdk.git@${{ inputs.ref }}
45
+ gclient sync --no-history
46
+
47
+ - name : Archive
48
+ run : |
49
+ tar -czf dart-${{ inputs.ref }}-${{ matrix.host-arch }}.tar.gz dart-sdk
50
+
51
+ - name : Upload Artifact
52
+ uses : actions/upload-artifact@v4
53
+ with :
54
+ name : dart-${{ inputs.ref }}-${{ matrix.host-arch }}
55
+ path : dart-${{ inputs.ref }}-${{ matrix.host-arch }}.tar.gz
56
+ if-no-files-found : error
57
+ compression-level : 0
58
+
19
59
build :
60
+ needs : [archive]
61
+
20
62
runs-on : ubuntu-latest
21
63
22
64
container :
@@ -38,10 +80,19 @@ jobs:
38
80
target-arch : riscv64
39
81
40
82
steps :
83
+ - name : Download Artifact
84
+ uses : actions/download-artifact@v4
85
+ with :
86
+ name : dart-${{ inputs.ref }}-${{ matrix.host-arch }}
87
+
88
+ - name : Unarchive
89
+ run : |
90
+ tar -xzf dart-${{ inputs.ref }}-${{ matrix.host-arch }}.tar.gz
91
+
41
92
- name : Install build tools
42
93
run : |
43
94
apt-get update
44
- apt-get install --no-install-recommends -y ca-certificates curl git python3 xz-utils
95
+ apt-get install --no-install-recommends -y ca-certificates curl git python3
45
96
46
97
- name : Setup multiarch
47
98
run : |
@@ -58,18 +109,6 @@ jobs:
58
109
;;
59
110
esac
60
111
61
- - name : Fetch Dart SDK
62
- id : fetch
63
- run : |
64
- git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
65
- export DEPOT_TOOLS_UPDATE=0 PATH=$PWD/depot_tools:$PATH
66
-
67
- mkdir dart-sdk
68
- cd dart-sdk
69
- gclient config --name sdk https://dart.googlesource.com/sdk.git@${{ inputs.ref }}
70
- echo "target_os = ['android']" | tee -a .gclient
71
- gclient sync --no-history
72
-
73
112
- name : Build
74
113
run : |
75
114
cd dart-sdk/sdk
0 commit comments