Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 10 additions & 5 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
name: Build LLVM XCFrameworks for Release
on: [push]
on:
push:
workflow_dispatch:

jobs:
prepare-build-tools:
runs-on: macos-latest
Expand All @@ -22,16 +25,18 @@ jobs:
timeout-minutes: 1200
steps:
- uses: actions/checkout@v3
with:
submodules: true
- run: |
make all
- name: create CoreCompiler framework archive
run: tar -cJf CoreCompiler.framework.tar.xz CoreCompiler.framework
- name: create LLVM.xcframework archive
run: tar -cJf LLVM.xcframework.tar.xz LLVM.xcframework
- name: create CoreCompilerSupportLibs archive
run: tar -cJf CoreCompilerSupportLibs.tar.xz CoreCompilerSupportLibs
- uses: actions/upload-artifact@v4
with:
name: CoreCompiler.framework
path: CoreCompiler.framework.tar.xz
name: LLVM.xcframework
path: LLVM.xcframework.tar.xz
- uses: actions/upload-artifact@v4
with:
name: CoreCompilerSupportLibs
Expand Down
4 changes: 1 addition & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,8 @@ swift:
perl -i -0pe 's|(// Swift LLVM fork downstream change start\n)(.*?)(// Swift LLVM fork downstream change end\n)|$$1/* NYXIAN: apple lies, lld works fine for MachO\n$$2*/\n$$3|s' \
llvm-project/lld/MachO/InputFiles.cpp

build/LLVMClangSwift_iphoneos/llvm-macosx-x86_64:
mkdir -p build/LLVMClangSwift_iphoneos; cd build/LLVMClangSwift_iphoneos; ln -sfn llvm-macosx-arm64 llvm-macosx-x86_64

.SwiftToolchain-iphoneos: swift build/LLVMClangSwift_iphoneos/llvm-macosx-x86_64
.SwiftToolchain-iphoneos: swift
$(call log_info,building iOS-native swift toolchain ($(SWIFT_BRANCH)))
SWIFT_BRANCH="$(SWIFT_BRANCH)" SWIFT_SOURCE_DIR="$(SWIFT_SOURCE_DIR)" Scripts/build-swift-toolchain.sh build
touch .SwiftToolchain-iphoneos
Expand Down
3 changes: 1 addition & 2 deletions Scripts/build-swift-toolchain.sh
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,7 @@ copy_ios_install() {
local build_dir="${SWIFT_BUILD_ROOT}/${SWIFT_BUILD_SUBDIR}"
local install_prefix="Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr"
local candidates=(
"${build_dir}/intermediate-install/iphoneos-arm64/${install_prefix}"
"${build_dir}/toolchain-macosx-arm64/${install_prefix}"
"${build_dir}/intermediate-install/iphoneos-arm64/${install_prefix}"
)
local swift_build="${build_dir}/swift-iphoneos-arm64"
local llvm_build="${build_dir}/llvm-iphoneos-arm64"
Expand Down