title: Debugging Android NDK C/C++ code in Eclipse - breakpoints are not hit
body: <p>I downloaded Android SDK Bundle for Linux and Android NDK. ADT was installed, I installed CDT.</p>
  
  <p>I created a Android project and added native support (jni). Then I wrote native function in java-code which exporting in c++ code. In c++ code I defined this function.</p>
  
  <p>Java-code:</p>
  
  <pre><code>static {
      System.loadLibrary("test");
  }
  
  private native String get_text_from_cpp();
  </code></pre>
  
  <p>c++ code (h):</p>
  
  <pre><code>extern "C"{
     JNIEXPORT jstring JNICALL Java_com_example_test_MainActivity_get_1text_1from_1cpp(JNIEnv *, jobject);
  }
  </code></pre>
  
  <p>c++ code (cpp):</p>
  
  <pre><code>JNIEXPORT jstring JNICALL Java_com_example_test_MainActivity_get_1text_1from_1cpp(JNIEnv * env, jobject){
      return env-&gt;NewStringUTF( "hello from C++" );
  }
  </code></pre>
  
  <p>Code works without errors. But when I set breakpoint in c++ code it is not hit.</p>
  
  <p>build-nkd NDK_DEBUG = 1 - are included</p>
  
  <p>I followed this instructions <a href="http://tools.android.com/recent/usingthendkplugin" rel="nofollow">http://tools.android.com/recent/usingthendkplugin</a></p>
  
  <p>Android.mk in jni/ has LOCAL_CFLAGS := -g</p>
  
  <p>I have read very much information but I could't customized Eclipse. Please, help anybody. </p>
  
  <p>PS: I am sorry for my English is not my native language. I have difficulty in writing.</p>
  
  <p>Add: Also during debug in console shows:
  "warning: Could not load shared library symbols for 95 libraries, e.g. /system/bin/linker.
  Use the "info sharedlibrary" command to see the complete listing.
  Do you need "set solib-search-path" or "set sysroot"?
  warning: Unable to find dynamic linker breakpoint function.
  GDB will retry eventurally.  Meanwhile, it is likely
  that GDB is unable to debug shared library initializers
  or resolve pending breakpoints after dlopen()."</p>