Git Product home page Git Product logo

eclipsejnidebug's Introduction

EclipseJNIDebug

small repo with an eclipse JNI debugging. Each commit is a new step in the process

Using the latest commit, you can debug JNI in eclipse. Assuming everything is setup correctly, load project, open the jni.c file and set a break point on the switch statement and do: Project->debug as->android native application. If you have any issues, look at the gotchas/issues for commit 3 below.

commit 1: -- initial eclipse project with a button. doesn't do anything commit 2: -- added a jni, but currently it compiles by hand commit 3: -- eclipse integration -- gotchas/issues: - project->Android Tools->Add Native Support * NDK location not valid in preferences -- fix by 'Window->Preferences->Android->NDK', update location * creates jni/ -- already have a jni, so i merely deleted it

        -- Properties->Buildiers-> NDK Builder (added by me)
            - Add a 'New Program'
            - name something useful -- NDK builder
            - path to 'ndk-build' script

        -- AndroidManifest.xml changes
            - enable debug
            - change Use SDK to match your phone

        -- debug as Android Native Application, you get these errors:
                [2013-11-21 09:48:12 - JniDebug] ActivityManager: Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] cmp=com.example.jnidebug/.MainActivity }
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] Android
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] NDK:
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] WARNING:
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] APP_PLATFORM
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] android-18
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] is
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] larger
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] than
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] android:minSdkVersion
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] 8
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] in
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] ./AndroidManifest.xml
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] 
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] 
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] 
                [2013-11-21 10:02:55 - JniDebug] Unknown Application ABI: 
                [2013-11-21 10:02:55 - JniDebug] 
                armeabi
                [2013-11-21 10:02:55 - JniDebug] Unable to detect application ABI's

                ==> make sure your manifest versions match your phone:
                    [jc@jc-u13:JniDebug]$ adb shell getprop|grep build.version
                    [ro.build.version.codename]: [REL]
                    [ro.build.version.incremental]: [eng.jc.20131105.131621]
                    [ro.build.version.release]: [4.3]
              ===>> [ro.build.version.sdk]: [18]        <<===== you need your min SDK to be this

eclipsejnidebug's People

Contributors

jonco29 avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.