Where does brew install the Python headers?
<p>I am trying to compile a simple "Hello, World!" in Cython. In a file I have:</p>

<pre><code>print("Hello, World!")
</code></pre>

<p>I run:</p>

<pre><code>cython hello_world.pyx
</code></pre>

<p>To get the <code>hello_world.c</code> file. I then try:</p>

<pre><code>gcc -c hello_world.c
</code></pre>

<p>Which gives the error:</p>

<pre><code>fatal error: 'Python.h' file not found
</code></pre>

<p>Then I tried <a href="http://stackoverflow.com/a/16454614/667648">this</a>:</p>

<pre><code>gcc -c hello_world.c -framework Python
</code></pre>

<p>Didn't work. I had changed <code>include "Python.h"</code> to <code>&lt;Python/Python.h&gt;</code> and got a different error:</p>

<pre><code>fatal error: 'longintrepr.h' file not found
</code></pre>

<p>Regardless, I want to use Python3, not the Python Apple ships with, but I am unable to figure out where the Python3 development headers are located.</p>

<p>Ultimately, I want to be able to compile <code>hello_world.c</code> so that it works in a Python3 interpreter.</p>

<p>(I am using brew's python3.5.2_1, if that helps.)</p>

<p>Going off from @sr3z's comment, doing:</p>

<pre><code>gcc -c random_sum.c -I/usr/local/Cellar/python3/3.5.2_1/Frameworks/Python.framework/Versions/3.5/include/python3.5m
</code></pre>

<p>Creates <code>random_sum.o</code>.</p>

python python-3.x homebrew cython