`executeCommand` function does not return expected value
jpmartha opened this issue · 2 comments
jpmartha commented
A Work In Progress 👷🏻
Return value is not correct when executing $ xcodebuild -showBuildSettings.
jpmartha commented
In the current implementation, tryswiftdev is different from Terminal.app in operating environment.
Apple Swift version 3.0-dev (LLVM 752e1430fc, Clang 1e6cba3ce3, Swift 56052cfe61)
Target: x86_64-apple-macosx10.9
< Executing `xcodebuild -showBuildSettings` with `posix_spawnp` function in tryswiftdev
---
> Typing `xcodebuild -showBuildSettings` in Terminal.app39c39
< COLOR_DIAGNOSTICS = NO
---
> COLOR_DIAGNOSTICS = YES
86c86
< ENABLE_BITCODE = NO
---
> ENABLE_BITCODE = 0
151c151
< LD_RUNPATH_SEARCH_PATHS = /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx
---
> LD_RUNPATH_SEARCH_PATHS = /Library/Developer/Toolchains/swift-DEVELOPMENT-SNAPSHOT-2016-04-25-a.xctoolchain/usr/lib/swift/macosx
187c187
< PATH = /Applications/Xcode.app/Contents/Developer/usr/bin
---
> PATH = /Applications/Xcode.app/Contents/Developer/usr/bin:/Library/Developer/Toolchains/swift-latest.xctoolchain/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
253a254
> SWIFT_DISABLE_REQUIRED_ARCLITE = 1
255a257
> SWIFT_LINK_OBJC_RUNTIME = 1
289c291,292
< TOOLCHAIN_DIR = /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain
---
> TOOLCHAINS = org.swift.3020160425a
> TOOLCHAIN_DIR = /Library/Developer/Toolchains/swift-DEVELOPMENT-SNAPSHOT-2016-04-25-a.xctoolchain
306a310
> XCODE_DEFAULT_TOOLCHAIN_OVERRIDE = /Library/Developer/Toolchains/swift-DEVELOPMENT-SNAPSHOT-2016-04-25-a.xctoolchain
313a318
> diagnostic_message_length = 80jpmartha commented
Executing xcodebuild -showBuildSettings with <buildsetting>=<value>, ...
xcodebuild -showBuildSettings <buildsetting>=<value>, ...
Concretly;
"ENABLE_BITCODE=0",
"SWIFT_DISABLE_REQUIRED_ARCLITE=1",
"SWIFT_LINK_OBJC_RUNTIME=1",
"TOOLCHAINS=org.swift.3020160425a",
"XCODE_DEFAULT_TOOLCHAIN_OVERRIDE=/Library/Developer/Toolchains/swift-DEVELOPMENT-SNAPSHOT-2016-04-25-a.xctoolchain",
For now, I have hard-coding Toolchains' version.