title: Compiling C code with R header files
body: <p>I need R header files to compile something. I installed R on ubuntu via:</p>
  
  <pre><code>sudo apt-get r-base-dev
  </code></pre>
  
  <p>R works fine. But I can't find the  R headers such as Rmath.h. I get this error when I try to compile:</p>
  
  <pre><code>gcc -g -std=c99 -I/usr/include -O3 -lRmath -lm -lpthread -o qcpg qcpg.c
  In file included from qcpg.c:1:0:
  qcpg.h:19:19: fatal error: Rmath.h: No such file or directory
  compilation terminated.
  make: *** [qcpg] Error 1
  </code></pre>
  
  <p>Any ideas??</p>