Androidstudio import internal dependency module summary, androidstudio Module
Today, I just found a good project from GitHub and want to import it into my own project. I also encountered some minor problems during the process. I would like to summarize it for review !!!!
1. First, extract the compressed package downloaded from GitHub, find the project file, and copy and paste it in the folder of the project you want to import !!! Then Build> Rebuild the Project and re-Build the Project.
2. An error occurred while building the file. Error Type:
Error: Execution failed for task': app: processDebugManifest '.
> Manifest merger failed: Attribute application @ icon value = (@ mipmap/ic_launcher) from AndroidManifest. xml: 7: 9-43
Is also present at [com. github. frank-zhu: pullzoomview: 1.0.0] AndroidManifest. xml: 13: 9-45 value = (@ drawable/ic_launcher ).
Suggestion: add'tools: replace = "android: icon" 'to <application> element at AndroidManifest. xml: 5: 5-18:19 to override.
3. solution: In Manifest. add tools: replace = "android: icon" to the application in the xml file. (If Theme conflicts, write: tools: replace = "android: icon, android: theme ") remember to add xmlns: tools = "http://schemas.android.com/toolsto the manifest and tag.
4. A Project can contain many modules that are completely independent from each other or dependent on each other. If you want a module to be dependent on one or more other modules, You need to declare the current Module as Library in the build. gradle file of the module.
You cannot use: apply plugin: 'com. android. application'
To use: appli plugin: 'com. android. library'
Then, you need to include the module name in the settings. gradle file under the top-level project directory.
Include ': app', 'moudle-name'
This is a success !!!