title: compiling c program into MATLAB format MAC OS X
body: <p>Any help on my problem is appreciated...</p>
  
  <p>I'm trying to run this program located in the sparsenet.tar.gz file at <a href="http://redwood.berkeley.edu/bruno/sparsenet/" rel="nofollow">http://redwood.berkeley.edu/bruno/sparsenet/</a></p>
  
  <p>There is a README that I try to follow but I can't seem to compile my cgf.c...</p>
  
  <p>The first step I assume I did correctly (I'm pretty sure I am able to compile the libnrfopt.a).</p>
  
  <p>But when I type "make" in the sparsenet directory, it says:
  new-host-2:sparsenet user123$ make
  mex -I./nrf -L./nrf -lnrfopt cgf.c
  make: mex: No such file or directory
  make: <em>*</em> [cgf.mexmaci64] Error 1</p>
  
  <p>I assume it means my terminal isn't recognizing Mex, can anyone point me to how that works? (Before you tell me I haven't done enough searching, I have...I just cant seem to find anything relevant...I have my command line options in Xcode running, GCC works, Mex -setup works)</p>
  
  <p>By the way, I'm doing this in Terminal, not inside MATLAB. Doing it inside matlab by directly using Mex doesn't work for me either.</p>
  
  <p>Also I've changed the mex extensions to a variety of choices including mexmac, mexmaci64, etc.</p>
  
  <p>Thanks in advance!!</p>