-
Notifications
You must be signed in to change notification settings - Fork 0
/
.appveyor.yml
162 lines (122 loc) · 4.53 KB
/
.appveyor.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
skip_branch_with_pr: true
environment:
python_stack: python 3.12
PYTHON_VERSION: 3.12.6
PYTHON_VERSION_SHORT: 3.12
GITHUB_TOKEN:
secure: 9SKIwc3VSfYJ5IChvNR74rlTF9BMbAfhCGu1/TmYJBMtC6lkY+UDDkZNK7rC9xnQFUxMrNgoo9kNcNAbKbU8XAcrSwkP2H4mX04FI7P+YbxfiWC8nVHhGNxR4LzO+GO0
matrix:
- job_name: Build Python for iOS and macOS
APPVEYOR_BUILD_WORKER_IMAGE: macos-sonoma
- job_name: Build Python for Android
APPVEYOR_BUILD_WORKER_IMAGE: ubuntu-gce-c
NDK_VERSION: r27
- job_name: Build Python for Linux
APPVEYOR_BUILD_WORKER_IMAGE: ubuntu-gce-c
PYTHON_DIST_RELEASE: 20240909
- job_name: Build Python for Windows
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2022
matrix:
fast_finish: true
stack: $python_stack
install:
- python --version
for:
# ======================================
# Build Python for iOS and macOS
# ======================================
- matrix:
only:
- job_name: Build Python for iOS and macOS
build_script:
- cd darwin
# Build Python for iOS and macOS
- git clone --branch=$PYTHON_VERSION_SHORT https://github.com/beeware/Python-Apple-support.git
- mkdir -p dist
- sh: |
pushd Python-Apple-support
make iOS || exit 1
tar -czf ../dist/python-ios-mobile-forge-$PYTHON_VERSION_SHORT.tar.gz install support -C .
make macOS || exit 1
popd
# Package for Dart
- ./package-ios-for-dart.sh Python-Apple-support $PYTHON_VERSION_SHORT
- ./package-macos-for-dart.sh Python-Apple-support $PYTHON_VERSION_SHORT
# Push all archives to artifacts
- find dist -maxdepth 1 -type f -iname python-*.tar.gz -exec appveyor PushArtifact -DeploymentName python-darwin {} \;
test: off
deploy:
provider: GitHub
auth_token: $(GITHUB_TOKEN)
release: v$(PYTHON_VERSION_SHORT)
artifact: python-darwin
# ======================================
# Build Python for Android
# ======================================
- matrix:
only:
- job_name: Build Python for Android
build_script:
- cd android
# Build all Python ABIs
- ./build-all.sh $PYTHON_VERSION
# Package support package for use with mobile-forge
- mkdir -p dist
- tar -czf dist/python-android-mobile-forge-$PYTHON_VERSION_SHORT.tar.gz install support
# Package individual ABIs for use with serious_python Flutter package
- ./package-for-dart.sh install $PYTHON_VERSION arm64-v8a
- ./package-for-dart.sh install $PYTHON_VERSION armeabi-v7a
- ./package-for-dart.sh install $PYTHON_VERSION x86_64
# Push all archives to artifacts
- find dist -maxdepth 1 -type f -iname python-android-*.tar.gz -exec appveyor PushArtifact -DeploymentName python-android {} \;
test: off
deploy:
provider: GitHub
auth_token: $(GITHUB_TOKEN)
release: v$(PYTHON_VERSION_SHORT)
artifact: python-android
# ======================================
# Build Python for Linux
# ======================================
- matrix:
only:
- job_name: Build Python for Linux
build_script:
- cd linux
- ./package-for-linux.sh x86_64 "_v3"
- ./package-for-linux.sh aarch64 ""
# Push all archives to artifacts
- ls
- find . -maxdepth 1 -type f -iname "python-linux-dart-*.tar.gz" -exec appveyor PushArtifact -DeploymentName python-linux {} \;
test: off
deploy:
provider: GitHub
auth_token: $(GITHUB_TOKEN)
release: v$(PYTHON_VERSION_SHORT)
artifact: python-linux
# ======================================
# Build Python for Windows
# ======================================
- matrix:
only:
- job_name: Build Python for Windows
install:
- C:\Python312\python --version
build_script:
- cd windows
- curl -OL https://www.python.org/ftp/python/3.12.5/python-3.12.5-amd64.exe
- start /wait python-3.12.5-amd64.exe /uninstall /quiet
- curl -OL https://www.python.org/ftp/python/%PYTHON_VERSION%/python-%PYTHON_VERSION%-amd64.exe
- start /wait python-%PYTHON_VERSION%-amd64.exe /quiet
- dir C:\python312-dist
- C:\python312-dist\python -m compileall -b C:\python312-dist\Lib
- 7z a [email protected] python-windows-for-dart-%PYTHON_VERSION_SHORT%.zip C:\python312-dist\*
test: off
artifacts:
- path: windows\python-windows-for-dart-*.zip
name: python-windows
deploy:
provider: GitHub
auth_token: $(GITHUB_TOKEN)
release: v$(PYTHON_VERSION_SHORT)
artifact: python-windows