[swift-users] Is there a simple direct way to compile with libdispatch on Ubuntu?

francisbailey francisbailey at protonmail.com
Wed Jan 27 23:57:18 CST 2016


Hi Isaac,

I recently came across this issue as well. You can use the command specified in this answer: http://stackoverflow.com/questions/34680816/swift-in-linux-use-of-unresolved-identifier-dispatch-async
Basically adding -Xcc -fblocks should get it to work.

If you're using the swift build command, the latest snapshot 2016-01-25-a, you can now pass in -Xcc args from your Package.swift file. See: https://github.com/apple/swift-package-manager/pull/107 for more details.


-------- Original Message --------
Subject: [swift-users] Is there a simple direct way to compile with libdispatch on Ubuntu?
Local Time: January 27, 2016 4:00 pm
UTC Time: January 28, 2016 12:00 AM
From: swift-users at swift.org
To: swift-users at swift.org

I have

/usr/include/Block.h

/usr/include/dispatch/dispatch.h

installed and have a program that uses GCD.


Is there a simple direct way to reference libdispatch in the program and on the command line to compile with swiftc?
_______________________________________________
swift-users mailing list
swift-users at swift.org
https://lists.swift.org/mailman/listinfo/swift-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-users/attachments/20160128/1238e419/attachment.html>


More information about the swift-users mailing list