Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Which XCode are you building against? #4

Closed
BenjaminHCCarr opened this issue Sep 25, 2016 · 6 comments
Closed

Which XCode are you building against? #4

BenjaminHCCarr opened this issue Sep 25, 2016 · 6 comments

Comments

@BenjaminHCCarr
Copy link
Contributor

Here is my gist-log: https://gist.github.com/BenjaminHCCarr/5bc4e50342e14a8ea727a4685c35c0fc

I'm on XCode Command Line Tools: 7.3.1.0.1.1461711523

Based on this response I see on swift-build-devel: https://lists.swift.org/pipermail/swift-build-dev/Week-of-Mon-20160321/000362.html

swift-build is not part of Xcode 7.3

swift-build is swift 3.0, and the apple stable and homebrew are both 2.2. XCode 8.0 BETA is Swift 3.0.

tyr:~/Code benc$ brew info swift
swift: stable 2.2.1 (bottled), HEAD [keg-only]

I tried --head:

benc$ brew install --HEAD swift

Warning: swift-2.2.1 already installed

I am guessing you're on Sierra at this point or at least the XCode BETA? Thoughts?

@BenjaminHCCarr
Copy link
Contributor Author

Oh, I should mention, this is the fork/update to the formula, that I haven't PR'ed yet, and will when we figure this out.

https://github.com/BenjaminHCCarr/homebrew-tap/blob/aa8d59476c2d723e4b171d8dfeeb6e55a9d78687/menubar-toggle.rb

@SpencerMichaels
Copy link
Owner

Not so! I'm on El Capitan; XCode 8.0 is the stable release as of last week

  • update via the app store and it should work.

2016年9月26日 03:59,"Ben" notifications@github.com寫道:

Here is my gist-log: https://gist.github.com/BenjaminHCCarr/
5bc4e50342e14a8ea727a4685c35c0fc

I'm on XCode Command Line Tools: 7.3.1.0.1.1461711523

Based on this response I see on swift-build-devel:
https://lists.swift.org/pipermail/swift-build-dev/
Week-of-Mon-20160321/000362.html

swift-build is not part of Xcode 7.3

swift-build is swift 3.0, and the apple stable and homebrew are both 2.2. XCode
8.0 BETA is Swift 3.0.

tyr:~/Code benc$ brew info swift
swift: stable 2.2.1 (bottled), HEAD [keg-only]

I tried --head:

benc$ brew install --HEAD swift

Warning: swift-2.2.1 already installed

I am guessing you're on Sierra at this point or at least the XCode BETA?
Thoughts?


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
#4, or mute the thread
https://github.com/notifications/unsubscribe-auth/ANScbyHl0VXW_U4_i-2dU5RW6P2S6E_uks5qttK2gaJpZM4KF_RP
.

@BenjaminHCCarr
Copy link
Contributor Author

It appears, XCode 8.0 Command Line was released broken by Apple and isn't currently available, so I guess I sit for a while.

I can't test, but I'll submit the pull request for the formula.

I think you can require a version of xcode (eg. 8.0) but I've never needed that.

@SpencerMichaels
Copy link
Owner

Now that you mention it, I'm on the same CLT version (CLT: 7.3.1.0.1.1461711523) but don't have the Brew version of Swift. This seems to give me v3.0.

> which swift
/usr/bin/swift

> swift --version
Apple Swift version 3.0 (swiftlang-800.0.46.2 clang-800.0.38)
Target: x86_64-apple-macosx10.9

It looks like your build process is trying to use brewed Swift and thus failing. What if you totally uninstall that and try with the built-in Swift binary? Does /usr/bin/swift --version yield 3.0 for you? (And do you have XCode 8 itself installed, even though CLT is at 7.3?)

EDIT: There is no CLT 8.0, strangely. See this issue.

@BenjaminHCCarr
Copy link
Contributor Author

I do not have XCode.app, with a 250GB SSD, I needed the space, sadly for other things, and yes I also have a uSD card in the SD slot, there is where media any media is, sadly I needed a machine ASAP, and the only one I could get in the timeframe with 16GB of ram was the 250GB model, and nothing is upgradeable. As I generally never used and actively disliked the GUI, I happily moved to CLT alone.

My process is building brewed swift and apple hasn't released swift 3.0 on Github, so the only way to get it at the moment is XCode.app.

From CLT:

tyr:~/Code benc$ /usr/bin/swift --version
Apple Swift version 2.2 (swiftlang-703.0.18.8 clang-703.0.31)
Target: x86_64-apple-macosx10.9
tyr:~/Code benc$ ls -l /usr/bin/swift
-rwxr-xr-x  1 root  wheel  18176 Jul  8 23:03 /usr/bin/swift
tyr:~/Code benc$ /Library/Developer/CommandLineTools/usr/bin/swift --version
Apple Swift version 2.2 (swiftlang-703.0.18.8 clang-703.0.31)
Target: x86_64-apple-macosx10.9
tyr:~/Code benc$ ls -l /Library/Developer/CommandLineTools/usr/bin/swift
-rwxr-xr-x  1 root  admin  54580608 Apr 26 20:02 /Library/Developer/CommandLineTools/usr/bin/swift

Brewed:

tyr:~/Code benc$ /usr/local/Cellar/swift/2.2.1/bin/swift --version
Swift version 2.2.1 (swift-2.2.1-RELEASE)
Target: x86_64-apple-macosx10.11
tyr:~/Code benc$ ls -l /usr/local/Cellar/swift/2.2.1/bin/
total 508000
-r-xr-xr-x  1 benc  admin  50800348 May  3 15:56 sil-extract
-r-xr-xr-x  1 benc  admin  51357604 May  3 15:56 sil-opt
-r-xr-xr-x  1 benc  admin  55332784 May  3 15:56 swift
lrwxr-xr-x  1 benc  admin         5 May  3 15:56 swift-autolink-extract -> swift
-r-xr-xr-x  1 benc  admin    679236 May  3 15:56 swift-compress
-r-xr-xr-x  1 benc  admin    616708 May  3 15:56 swift-demangle
-r-xr-xr-x  1 benc  admin  49681880 May  3 15:56 swift-ide-test
-r-xr-xr-x  1 benc  admin  51608012 May  3 15:56 swift-llvm-opt
lrwxr-xr-x  1 benc  admin         5 May  3 15:56 swiftc -> swift

I saw that bug, sounds like Apple is bungling the roll out of CLT-8, hope it comes soon.

@SpencerMichaels
Copy link
Owner

SpencerMichaels commented Sep 27, 2016

Ah, I see. It seems you might still be able to avoid installing Xcode.app and still get Swift 3, though — have you tried swiftenv? It looks like it can manually fetch Swift binary snapshots from Apple and install them (3.0 included), which may solve your problem.

Regardless, it looks like the build issue has little to do with my formula/program specifically and can't be fixed without Apple/Homebrew doing something, so I will close this issue for now. In case swiftenv doesn't work for you, what I have done is to add an El Capitan binary to the latest release (2.0.1) which you can install manually and use while waiting for an upstream fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants