Can I use newlib or newlib-nano with android NDK to build a dynamic library?
I know this is not a to-the-point question. But couldn't find much write-up on this. Any help is appreciated. I'm a newbie to android.
Android uses bionic, not newlib. The C runtime is already loaded as part of the zygote in any app so this is not optional.
Related
When we develop an Android app in Java, we have the option to obfuscate the code and built the APK.
Is there any advance feature in Kotlin to do the same?
Code obfuscation is neither a Java feature nor a Kotlin one.
Since Kotlin is compiled to the same bytecode as Java, you can use the same tools (for example Proguard). Those tools obfuscate the bytecode and not the sources, I think you misunderstood that.
Suppose you're running gradle build on your Kotlin Android project. Then you'll find following tasks being run:
:app:compileReleaseKotlin
:app:compileReleaseJavaWithJavac
:app:copyReleaseKotlinClasses
:app:compileReleaseSources
:app:transformResourcesWithMergeJavaResForRelease
:app:transformClassesAndResourcesWithProguardForRelease
:app:transformClassesWithDexForRelease
As you can see Kotlin sources are compiled first, then the Java sources. This results in only one collection of Java classes which are processed with Proguard; just at the end. There is no differentiation between Java and Kotlin anymore at this step.
I'm coding a program that really need libev (not libevent) on Android. I google many time to find how to build libev but unsuccess.
Could any one tell me, how to build libev on android. Thank so much.
Did you have any success? I'm stuck with the same problem, trying to use it on a native app for Android (working on Ubuntu). This article gave me some light:
http://pod.tst.eu/http://cvs.schmorp.de/libev/ev.pod#EMBEDDING
It might be useful for you. I tried the standalone case. In any case, I can't still make it work
has anyone ever written a netbeans' toolchain for MS VC++ compiler?
Following this bug report.
I read this should be possibile since version 6.7.
I thank in advance you all.
I am currently writing a module/toolchain to use Visual C++ on Netbeans.
You can find the project called VCC4N on source forge.
It may be a bit late for you, but I hope it can help other people.
I have a game written in C/C++ for iOS (using only obj-c for the GLES initialization) and I would like to port it to Android, I saw that it was possible using the NDK by creating a dynamic library (.so).
I install the Android SDK and NDK compile a simple library load it run, no problem, but I simply can't debug it... I can only debug the Java part (where my GLES context is created etc...) Am I missing something or? how can I debug my dynamic library?
It doesn't seems to have no support for debugging anything created with the NDK for Eclipse... so how am I suppose to debug my C/C++ then?
Anybody have experience with this? Any help would be greatly appreciated!
You have to use ndk-gdb. Take a look at this articles:
http://groups.google.com/group/android-ndk/web/debugging-through-the-jni-with-android-2-2
http://www.eclipse.org/sequoyah/documentation/native_debug.php
I have a problem when compiling JNI. It returns the error message like
that "arm-eabi/bin/ld: cannot find -landroid_runtime".
I think libandroid_runtime.so is the android's own lib. Why ld can't find the
lib. Can somebody help me.
My develop environment as follow:
OS: Ubuntu 9.10
SDK: Android2.2
NDK: r4b
libandroid_runtime.so is in fact one of the Android system libraries, and as such is not available for NDK apps.
Check the file docs/STABLE-APIS.txt for a list of supported libraries, or even better, check the folder build/platforms/android-#/arch-arm/usr/lib where # is the Android platform level, for the definitive list of libraries you can link against.
As they say on the NDK lists, even if you manage to link against one of the other Android libraries, it likely won't work on some (or possibly even most) phones, even if it works on the one you're testing.
To solve your problem build a emulation of every android possible and recompile a version for each android and put it on the market with specific compatibility.
EDIT: Try using: adb pull /system/lib
EDIT 2: There also should be a egl folder in /lib so you know to look for it.