Skip to content

Xcode: Relax swift compiler detection regex for Xcode 11

Gregor Jasny requested to merge gjasny/cmake:xcode11-swift into master

The Xcode 11 output:

  CompileSwift normal x86_64
  /Users/gregorj/Git/cmake/_build_xcode/Tests/SwiftOnly/CMakeFiles/3.15.20190826-g89479bd/CompilerIdSwift/CompilerId/main.swift
  (in target 'CompilerIdSwift' from project 'CompilerIdSwift')

      cd /Users/gregorj/Git/cmake/_build_xcode/Tests/SwiftOnly/CMakeFiles/3.15.20190826-g89479bd/CompilerIdSwift
      /Applications/Xcode-beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swift -frontend -c -primary-file /Users/gregorj/Git/cmake/_build_xcode/Tests/SwiftOnly/CMakeFiles/3.15.20190826-g89479bd/CompilerIdSwift/CompilerId/main.swift ...

The Xcode 10 output:

CompileSwiftSources normal x86_64 com.apple.xcode.tools.swift.compiler
    cd /Users/gjasny/src/cmake/Tests/SwiftOnly
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swiftc -incremental -module-name SwiftOnly -O -enable-batch-mode -enforce-exclusivity=checked -swift-version 5.0 -sdk /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk -target x86_64-apple-macosx10.14 -g -Xfrontend -serialize-debugging-options -swift-version 5 -Xlinker -rpath -Xlinker /usr/lib/swift -I /Users/gjasny/src/cmake/_build_xcode/Tests/SwiftOnly/Debug -F /Users/gjasny/src/cmake/_build_xcode/Tests/SwiftOnly/Debug -c -j24 /Users/gjasny/src/cmake/Tests/SwiftOnly/main.swift ...

CompileSwift normal x86_64 /Users/gjasny/src/cmake/Tests/SwiftOnly/main.swift
    cd /Users/gjasny/src/cmake/Tests/SwiftOnly
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swift -frontend -c -primary-file /Users/gjasny/src/cmake/Tests/SwiftOnly/main.swift ...

The Xcode 11 output lacks the CompileSwiftSources action but the CompileSwift action is present for both and also look suitable.

Merge request reports