@@ -114,10 +114,6 @@ jobs:
114114 STUPID_FILE_RENAMING=Tool 
115115 else 
116116 sed -i "s%r26%ndk/26%" swift/stdlib/cmake/modules/AddSwiftStdlib.cmake 
117-  if [ ${{ matrix.version }} = 'devel' ]; then 
118-  sed -i "s%canImport(Android%os(Android%" sourcekit-lsp/Sources/SKSupport/Process+Run.swift 
119-  git apply -C1 readlink-devel.patch 
120-  fi 
121117 STUPID_FILE_RENAMING=Command 
122118 fi 
123119 if [ ${{ matrix.version }} = 'release-25c' ]; then 
@@ -131,8 +127,13 @@ jobs:
131127 git apply -C0 swift-android-foundation-ndk26.patch 
132128 if [ ${{ matrix.version }} = 'release-26d' ]; then 
133129 git apply swift-android-stdlib-ndk26.patch 
134-  elif [ ${{ matrix.version }} = 'trunk' ]; then  
130+  else  
135131 git apply android-overlay/foundation-fixes.patch android-overlay/import-android.patch android-overlay/swift-argument-parser.patch android-overlay/swift-system-tag.patch android-overlay/yams.patch 
132+  if [ ${{ matrix.version }} = 'devel' ]; then 
133+  git apply android-overlay/sourcekit-lsp-swiftpm-devel.patch 
134+  else 
135+  git apply android-overlay/sourcekit-lsp-trunk.patch 
136+  fi 
136137 fi 
137138 fi 
138139 sed -i "s%/data/data/com.termux/files%$SDK%" $SDK/usr/lib/pkgconfig/sqlite3.pc 
@@ -159,6 +160,11 @@ jobs:
159160 if [ ! -d ${{ steps.version.outputs.tag }}-ubuntu22.04 ]; then 
160161 tar xf ~/${{ steps.version.outputs.tag }}-ubuntu22.04.tar.gz 
161162 fi 
163+  if [ ${{ matrix.version }} = 'devel' ]; then 
164+  sed -i "s%canImport(Glibc%canImport(Android%" ${{ steps.version.outputs.tag }}-ubuntu22.04/usr/bin/swift-package 
165+  sed -i "s%import Glibc%import Android%" ${{ steps.version.outputs.tag }}-ubuntu22.04/usr/bin/swift-package 
166+  sed -i "s%TSCBasic, would be nice%TSCBasic, would be %" ${{ steps.version.outputs.tag }}-ubuntu22.04/usr/bin/swift-package 
167+  fi 
162168 ./${{ steps.version.outputs.tag }}-ubuntu22.04/usr/bin/swift --version 
163169
164170 tar xf ~/swift-${{ matrix.version }}-android-${{ matrix.arch }}*-sdk.tar.xz 
@@ -169,7 +175,7 @@ jobs:
169175 path : swift-argument-parser 
170176 - name : Build Swift Argument Parser package 
171177 run : | 
172-  if [ ${{ matrix.version }} = 'trunk'  ]; then 
178+  if [[  ${{ matrix.version }} ! = 'release'* ] ]; then 
173179 git apply sdk-config/android-overlay/swift-argument-parser.patch 
174180 fi 
175181 cd swift-argument-parser 
@@ -199,7 +205,7 @@ jobs:
199205 git apply ../sdk-config/swift-nio-disable-ecn-tests.patch ../sdk-config/swift-nio-filesystem-both-ndks.patch 
200206 if [ ${{ matrix.version }} = 'release-25c' ]; then 
201207 git apply -R ../sdk-config/swift-nio-ndk26.patch 
202-  elif [ ${{ matrix.version }} = 'trunk'  ]; then 
208+  elif [[  ${{ matrix.version }} ! = 'release-26d' ] ]; then 
203209 ../sdk-config/${{ steps.version.outputs.tag }}-ubuntu22.04/usr/bin/swift package update 
204210 cd .build/checkouts/swift-system/ 
205211 git apply ../../../../sdk-config/android-overlay/swift-system-checkout.patch 
@@ -224,7 +230,7 @@ jobs:
224230 - name : Build Swift System package 
225231 run : | 
226232 cd swift-system 
227-  if [ ${{ matrix.version }} = 'trunk'  ]; then 
233+  if [[  ${{ matrix.version }} ! = 'release'* ] ]; then 
228234 git apply ../sdk-config/android-overlay/swift-system.patch 
229235 fi 
230236 ../sdk-config/${{ steps.version.outputs.tag }}-ubuntu22.04/usr/bin/swift build --build-tests --destination ../sdk-config/swift-*-sdk/usr/swiftpm-android-${{ matrix.arch }}.json -Xlinker -rpath -Xlinker \$ORIGIN/lib/swift/android 
@@ -251,7 +257,7 @@ jobs:
251257 - name : Build Swift NIO SSH package 
252258 run : | 
253259 cd sns 
254-  if [ ${{ matrix.version }} = 'trunk'  ]; then 
260+  if [[  ${{ matrix.version }} ! = 'release'* ] ]; then 
255261 git apply ../sdk-config/android-overlay/swift-nio-ssh.patch 
256262 fi 
257263 sed -i "s%url: .*swift-\(\w\+\)\.git.*$%path: \"../swift-\1\"),%g" Package.swift 
@@ -266,7 +272,7 @@ jobs:
266272 cd snl 
267273 if [ ${{ matrix.version }} = 'release-25c' ]; then 
268274 sed -i "s%#include <time%#include <signal.h>\n#include <time%" Sources/CNIOBoringSSL/include/CNIOBoringSSL_asn1.h 
269-  elif [ ${{ matrix.version }} = 'trunk ' ]; then 
275+  elif [ ${{ matrix.version }} ! = 'release-26d ' ]; then 
270276 git apply ../sdk-config/android-overlay/swift-nio-ssl.patch 
271277 fi 
272278 SWIFTCI_USE_LOCAL_DEPS=1 ../sdk-config/${{ steps.version.outputs.tag }}-ubuntu22.04/usr/bin/swift build --build-tests --destination ../sdk-config/swift-*-sdk/usr/swiftpm-android-${{ matrix.arch }}.json -Xlinker -rpath -Xlinker \$ORIGIN/lib/swift/android 
@@ -277,7 +283,7 @@ jobs:
277283 path : yams 
278284 - name : Build Yams package 
279285 run : | 
280-  if [ ${{ matrix.version }} = 'trunk'  ]; then 
286+  if [[  ${{ matrix.version }} ! = 'release'* ] ]; then 
281287 git apply sdk-config/android-overlay/yams.patch 
282288 fi 
283289 cd yams 
@@ -292,7 +298,7 @@ jobs:
292298 if : ${{ matrix.arch != 'armv7' }} 
293299 run : | 
294300 cd snh 
295-  if [ ${{ matrix.version }} = 'trunk'  ]; then 
301+  if [[  ${{ matrix.version }} ! = 'release'* ] ]; then 
296302 git apply ../sdk-config/android-overlay/swift-nio-http2.patch 
297303 fi 
298304 sed -i "s%url: .*swift-\(\w\+\)\.git.*$%path: \"../swift-\1\"),%g" Package.swift 
0 commit comments