I recently recovered my ionic source code from a crashed PC and tried setting up a new PC, after the installations of the required files. I tried building the project, but got an error as below. I have been trying to figure out where and how to update the AndroidManifest.xml
to reflect the suggestion in the error message. Any help to resolve this and build my project would be welcome.
output from the build terminal:'
BUILD FAILED
Total time: 2 mins 19.549 secs
FAILURE: Build failed with an exception.
- What went wrong: Execution failed for task ':processDebugManifest'.
Manifest merger failed : Attribute meta-data#android.support.VERSION@value value=(25.4.0) from [com.android.support:appcompat-v7:25.4.0] AndroidManifest.xml:28:13-35 is also present at [com.android.support:support-v4:26.1.0] AndroidManifest.xml:28:13-35 value=(26.1.0). Suggestion: add 'tools:replace="android:value"' to element at AndroidManifest.xml:26:9-28:38 to override.
Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
(node:8808) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: cmd: Command failed with exit code 1 Error output: Note: Some input files use or override a deprecated API. Note: Recompile with -Xlint:deprecation for details. Note: Some input files use or override a deprecated API. Note: Recompile with -Xlint:deprecation for details. C:\wamp64\www\myapp\platforms\android\AndroidManifest.xml:28:13-35 Error: Attribute meta-data#android.support.VERSION@value value=(25.4.0) from [com.android.support:appcompat-v7:25.4.0] AndroidManifest.xml:28:13-35 is also present at [com.android.support:support-v4:26.1.0] AndroidManifest.xml:28:13-35 value=(26.1.0).
Suggestion:
add 'tools:replace="android:value"' to element at AndroidManifest.xml:26:9-28:38 to override.
FAILURE: Build failed with an exception.
- What went wrong: Execution failed for task ':processDebugManifest'.
Manifest merger failed : Attribute meta-data#android.support.VERSION@value value=(25.4.0) from [com.android.support:appcompat-v7:25.4.0] AndroidManifest.xml:28:13-35 is also present at [com.android.support:support-v4:26.1.0] AndroidManifest.xml:28:13-35 value=(26.1.0). Suggestion: add 'tools:replace="android:value"' to element at AndroidManifest.xml:26:9-28:38 to override. * Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
package.json file
{
"name": "myapp",
"version": "0.0.1",
"author": "Ionic Framework",
"homepage": "http://ionicframework.com/",
"private": true,
"scripts": {
"clean": "ionic-app-scripts clean",
"build": "ionic-app-scripts build",
"lint": "ionic-app-scripts lint",
"ionic:build": "ionic-app-scripts build",
"ionic:serve": "ionic-app-scripts serve"
},
"dependencies": {
"@angular/common": "4.4.3",
"@angular/compiler": "4.4.3",
"@angular/compiler-cli": "4.4.3",
"@angular/core": "4.4.3",
"@angular/forms": "4.4.3",
"@angular/http": "4.4.3",
"@angular/platform-browser": "4.4.3",
"@angular/platform-browser-dynamic": "4.4.3",
"@ionic-native/app-minimize": "^4.4.2",
"@ionic-native/call-number": "^4.5.2",
"@ionic-native/camera": "^4.5.2",
"@ionic-native/core": "4.3.2",
"@ionic-native/crop": "^4.3.2",
"@ionic-native/deeplinks": "^4.5.2",
"@ionic-native/fcm": "^4.3.2",
"@ionic-native/file": "^4.3.2",
"@ionic-native/file-chooser": "^4.3.2",
"@ionic-native/file-path": "^4.3.2",
"@ionic-native/file-transfer": "^4.3.2",
"@ionic-native/firebase-dynamic-links": "^4.5.2",
"@ionic-native/geolocation": "^4.4.2",
"@ionic-native/image-picker": "^4.3.2",
"@ionic-native/image-resizer": "^4.5.2",
"@ionic-native/in-app-browser": "^4.3.3",
"@ionic-native/keyboard": "^4.4.2",
"@ionic-native/native-audio": "^4.4.2",
"@ionic-native/native-page-transitions": "^4.5.2",
"@ionic-native/sim": "^4.3.2",
"@ionic-native/sms": "^4.5.2",
"@ionic-native/social-sharing": "^4.5.2",
"@ionic-native/splash-screen": "4.3.2",
"@ionic-native/status-bar": "4.3.2",
"@ionic/storage": "2.0.1",
"angular4-paystack": "^2.0.0",
"angularfire2": "^5.0.0-rc.3",
"call-number": "^1.0.1",
"chart.js": "^2.7.1",
"com.synconset.imagepicker": "~2.1.8",
"com.telerik.plugins.nativepagetransitions": "^0.6.5",
"cordova-android": "~6.3.0",
"cordova-plugin-appminimize": "^1.0.0",
"cordova-plugin-camera": "^4.0.1",
"cordova-plugin-compat": "^1.2.0",
"cordova-plugin-crop": "^0.4.0",
"cordova-plugin-device": "^1.1.4",
"cordova-plugin-fcm": "^2.1.2",
"cordova-plugin-file": "^4.3.3",
"cordova-plugin-file-transfer": "^1.6.3",
"cordova-plugin-filechooser": "^1.0.1",
"cordova-plugin-filepath": "^1.1.0",
"cordova-plugin-geolocation": "^4.0.1",
"cordova-plugin-inappbrowser": "^1.7.1",
"cordova-plugin-ionic-webview": "^1.1.16",
"cordova-plugin-nativeaudio": "^3.0.9",
"cordova-plugin-sim": "^1.3.3",
"cordova-plugin-splashscreen": "^4.0.3",
"cordova-plugin-statusbar": "^2.2.3",
"cordova-plugin-telerik-imagepicker": "^2.1.8",
"cordova-plugin-whitelist": "^1.3.1",
"cordova-plugin-x-socialsharing": "^5.2.1",
"cordova-support-google-services": "^1.0.0",
"es6-promise-plugin": "^4.1.0",
"firebase": "^4.6.0",
"info.protonet.imageresizer": "^0.1.1",
"ionic-angular": "3.7.1",
"ionic-plugin-deeplinks": "^1.0.15",
"ionic-plugin-keyboard": "^2.2.1",
"ionicons": "3.0.0",
"moment": "^2.19.2",
"mx.ferreyra.callnumber": "~0.0.2",
"rxjs": "5.4.3",
"sw-toolbox": "3.6.0",
"zone.js": "0.8.18"
},
"devDependencies": {
"@ionic/app-scripts": "3.0.1",
"typescript": "2.3.4"
},
"description": "An Ionic project",
"cordova": {
"plugins": {
"ionic-plugin-keyboard": {},
"cordova-plugin-whitelist": {},
"cordova-plugin-device": {},
"cordova-plugin-splashscreen": {},
"cordova-plugin-ionic-webview": {},
"cordova-plugin-sim": {},
"com.synconset.imagepicker": {
"PHOTO_LIBRARY_USAGE_DESCRIPTION": "select image"
},
"cordova-plugin-crop": {},
"cordova-plugin-file": {},
"cordova-plugin-filepath": {},
"cordova-plugin-filechooser": {},
"cordova-plugin-file-transfer": {},
"cordova-plugin-inappbrowser": {},
"cordova-plugin-appminimize": {},
"cordova-plugin-nativeaudio": {},
"cordova-plugin-x-socialsharing": {},
"mx.ferreyra.callnumber": {},
"cordova-plugin-geolocation": {},
"com.telerik.plugins.nativepagetransitions": {},
"ionic-plugin-deeplinks": {
"URL_SCHEME": "myappapp",
"DEEPLINK_SCHEME": "https",
"DEEPLINK_HOST": "myappmobile.firebaseapp.com",
"ANDROID_PATH_PREFIX": "/myapppp",
"ANDROID_2_PATH_PREFIX": "/",
"ANDROID_3_PATH_PREFIX": "/",
"ANDROID_4_PATH_PREFIX": "/",
"ANDROID_5_PATH_PREFIX": "/",
"DEEPLINK_2_SCHEME": " ",
"DEEPLINK_2_HOST": " ",
"DEEPLINK_3_SCHEME": " ",
"DEEPLINK_3_HOST": " ",
"DEEPLINK_4_SCHEME": " ",
"DEEPLINK_4_HOST": " ",
"DEEPLINK_5_SCHEME": " ",
"DEEPLINK_5_HOST": " "
},
"info.protonet.imageresizer": {},
"cordova-plugin-camera": {},
"cordova-plugin-fcm": {},
"cordova-plugin-compat": {}
},
"platforms": [
"android"
]
}
}