- Home /
CommandInvokationFailure: Failed to re-package resources.
Hi there. I have a problem with building for android. All other platforms work fine. I have been looking through the other answers but can't seem to find any solutions. I have been looking for duplicates, and tried to delete google play services and reinstalling and everything. Is anybody here able to see what the error is? Thanks a lot. Rune
CommandInvokationFailure: Failed to re-package resources. /Users/Rune/Library/Android/sdk/build-tools/25.0.3/aapt package --auto-add-overlay -v -f -m -J "gen" -M "AndroidManifest.xml" -S "res" -I "/Users/Rune/Library/Android/sdk/platforms/android-25/android.jar" -F bin/resources.ap_ --extra-packages com.android.vending.billing:com.google.unity.ads:com.unity.purchasing.googleplay:com.google.example.games.mainlibproj:android.support.graphics.drawable.animated:android.support.v7.appcompat:android.support.v7.cardview:com.unity.purchasing:android.support.customtabs:com.facebook:com.facebook:com.facebook.android:com.facebook.android:com.google.android.gms.ads.impl:com.google.android.gms.ads:com.google.android.gms.auth.api:com.google.android.gms.auth:com.google.android.gms.base:com.google.android.gms:com.google.android.gms.clearcut:com.google.android.gms.drive:com.google.android.gms.games:com.google.android.gms.gass:com.google.android.gms.nearby:com.google.android.gms.safetynet:com.google.android.gms.tasks:android.support.compat:android.support.coreui:android.support.coreutils:android.support.fragment:android.support.mediacompat:android.support.v4:android.support.graphics.drawable:com.unity3d.ads -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/GoogleAIDL/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/GooglePlay/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/animated-vector-drawable-23.4.0/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/cardview-v7-23.4.0/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/common/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/customtabs-23.4.0/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/facebook-android-sdk-4.17.0/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/facebook-android-sdk-4.7.0/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/facebook-android-wrapper-7.9.4/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/facebook-android-wrapper-release/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/play-services-ads-11.0.2/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/play-services-ads-lite-11.0.2/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/play-services-auth-11.0.2/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/play-services-auth-base-11.0.2/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/play-services-base-11.0.2/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/play-services-basement-11.0.2/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/play-services-clearcut-11.0.2/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/play-services-drive-11.0.2/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/play-services-games-11.0.2/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/play-services-gass-11.0.2/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/play-services-nearby-11.0.2/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/play-services-safetynet-11.0.2/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/play-services-tasks-11.0.2/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/support-compat-25.2.0/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/support-core-ui-25.2.0/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/support-core-utils-25.2.0/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/support-fragment-25.2.0/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/support-media-compat-25.2.0/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/support-v4-25.2.0/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/support-vector-drawable-23.4.0/res" -S "/Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/unity-ads/res"
stderr[ /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/abc_alert_dialog_button_bar_material.xml:18: note: removing attribute http://schemas.android.com/apk/res/android:layoutDirection from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/abc_alert_dialog_button_bar_material.xml: note: using v17 attributes; synthesizing resource com.rudie.trumpvsliberty:layout/abc_alert_dialog_button_bar_material for configuration v17. /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/abc_alert_dialog_material.xml:48: note: removing attribute http://schemas.android.com/apk/res/android:textAlignment from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/abc_alert_dialog_material.xml: note: using v17 attributes; synthesizing resource com.rudie.trumpvsliberty:layout/abc_alert_dialog_material for configuration v17. /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/abc_dialog_title_material.xml:29: note: removing attribute http://schemas.android.com/apk/res/android:textAlignment from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/abc_dialog_title_material.xml: note: using v17 attributes; synthesizing resource com.rudie.trumpvsliberty:layout/abc_dialog_title_material for configuration v17. /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/abc_screen_toolbar.xml:27: note: removing attribute http://schemas.android.com/apk/res/android:touchscreenBlocksFocus from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/abc_screen_toolbar.xml: note: using v21 attributes; synthesizing resource com.rudie.trumpvsliberty:layout/abc_screen_toolbar for configuration v21. /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/abc_search_view.xml:47: note: removing attribute http://schemas.android.com/apk/res/android:layoutDirection from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/abc_search_view.xml: note: using v17 attributes; synthesizing resource com.rudie.trumpvsliberty:layout/abc_search_view for configuration v17. /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/facebook-android-sdk-4.17.0/res/layout/com_facebook_device_auth_dialog_fragment.xml:80: note: removing attribute http://schemas.android.com/apk/res/android:layout_marginEnd from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/facebook-android-sdk-4.17.0/res/layout/com_facebook_device_auth_dialog_fragment.xml:80: note: removing attribute http://schemas.android.com/apk/res/android:layout_marginStart from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/facebook-android-sdk-4.17.0/res/layout/com_facebook_device_auth_dialog_fragment.xml: note: using v17 attributes; synthesizing resource com.rudie.trumpvsliberty:layout/com_facebook_device_auth_dialog_fragment for configuration v17. /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/facebook-android-sdk-4.17.0/res/layout/com_facebook_smart_device_dialog_fragment.xml:112: note: removing attribute http://schemas.android.com/apk/res/android:layout_marginStart from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/facebook-android-sdk-4.17.0/res/layout/com_facebook_smart_device_dialog_fragment.xml:112: note: removing attribute http://schemas.android.com/apk/res/android:layout_marginEnd from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/facebook-android-sdk-4.17.0/res/layout/com_facebook_smart_device_dialog_fragment.xml:47: note: removing attribute http://schemas.android.com/apk/res/android:layout_marginStart from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/facebook-android-sdk-4.17.0/res/layout/com_facebook_smart_device_dialog_fragment.xml: note: using v17 attributes; synthesizing resource com.rudie.trumpvsliberty:layout/com_facebook_smart_device_dialog_fragment for configuration v17. /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_big_media.xml:42: note: removing attribute http://schemas.android.com/apk/res/android:layoutDirection from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_big_media.xml:34: note: removing attribute http://schemas.android.com/apk/res/android:layout_marginStart from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_big_media.xml:34: note: removing attribute http://schemas.android.com/apk/res/android:layout_toStartOf from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_big_media.xml: note: using v17 attributes; synthesizing resource com.rudie.trumpvsliberty:layout/notification_template_big_media for configuration v17. /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_big_media_narrow.xml:60: note: removing attribute http://schemas.android.com/apk/res/android:layout_toEndOf from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_big_media_narrow.xml:46: note: removing attribute http://schemas.android.com/apk/res/android:layout_toEndOf from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_big_media_narrow.xml:46: note: removing attribute http://schemas.android.com/apk/res/android:layoutDirection from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_big_media_narrow.xml:38: note: removing attribute http://schemas.android.com/apk/res/android:layout_marginStart from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_big_media_narrow.xml:38: note: removing attribute http://schemas.android.com/apk/res/android:layout_toStartOf from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_big_media_narrow.xml:30: note: removing attribute http://schemas.android.com/apk/res/android:layout_alignParentEnd from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_big_media_narrow.xml: note: using v17 attributes; synthesizing resource com.rudie.trumpvsliberty:layout/notification_template_big_media_narrow for configuration v17. /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_lines.xml:18: note: removing attribute http://schemas.android.com/apk/res/android:paddingEnd from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_lines.xml:77: note: removing attribute http://schemas.android.com/apk/res/android:layout_marginStart from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_lines.xml:96: note: removing attribute http://schemas.android.com/apk/res/android:paddingStart from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_lines.xml:64: note: removing attribute http://schemas.android.com/apk/res/android:layout_marginStart from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_lines.xml:27: note: removing attribute http://schemas.android.com/apk/res/android:layout_marginStart from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_lines.xml: note: using v17 attributes; synthesizing resource com.rudie.trumpvsliberty:layout/notification_template_lines for configuration v17. /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_media.xml:43: note: removing attribute http://schemas.android.com/apk/res/android:layout_marginEnd from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_media.xml:33: note: removing attribute http://schemas.android.com/apk/res/android:layoutDirection from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_media.xml: note: using v17 attributes; synthesizing resource com.rudie.trumpvsliberty:layout/notification_template_media for configuration v17. /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_part_chronometer.xml:18: note: removing attribute http://schemas.android.com/apk/res/android:paddingStart from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_part_chronometer.xml: note: using v17 attributes; synthesizing resource com.rudie.trumpvsliberty:layout/notification_template_part_chronometer for configuration v17. /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_part_time.xml:18: note: removing attribute http://schemas.android.com/apk/res/android:paddingStart from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/notification_template_part_time.xml: note: using v17 attributes; synthesizing resource com.rudie.trumpvsliberty:layout/notification_template_part_time for configuration v17. /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/select_dialog_multichoice_material.xml:18: note: removing attribute http://schemas.android.com/apk/res/android:paddingStart from /Users/Rune/Documents/Unity/Trump Vs Liberty/Temp/StagingArea/android-libraries/appcompat-v7-23.4.0/res/layout/select_dialog_multichoice_material.xml:18: note: removing attribute http://schemas.android
Answer by RuneSoegaard · Jul 19, 2017 at 02:56 PM
Okay, I figured out that there was some kind of problem with have both google play services and the facebook sdk at the same time. So I kind of solved it by sacrificing the facebook sdk.
Answer by Soniya_unity · Jul 20, 2017 at 09:28 AM
remove duplication of system_V4 file. in the project window type V4 in search bar. if you find more than v4 file then delete one which is in the facebook SDK.
if not working then tell me which plugins you combine in your project?