I am basically a .NET Developer but from the last few days, I was working with Ionic. I was able to build and generate APK files from my system where I had installed Android tools from Visual Studio & other dependencies. Below is a list of dependencies that I had installed on my system.
- Java (JDK8)
- Gradle
- Android SDK & Emulator
By using these dependencies, I was able to build my Ionic App and generate APK files.
My Question is that - Now I am moving my code to a new system. What are the minimum dependencies I need to install so that I can keep the show running as before? I know, below dependencies are required.
- Java (JDK8)
- Gradle
Now confusion comes when I think about Android dependencies.
Q1. Installing the Android SDK will be enough for building an app and generating APK files?
Q2. If Android SDK is the only requirement left then from where can I
download it for the latest API Level & what is the size of Android SDK? How much space it would take on my hard disc?
Q3. Will I be required to install other dependencies from SDK Manager after installing the SDK to build the app?
My sole objective is to know the minimum dependencies and their setup to build the Ionic Android App & it's APK generation.
You need Java, Gradle, Android SDK to generate an apk(Android) in Ionic.
So in your case just install the android SDK.
Do not forget to add the path variables for Gradle, Java.
Related
I have run into some issues with gradlew failing to run in my nativescript application. People have told me that it's a gradle issue and I need to update it, but wherever I search I see instructions for updating gradle using android studio. But I've just installed my SDKs using the sdkmanager and avdmanager. Is there any way to update gradle using them?
I don't want to update my emulator images etc. only gradle.
When you update android studio you should be able to keep settings from past versions I've been using android studio on the same computer for 3 to 4 years and all my old images/ SDKs are still there, plus if you update grade without updating android studio the grade may not be recognized by that version of android studio. If I was in your place I would update android studio to the latest stable version.
I know that Android Studio is now the official IDE for developing Android apps, but my computer is really slow and I find it difficult to use Android Studio on it.
I'm using Netbeans for Android apps development and fortunately it works fine.
The problem I am having now is using the Android support libraries in netbeans. I found out that Android now uses the Gradle system for apps development in which the dependencies are declared, but the apps that that Netbeans creates don't have a Gradle file and I won't be able to add the dependencies.
My question is:
How do I create Gradle files in Netbeans?
Or how can I add the support libraries directly into my Netbeans projects without the need for Gradle?
I have downloaded the support libraries and I have also installed Gradle on my computer.
Currently it's not very intuitive how to switch between Android SDK source files in Android Studio while, for example, debugging or just inspecting the sources.
I've got the feeling that Android Studio, unlike IntelliJ, is getting the source's version from the compiled SDK version section of the Gradle configuration. But, this is forcing me to debug on a device which is using the same Android version when debugging. If I don't, then the sources won't be in sync with the debugger.
My question: Is there an easy way to switch between Android sources in Android Studio without having to change the configuration in build.gradle?
Try this:
mv $ANDROID_HOME/sources/android-21 $ANDROID_HOME/sources/android-21-orig
cp $ANDROID_HOME/sources/android-17 $ANDROID_HOME/sources/android-21
Restart android studio so it will pick up the correct paths.
Debug
NodeJS program to easily switch the Android SDK Sources which Android Studio attaches when debugging.
I think studio grabs the Android SDK platform source from the targetSDKVersion.
It's wise to update the targetSDKVersion to the latest Android platform SDK from your SDK manager.
It's better for development if your project constraints you from increasing the targetSDKVersion grab the platform SDK your project mentions.
Android platform SDK's
I am a newbie to Android programming. I am using Android Studio 1.1.0
I have following query regarding building an app using gradle.
What is the purpose of specifying buildscript dependencies 'com.android.tools.build:gradle:1.1.0' in build.gradle
What does this build statement actually do.
I have searched the forum but could not find anything specific on this.
However from some of the google search it seems to suggest that this statement might be required for the gradle script to download Android Plugin for gradle.
I find it surprising that though I am using Android Studio I still need to download Android Plugin for gradle. Should it not be coming in-built.
Appreciate your time and help
As the name suggest, "Android Build Tools" is a command line tools for building your Java source code (along with all the related assets) into executable APK file. It's located at your Android SDK directory (usually at $ANDROID_HOME) and can be updated using Android SDK manager (accessible via Android Studio IDE).
What is the purpose of specifying buildscript dependencies com.android.tools.build:gradle:1.1.0 in build.gradle
Android is using Gradle build system. That build script dependency is Gradle plugin to interact (compile, test, etc) with the Android Build Tools. That line declares that your project require Android's Gradle plugin version 1.1.0.
I find it surprising that though I am using Android Studio I still need to download Android Plugin for gradle. Should it not be coming in-built.
Android Studio (AS) is just an IDE, you can actually use any IDE that support Gradle build system. Android Build Tools and its Gradle plugin (it's not AS plugin) is constantly updated by the devs separated from Android Studio project (although it's pretty closely related). Moreover, different projects can requires different version of build tools and its Gradle plugins. So it's just make sense that Android Studio requires them to be downloaded independently from the IDE.
I am trying a sample app for Tizen Wearable SDK but the IDE does not seem to be configured properly. It reports imports could not be resolved library and the samsung android libraries. My guess is these dependencies need to be added to the project's path somehow.
I tried adding external classes from the Tizen Wearable SDK
UPDATE
I have tried to install the ADT Plugin but I get stuck on the license screen
You don't have the Android plugins for Eclipse installed from what I can see on your preferences panel. The Tizen IDE, out of the box, only supports the Tizen Wearable build.
You will need to install the Android Development Tools (ADT) plugins for Eclipse and then point the preferences at the SDK. That will clear up your Android SDK build errors. Then you just need to add the Samsung SDK jars to your project if they still fail to build. The samples should already have the links to SDK jars in them, so just getting the plugins installed is your first step.
Here's a blog post I wrote on the subject a few months ago. Skip to the TL;DR part. But, the short answer is, add the ADT plugins by adding a new install site that points to
https://dl-ssl.google.com/android/eclipse/
You will not be able to install the Native Development Tools component due to a conflict with CDT versions, so uncheck that.
You can try using the Tizen IDE to create the HelloAccessoryConsumer (wearable part) and a separate Eclipse IDE with ADT plugin to create the HelloAccessoryProvider (Android part). Then add the .wgt file which is generated in the HelloAccessoryConsumer project to the assets folder in the HelloAccessoryProvider project.