title: java.lang.UnsatisfiedLinkError in Linux
body: <p>I've managed to get into a linux machine to try the HotKey library suggested in <a href="https://stackoverflow.com/questions/79658/react-on-global-hotkey-in-a-java-program-on-windows-linux-mac/202272#202272">this answer.</a></p>
  
  <p>I've compiled the sample code and now I run the program and I've got the following message:</p>
  
  <pre>
  [oracle@machine jxgrabkey-0.2.1_i386]$ java -classpath lib/JXGrabKey.jar:Example JXGrabKeyTest
  
  Exception in thread "main" **java.lang.UnsatisfiedLinkError:** /home/oracle/javasample/jxgrabkey-0.2.1_i386/lib/libJXGrabKey.so: /usr/lib/libstdc++.so.6: version `GLIBCXX_3.4.9' not found (required by /home/oracle/javasample/jxgrabkey-0.2.1_i386/lib/libJXGrabKey.so)
     at java.lang.Runtime._load(libgcj.so.7rh)
     at java.lang.Runtime.load(libgcj.so.7rh)
     at java.lang.System.load(libgcj.so.7rh)
     at JXGrabKeyTest.main(JXGrabKeyTest.java:17)
  
  </pre>
  
  <p>I know how to handle this in Windows ( just by adding the DLL to the PATH env var ) but I'm not that sure about linux. </p>
  
  <p>I've read something about LD_LIBRARY_PATH and some other env vars but I can make it work.</p>
  
  <p>Any advice?</p>
  
  <p><strong>EDIT</strong></p>
  
  <p>After the support  from mmyers to indentify the problem and reading <a href="http://www.linuxquestions.org/questions/linux-newbie-8/usrliblibstdc.so.6-version-glibcxx3.4.9-not-found-required-by-.example1-604625/" rel="nofollow noreferrer">this thread</a> and <a href="http://ubuntuforums.org/showthread.php?t=666744" rel="nofollow noreferrer">this other</a>. </p>
  
  <p>I can tell:</p>
  
  <p>My system is: Linux 2.6.18-53.el5</p>
  
  <p>My GCC version(s) is ( are) : </p>
  
  <p>gcc-c++-4.1.2-14.el5</p>
  
  <p>gcc-gfortran-4.1.2-14.el5</p>
  
  <p>libgcc-4.1.2-14.el5</p>
  
  <p>gcc-4.1.2-14.el5</p>
  
  <p>The problems is I require gcc 4.2.0</p>
  
  <p>Aaand apparently there is no gcc 4.2.0 for my system. </p>
  
  <p>I guess I would have to wait for it to come or the author recompile it in a previous version.</p>
  
  <p>mmyers, thanks a lot for your help.</p>