<div dir="ltr">There is another problem regarding to the coexistence of xcode gcc and gcc48 from macports. <div>When I do  &quot;port select gcc mp-gcc48&quot; , I can compile using &quot;g++&quot;. But when I switch back by &quot;port select gcc none&quot;, </div>
<div>I got the error: </div><div>







<p class="">&gt; g++ -g -o HelloWorld HelloWorld.cpp</p>
<p class="">-bash: /opt/local/bin/g++: No such file or directory</p><p class="">But strangely, when I do &quot;which g++&quot;,  I get &quot;/usr/bin/g++&quot;. Then why &quot;g++&quot; still try to involve &quot;/opt/local/bin/g++&quot; but not &quot;/usr/bin/g++&quot;? </p>
<p class="">Thanks. </p><p class="">Shiyuan </p></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Jan 10, 2014 at 9:32 PM, Shiyuan <span dir="ltr">&lt;<a href="mailto:gshy2014@gmail.com" target="_blank">gshy2014@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">That solves the problem. Thanks. </div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br>
<br><div class="gmail_quote">On Fri, Jan 10, 2014 at 7:47 PM, Brandon Allbery <span dir="ltr">&lt;<a href="mailto:allbery.b@gmail.com" target="_blank">allbery.b@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div>On Fri, Jan 10, 2014 at 9:53 PM, Shiyuan <span dir="ltr">&lt;<a href="mailto:gshy2014@gmail.com" target="_blank">gshy2014@gmail.com</a>&gt;</span> wrote:<br>


<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>   I am on OS 10.9 Mavericks. I install gcc48 from macport. However, I got the follow error when I compile HelloWorld. What might go wrong? Thanks. </div>


</div></blockquote><div><br></div></div><div>wchar.h is part of the Xcode command line tools package. If you got gcc48 from a prebuilt package instead of locally built, you may never have gotten the Xcode 5 command line tools (which may be auto-installed the first time something invokes `clang`) and may be missing system include files.</div>


<div><br></div><div>`xcode-select --install` should force installation of the command line tools.</div><span><font color="#888888"><div><br></div></font></span></div><span><font color="#888888">-- <br>
<div dir="ltr"><div>brandon s allbery kf8nh                               sine nomine associates</div>
<div><a href="mailto:allbery.b@gmail.com" target="_blank">allbery.b@gmail.com</a>                                  <a href="mailto:ballbery@sinenomine.net" target="_blank">ballbery@sinenomine.net</a></div><div>unix, openafs, kerberos, infrastructure, xmonad        <a href="http://sinenomine.net" target="_blank">http://sinenomine.net</a></div>


</div>
</font></span></div></div>
</blockquote></div><br></div>
</div></div></blockquote></div><br></div>