Using the new “manifestmerger” property in Android

Add the following line to your project.properties file of your application project. manifestmerger.enabled=true Introduced with Android SDK Tools, Revision 20 (June 2012): https://developer.android.com/studio/releases/sdk-tools Build System     * Added automatic merging of library project manifest files into the including project’s manifest.       Enable this feature with the manifestmerger.enabled property.

Convert existing project to library project in Android Studio

In your module’s build.gradle file (not the root project, if you use modules!), simply replace: apply plugin: ‘com.android.application’ // or, if you’re on an old version apply plugin: ‘android’ // note: this one is deprecated …with: apply plugin: ‘com.android.library’ // or, if you’re on an old version apply plugin: ‘android-library’ // note: this one is … Read more

Android support multidex library implementation

The Blog was the old solution. With Android Studio 0.9.2 & Gradle Plugin 0.14.1, you only need to: Add to AndroidManifest.xml: . android:name=”android.support.multidex.MultiDexApplication” or Add MultiDex.install(this); in your custom Application’s attachBaseContext method or your custom Application extend MultiDexApplication add multiDexEnabled = true in your build.gradle . android { defaultConfig { … multiDexEnabled = true } … Read more

Using an Android library project Activity within another project

I believe you must include the <activity> in your own AndroidManifest.xml — I don’t think it gets picked up from a library. I don’t have my reference for that handy. Update: It’s official solution. From the doc: Declaring library components in the manifest file In the manifest file of the application project, you must add … Read more

java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader

I am currently working on an Android application which streams radio. I use native decoder library which is called aacdecoder. Everything was fine till app gets crash error on some Android devices. It was really annoying. Because app was perfectly plays radio streams almost all devices but Samsung S6 and S6 Edge. Crash report says … Read more

Debug native code in Android Library

I was able to set breakpoints and debug native code in an android library on eclipse by adding the directory of the unstripped shared library/libraries to the debugger in the debug configurations dialog: Go to “Run” menu-> “Debug Configurations” Under “Android Native Application” in the left pane, select your application Under the “Debugger” tab click … Read more

tech