Reputation: 669
I used Unity Hub downloaded latest Unity Editor, it works fine for editor,document and language packs, but can not download android build support. Just told me download failed many many times in the past two days.
So I downloaded UnitySetup-Android-Support-for-Editor-2018.2.16f1.pkg
from webpage. This package install reported failed at the end of every try.This package size(348.9M) is not same as the one showed(365.8M) in UnityHub download list.
There is a 2017 version Unity Editor installed by download **.pkg, but the support installer never ask me about Editor's location.
Is there some way to install android build support manually?
Thanks for any tips.
Upvotes: 2
Views: 35183
Reputation: 11
Download pkg:
Head to this page, select your specific unity version from the dropdown at the right.
For those modules that arent listed in linux section, download the pkg from the mac section.
7z x -o* UnitySetup-XXXXXX-Support-for-Editor-2022.1.16f1.pkg
bsdtar -xf UnitySetup-XXXXXX-Support-for-Editor-2022.1.16f1.pkg TargetSupport.pkg.tmp/Payload
Move the extracted "Payload" file to one of these directories:
{UNITY_PATH}/Editor/Data/PlaybackEngines/AndroidPlayer
{UNITY_PATH}/Editor/Data/PlaybackEngines/WindowsStandaloneSupport
{UNITY_PATH}/Editor/Data/PlaybackEngines/MacStandaloneSupport
zcat Payload | cpio -iu && rm Payload
or if it's named Payload~ just extract it:
cpio -iu < Payload~ && rm Payload~
Upvotes: 1
Reputation: 512
This worked for me. To anyone facing this problem. I apologize for my long explanation and my english.
You can verify if *.pkg file is complete by comparing the checksum (I use dolphin)
Execute this command to manually install your UnitySetup-Android-Support-for-Editor-*.pkg
:~> ./UnitySetup-2019.1.0f2 -u --use-component-list unity-2019.1.0f2-linux.ini --install-location $HOME/2019.1.6f1/ -d $HOME
Note that the unity version must be compatible, otherwise you will have the error unable to initialize the Unity engine in you android device. I use:
UnitySetup-Android-Support-for-Editor-2019.1.6f1
Unity-2019.1.6f1
As much as possible use unity hub to install the android add-on, I use unity hub 2.0.1
Step by step explanation of the installation manually of *.pkg
The problem :(
I will put them in context.
I use opensuse tumbleweed. My problem was that I did not have android build support. No Android module loaded image, and when I press open download page, the browser shows me a message:
<Error> <Code>AccessDenied</Code> <Message>Access denied.</Message> <Details> Anonymous caller does not have storage.objects.get access to publishing-unity-binaries-prd/6e9a27477296/Unknown/UnitySetup-Android-Support-for-Editor-2018.3.0f2. </Details> </Error>
and I can not do anything else.
The SOLUTION :)
0.- Previous requirements
I already had my previous installation this file:
UnitySetup-2019.1.0f2
1.- Download UnitySetup-Android-Support-for-Editor-2019.1.x.pkg
To achieve this look for UnitySetup-Android-Support-for-Editor- in the file https://public-cdn.cloud.unity3d.com/hub/prod/releases-linux.json
This is a fragment of release-linux.json file
... { "id": "android", "name": "Android Build Support", "description": "Allows building your Unity projects for the Android platform", "downloadUrl": "h ttps://download.unity3d.com/download_unity/f2970305fe1c/MacEditorTargetInstaller/UnitySetup-Android-Support-for-Editor-2019.1.6f1.pkg", "category": "Platforms", "installedSize": 1958542000, "downloadSize": 664332318, "visible": true, "selected": false, "destination": "{UNITY_PATH}/Editor/Data/PlaybackEngines/AndroidPlayer", "checksum": "d00addecefb7babcb9cd6a8085672908" } ...
What interests us about this file is the url to download https://download.unity3d.com/download_unity/f2970305fe1c/MacEditorTargetInstaller/UnitySetup-Android-Support-for-Editor-2019.1.6f1.pkg and the checksum.
2.- Component list file
Download the file from the list of components from here or create a file like unity-2019.1.0f2-linux.ini
:
[Android]
title=Android Build Support
description=Allows building your Unity projects for the Android platform
url=MacEditorTargetInstaller/UnitySetup-Android-Support-for-Editor-2019.1.6f1.pkg
md5=d00addecefb7babcb9cd6a8085672908
install=true
mandatory=false
size=365578263
installedsize=1259081000
requires_unity=false
for [Android] install=true, the url and md5 which is the checksum from the previous step (or again I get md5 with dolphin to verify)
3.- Installation
Have the following files in the same directory that in my case are in $HOME
UnitySetup-2019.1.0f2
UnitySetup-Android-Support-for-Editor-2019.1.6f1.pkg
unity-2019.1.0f2-linux.ini
Finally, execute the following command line. (Note that my current unity installation is in $HOME/2019.1.6f1/).
:~> ./UnitySetup-2019.1.0f2 -u --use-component-list unity-2019.1.0f2-linux.ini --install-location $HOME/Unity-2019.1.6f1/ -d $HOME
Thanks
Source
https://forum.unity.com/threads/how-to-install-editor-packages.554977/
Upvotes: 3
Reputation: 91
Download the Android Sdk Manager under Command line tools only. And download the SDK you need, then link it to Unity.
I usually download AndroidStudio and it comes with a GUI manager. Here is some more info about how to update sdk tools.
You link it here: Edit/Preferences/External Tools
Upvotes: 1
Reputation:
According to this:
Possible causes could be:
A corrupt package (download again manually from the list of individual packages)
Filesystem corruption (repair disk from single-user mode, reboot and try again)
The user account somehow not being in the sudoers group (deeper technical problem - check Apple's forums)
Package file stored on a drive formatted weirdly, so execute permissions aren't set correctly (pre-/post-installation script won't run; move to boot drive)
Upvotes: 0