I'm trying to install opencv on android studio but i get this error,when i try to update build.gradle:
Cause:failed to find target with hash string 'android-14'
But in the sdk manager there is no api level 14 to download
I assumed you imported the Android Program from the examples provided by OpenCV here.
(Note* Eclipse is deprecated but as long as you import the Eclipse project into Android Studio it will still be there.)
I assumed you are using OpenCV 3.0.
After you import, you will see "openCVLibrary310" folder. Change the "compileSDKVersion 14" to "compileSDKVersion [your version]" and rebuild the gradle!
Good luck!
Related
I'm importing this project from Github into Android Studio 2.1.2. I'm at a point where it's asking me "Please select project SDK. This SDK will be used by default by all project modules." There are 2 options - "1.7" or "Android API 23 Platform". How do I know which one to pick? The "1.7" option has a ton of files while the other has only 2 files.
My overall goal is to just open this project and learn from it. I wanted to look at the source code for a functioning project that is not as simple as the tutorials given for Android Studio. I wanted a bit more complexity.
That means you probably haven't configured Android Studio. YOu have to install Android SDK in order for everything to work.
I cannot find the raw SDK download link, so you probably have to use Android Studio to download it.
Also, you should download Java 8 to get all functionality of Android Studio 2.1.2(Android Studio 2.x requires java 8(or higher)) so selecting 1.7 is probably for compatability mode
When I attempt to open the Android SDK samples for v19, for example connectivity/BasicNetworking, I get the following error in Android Studio:
The project is using an unsupported version of the Android Gradle plug-in (0.12.2).
The recommended version is 1.1.0
Not only can I not build the project - I can't even open it and browse the source code.
I understand I can alter build.gradle to use v1.1.0 of the plugin but I don't feel that should be my job. Google is providing both the samples and the IDE. Why can't I open their samples in their IDE?
Is there any setting in Android Studio I can set so that it automatially sets the latest gradle plugin version in the build.gradle file when opening old projects?
The "Import an Android code sample" on the Android Studio startup screen, or "File > Import sample" actually takes care of this (although a side effect is that it copies the project to a new folder).
With the release of Android Studio 1.0 (AS) i want to migrate from Eclipse. Generally I need no other library then libpd (PureData) for Audio synthesis. The Problem is, that libpd for android is geared to the needs of Eclipse. So in Eclipse everything is working as expected.
The only information I could found was that: Using libpd in Android Studio So I know libpd and Android Studio could work together but here are maybe some other problems.
I started to generate a new simple project (MinSDK 10 - CompileSDK 21 - BuildTools 21.1.2) just with a blank activity. I can deploy this simple app to my Nexus and everything is fine.
Then I import :PDCore and :AndroidMidi as Module into my AS project and I get the Gradle build-error: Error:The SDK Build Tools revision (17.0.0) is too low for project ':PdCore'. Minimum required is 19.1.0
I installed API 19 and Build Tools version 19.1 via the SDK Manager but that's not solving my problem.
I changed the buildToolsVersion of the apps build.gradle file to "19.1.0" but that's not solving my problem.
Any advices to get Gradle working probably?
Maybe anyone got a sample Android Studio project with libpd to share?
Thanks in advance!
FYI: I wrote some posts regarding migrating to Android Studio using libpd. Take a look here:
http://www.journal.deviantdev.com/using-libpd-with-android-studio/
http://www.journal.deviantdev.com/update-using-libpd-with-android-studio/
http://www.journal.deviantdev.com/sample-libpd-android-studio/
You have to change the build.gradle of the :PDCore and :AndroidMidi modules. At the moment they are using 17, update the BuildTools to the newest version (21.1.2). This should solve your problem.
I created a fork of the libpd-for-android and migrated it to Android Studio. You can clone it and open it in Android Studio as a 'Non Android Studio Project'. This worked very nicely for me and you can also now created an .aar file and use it in your Android App ( instead of copying the whole code or using git submodules):
https://github.com/tkirshboim/pd-for-android
First of all, i know this question has been asked a lot, but nothing seem to be working for me.I have installed Eclipse ADT On MAC 10.9.5 from android.developer.com and have installed latest Android SDK tools, and all other platform and tools required for Android 5.0, android 4.4W and Android 4.4.2. I have also installed Android support library. But when i try to run the project with the default properties,
http://postimg.org/image/4lf8ayl99/
Minimum Required : SDK-API8:Android 2.2(Froyo)
Target SDk-Android; 4.x(L Preview)
Compile With ; API 21: Android 4.x( L Preview)
It always give me error,
The container 'Android Dependencies' references non existing library '/Users/xxx/Documents/workspace/appcompat_v7/bin/appcompat_v7.jar'
I went through all the solutions listed on web and on this website too, but nothing worked for me.
appcompat_v7 library gets generated, and then i click on add to build path for android-support-v7-appcompat.jar and android-support-v4.jar, and then from build path add the two libraries and untick android dependencies and add the library to my project from android library. From other posts i get to know that after clean and build appcompat_v7 library project , appcompat_v7.jar would be generated in bin directory, but it doesn't happen in my case.
Please help. I have spent too much time looking for the solution, but didn't find any.
I finally found the solution, I had to update the jdk to 1.8, The jdk installed by default by eclipse ADT form android.developer.com doesn't seem to be updated and Since API 21 requires jdk 1.7 or above thus i had to install it from JDK official website http://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1880260.html. Finally i got the support library appcompat_v7 working.
I had the same problem and I tried and after that message I got another from the res folder. Anyways what I did was switch work space and it worked fine . it should create those files for you as long as you downloaded the extras from android manager downloader.
Hello guys, Now I'm face on some error using android studio(0.3.6 version) (using at win8)
I cloned project from bitbucket and import project, but that error message occured.
what should I do?
ah! Project make from android studio version 0.3.2. is this reason?
In addition, how can I import external library at 0.3.6 project structure?
should I make new module? then what?
anyway! thanks in advance. I hope to get answer!
Android Studio comes bundled with its own SDK, which may not have the same Android API targets you used to create the project in Eclipse. You can either add the APIs to Android Studio's SDK by clicking on the SDK Manager toolbar icon in Android Studio if you have a project open, or if you don't, from the Welcome screen choose Configure > SDK Manager, or you can tell Android Studio to use the same SDK you were using from Eclipse: Project Structure > Android SDK if you have a project open, or Welcome > Configure > Project Defaults > Project Structure > Android SDK if you don't.
Compile the project with latest version of android , go to sdk manager and install the android api level 18 and then in your project right click open android tools and add support library. clean the project and restart the eclipse.