Merge branch 'openfl:develop' into submodules
This commit is contained in:
@@ -450,7 +450,7 @@ class AndroidPlatform extends PlatformTarget
|
||||
context.CPP_DIR = targetDirectory + "/obj";
|
||||
context.OUTPUT_DIR = targetDirectory;
|
||||
context.ANDROID_INSTALL_LOCATION = project.config.getString("android.install-location", "auto");
|
||||
context.ANDROID_MINIMUM_SDK_VERSION = project.config.getInt("android.minimum-sdk-version", 16);
|
||||
context.ANDROID_MINIMUM_SDK_VERSION = project.config.getInt("android.minimum-sdk-version", 21);
|
||||
context.ANDROID_TARGET_SDK_VERSION = project.config.getInt("android.target-sdk-version", 28);
|
||||
context.ANDROID_EXTENSIONS = project.config.getArrayString("android.extension");
|
||||
context.ANDROID_PERMISSIONS = project.config.getArrayString("android.permission", [
|
||||
|
||||
@@ -207,6 +207,20 @@ class MacPlatform extends PlatformTarget
|
||||
if (noOutput) return;
|
||||
|
||||
HashlinkHelper.copyHashlink(project, targetDirectory, executableDirectory, executablePath, is64);
|
||||
|
||||
// HashLink looks for hlboot.dat and libraries in the current
|
||||
// working directory, so the .app file won't work properly if it
|
||||
// tries to run the HashLink executable directly.
|
||||
// when the .app file is launched, we can tell it to run a shell
|
||||
// script instead of the HashLink executable. the shell script will
|
||||
// adjusts the working directory before running the HL executable.
|
||||
|
||||
// unlike other platforms, we want to use the original "hl" name
|
||||
var hlExecutablePath = Path.combine(executableDirectory, "hl");
|
||||
System.renameFile(executablePath, hlExecutablePath);
|
||||
System.runCommand("", "chmod", ["755", hlExecutablePath]);
|
||||
// then we can use the executable name for the shell script
|
||||
System.copyFileTemplate(project.templatePaths, 'hl/mac-launch.sh', executablePath);
|
||||
}
|
||||
else if (targetType == "java")
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user