<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>C on</title><link>http://salopst.yearl.us/tags/c/</link><description>Recent content in C on</description><generator>Hugo</generator><language>en</language><copyright>&lt;a href="https://creativecommons.org/licenses/by-nc/4.0/" target="_blank" rel="noopener"&gt;CC BY-NC 4.0&lt;/a&gt;</copyright><lastBuildDate>Tue, 31 Aug 2021 06:23:00 +0100</lastBuildDate><atom:link href="http://salopst.yearl.us/tags/c/index.xml" rel="self" type="application/rss+xml"/><item><title>Installing Ruby 1.9.2 with RVM fails on OS X Lion</title><link>http://salopst.yearl.us/installing-ruby-1-9-2-with-rvm-fails-on-os-x-lion/</link><pubDate>Fri, 28 Oct 2011 14:51:58 +0000</pubDate><guid>http://salopst.yearl.us/installing-ruby-1-9-2-with-rvm-fails-on-os-x-lion/</guid><description>&lt;p&gt;Remove RVM, thus making for a cleaner install later:&lt;/p&gt;&#10;&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-bash" data-lang="bash"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;$ RVM implode&#10;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Remove XCode:&lt;/p&gt;&#10;&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-bash" data-lang="bash"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;$ sudo /Developer/Library/uninstall-devtools –mode&lt;span style="color:#f92672"&gt;=&lt;/span&gt;all&#10;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;XCode is removed since in 4.2, at least, all references to gcc are linked to llvm-gcc (Apple&amp;rsquo;s) own fork of gcc. llvm will NOT compile ruby.&lt;/p&gt;&#10;&lt;p&gt;(One can always re-install from the AppStore later)&#10;download and install GCC-10.7-v2.pkg from &lt;a href="https://github.com/kennethreitz/osx-gcc-installer/downloads"&gt;https://github.com/kennethreitz/osx-gcc-installer/downloads&lt;/a&gt;&lt;/p&gt;&#10;&lt;p&gt;This will install just the bare-bones GCC compiler. It can safely be overwritten by XCode if you decide to reinstall it, or simple removed using the same command as that used for removing XCode.&#10;reinstall RVM: &lt;a href="http://beginrescueend.com/rvm/install/"&gt;http://beginrescueend.com/rvm/install/&lt;/a&gt;&#10;Install the package manager &amp;ldquo;homebrew&amp;rdquo; from &lt;a href="http://mxcl.github.com/homebrew/"&gt;http://mxcl.github.com/homebrew/&lt;/a&gt; and with it install libiconv.&lt;/p&gt;</description></item><item><title>Setting GCC 4.2 as the default compiler on Mac OS X Leopard</title><link>http://salopst.yearl.us/setting-gcc-4-2-as-the-default-compiler-on-mac-os-x-leopard/</link><pubDate>Thu, 27 Oct 2011 15:00:01 +0000</pubDate><guid>http://salopst.yearl.us/setting-gcc-4-2-as-the-default-compiler-on-mac-os-x-leopard/</guid><description>&lt;p&gt;Im my experience (limited), changing CC in .profile does not change Lion&amp;rsquo;s (10.7.2) defaulting to i686-apple-darwin11-llvm-gcc-4.2. I wonder if this has anything to do with Apple&amp;rsquo;s own sym linking:&#10;a partial: &lt;code&gt;$ls -la /usr/bin | grep .*gcc.*&lt;/code&gt;:&lt;/p&gt;&#10;&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-bash" data-lang="bash"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;lrwxr-xr-x &lt;span style="color:#ae81ff"&gt;1&lt;/span&gt; root wheel &lt;span style="color:#ae81ff"&gt;12&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;25&lt;/span&gt; oct 19:31 cc -&amp;gt; llvm-gcc-4.2lrwxr-xr-x &lt;span style="color:#ae81ff"&gt;1&lt;/span&gt; root wheel &lt;span style="color:#ae81ff"&gt;12&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;25&lt;/span&gt; oct 19:31 gcc -&amp;gt; llvm-gcc-4.2lrwxr-xr-x &lt;span style="color:#ae81ff"&gt;1&lt;/span&gt; root admin &lt;span style="color:#ae81ff"&gt;32&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;25&lt;/span&gt; oct 19:31 llvm-gcc-4.2 -&amp;gt; ../llvm-gcc-4.2/bin/llvm-gcc-4.2&#10;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I am wary about breaking these and adding my own to &lt;code&gt;usr/bin/gcc-4.2&lt;/code&gt; per Martin v. Löwis&amp;rsquo;s answer.&lt;/p&gt;</description></item></channel></rss>