-
Notifications
You must be signed in to change notification settings - Fork 93
Getting Started
Historically this project used Maven as build system with Android Maven Plugin. At that time it was the best choice to build an Android application. Regarding the evolution of Android and Android tools we decided to switch to Gradle .
So starting from version 1.5 the Alfresco Android Application can be build only with Gradle and Android Studio
Even if it's possible to create the Android application via gradle command line, we heavily recommends to use Android Studio.
Please follow the Prerequisites if you haven't Android Studio installed and configured.
First you need to configure the type in gradle.properties
- Open gradle.properties file
- Find DEFAULT_PUBLISH key and replace debug value by release (if necessary)
Next you need to change Build Variant Type
- Open Build Variants View
- Select release for foundation project
- Select customRelease for alfresco-mobile-android project
- Wait the end of the automatic build
- Launch the application
- APK is available at Root project folder\alfresco-mobile-android\build\outputs\apk
- Your application file is : alfresco-mobile-android-custom-release-X.X.X-SNAPSHOT.apk
NB: The application can be build on Debug Mode or Release Mode. In Debug you can replace all previous mentions of release & customRelease by debug and customDebug.
- Open a Command Prompt in root project folder
- Tap and execute **gradlew assembleCustomRelease -PDEFAULT_PUBLISH=release **
- Wait the end of the build
- Go to Root project folder\alfresco-mobile-android\build\outputs\apk
- Your application file is : alfresco-mobile-android-custom-release-X.X.X-SNAPSHOT.apk
If you encounter messages like
Failed to resolve: com.samsung.android:sdk:1.0.0
Failed to resolve: com.samsung.android.sdk:pen:1.0.2
You can comment
storeCompile project(':extensions:samsung')
in alfresco-android-app\gradle.properties
and comment
include ':extensions:samsung'
in settings.gradle
After that Rebuild/clean Project and/or Sync Project with Gradle Files the project shouldn't integrate the Samsung module at all.
##More informations