<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="">-swift-evolution, for now.<div class=""><br class=""></div><div class="">I’m trying to build a C++ shim around the LLVM API to create an instance of the ORCJIT, visible in this PR:</div><div class=""><a href="https://github.com/trill-lang/LLVMSwift/pull/18" class="">https://github.com/trill-lang/LLVMSwift/pull/18</a></div><div class=""><br class=""></div><div class="">I can’t build this file without passing `-Xcc -std=c++1` to `swift build`. When I pass that (along with the necessary linker flags and include dirs):</div><div class=""><br class=""></div><div class="">`swift build -Xcc -std=c++11 -Xcc -I/usr/local/opt/llvm/include -Xlinker -L/usr/local/opt/llvm/lib -Xlinker -lc++ -Xlinker -lLLVM`</div><div class=""><br class=""></div><div class="">Then It can’t build SwiftShims:</div><div class=""><br class=""></div><div class=""><div class="">&lt;unknown&gt;:0: error: could not build Objective-C module 'SwiftShims'</div><div class="">&lt;unknown&gt;:0: error: invalid argument '-std=c++11' not allowed with 'C/ObjC'</div></div><div class=""><br class=""></div><div class="">That’s the issue here — I can’t pass arguments to the C++ files without affecting the C/ObjC files.</div><div class=""><br class=""></div><div class="">Thanks,</div><div class="">Harlan</div><div class=""><br class=""></div><div class=""><div><blockquote type="cite" class=""><div class="">On Jan 16, 2017, at 4:51 PM, Daniel Dunbar via swift-build-dev &lt;<a href="mailto:swift-build-dev@swift.org" class="">swift-build-dev@swift.org</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">Hi Harlan,<div class=""><br class=""></div><div class="">Can you describe more about exactly what distinct problems you are running into?</div><div class=""><br class=""></div><div class="">Thanks!</div><div class="">&nbsp;- Daniel<br class=""><div class="gmail_extra"><br class=""><div class="gmail_quote">On Mon, Jan 16, 2017 at 10:54 AM, Ankit Agarwal via swift-build-dev<span class="Apple-converted-space">&nbsp;</span><span dir="ltr" class="">&lt;<a href="mailto:swift-build-dev@swift.org" target="_blank" class="">swift-build-dev@swift.org</a>&gt;</span><span class="Apple-converted-space">&nbsp;</span>wrote:<br class=""><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; padding-left: 1ex;"><div dir="ltr" class="">+ swift-build-dev</div><div class="gmail_extra"><br class=""><div class="gmail_quote">On Tue, Jan 17, 2017 at 12:03 AM, Harlan Haskins via swift-evolution<span class="Apple-converted-space">&nbsp;</span><span dir="ltr" class="">&lt;<a href="mailto:swift-evolution@swift.org" target="_blank" class="">swift-evolution@swift.org</a>&gt;</span><span class="Apple-converted-space">&nbsp;</span>wrote:<br class=""><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; padding-left: 1ex;"><div style="word-wrap: break-word;" class="">Hi swift-evolution!<div class=""><br class=""></div><div class="">Robert Widmann and I have been working on a Swift wrapper for LLVM (<a href="https://github.com/harlanhaskins/LLVMSwift" target="_blank" class="">https://github.com/harlanhask<wbr class="">ins/LLVMSwift</a>) and we’re lamenting the lack of C++ support in SwiftPM.</div><div class=""><br class=""></div><div class="">Ideally, we’d be able to write C++ files that expose C APIs for LLVM APIs that aren’t yet exposed in the llvm-c API.</div><div class=""><br class=""></div><div class="">Before we write a proposal for C++ files in SwiftPM targets, are there any concerns/things we should consider?</div><div class=""><br class=""></div><div class="">Thanks,</div><div class="">Harlan</div></div><br class="">______________________________<wbr class="">_________________<br class="">swift-evolution mailing list<br class=""><a href="mailto:swift-evolution@swift.org" target="_blank" class="">swift-evolution@swift.org</a><br class=""><a href="https://lists.swift.org/mailman/listinfo/swift-evolution" rel="noreferrer" target="_blank" class="">https://lists.swift.org/mailma<wbr class="">n/listinfo/swift-evolution</a><br class=""><br class=""></blockquote></div><span class="m_-1088498786653000013HOEnZb"><font color="#888888" class=""><br class=""><br clear="all" class=""><div class=""><br class=""></div>--<span class="Apple-converted-space">&nbsp;</span><br class=""><div class="m_-1088498786653000013m_-7650781582531140897gmail_signature" data-smartmail="gmail_signature">Ankit<br class=""><br class=""></div></font></span></div><br class="">______________________________<wbr class="">_________________<br class="">swift-build-dev mailing list<br class=""><a href="mailto:swift-build-dev@swift.org" target="_blank" class="">swift-build-dev@swift.org</a><br class=""><a href="https://lists.swift.org/mailman/listinfo/swift-build-dev" rel="noreferrer" target="_blank" class="">https://lists.swift.org/mailma<wbr class="">n/listinfo/swift-build-dev</a><br class=""><br class=""></blockquote></div><br class=""></div></div></div><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class="">_______________________________________________</span><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class="">swift-build-dev mailing list</span><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><a href="mailto:swift-build-dev@swift.org" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" class="">swift-build-dev@swift.org</a><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><a href="https://lists.swift.org/mailman/listinfo/swift-build-dev" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" class="">https://lists.swift.org/mailman/listinfo/swift-build-dev</a></div></blockquote></div><br class=""></div></body></html>