<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">Ah! No, launch-with-toolchain's all that's supported. But it's an interesting direction to go. It'd be an Xcode feature more than a Swift feature, though, so <a href="http://bugs.swift.org" class="">bugs.swift.org</a> isn't an appropriate place for the request.</div><div class=""><br class=""></div><div class="">Glad everything's working manually now.</div><div class=""><br class=""></div><div class="">Jordan</div><br class=""><div><blockquote type="cite" class=""><div class="">On Dec 10, 2015, at 22:09 , Jens Persson <<a href="mailto:jens@bitcycle.com" class="">jens@bitcycle.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">Just to clarify (not sure if it's needed): Note that I can run Xcode with my custom toolchain, eg:<div class="">xcrun launch-with-toolchain ./swift-SNAPSHOT-2015-12-11-a.xctoolchain<br class=""></div><div class=""><br class=""></div><div class="">What I want to know is the part about switching between the command line tools, not only between my Xcode and Xcode-beta (which I can do using xcode-select) but also between those and my custom built Swift.</div><div class=""><br class=""></div><div class="">/Jens</div><div class=""><br class=""></div></div><div class="gmail_extra"><br class=""><div class="gmail_quote">On Fri, Dec 11, 2015 at 6:47 AM, Dmitri Gribenko <span dir="ltr" class=""><<a href="mailto:gribozavr@gmail.com" target="_blank" class="">gribozavr@gmail.com</a>></span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Mish Awadah probably knows about setting up a custom toolchain in Xcode.<br class="">
<span class="HOEnZb"><font color="#888888" class=""><br class="">
Dmitri<br class="">
</font></span><div class="HOEnZb"><div class="h5"><br class="">
On Thu, Dec 10, 2015 at 9:44 PM, Jens Persson <<a href="mailto:jens@bitcycle.com" class="">jens@bitcycle.com</a>> wrote:<br class="">
> Thanks again,<br class="">
> I pulled the latest Swift repos which included the fix of the failing test<br class="">
> and modified the build preset locally according to Dmitri's advice and the<br class="">
> build completes without problems.<br class="">
><br class="">
> But now I wonder if there is a way to switch between the command line tools<br class="">
> of Xcode, Xcode-beta and the Swift I've just built from sources?<br class="">
><br class="">
> I mean, when I want to switch between the command line tools of Xcode and<br class="">
> Xcode-beta I can simply do:<br class="">
> sudo xcode-select -s /Applications/Xcode[-beta].app<br class="">
><br class="">
> Is there something similar that I can do in order to switch to the command<br class="">
> line tools from the one I built from sources?<br class="">
><br class="">
> These instructions: <a href="https://swift.org/download/" rel="noreferrer" target="_blank" class="">https://swift.org/download/</a><br class="">
> just says "add the Swift toolchain to your path" (using export) but I'm<br class="">
> hesitant to do that since I don't know whether that will work when I already<br class="">
> have Xcode and Xcode-beta installed (and thus /usr/bin/swiftc etc)?<br class="">
><br class="">
> /Jens<br class="">
><br class="">
><br class="">
> On Thu, Dec 10, 2015 at 6:11 PM, Dmitri Gribenko <<a href="mailto:gribozavr@gmail.com" class="">gribozavr@gmail.com</a>><br class="">
> wrote:<br class="">
>><br class="">
>> On Thu, Dec 10, 2015 at 7:41 AM, Jens Persson <<a href="mailto:jens@bitcycle.com" class="">jens@bitcycle.com</a>> wrote:<br class="">
>> > Thanks!<br class="">
>> > I tried the above to compile with the buildbot_osx_package preset. It<br class="">
>> > kind<br class="">
>> > of worked, but it failed while performing the tests.<br class="">
>> > (TEST 'Swift :: Driver/Dependencies/bindings-build-record.swift' FAILED)<br class="">
>> > So, I got a working swiftc etc but no package or toolchain or anything<br class="">
>> > (at<br class="">
>> > least as far as I could see).<br class="">
>> ><br class="">
>> > However, trying out the resulting swiftc shows that it is slow, ie the<br class="">
>> > buildbot_osx_package preset did not imply --no-assertions<br class="">
>> > --no-swift-stdlib-assertions.<br class="">
>><br class="">
>> Jens,<br class="">
>><br class="">
>> I think you found an issue in our presets. I filed<br class="">
>> <a href="https://bugs.swift.org/browse/SR-180" rel="noreferrer" target="_blank" class="">https://bugs.swift.org/browse/SR-180</a> Here, we have an incorrect<br class="">
>> workaround that causes this issue:<br class="">
>><br class="">
>> [preset: mixin_lightweight_assertions]<br class="">
>> assertions<br class="">
>><br class="">
>> # FIXME: This should be:<br class="">
>> # no-assertions<br class="">
>> # swift-assertions<br class="">
>> # ... but our tests are expecting assertions to be either on or off<br class="">
>> everywhere.<br class="">
>><br class="">
>> I think this hacky patch should get you unblocked (untested!):<br class="">
>><br class="">
>><br class="">
>> -------------------------------------------------------------------------------------<br class="">
>> diff --git a/utils/build-presets.ini b/utils/build-presets.ini<br class="">
>> index 6dc6d24..1ab441f 100644<br class="">
>> --- a/utils/build-presets.ini<br class="">
>> +++ b/utils/build-presets.ini<br class="">
>> @@ -462,12 +462,8 @@ swift-runtime-enable-leak-checker=1<br class="">
>> # A mixin that enables 'lightweight' assertions that don't slow down the<br class="">
>> # compiler significantly.<br class="">
>> [preset: mixin_lightweight_assertions]<br class="">
>> -assertions<br class="">
>> -<br class="">
>> -# FIXME: This should be:<br class="">
>> -# no-assertions<br class="">
>> -# swift-assertions<br class="">
>> -# ... but our tests are expecting assertions to be either on or off<br class="">
>> everywhere.<br class="">
>> +no-assertions<br class="">
>> +swift-assertions<br class="">
>><br class="">
>> dash-dash<br class="">
>><br class="">
>> @@ -592,8 +588,6 @@ build-subdir=buildbot_osx<br class="">
>> ios<br class="">
>> tvos<br class="">
>> watchos<br class="">
>> -test<br class="">
>> -validation-test<br class="">
>><br class="">
>> dash-dash<br class="">
>><br class="">
>> -------------------------------------------------------------------------------------<br class="">
>><br class="">
>> Dmitri<br class="">
>><br class="">
>> --<br class="">
>> main(i,j){for(i=2;;i++){for(j=2;j<i;j++){if(!(i%j)){j=0;break;}}if<br class="">
>> (j){printf("%d\n",i);}}} /*Dmitri Gribenko <<a href="mailto:gribozavr@gmail.com" class="">gribozavr@gmail.com</a>>*/<br class="">
><br class="">
><br class="">
><br class="">
><br class="">
> --<br class="">
> bitCycle AB | Smedjegatan 12 | 742 32 Östhammar | Sweden<br class="">
> <a href="http://www.bitcycle.com/" rel="noreferrer" target="_blank" class="">http://www.bitcycle.com/</a><br class="">
> Phone: +46-73-753 24 62<br class="">
> E-mail: <a href="mailto:jens@bitcycle.com" class="">jens@bitcycle.com</a><br class="">
><br class="">
<br class="">
<br class="">
<br class="">
--<br class="">
main(i,j){for(i=2;;i++){for(j=2;j<i;j++){if(!(i%j)){j=0;break;}}if<br class="">
(j){printf("%d\n",i);}}} /*Dmitri Gribenko <<a href="mailto:gribozavr@gmail.com" class="">gribozavr@gmail.com</a>>*/<br class="">
</div></div></blockquote></div><br class=""><br clear="all" class=""><div class=""><br class=""></div>-- <br class=""><div class="gmail_signature">bitCycle AB | Smedjegatan 12 | 742 32 Östhammar | Sweden<br class=""><a href="http://www.bitcycle.com/" target="_blank" class="">http://www.bitcycle.com/</a><br class="">Phone: +46-73-753 24 62<br class="">E-mail: <a href="mailto:jens@bitcycle.com" target="_blank" class="">jens@bitcycle.com</a><br class=""><br class=""></div>
</div>
</div></blockquote></div><br class=""></body></html>