title: How do I get the right libjpeg dylib for Lua?
body: <p>So, I am running torch on OSX (See error in bold below):</p>
  
  <pre><code>     ______             __   |  Torch7                                  
   /_  __/__  ________/ /   |  Scientific computing for Lua.        
    / / / _ \/ __/ __/ _ \  |                                          
   /_/  \___/_/  \__/_//_/  |  https://github.com/torch  
                            |  http://torch.ch           
  
  
  th&gt; package.cpath = package.cpath .. ";/usr/local/Cellar/jpeg/8d/lib/?.dylib"
                                                                        [0.0000s] 
  th&gt; require 'image'
  true    
                                                                        [0.0120s] 
  th&gt; image.lena();
  /Users/&lt;user&gt;/torch/install/share/lua/5.1/trepl/init.lua:319: error loading module 'libjpeg' from file '/usr/local/Cellar/jpeg/8d/lib/libjpeg.dylib':
      dlsym(0x7fd564000320, luaopen_libjpeg): symbol not found
  warning: &lt;libjpeg&gt; could not be loaded (is it installed?)
                                                                        [0.0229s] 
  th&gt;
  </code></pre>
  
  <p>Specifically this line:
  <strong>error loading module 'libjpeg' from file '/usr/local/Cellar/jpeg/8d/lib/libjpeg.dylib':
          dlsym(0x7fd564000320, luaopen_libjpeg): symbol not found
      warning:  could not be loaded (is it installed?)</strong></p>
  
  <p>Seems like I don't have the right dylib? If so, where do I get it?</p>