Ivan Vučica
Ivan Vučica

Reputation: 9679

Targeting WinRT via LLVM or GCC

Both LLVM and GCC support Objective-C, and I like the language. Hence, I'd be interested in targeting WinRT native code using LLVM or GCC, probably using MinGW.

While the question I'm interested in should be easily googlable, I couldn't find any salient information: does either LLVM or GCC support targeting WinRT?


Intel has an article on using Intel C++ Compiler 13.0 with Visual Studio 2012 which may contain useful hints.

Also, a near duplicate question.

Upvotes: 6

Views: 1798

Answers (2)

Chandler Carruth
Chandler Carruth

Reputation: 3341

Clang now has full support for native C and C++ on Windows, with the native ABI, etc. If there is a C or C++ API for WinRT, you should easily be able to call that with code compiled using Clang on Windows.

That doesn't directly connect ObjC to WinRT, but you could potentially write code to build such a connection if you wished.

Upvotes: 2

Marcus Ilgner
Marcus Ilgner

Reputation: 7241

For the moment, you're stuck with MSVC. While it's not impossible to access the API itself (it's basically COM with some bells and whistles), it wouldn't be much fun to interface it with Objective-C without jumping through some hooks.

One problem I see initially would be the fact that Objective C doesn't support namespaces and using the WinRT API from within Objective C probably wouldn't be much fun. The PPL is available for C++ and in C# there's the await keyword but using all these ...Async methods in Objective-C... you probably don't want that ;)

Upvotes: 0

Related Questions