this project can build & run,but c file always show Cannot find 'jni.h'.
other jni function also not found.
What should I do?
Try to use classpath 'com.android.tools.build:gradle-experimental:0.7.0-rc1' instead of 0.8.0-alpha3.
I got a same problem on Android Studio 2.1.2, I tried another version, it works.Sorry for my bad English, hope it can help you :)
It is the bug in Androind Studio 2.0 Preview, please wait for the bugfix.
Issue 195483: Android Studio cannot find jni.h, but compilation still works.
Related
I am using the project CSipSimple as a reference in my current project.
Project works fine until i have not tested it in the Android N.
I am getting strange errors when m running my project in Android N.
I have done some googling for that and came to know that by changing the complile SDK version for project will help me to get rid of this error but that thing wont help me in my case.
So any other workaround for this ?
It would be grateful to suggest any changes/guidelines to avoid this issue.
Thanks in advance
Before API 23, this error Text Relocations was given as warning, so it does not cause problems. From API 23 it was thrown as error. The .so file with text relocation may have memory leaks. So it must be fixed and recompiled with latest Android NDK.
Quick fix will be to set tagetApiVersion to 22 in build.gradle file.
I upgraded android studio to 2.2.p1 and builded my project without errors. There are some strange borders around views (see att). When I create the new default project and build it in 2.2.p1 the problem is the same. When I do the same in 2.1.1 the app behaviour is normal - without borders. The problem is, that I'm not able to find the cause of this behaviour and build my existing project in 2.1.1 did not help -> there is something "strange" in existing project which was already compiled in 2.2p1. Do you have a idea and solution for this?
thank you for your time and help ... noe
https://code.google.com/p/android/issues/detail?id=210467
I think this is correlated to the bug that is filed.
So long story short, just wait for the fix, OR, downgrade your gradle to
classpath 'com.android.tools.build:gradle:2.1.+'
I'm using Android Studio and I want to copy my code keeping the highlighting of my text. I found this plugin for IntelliJ Idea : https://plugins.jetbrains.com/plugin/7198 (copy on steroide) but when I try to install it I've got this error :
"Following plugins are incompatible with current IDE build : 'Copy' on
steroide"
Does someone know how to fix it? Or know another plugin to copy text with colors?
Thank's in advance !
"'Copy on steroids' plugin functionality is bundled with the platform now - available for testing in IDEA 14 EAP."
It works out of the box in Android Studio 1.2
I have a Kotlin file where I want access some Android resources through R.java file. In this case Intellij IDEA doesn't show up available suggestions kinda like R.layout.main
Please look at this screenshot
Is it an issue in IDEA/Kotlin plugin or I have to configure something?
Kotlin plugin 0.7.270.1
Intellij IDEA IC-135.1019
Andorid API 19
Java 7
Android Build tools 19.1
Looks like a bug in Kotlin plugin. Please report bugs to our issue tracker: http://youtrack.jetbrains.com/issues/KT
Long shot but, I would recommend following the docs for android http://kotlinlang.org/docs/tutorials/kotlin-android.html
I can see, for example, in your screenshot you don't have separate folders for kotlin and java with /src/main/java /src/main/kotlin
Maybe seeing your gradle file could be of some help.
Right now I'm using kotlin 0.10.195 with android 1.1, build tools 21.1.2 and gradle plugin 1.0.1 , and suggestions are working fine.
I am new to Android development. I have succesfully installed eclipse with Android Developer Tool plugin and many of the samples work fine.
But Android samples - Accelerometer and APIDemos do not build. I see many build errors notifying to fix the errors in code. I dont think Google has released APIDemo sample with build errors.
Thanks in advance, please advice how to fix these errors, or if any configuration/setting is required.
I have set the Java compiler compliance level to 1.6.
Error information(for acceralometer sample):
The project contains error(s) in application. Please fix them before running
Error details:
The method onAccuracyChanged(Sensor, int) of type AccelerometerPlayActivity.SimulationView must override a superclass method
AccelerometerPlayActivity.java /AccelerometerPlay/src/com/example/android/accelerometerplay line 456
Java Problem
Call requires API level 8 (current min is 5):
android.view.Display#getRotation AccelerometerPlayActivity.java /AccelerometerPlay/src/com/example/android/accelerometerplay
line 389 Android Lint Problem
Regards,
Jai
Look for the line androidminSdkVersion ="5" in your android.manifest file
and change its value from 5 to 8 or anything more than 8
Alternative is
Go to project properties by right clicking on you project,
thereafter look for Android in properties.
You have to select the build target here equivalent to the api for which it the sample project is build for
Refer Image
Say if you are using the sample from folder android-12 then you have to check the same option(ie API Level 12) here in properties
A possible reason can be a slow PC, which does not build in time. Then errors occur due to absence of R.java
In that case (errors are with something like R.id.stuff), build the project and wait.
I found the fix myself!
Earlier I tried with Andriod version 4.0. Now I just tried ApiDemos sample with Android version 4.1.2. It worked fine. I also deployed the apk in my mobile. It just works fine.