Install mac modules based on target platform for greater flexibility (#481)

This commit is contained in:
AndrewKahr
2022-12-14 01:27:36 -08:00
committed by GitHub
parent 5bd589e19f
commit 9329b7369c
3 changed files with 31 additions and 9 deletions
Generated Vendored
+14 -4
View File
@@ -6852,11 +6852,21 @@ class SetupMac {
static installUnity(buildParameters, silent = false) {
return __awaiter(this, void 0, void 0, function* () {
const unityChangeset = yield unity_changeset_1.getUnityChangeset(buildParameters.editorVersion);
const command = `${this.unityHubPath} -- --headless install \
let command = `${this.unityHubPath} -- --headless install \
--version ${buildParameters.editorVersion} \
--changeset ${unityChangeset.changeset} \
--module mac-il2cpp \
--childModules`;
--changeset ${unityChangeset.changeset} `;
switch (buildParameters.targetPlatform) {
case 'iOS':
command += `--module ios `;
break;
case 'StandaloneOSX':
command += `--module mac-il2cpp `;
break;
case 'android':
command += `--module android `;
break;
}
command += `--childModules`;
// Ignoring return code because the log seems to overflow the internal buffer which triggers
// a false error
const errorCode = yield exec_1.exec(command, undefined, { silent, ignoreReturnCode: true });
Generated Vendored
+1 -1
View File
File diff suppressed because one or more lines are too long
+16 -4
View File
@@ -32,11 +32,23 @@ class SetupMac {
private static async installUnity(buildParameters: BuildParameters, silent = false) {
const unityChangeset = await getUnityChangeset(buildParameters.editorVersion);
const command = `${this.unityHubPath} -- --headless install \
let command = `${this.unityHubPath} -- --headless install \
--version ${buildParameters.editorVersion} \
--changeset ${unityChangeset.changeset} \
--module mac-il2cpp \
--childModules`;
--changeset ${unityChangeset.changeset} `;
switch (buildParameters.targetPlatform) {
case 'iOS':
command += `--module ios `;
break;
case 'StandaloneOSX':
command += `--module mac-il2cpp `;
break;
case 'android':
command += `--module android `;
break;
}
command += `--childModules`;
// Ignoring return code because the log seems to overflow the internal buffer which triggers
// a false error