diff --git a/.gitignore b/.gitignore index 985acf46..6ffad943 100644 --- a/.gitignore +++ b/.gitignore @@ -3,6 +3,7 @@ /.gradle /.idea /tmp -server/test-data/sdk/** +!server/test-data/sdk/ +server/test-data/sdk/* !server/test-data/sdk/a diff --git a/server/docker-base/Dockerfile b/server/docker-base/Dockerfile index f75f398c..5bd66196 100644 --- a/server/docker-base/Dockerfile +++ b/server/docker-base/Dockerfile @@ -10,7 +10,6 @@ RUN \ echo oracle-java8-installer shared/accepted-oracle-license-v1-1 select true | debconf-set-selections && \ apt-get install -y --no-install-recommends \ oracle-java8-installer \ - wine \ gcc \ g++ \ libssl-dev \ @@ -70,16 +69,7 @@ ENV S3_URL https://s3-eu-west-1.amazonaws.com/defold-packages RUN wget -q -O - ${S3_URL}/clang%2Bllvm-3.9.0-x86_64-linux-gnu-ubuntu-16.04.tar.xz | tar xJ -C /usr/local --strip-components=1 -# Windows -ENV PROGRAM_FILES "/root/.wine/drive_c/Program Files" - -RUN \ - mkdir -p "/root/.wine/drive_c/windows/system32" && \ - wget -P /usr/bin ${S3_URL}/prepreg-vc10-dx09-32.exe && \ - ls /root/.wine/drive_c/windows/system32 && \ - mkdir -p "${PROGRAM_FILES}" && \ - wget -q -O - ${S3_URL}/Microsoft-Visual-Studio-10.0.tar.gz | tar xz -C "${PROGRAM_FILES}" - +# Darwin RUN locale-gen en_US.UTF-8 ENV LANG en_US.UTF-8 ENV LANGUAGE en_US:en @@ -139,3 +129,57 @@ RUN \ sed '/TEMP_DIR =/d' ${EMSCRIPTEN_CONFIG} && \ echo TEMP_DIR = \'/var/extender/builds\' >> ${EMSCRIPTEN_CONFIG} && \ chmod -R 755 ${EMSCRIPTEN_HOME} + + +# Windows +RUN \ + apt-get install apt-transport-https + +# According to some notes, wine 1.8 is needed for Visual Studio 2015, and Ubuntu 14 only has wine 1.4 +RUN \ + wget https://dl.winehq.org/wine-builds/Release.key && \ + apt-key add Release.key && \ + rm Release.key && \ + apt-add-repository https://dl.winehq.org/wine-builds/ubuntu/ && \ + dpkg --add-architecture i386 && \ + apt-get update && \ + apt-get install -y --install-recommends wine-devel + +ENV PATH ${PATH}:/opt/wine-devel/bin + +ENV PROGRAM_FILES "C:/Program Files (x86)" + +# Grabbed after a call to /bin/x86_amd64\vcvarsx86_amd64.bat (Can probably be trimmed further) +ENV VS140COMNTOOLS "${PROGRAM_FILES}/Microsoft Visual Studio 14.0/Common7/Tools/" +ENV VCINSTALLDIR "${PROGRAM_FILES}/Microsoft Visual Studio 14.0/VC/" +ENV VSINSTALLDIR "${PROGRAM_FILES}/Microsoft Visual Studio 14.0/" +ENV WindowsLibPath "${PROGRAM_FILES}/Windows Kits/8.1/References/CommonConfiguration/Neutral" +ENV WindowsSdkDir "${PROGRAM_FILES}/Windows Kits/8.1/" +ENV WindowsSDKLibVersion "winv6.3/" +ENV WindowsSDKVersion "/" +ENV WindowsSDK_ExecutablePath_x64 "${PROGRAM_FILES}/Microsoft SDKs/Windows/v10.0A/bin/NETFX 4.6.1 Tools/x64/" +ENV WindowsSDK_ExecutablePath_x86 "${PROGRAM_FILES}/Microsoft SDKs/Windows/v10.0A/bin/NETFX 4.6.1 Tools/" + +# Disable all debug messages +ENV WINEDEBUG "-all" + +# Set the wine home to be in a folder that extender will own (Or you'll get the "wine: is not owned by you") +ENV WINEPREFIX "/var/extender/.wine" + +# Initialize Wine (also see next Dockerfile) +# Setup symbolic links for folders to exist in the C:/ space +# Also, for the installed packages, create symlinks without spaces in the paths! +# Once we run wine, the folder is created for the root user, this needs to be chown'ed back to the extender user (see next Dockerfile) + +RUN \ + mkdir -p ${WINEPREFIX} && \ + wine cmd /c echo Initialized Wine folder && \ + chmod -R 755 ${WINEPREFIX} && \ + ln -s /tmp ${WINEPREFIX}/drive_c/tmp && \ + ln -s ${WINEPREFIX}/drive_c/Program\ Files\ \(x86\) ${WINEPREFIX}/drive_c/ProgramFilesx86 && \ + mkdir ${WINEPREFIX}/drive_c/ProgramFilesx86/WindowsKits && \ + wget -q -O - ${S3_URL}/WindowsKits-8.1.tar.gz | tar xz -C ${WINEPREFIX}/drive_c/ProgramFilesx86/WindowsKits && \ + wget -q -O - ${S3_URL}/WindowsKits-10.0.tar.gz | tar xz -C ${WINEPREFIX}/drive_c/ProgramFilesx86/WindowsKits && \ + wget -q -O - ${S3_URL}/Microsoft-Visual-Studio-14-0.tar.gz | tar xz -C ${WINEPREFIX}/drive_c/ProgramFilesx86 && \ + ln -s ${WINEPREFIX}/drive_c/ProgramFilesx86/Microsoft\ Visual\ Studio\ 14.0 ${WINEPREFIX}/drive_c/ProgramFilesx86/MicrosoftVisualStudio14.0 + diff --git a/server/docker/Dockerfile b/server/docker/Dockerfile index 60dab7bd..cebfd9d8 100644 --- a/server/docker/Dockerfile +++ b/server/docker/Dockerfile @@ -5,7 +5,8 @@ RUN \ mkdir -p /var/extender && \ chown extender: /var/extender && \ chown extender: $(readlink -f /usr/bin/java) && \ - chmod +s $(readlink -f /usr/bin/java) + chmod +s $(readlink -f /usr/bin/java) && \ + chown -R extender:extender ${WINEPREFIX} USER extender diff --git a/server/src/main/java/com/defold/extender/Extender.java b/server/src/main/java/com/defold/extender/Extender.java index f753ad32..104d50df 100644 --- a/server/src/main/java/com/defold/extender/Extender.java +++ b/server/src/main/java/com/defold/extender/Extender.java @@ -12,9 +12,6 @@ import java.io.File; import java.io.IOException; import java.nio.charset.Charset; -import java.nio.file.Files; -import java.nio.file.Path; -import java.nio.file.Paths; import java.util.*; import java.util.regex.Matcher; import java.util.regex.Pattern; @@ -27,8 +24,9 @@ class Extender { private final AppManifestConfiguration appManifest; private final String platform; private final File sdk; - private final File extensionSource; - private final File build; + private final File uploadDirectory; + private final File jobDirectory; + private final File buildDirectory; private final PlatformConfig platformConfig; private final ExtensionManifestValidator manifestValidator; private final TemplateExecutor templateExecutor = new TemplateExecutor(); @@ -48,16 +46,38 @@ class Extender { private static final String ANDROID_STL_LIB_PATH = System.getenv("ANDROID_STL_LIB"); private static final String ANDROID_SYSROOT_PATH = System.getenv("ANDROID_SYSROOT"); - Extender(String platform, File extensionSource, File sdk, String buildDirectory) throws IOException, ExtenderException { - this.extensionSource = extensionSource; + Extender(String platform, File sdk, File jobDirectory, File uploadDirectory, File buildDirectory) throws IOException, ExtenderException { + this.jobDirectory = jobDirectory; + this.uploadDirectory = uploadDirectory; + this.buildDirectory = buildDirectory; // Read config from SDK - this.config = Extender.loadYaml(this.extensionSource, new File(sdk.getPath() + "/extender/build.yml"), Configuration.class); + this.config = Extender.loadYaml(uploadDirectory, new File(sdk.getPath() + "/extender/build.yml"), Configuration.class); - // Make sure the Emscripten compiler doesn't pollute the environment - processExecutor.putEnv("EM_CACHE", buildDirectory); + this.platform = platform; + this.sdk = sdk; + this.platformConfig = getPlatformConfig(); + + // LEGACY: Make sure the Emscripten compiler doesn't pollute the environment + processExecutor.putEnv("EM_CACHE", buildDirectory.toString()); + + processExecutor.setCwd(jobDirectory); - Collection allFiles = FileUtils.listFiles(extensionSource, null, true); + if (this.platformConfig != null && this.platformConfig.env != null) { + + HashMap envContext = new HashMap<>(); + envContext.put("build_folder", buildDirectory); + + Set keys = this.platformConfig.env.keySet(); + for (String k : keys) { + String v = this.platformConfig.env.get(k); + v = templateExecutor.execute(v, envContext); + + processExecutor.putEnv(k, v); + } + } + + Collection allFiles = FileUtils.listFiles(uploadDirectory, null, true); List appManifests = allFiles.stream().filter(f -> f.getName().equals("app.manifest")).collect(Collectors.toList()); if (appManifests.size() > 1 ) { @@ -66,17 +86,9 @@ class Extender { if (appManifests.isEmpty()) { this.appManifest = new AppManifestConfiguration(); } else { - this.appManifest = Extender.loadYaml(this.extensionSource, appManifests.get(0), AppManifestConfiguration.class); + this.appManifest = Extender.loadYaml(this.uploadDirectory, appManifests.get(0), AppManifestConfiguration.class); } - this.platform = platform; - this.sdk = sdk; - this.platformConfig = getPlatformConfig(); - - Path buildPath = Paths.get(buildDirectory); - Files.createDirectories(buildPath); - this.build = Files.createTempDirectory(buildPath, "build").toFile(); - this.manifestValidator = new ExtensionManifestValidator(new WhitelistConfig(), this.platformConfig.allowedFlags, this.platformConfig.allowedLibs); // Collect extension directories (used by both buildEngine and buildClassesDex) @@ -137,7 +149,16 @@ static List collectFilesByPath(File dir, String re) { private File uniqueTmpFile(String prefix, String suffix) { File file; do { - file = new File(build, prefix + UUID.randomUUID().toString() + suffix); + file = new File(buildDirectory, prefix + UUID.randomUUID().toString() + suffix); + } while (file.exists()); + + return file; + } + + private File uniqueTmpFile(String pattern) { + File file; + do { + file = new File(buildDirectory, String.format(pattern, UUID.randomUUID().toString())); } while (file.exists()); return file; @@ -178,20 +199,25 @@ static Map mergeContexts(Map originalContext, Ma Set keys = extensionContext.keySet(); for (String k : keys) { - Object v1 = context.get(k); + Object v1 = context.getOrDefault(k, null); Object v2 = extensionContext.get(k); - if (!v1.getClass().equals(v2.getClass())) { + if (v1 != null && !v1.getClass().equals(v2.getClass())) { throw new ExtenderException(String.format("Wrong manifest context variable type for %s: Expected %s, got %s: %s", k, v1.getClass().toString(), v2.getClass().toString(), v2.toString())); } if (!Extender.isListOfStrings((List) v2)) { throw new ExtenderException(String.format("The context variables only support strings or lists of strings. Got %s (type %s)", v2.toString(), v2.getClass().getCanonicalName())); } - if (v1 instanceof List) { + if (v1 != null && v1 instanceof List) { v1 = Extender.mergeLists((List) v1, (List) v2); } - context.put(k, v1); + + if (v1 != null) { + context.put(k, v1); + } else { + context.put(k, v2); + } } return context; } @@ -214,8 +240,6 @@ private static Map createEmptyContext(Map origin @SuppressWarnings("unchecked") private Map context(Map manifestContext) throws ExtenderException { Map context = new HashMap<>(config.context); - context.put("dynamo_home", sdk.getAbsolutePath()); - context.put("platform", this.platform); if (this.platform.contains("android")) { context.put("android_ndk_path", ANDROID_NDK_PATH); @@ -226,7 +250,12 @@ private Map context(Map manifestContext) throws context.put("android_sysroot", ANDROID_SYSROOT_PATH); } - context.putAll(Extender.mergeContexts(platformConfig.context, manifestContext)); + context = Extender.mergeContexts(context, platformConfig.context); + context = Extender.mergeContexts(context, manifestContext); + + // Should not be allowed to be overridden by manifests + context.put("dynamo_home", ExtenderUtil.getRelativePath(jobDirectory, sdk)); + context.put("platform", this.platform); Set keys = context.keySet(); for (String k : keys) { @@ -279,15 +308,15 @@ private List getJars(File extDir) { private File compileFile(int index, File extDir, File src, Map manifestContext) throws IOException, InterruptedException, ExtenderException { List includes = new ArrayList<>(); - includes.add(extDir.getAbsolutePath() + File.separator + "include"); - File o = new File(build, String.format("%s_%d.o", src.getName(), index)); + includes.add( ExtenderUtil.getRelativePath(jobDirectory, new File(extDir, "include") ) ); + File o = new File(buildDirectory, String.format("%s_%d.o", src.getName(), index)); List frameworks = getFrameworks(extDir); List frameworkPaths = getFrameworkPaths(extDir); Map context = context(manifestContext); - context.put("src", src); - context.put("tgt", o); + context.put("src", ExtenderUtil.getRelativePath(jobDirectory, src)); + context.put("tgt", ExtenderUtil.getRelativePath(jobDirectory, o)); context.put("ext", ImmutableMap.of("includes", includes, "frameworks", frameworks, "frameworkPaths", frameworkPaths)); String command = templateExecutor.execute(platformConfig.compileCmd, context); @@ -298,8 +327,8 @@ private File compileFile(int index, File extDir, File src, Map m private File compileMain(File maincpp, Map manifestContext) throws IOException, InterruptedException, ExtenderException { Map context = context(manifestContext); File o = uniqueTmpFile("main_tmp", ".o"); - context.put("src", maincpp); - context.put("tgt", o); + context.put("src", ExtenderUtil.getRelativePath(jobDirectory, maincpp)); + context.put("tgt", ExtenderUtil.getRelativePath(jobDirectory, o)); String command = templateExecutor.execute(platformConfig.compileCmd, context); processExecutor.execute(command); return o; @@ -315,7 +344,7 @@ private void buildExtension(File manifest, Map manifestContext) } if (srcFiles.isEmpty()) { - throw new ExtenderException(String.format("Extension '%s' has no source!", ExtenderUtil.getRelativePath(this.extensionSource, manifest) )); + throw new ExtenderException(String.format("Extension '%s' has no source!", ExtenderUtil.getRelativePath(this.uploadDirectory, manifest) )); } List objs = new ArrayList<>(); @@ -324,12 +353,17 @@ private void buildExtension(File manifest, Map manifestContext) int i = 0; for (File src : srcFiles) { File o = compileFile(i, extDir, src, manifestContext); - objs.add(o.getAbsolutePath()); + objs.add(ExtenderUtil.getRelativePath(jobDirectory, o)); i++; } // Create c++ library - File lib = uniqueTmpFile("lib", ".a"); + File lib = null; + if (platformConfig.writeLibPattern != null) { + lib = uniqueTmpFile(platformConfig.writeLibPattern); + } else { + lib = uniqueTmpFile("lib", ".a"); // Deprecated, remove in a few versions + } Map context = context(manifestContext); context.put("tgt", lib); context.put("objs", objs); @@ -366,8 +400,7 @@ static List getAppManifestItems(AppManifestConfiguration manifest, Strin } private File linkEngine(List symbols, Map manifestContext) throws IOException, InterruptedException, ExtenderException { - File maincpp = new File(build, "main.cpp"); - File exe = new File(build, String.format("%sdmengine%s", platformConfig.exePrefix, platformConfig.exeExt)); + File maincpp = new File(buildDirectory , "main.cpp"); List extSymbols = new ArrayList<>(); extSymbols.addAll(symbols); @@ -376,7 +409,6 @@ private File linkEngine(List symbols, Map manifestContex extSymbols = ExtenderUtil.pruneItems( extSymbols, getAppManifestItems(appManifest, platform, "includeSymbols"), getAppManifestItems(appManifest, platform, "excludeSymbols") ); mainContext.put("symbols", ExtenderUtil.pruneItems( (List)mainContext.get("symbols"), getAppManifestItems(appManifest, platform, "includeSymbols"), getAppManifestItems(appManifest, platform, "excludeSymbols"))); - mainContext.put("ext", ImmutableMap.of("symbols", extSymbols)); String main = templateExecutor.execute(config.main, mainContext); @@ -385,12 +417,12 @@ private File linkEngine(List symbols, Map manifestContex File mainObject = compileMain(maincpp, manifestContext); List extLibs = new ArrayList<>(); - List extLibPaths = new ArrayList<>(Arrays.asList(build.toString())); + List extLibPaths = new ArrayList<>(Arrays.asList(buildDirectory.toString())); List extFrameworks = new ArrayList<>(); - List extFrameworkPaths = new ArrayList<>(Arrays.asList(build.toString())); + List extFrameworkPaths = new ArrayList<>(Arrays.asList(buildDirectory.toString())); List extJsLibs = new ArrayList<>(); - extLibs.addAll(Extender.collectFilesByName(build, platformConfig.stlibRe)); + extLibs.addAll(Extender.collectFilesByName(buildDirectory, platformConfig.stlibRe)); for (File extDir : this.extDirs) { File libDir = new File(extDir, "lib" + File.separator + this.platform); // e.g. arm64-ios @@ -423,23 +455,28 @@ private File linkEngine(List symbols, Map manifestContex extLibs = ExtenderUtil.pruneItems( extLibs, getAppManifestItems(appManifest, platform, "includeLibs"), getAppManifestItems(appManifest, platform, "excludeLibs")); extJsLibs = ExtenderUtil.pruneItems( extJsLibs, getAppManifestItems(appManifest, platform, "includeJsLibs"), getAppManifestItems(appManifest, platform, "excludeJsLibs")); + File exe; + if (platformConfig.writeExePattern != null ) { + exe = new File(buildDirectory, platformConfig.writeExePattern); + } else { + exe = new File(buildDirectory, String.format("%sdmengine%s", platformConfig.exePrefix, platformConfig.exeExt)); // Legacy, remove in a few versions! + } + Map context = context(manifestContext); - context.put("src", mainObject); - context.put("tgt", exe.getAbsolutePath()); + context.put("src", ExtenderUtil.getRelativePath(jobDirectory, mainObject)); + context.put("tgt", ExtenderUtil.getRelativePath(jobDirectory, exe)); context.put("ext", ImmutableMap.of("libs", extLibs, "libPaths", extLibPaths, "frameworks", extFrameworks, "frameworkPaths", extFrameworkPaths, "jsLibs", extJsLibs)); - context.put("engineLibs", ExtenderUtil.pruneItems((List) context.getOrDefault("engineLibs", new ArrayList<>()), getAppManifestItems(appManifest, platform, "includeLibs"), getAppManifestItems(appManifest, platform, "excludeLibs")) ); context.put("engineJsLibs", ExtenderUtil.pruneItems((List) context.getOrDefault("engineJsLibs", new ArrayList<>()), getAppManifestItems(appManifest, platform, "includeJsLibs"), getAppManifestItems(appManifest, platform, "excludeJsLibs")) ); String command = templateExecutor.execute(platformConfig.linkCmd, context); processExecutor.execute(command); - return exe; } private File buildRJar() throws ExtenderException { try { - File rJavaDir = new File(extensionSource, "_app/rjava/"); + File rJavaDir = new File(uploadDirectory, "_app/rjava/"); if (rJavaDir.exists() && rJavaDir.isDirectory()) { LOGGER.info("Building Android resources (R.java)."); @@ -505,7 +542,7 @@ private File buildJavaExtension(File manifest, Map manifestConte try { - LOGGER.info("Building Java sources with extension source {}", extensionSource); + LOGGER.info("Building Java sources with extension source {}", uploadDirectory); // Collect all Java source files File extDir = manifest.getParentFile(); @@ -585,7 +622,7 @@ private List buildJava(File rJar) throws ExtenderException { try { Map> manifestConfigs = new HashMap<>(); for (File manifest : this.manifests) { - ManifestConfiguration manifestConfig = Extender.loadYaml(this.extensionSource, manifest, ManifestConfiguration.class); + ManifestConfiguration manifestConfig = Extender.loadYaml(this.uploadDirectory, manifest, ManifestConfiguration.class); Map manifestContext = new HashMap<>(); if (manifestConfig.platforms != null) { @@ -627,14 +664,14 @@ private Map getManifestContext(ManifestConfiguration manifestCon } private File buildClassesDex(List extraJars) throws ExtenderException { - LOGGER.info("Building classes.dex with extension source {}", extensionSource); + LOGGER.info("Building classes.dex with extension source {}", uploadDirectory); // To support older versions of build.yml where dxCmd is not defined: if (platformConfig.dxCmd == null || platformConfig.dxCmd.isEmpty()) { return null; } - File classesDex = new File(build, "classes.dex"); + File classesDex = new File(buildDirectory, "classes.dex"); List extJars = new ArrayList<>(); for (File extDir : this.extDirs) { @@ -660,22 +697,36 @@ private File buildClassesDex(List extraJars) throws ExtenderException { return classesDex; } + private void buildWin32Manifest(File exe, Map mergedExtensionContext) throws ExtenderException { + LOGGER.info("Adding manifest file to engine"); + + Map context = context(mergedExtensionContext); + context.put("tgt", ExtenderUtil.getRelativePath(jobDirectory, exe)); + + String command = templateExecutor.execute(platformConfig.mtCmd, context); + try { + processExecutor.execute(command); + } catch (IOException | InterruptedException e) { + throw new ExtenderException(e, processExecutor.getOutput()); + } + } + private File buildEngine() throws ExtenderException { - LOGGER.info("Building engine for platform {} with extension source {}", platform, extensionSource); + LOGGER.info("Building engine for platform {} with extension source {}", platform, uploadDirectory); try { List symbols = new ArrayList<>(); Map> manifestConfigs = new HashMap<>(); for (File manifest : this.manifests) { - ManifestConfiguration manifestConfig = Extender.loadYaml(this.extensionSource, manifest, ManifestConfiguration.class); + ManifestConfiguration manifestConfig = Extender.loadYaml(this.uploadDirectory, manifest, ManifestConfiguration.class); Map manifestContext = new HashMap<>(); if (manifestConfig.platforms != null) { manifestContext = getManifestContext(manifestConfig); } - String relativePath = ExtenderUtil.getRelativePath(this.extensionSource, manifest); + String relativePath = ExtenderUtil.getRelativePath(this.uploadDirectory, manifest); this.manifestValidator.validate(relativePath, manifestContext); manifestConfigs.put(manifestConfig.name, manifestContext); @@ -693,7 +744,13 @@ private File buildEngine() throws ExtenderException { mergedExtensionContext = Extender.mergeContexts(mergedExtensionContext, extensionContext); } - return linkEngine(symbols, mergedExtensionContext); + File exe = linkEngine(symbols, mergedExtensionContext); + + if (platform.endsWith("win32")) { + buildWin32Manifest(exe, mergedExtensionContext); + } + + return exe; } catch (IOException | InterruptedException e) { throw new ExtenderException(e, processExecutor.getOutput()); } @@ -717,8 +774,4 @@ List build() throws ExtenderException { return outputFiles; } - - void dispose() throws IOException { - FileUtils.deleteDirectory(build); - } } diff --git a/server/src/main/java/com/defold/extender/ExtenderController.java b/server/src/main/java/com/defold/extender/ExtenderController.java index 2c00d4b5..04141077 100644 --- a/server/src/main/java/com/defold/extender/ExtenderController.java +++ b/server/src/main/java/com/defold/extender/ExtenderController.java @@ -34,9 +34,6 @@ public class ExtenderController { private final DefoldSdkService defoldSdkService; - @Value("${extender.build-location}") - String buildDirectory; - @Autowired public ExtenderController(DefoldSdkService defoldSdkService) { this.defoldSdkService = defoldSdkService; @@ -69,7 +66,6 @@ public void buildEngineLocal(MultipartHttpServletRequest request, HttpServletRes throws URISyntaxException, IOException, ExtenderException { if (defoldSdkService.isLocalSdkSupported()) { - buildEngine(request, response, platform, null); return; } @@ -84,7 +80,11 @@ public void buildEngine(MultipartHttpServletRequest request, @PathVariable("sdkVersion") String sdkVersion) throws ExtenderException, IOException, URISyntaxException { - File uploadDirectory = Files.createTempDirectory("upload").toFile(); + File jobDirectory = Files.createTempDirectory("job").toFile(); + File uploadDirectory = new File(jobDirectory, "upload"); + uploadDirectory.mkdir(); + File buildDirectory = new File(jobDirectory, "build"); + buildDirectory.mkdir(); try { validateFilenames(request); @@ -98,18 +98,14 @@ public void buildEngine(MultipartHttpServletRequest request, sdk = defoldSdkService.getSdk(sdkVersion); } - Extender extender = new Extender(platform, uploadDirectory, sdk, buildDirectory); + Extender extender = new Extender(platform, sdk, jobDirectory, uploadDirectory, buildDirectory); - try { - // Build and write output files to output stream - List outputFiles = extender.build(); - ZipUtils.zip(response.getOutputStream(), outputFiles); - } finally { - extender.dispose(); - } + // Build and write output files to output stream + List outputFiles = extender.build(); + ZipUtils.zip(response.getOutputStream(), outputFiles); } finally { // Delete temporary upload directory - FileUtils.deleteDirectory(uploadDirectory); + FileUtils.deleteDirectory(jobDirectory); } } diff --git a/server/src/main/java/com/defold/extender/ExtenderUtil.java b/server/src/main/java/com/defold/extender/ExtenderUtil.java index d64d8565..edba8e1c 100644 --- a/server/src/main/java/com/defold/extender/ExtenderUtil.java +++ b/server/src/main/java/com/defold/extender/ExtenderUtil.java @@ -3,6 +3,7 @@ import java.io.File; import java.util.ArrayList; import java.util.List; +import java.util.Map; import java.util.regex.Matcher; import java.util.regex.Pattern; @@ -81,4 +82,19 @@ static List pruneItems(List input, List includePatterns, static String getRelativePath(File base, File path) { return base.toURI().relativize(path.toURI()).getPath(); } + + static void debugPrint(Map map, int indent) { + + for (String key : map.keySet()) { + Object v = map.get(key); + if (v instanceof Map) { + debugPrint((Map)v, indent+1); + } else { + for (int i = 0; i < indent; ++i) { + System.out.print(" "); + } + System.out.println(String.format("%s:\t%s", key, v.toString() ) ); + } + } + } } \ No newline at end of file diff --git a/server/src/main/java/com/defold/extender/PlatformConfig.java b/server/src/main/java/com/defold/extender/PlatformConfig.java index 678585fb..a7db26e4 100644 --- a/server/src/main/java/com/defold/extender/PlatformConfig.java +++ b/server/src/main/java/com/defold/extender/PlatformConfig.java @@ -6,9 +6,12 @@ class PlatformConfig { + public Map env; public Map context = new HashMap<>(); - public String exePrefix; - public String exeExt; + public String exePrefix; // deprecated + public String exeExt; // deprecated + public String writeLibPattern; + public String writeExePattern; public String shlibRe; public String stlibRe; public String sourceRe; @@ -19,6 +22,7 @@ class PlatformConfig { public String javacCmd; public String jarCmd; public String dxCmd; + public String mtCmd; public List allowedLibs; public List allowedFlags; } diff --git a/server/src/main/java/com/defold/extender/ProcessExecutor.java b/server/src/main/java/com/defold/extender/ProcessExecutor.java index 95a4861e..6ea9523f 100644 --- a/server/src/main/java/com/defold/extender/ProcessExecutor.java +++ b/server/src/main/java/com/defold/extender/ProcessExecutor.java @@ -1,16 +1,15 @@ package com.defold.extender; +import java.io.File; import java.io.IOException; import java.io.InputStream; -import java.util.Arrays; -import java.util.HashMap; -import java.util.List; -import java.util.Map; +import java.util.*; import java.util.stream.Collectors; class ProcessExecutor { private final StringBuilder output = new StringBuilder(); private final HashMap env = new HashMap<>(); + private File cwd = null; int execute(String command) throws IOException, InterruptedException { output.append(command).append("\n"); @@ -21,6 +20,9 @@ int execute(String command) throws IOException, InterruptedException { .collect(Collectors.toList()); ProcessBuilder pb = new ProcessBuilder(args); + if (cwd != null ) { + pb.directory(cwd); + } pb.redirectErrorStream(true); Map pbEnv = pb.environment(); @@ -60,4 +62,8 @@ String getOutput() { void putEnv(String key, String value) { env.put(key, value); } + + void setCwd(File cwd) { + this.cwd = cwd; + } } diff --git a/server/src/test/java/com/defold/extender/ExtenderTest.java b/server/src/test/java/com/defold/extender/ExtenderTest.java index 06ec74ff..a52a8b8d 100644 --- a/server/src/test/java/com/defold/extender/ExtenderTest.java +++ b/server/src/test/java/com/defold/extender/ExtenderTest.java @@ -18,14 +18,15 @@ public class ExtenderTest { @Test public void testExtender() throws IOException, InterruptedException, ExtenderException { - File uploadDir = new File("/tmp/tmpUpload"); + File jobDir = new File("/tmp/tmpJob"); + jobDir.mkdirs(); + jobDir.deleteOnExit(); + File uploadDir = new File(jobDir, "upload"); uploadDir.mkdirs(); - uploadDir.deleteOnExit(); - File buildDir = new File("/tmp/tmpBuild"); + File buildDir = new File(jobDir, "build"); buildDir.mkdirs(); - buildDir.deleteOnExit(); File sdk = new File("test-data/sdk/a/defoldsdk"); - Extender extender = new Extender("x86-osx", uploadDir, sdk, buildDir.getAbsolutePath()); + Extender extender = new Extender("x86-osx", sdk, jobDir, uploadDir, buildDir); uploadDir.delete(); assertTrue(true); @@ -235,21 +236,18 @@ public void testMergeContext() throws IOException, InterruptedException, Extende Map a = new HashMap<>(); Map b = new HashMap<>(); - String[] a_frameworks = {"a", "b", "b", "c"}; - a.put("frameworks", Arrays.asList(a_frameworks)); - String[] a_defines = {"A", "B"}; - a.put("defines", Arrays.asList(a_defines)); + a.put("frameworks", Arrays.asList("a", "b", "b", "c")); + a.put("defines", Arrays.asList("A", "B")); - String[] b_frameworks = {"a", "d"}; - b.put("frameworks", Arrays.asList(b_frameworks)); + b.put("frameworks", Arrays.asList("a", "d")); + b.put("symbols", Arrays.asList("S1")); Map result = Extender.mergeContexts(a, b); Map expected = new HashMap<>(); - String[] expected_frameworks = {"a", "b", "b", "c", "a", "d"}; - expected.put("frameworks", Arrays.asList(expected_frameworks)); - String[] expected_defines = {"A", "B"}; - expected.put("defines", Arrays.asList(expected_defines)); + expected.put("frameworks", Arrays.asList("a", "b", "b", "c", "a", "d")); + expected.put("defines", Arrays.asList("A", "B")); + expected.put("symbols", Arrays.asList("S1")); assertEquals(expected, result); } @@ -373,6 +371,5 @@ public void testExcludeItems() throws IOException, InterruptedException, Extende assertEquals( 1, items.size() ); assertTrue( items.contains("{{dynamo_home}}/ext/share/java/facebooksdk.jar") ); } - } } diff --git a/server/src/test/java/com/defold/extender/IntegrationTest.java b/server/src/test/java/com/defold/extender/IntegrationTest.java index af25f3c2..8aa015c6 100644 --- a/server/src/test/java/com/defold/extender/IntegrationTest.java +++ b/server/src/test/java/com/defold/extender/IntegrationTest.java @@ -105,7 +105,7 @@ public static Collection data() { DefoldVersion[] versions = { // "a" is a made up sdk where we can more easily test build.yml fixes - new DefoldVersion("a", new Version(0, 0, 0), new String[] {"x86-osx", "armv7-android", "js-web"} ), + new DefoldVersion("a", new Version(0, 0, 0), new String[] {"x86-osx", "armv7-android", "js-web", "x86_64-win32"} ), new DefoldVersion("8e1d5f8a8a0e1734c9e873ec72b56bea53f25d87", new Version(1, 2, 97), new String[] {"x86-osx"}), new DefoldVersion("735ff76c8b1f93b3126ff223cd234d7ceb5b886d", new Version(1, 2, 98), new String[] {"armv7-android", "armv7-ios", "arm64-ios", "x86-osx", "x86_64-osx"}), @@ -171,7 +171,7 @@ public void buildEngineOLD() throws IOException, ExtenderClientException { List sourceFiles = Lists.newArrayList( new FileExtenderResource("test-data/ext/ext.manifest"), new FileExtenderResource("test-data/ext/src/test_ext.cpp"), - new FileExtenderResource(String.format("test-data/ext/lib/%s/libalib.a", configuration.platform)) + new FileExtenderResource(String.format("test-data/ext/lib/%s/%s", configuration.platform, getLibName(configuration.platform, "alib"))) ); File destination = Files.createTempFile("dmengine", ".zip").toFile(); File log = Files.createTempFile("dmengine", ".log").toFile(); @@ -208,8 +208,7 @@ public void buildEngineOLD() throws IOException, ExtenderClientException { FileUtils.deleteDirectory(new File("build" + File.separator + sdkVersion)); } - private String getEngineName(String platform) - { + private String getEngineName(String platform) { if (platform.endsWith("android")) { return "libdmengine.so"; } @@ -219,9 +218,19 @@ else if (platform.endsWith("ios") || platform.endsWith("osx")) { else if (platform.endsWith("web")) { return "dmengine.js"; } + else if (platform.endsWith("win32")) { + return "dmengine.exe"; + } return null; } + private String getLibName(String platform, String lib) { + if (platform.endsWith("win32")) { + return String.format("%s.lib", lib); + } + return String.format("lib%s.a", lib); + } + @Test public void buildEngine() throws IOException, ExtenderClientException { @@ -238,8 +247,8 @@ public void buildEngine() throws IOException, ExtenderClientException { List sourceFiles = Lists.newArrayList( new FileExtenderResource("test-data/ext2/ext.manifest"), new FileExtenderResource("test-data/ext2/src/test_ext.cpp"), - new FileExtenderResource(String.format("test-data/ext2/lib/%s/libalib.a", configuration.platform)), - new FileExtenderResource(String.format("test-data/ext2/lib/%s/libblib.a", configuration.platform)) + new FileExtenderResource(String.format("test-data/ext2/lib/%s/%s", configuration.platform, getLibName(configuration.platform, "alib"))), + new FileExtenderResource(String.format("test-data/ext2/lib/%s/%s", configuration.platform, getLibName(configuration.platform, "blib"))) ); File destination = Files.createTempFile("dmengine", ".zip").toFile(); File log = Files.createTempFile("dmengine", ".log").toFile(); @@ -461,6 +470,7 @@ public void buildAndroidJavaJarDependency() throws IOException, ExtenderClientEx assertTrue(dexClasses.contains("Lcom/defold/JarDep;")); assertTrue(dexClasses.contains("Lcom/defold/Test;")); } + @Test public void buildAndroidRJar() throws IOException, ExtenderClientException, InterruptedException { @@ -535,10 +545,10 @@ public void buildEngineAppManifest() throws IOException, ExtenderClientException new FileExtenderResource("test-data/testproject_appmanifest/_app/app.manifest"), new FileExtenderResource("test-data/testproject_appmanifest/ext/ext.manifest"), new FileExtenderResource("test-data/testproject_appmanifest/ext/src/test_ext.cpp"), - new FileExtenderResource(String.format("test-data/testproject_appmanifest/ext/lib/%s/libalib.a", configuration.platform)), + new FileExtenderResource(String.format("test-data/testproject_appmanifest/ext/lib/%s/%s", configuration.platform, getLibName(configuration.platform, "alib"))), new FileExtenderResource("test-data/testproject_appmanifest/ext2/ext.manifest"), new FileExtenderResource("test-data/testproject_appmanifest/ext2/src/test_ext.cpp"), - new FileExtenderResource(String.format("test-data/testproject_appmanifest/ext2/lib/%s/libblib.a", configuration.platform)) + new FileExtenderResource(String.format("test-data/testproject_appmanifest/ext2/lib/%s/%s", configuration.platform, getLibName(configuration.platform, "blib"))) ); if (isAndroid) { diff --git a/server/test-data/build-libs.sh b/server/test-data/build-libs.sh index 19f2217f..338e119b 100755 --- a/server/test-data/build-libs.sh +++ b/server/test-data/build-libs.sh @@ -1,4 +1,12 @@ +# How to build on Windows +# * Make a shared directory between OSX/Win32 for test-data in Parallels Desktop +# * On the windows machine, open an msys terminal +# * Change directory to the new drive (E.g. X: "cd x:") which was mounted for you by Parallels Desktop +# * Run "sh build-libs.sh" +# All files should be named and copied automatically by this script + + source ./compile.sh # Find all .cpp files in a folder and make a lib of each of them @@ -24,7 +32,7 @@ function Copy { CompileLibsToExtension enginelibs engineext/lib # # copy these into the "a" sdk -cp -v -r engineext/lib/ sdk/a/defoldsdk/lib +cp -v -r engineext/lib/ sdk/a/defoldsdk/ rm -rf ./engineext CompileLibsToExtension alib ext/lib diff --git a/server/test-data/compile.sh b/server/test-data/compile.sh index a5f270f0..a2ea8ce4 100755 --- a/server/test-data/compile.sh +++ b/server/test-data/compile.sh @@ -12,6 +12,10 @@ OSX_AR=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctool EMCC=$DYNAMO_HOME/ext/bin/emsdk_portable/emscripten/1.35.0/em++ EMAR=$DYNAMO_HOME/ext/bin/emsdk_portable/emscripten/1.35.0/emar +WIN32_CL=cl.exe +WIN32_LIB=lib.exe + + function RemoveTarget { local name=$1 @@ -109,13 +113,53 @@ function CompileHTML5 { done } +function CompileWindows { + local name=$1 + local src=$2 + local targetdir=$3 + + archs=( "x86" "x86_64") + for arch in "${archs[@]}" + do + local archname=$arch-win32 + local target=$targetdir/$archname/$name.lib + + RemoveTarget $target + mkdir -p $(dirname $target) + + local OLDPATH=$PATH + + if [ "$arch" == "x86_64" ]; then + export PATH="/c/Program Files (x86)/MSBuild/14.0/bin:/c/Program Files (x86)/Microsoft Visual Studio 14.0/Common7/IDE/:/c/Program Files (x86)/Microsoft Visual Studio 14.0/VC/BIN/x86_amd64:/c/Program Files (x86)/Microsoft Visual Studio 14.0/VC/BIN:/c/Program Files (x86)/Microsoft Visual Studio 14.0/Common7/Tools:/c/WINDOWS/Microsoft.NET/Framework/v4.0.30319:/c/Program Files (x86)/Microsoft Visual Studio 14.0/VC/VCPackages:/c/Program Files (x86)/HTML Help Workshop:/c/Program Files (x86)/Microsoft Visual Studio 14.0/Team Tools/Performance Tools:/c/Program Files (x86)/Windows Kits/8.1/bin/x86:/c/Program Files (x86)/Microsoft SDKs/Windows/v10.0A/bin/NETFX 4.6.1 Tools/:$PATH" + else + export PATH="/c/Program Files (x86)/MSBuild/14.0/bin:/c/Program Files (x86)/Microsoft Visual Studio 14.0/Common7/IDE/:/c/Program Files (x86)/Microsoft Visual Studio 14.0/VC/BIN:/c/Program Files (x86)/Microsoft Visual Studio 14.0/VC/BIN:/c/Program Files (x86)/Microsoft Visual Studio 14.0/Common7/Tools:/c/WINDOWS/Microsoft.NET/Framework/v4.0.30319:/c/Program Files (x86)/Microsoft Visual Studio 14.0/VC/VCPackages:/c/Program Files (x86)/HTML Help Workshop:/c/Program Files (x86)/Microsoft Visual Studio 14.0/Team Tools/Performance Tools:/c/Program Files (x86)/Windows Kits/8.1/bin/x86:/c/Program Files (x86)/Microsoft SDKs/Windows/v10.0A/bin/NETFX 4.6.1 Tools/:$PATH" + fi + + $WIN32_CL -nologo -TP -O2 -Oy- -Z7 -MT -D__STDC_LIMIT_MACROS -DWINVER=0x0600 -D_WIN32_WINNT=0x0600 -DWIN32 -D_CRT_SECURE_NO_WARNINGS -wd4200 -W3 -EHsc $src -c -Fo$name-$archname.obj + # For some reason, only the /OUT cannot be set using -OUT :/ + $WIN32_LIB -nologo $name-$archname.obj + rm $name-$archname.obj + mv -v $name-$archname.lib $target + + export PATH=$OLDPATH + + echo Wrote $target + done +} + + function Compile { local name=$1 local src=$2 local targetdir=$3 - CompileOSX $name $src $targetdir - CompileiOS $name $src $targetdir - CompileAndroid $name $src $targetdir - CompileHTML5 $name $src $targetdir + if [ "$(uname)" == "Darwin" ]; then + CompileOSX $name $src $targetdir + CompileiOS $name $src $targetdir + CompileAndroid $name $src $targetdir + CompileHTML5 $name $src $targetdir + fi + if [ "$(uname)" == "MINGW32_NT-6.2" ]; then + CompileWindows $name $src $targetdir + fi } diff --git a/server/test-data/enginelibs/engine_main.cpp b/server/test-data/enginelibs/engine_main.cpp index 95f1854d..72cb3eaa 100644 --- a/server/test-data/enginelibs/engine_main.cpp +++ b/server/test-data/enginelibs/engine_main.cpp @@ -1,4 +1,4 @@ -int engine_main(int argc, char** argv) +int engine_main(int argc, char* argv[]) { return 0; } diff --git a/server/test-data/ext/lib/arm64-ios/libalib.a b/server/test-data/ext/lib/arm64-ios/libalib.a index 2898c5d1..a64e7cb9 100644 Binary files a/server/test-data/ext/lib/arm64-ios/libalib.a and b/server/test-data/ext/lib/arm64-ios/libalib.a differ diff --git a/server/test-data/ext/lib/armv7-android/libalib.a b/server/test-data/ext/lib/armv7-android/libalib.a index 96038b6a..aa23fe8e 100644 Binary files a/server/test-data/ext/lib/armv7-android/libalib.a and b/server/test-data/ext/lib/armv7-android/libalib.a differ diff --git a/server/test-data/ext/lib/armv7-ios/libalib.a b/server/test-data/ext/lib/armv7-ios/libalib.a index 0bd2fd68..a86238d6 100644 Binary files a/server/test-data/ext/lib/armv7-ios/libalib.a and b/server/test-data/ext/lib/armv7-ios/libalib.a differ diff --git a/server/test-data/ext/lib/js-web/libalib.a b/server/test-data/ext/lib/js-web/libalib.a index 0f29e371..ebb301d4 100644 Binary files a/server/test-data/ext/lib/js-web/libalib.a and b/server/test-data/ext/lib/js-web/libalib.a differ diff --git a/server/test-data/ext/lib/x86-osx/libalib.a b/server/test-data/ext/lib/x86-osx/libalib.a index d04aabb0..059b7f0b 100644 Binary files a/server/test-data/ext/lib/x86-osx/libalib.a and b/server/test-data/ext/lib/x86-osx/libalib.a differ diff --git a/server/test-data/ext/lib/x86-win32/alib.lib b/server/test-data/ext/lib/x86-win32/alib.lib new file mode 100644 index 00000000..73db8004 Binary files /dev/null and b/server/test-data/ext/lib/x86-win32/alib.lib differ diff --git a/server/test-data/ext/lib/x86_64-osx/libalib.a b/server/test-data/ext/lib/x86_64-osx/libalib.a index d48a28b6..d79ffa56 100644 Binary files a/server/test-data/ext/lib/x86_64-osx/libalib.a and b/server/test-data/ext/lib/x86_64-osx/libalib.a differ diff --git a/server/test-data/ext/lib/x86_64-win32/alib.lib b/server/test-data/ext/lib/x86_64-win32/alib.lib new file mode 100644 index 00000000..50e62aa5 Binary files /dev/null and b/server/test-data/ext/lib/x86_64-win32/alib.lib differ diff --git a/server/test-data/ext2/lib/arm64-ios/libalib.a b/server/test-data/ext2/lib/arm64-ios/libalib.a index 6c9cf8ac..02903123 100644 Binary files a/server/test-data/ext2/lib/arm64-ios/libalib.a and b/server/test-data/ext2/lib/arm64-ios/libalib.a differ diff --git a/server/test-data/ext2/lib/arm64-ios/libblib.a b/server/test-data/ext2/lib/arm64-ios/libblib.a index bfd34cf3..f0348106 100644 Binary files a/server/test-data/ext2/lib/arm64-ios/libblib.a and b/server/test-data/ext2/lib/arm64-ios/libblib.a differ diff --git a/server/test-data/ext2/lib/armv7-android/libalib.a b/server/test-data/ext2/lib/armv7-android/libalib.a index 96038b6a..4e8accee 100644 Binary files a/server/test-data/ext2/lib/armv7-android/libalib.a and b/server/test-data/ext2/lib/armv7-android/libalib.a differ diff --git a/server/test-data/ext2/lib/armv7-android/libblib.a b/server/test-data/ext2/lib/armv7-android/libblib.a index 2bdeff71..8f77abe9 100644 Binary files a/server/test-data/ext2/lib/armv7-android/libblib.a and b/server/test-data/ext2/lib/armv7-android/libblib.a differ diff --git a/server/test-data/ext2/lib/armv7-ios/libalib.a b/server/test-data/ext2/lib/armv7-ios/libalib.a index df0eae61..676fe030 100644 Binary files a/server/test-data/ext2/lib/armv7-ios/libalib.a and b/server/test-data/ext2/lib/armv7-ios/libalib.a differ diff --git a/server/test-data/ext2/lib/armv7-ios/libblib.a b/server/test-data/ext2/lib/armv7-ios/libblib.a index c8949a07..509b8ebd 100644 Binary files a/server/test-data/ext2/lib/armv7-ios/libblib.a and b/server/test-data/ext2/lib/armv7-ios/libblib.a differ diff --git a/server/test-data/ext2/lib/js-web/libalib.a b/server/test-data/ext2/lib/js-web/libalib.a index 777333a3..ebb301d4 100644 Binary files a/server/test-data/ext2/lib/js-web/libalib.a and b/server/test-data/ext2/lib/js-web/libalib.a differ diff --git a/server/test-data/ext2/lib/js-web/libblib.a b/server/test-data/ext2/lib/js-web/libblib.a index ee3348d1..04f7ec2e 100644 Binary files a/server/test-data/ext2/lib/js-web/libblib.a and b/server/test-data/ext2/lib/js-web/libblib.a differ diff --git a/server/test-data/ext2/lib/x86-osx/libalib.a b/server/test-data/ext2/lib/x86-osx/libalib.a index b5f2bbe8..dfdc43e1 100644 Binary files a/server/test-data/ext2/lib/x86-osx/libalib.a and b/server/test-data/ext2/lib/x86-osx/libalib.a differ diff --git a/server/test-data/ext2/lib/x86-osx/libblib.a b/server/test-data/ext2/lib/x86-osx/libblib.a index 034eb1d3..4dfb64da 100644 Binary files a/server/test-data/ext2/lib/x86-osx/libblib.a and b/server/test-data/ext2/lib/x86-osx/libblib.a differ diff --git a/server/test-data/ext2/lib/x86-win32/alib.lib b/server/test-data/ext2/lib/x86-win32/alib.lib new file mode 100644 index 00000000..a3a919fc Binary files /dev/null and b/server/test-data/ext2/lib/x86-win32/alib.lib differ diff --git a/server/test-data/ext2/lib/x86-win32/blib.lib b/server/test-data/ext2/lib/x86-win32/blib.lib new file mode 100644 index 00000000..6a558c01 Binary files /dev/null and b/server/test-data/ext2/lib/x86-win32/blib.lib differ diff --git a/server/test-data/ext2/lib/x86_64-osx/libalib.a b/server/test-data/ext2/lib/x86_64-osx/libalib.a index 0c9e5290..2aadbc03 100644 Binary files a/server/test-data/ext2/lib/x86_64-osx/libalib.a and b/server/test-data/ext2/lib/x86_64-osx/libalib.a differ diff --git a/server/test-data/ext2/lib/x86_64-osx/libblib.a b/server/test-data/ext2/lib/x86_64-osx/libblib.a index b18705c1..877a81da 100644 Binary files a/server/test-data/ext2/lib/x86_64-osx/libblib.a and b/server/test-data/ext2/lib/x86_64-osx/libblib.a differ diff --git a/server/test-data/ext2/lib/x86_64-win32/alib.lib b/server/test-data/ext2/lib/x86_64-win32/alib.lib new file mode 100644 index 00000000..feebbf90 Binary files /dev/null and b/server/test-data/ext2/lib/x86_64-win32/alib.lib differ diff --git a/server/test-data/ext2/lib/x86_64-win32/blib.lib b/server/test-data/ext2/lib/x86_64-win32/blib.lib new file mode 100644 index 00000000..923303ca Binary files /dev/null and b/server/test-data/ext2/lib/x86_64-win32/blib.lib differ diff --git a/server/test-data/sdk/a/defoldsdk/extender/build.yml b/server/test-data/sdk/a/defoldsdk/extender/build.yml index 1bdff6d7..853f55e9 100644 --- a/server/test-data/sdk/a/defoldsdk/extender/build.yml +++ b/server/test-data/sdk/a/defoldsdk/extender/build.yml @@ -77,16 +77,19 @@ platforms: frameworks: [] engineLibs: ["engine_main", "engine_foo"] libPaths: ["{{dynamo_home}}/lib/darwin", "{{dynamo_home}}/ext/lib/darwin", "{{dynamo_home}}/lib/x86-osx"] - exePrefix: '' - exeExt: '' - shlibRe: 'lib(.+).dylib' - stlibRe: 'lib(.+).a' - sourceRe: '(?i).*(.cpp|.c|.cc|.mm|.m)' - allowedLibs: ['lber','apr-1.0','AVFAudio','netsnmpmibs.25','bsm','form.5.4','tk','QMIParserDynamic','gmalloc','ncurses','heimdal-asn1','iodbcinst','krb5','tidy','curl.4','pmenergy','python2.7','icucore','ecpg','ATCommandStudioDynamic','dtrace_dyld','lzma.5','pcre.0','pgtypes.3.4','pq.5.6','pam.1','netsnmp.5','energytrace','sasl2.2.0.15','python2.6','germantok','cmph','ssh-keychain','xar.1','xml2','pcreposix.0','m','pam.2','apr-1','auto','alias','c++','ipconfig','Match','crypto.35','netsnmpmibs','cups','exslt.0','iodbcinst.2.1.18','pgtypes.3','mx.A','CRFSuite','cupsmime.1','aprutil-1.0','objc.A','edit','crypto.0.9.8','pmsample','des425','gcc_s.10.5','ruby.2.0','crypto.0.9.7','CRFSuite0.12','auditd.0','edit.2','pthread','ecpg.6.5','odfde','tcl8.5','z.1.1.3','netsnmp.5.2.1','cupsppdc.1','util','lapack','extension','ffi','System','iodbcinst.2','dns_services','pcreposix','mx','panel','ldap','readline','IASUnifiedProgress','edit.3','ssl.0.9.7','csfde','python','hunspell-1.2.0.0.0','netsnmp.25','charset.1.0.0','panel.5.4','gssapi_krb5','aprutil-1','cupsimage.2','BSDPClient.A','menu.5.4','info','spindump','marisa','dl','cupsimage','pq.5','com_err','auditd','UniversalAccess','sasl2.2.0.22','ecpg.6','blas','XSEvent','z','form','ktrace','krb5support','DiagnosticMessagesClient','c++abi','expat.1','System_debug','iodbc','tk8.5','Xplugin.1','pcap.A','curl.3','dbm','iconv','ssl','gcc_s.10.4','netsnmp.15.1.2','xar','menu','exslt','odmodule','alias.A','sasl2','charset','sasl2.2','ThaiTokenizer','tidy.A','archive','bz2.1.0.5','netsnmptrapd','ncurses.5.4','pcre','Fosl_dynamic','cblas','pq','System.B_debug','mecab','ipsec.A','ecpg_compat.3.5','f77lapack','cupsppdc','ipsec','netsnmphelpers.25','edit.3.0','tls','z.1.2.5','netsnmp.15','xslt','resolv','sasl2.2.0.1','iconv.2','ecpg_compat','netsnmpagent','krb524','OpenScriptingUtil','dtrace','cupsmime','bz2','AccountPolicyTranslation','netsnmpagent.25','expat','ssl.0.9.8','cups.2','netsnmphelpers','crypto','z.1','netsnmp','sandbox','CoreStorage','util1.0','DHCPServer.A','langid','Match.1','iodbc.2.1.18','xml2.2','quit','prequelite','stdc++.6.0.9','pcap','objc','ecpg_compat.3','ruby','ScreenReader','c++.1','tls.6','System.B','ChineseTokenizer','ssl.35','sqlite3','proc','BSDPClient','k5crypto','network','hunspell-1.2.0','cupscgi.1','sysmon','bz2.1.0','IASAuthReboot','ldap_r','c','termcap','ncurses.5','archive.2','cupscgi','bsm.0','lzma','iconv.2.4.0','xcselect','poll','sandbox.1','gcc_s.1','iodbc.2','curl','Xplugin','krb4','hunspell-1.2','stdc++','netsnmptrapd.25','rpcsvc','pam','clapack','tcl','mecabra','sasl2.2.0.21','resolv.9','compression','charset.1','icucore.A','pgtypes','DHCPServer','systemstats','TelephonyUtilDynamic','ruby.2.0.0','system_notify','system_c','system_secinit','system_dnssd','removefile','system_malloc','system_blocks','copyfile','xpc','mathCommon','unwind','system_platform','dyld','system_network','system_sandbox','dispatch','system_trace','system_info','keymgr','system_kernel','mathCommon.A','system_networkextension','system_coreservices','system_asl','unc','launch','system_coretls','dispatch','system_pthread','system_m','system_configuration','kxld','quarantine','corecrypto','macho','commonCrypto','system_pthread','compiler_rt','cache','sqlite3.0','stdc++.6','xslt.1','mecab.1.0.0','curses','Accelerate','Accounts','AddressBook','AGL','AppKit','AppKitScripting','AppleScriptKit','AppleScriptObjC','ApplicationServices','AudioToolbox','AudioUnit','AudioVideoBridging','Automator','AVFoundation','AVKit','CalendarStore','Carbon','CFNetwork','CloudKit','Cocoa','Collaboration','Contacts','ContactsUI','CoreAudio','CoreAudioKit','CoreBluetooth','CoreData','CoreFoundation','CoreGraphics','CoreImage','CoreLocation','CoreMedia','CoreMediaIO','CoreMIDI','CoreMIDIServer','CoreServices','CoreTelephony','CoreText','CoreVideo','CoreWLAN','CryptoTokenKit','DirectoryService','DiscRecording','DiscRecordingUI','DiskArbitration','DrawSprocket','DVComponentGlue','DVDPlayback','EventKit','ExceptionHandling','FinderSync','ForceFeedback','Foundation','FWAUserLib','GameController','GameKit','GameplayKit','GLKit','GLUT','GSS','Hypervisor','ICADevices','ImageCaptureCore','ImageIO','IMServicePlugIn','InputMethodKit','InstallerPlugins','InstantMessage','IOBluetooth','IOBluetoothUI','IOKit','IOSurface','JavaFrameEmbedding','JavaScriptCore','JavaVM','Kerberos','Kernel','LatentSemanticMapping','LDAP','LocalAuthentication','MapKit','MediaAccessibility','MediaLibrary','MediaToolbox','Message','Metal','MetalKit','ModelIO','MultipeerConnectivity','NetFS','NetworkExtension','NotificationCenter','OpenAL','OpenCL','OpenDirectory','OpenGL','OSAKit','PCSC','Photos','PhotosUI','PreferencePanes','PubSub','Python','QTKit','QuartzCore','Quartz','QuickLook','QuickTime','Ruby','SceneKit','ScreenSaver','ScriptingBridge','Scripting','SecurityFoundation','Security','SecurityInterface','ServiceManagement','Social','SpriteKit','StoreKit','SyncServices','SystemConfiguration','System','Tcl','Tk','TWAIN','vecLib','VideoDecodeAcceleration','VideoToolbox','vmnet','WebKit'] - allowedFlags: ["-ObjC","-ObjC++","-Wa,{{comma_separated_arg}}","-W{{warning}}","-ansi","--ansi","-std-default={{arg}}","-stdlib=(libstdc\\+\\+|libc\\+\\+)","-w","-std=(c89|c99|c\\+\\+0x|c\\+\\+11|c\\+\\+14|c\\+\\+17)","-Wp,{{comma_separated_arg}}","-W{{warning}}","--extra-warnings","--warn-{{warning}}","--warn-={{warning}}","-ferror-limit={{number}}","-O([0-4]?|fast|s|z)"] - compileCmd: 'clang++ -c -arch i386 -target x86_64-apple-darwin11 -isysroot /opt/MacOSX.sdk/ -m32 -O2 -g -mmacosx-version-min=10.7 {{#defines}}-D{{{.}}} {{/defines}} {{#flags}}{{{.}}} {{/flags}} {{#ext.includes}}-I{{{.}}} {{/ext.includes}} {{#ext.frameworkPaths}}-F{{{.}}} {{/ext.frameworkPaths}} {{#includes}}-I{{{.}}} {{/includes}} {{src}} -o{{tgt}}' - linkCmd: 'clang++ -arch i386 -target x86_64-apple-darwin11 -isysroot /opt/MacOSX.sdk/ -m32 -O2 -g -mmacosx-version-min=10.7 -o {{tgt}} {{#linkFlags}}{{{.}}} {{/linkFlags}} {{#ext.libPaths}}-L{{{.}}} {{/ext.libPaths}} {{#libs}}-l{{{.}}} {{/libs}} {{#ext.libs}}-l{{{.}}} {{/ext.libs}} {{#ext.frameworkPaths}}-F{{{.}}} {{/ext.frameworkPaths}} {{#ext.frameworks}}-framework {{{.}}} {{/ext.frameworks}} {{#frameworks}}-framework {{{.}}} {{/frameworks}} {{#libPaths}}-L{{{.}}} {{/libPaths}} {{#engineLibs}}-l{{{.}}} {{/engineLibs}} {{#src}}{{{.}}} {{/src}}' - libCmd: 'llvm-ar rcs {{tgt}} {{#objs}}{{{.}}} {{/objs}}' + + exePrefix: '' + exeExt: '' + shlibRe: 'lib(.+)\.dylib' + stlibRe: 'lib(.+)\.a' + writeLibPattern: 'lib%s.a' + writeExePattern: 'dmengine' + sourceRe: '(?i).*(.cpp|.c|.cc|.mm|.m)' + allowedLibs: ['lber','apr-1.0','AVFAudio','netsnmpmibs.25','bsm','form.5.4','tk','QMIParserDynamic','gmalloc','ncurses','heimdal-asn1','iodbcinst','krb5','tidy','curl.4','pmenergy','python2.7','icucore','ecpg','ATCommandStudioDynamic','dtrace_dyld','lzma.5','pcre.0','pgtypes.3.4','pq.5.6','pam.1','netsnmp.5','energytrace','sasl2.2.0.15','python2.6','germantok','cmph','ssh-keychain','xar.1','xml2','pcreposix.0','m','pam.2','apr-1','auto','alias','c++','ipconfig','Match','crypto.35','netsnmpmibs','cups','exslt.0','iodbcinst.2.1.18','pgtypes.3','mx.A','CRFSuite','cupsmime.1','aprutil-1.0','objc.A','edit','crypto.0.9.8','pmsample','des425','gcc_s.10.5','ruby.2.0','crypto.0.9.7','CRFSuite0.12','auditd.0','edit.2','pthread','ecpg.6.5','odfde','tcl8.5','z.1.1.3','netsnmp.5.2.1','cupsppdc.1','util','lapack','extension','ffi','System','iodbcinst.2','dns_services','pcreposix','mx','panel','ldap','readline','IASUnifiedProgress','edit.3','ssl.0.9.7','csfde','python','hunspell-1.2.0.0.0','netsnmp.25','charset.1.0.0','panel.5.4','gssapi_krb5','aprutil-1','cupsimage.2','BSDPClient.A','menu.5.4','info','spindump','marisa','dl','cupsimage','pq.5','com_err','auditd','UniversalAccess','sasl2.2.0.22','ecpg.6','blas','XSEvent','z','form','ktrace','krb5support','DiagnosticMessagesClient','c++abi','expat.1','System_debug','iodbc','tk8.5','Xplugin.1','pcap.A','curl.3','dbm','iconv','ssl','gcc_s.10.4','netsnmp.15.1.2','xar','menu','exslt','odmodule','alias.A','sasl2','charset','sasl2.2','ThaiTokenizer','tidy.A','archive','bz2.1.0.5','netsnmptrapd','ncurses.5.4','pcre','Fosl_dynamic','cblas','pq','System.B_debug','mecab','ipsec.A','ecpg_compat.3.5','f77lapack','cupsppdc','ipsec','netsnmphelpers.25','edit.3.0','tls','z.1.2.5','netsnmp.15','xslt','resolv','sasl2.2.0.1','iconv.2','ecpg_compat','netsnmpagent','krb524','OpenScriptingUtil','dtrace','cupsmime','bz2','AccountPolicyTranslation','netsnmpagent.25','expat','ssl.0.9.8','cups.2','netsnmphelpers','crypto','z.1','netsnmp','sandbox','CoreStorage','util1.0','DHCPServer.A','langid','Match.1','iodbc.2.1.18','xml2.2','quit','prequelite','stdc++.6.0.9','pcap','objc','ecpg_compat.3','ruby','ScreenReader','c++.1','tls.6','System.B','ChineseTokenizer','ssl.35','sqlite3','proc','BSDPClient','k5crypto','network','hunspell-1.2.0','cupscgi.1','sysmon','bz2.1.0','IASAuthReboot','ldap_r','c','termcap','ncurses.5','archive.2','cupscgi','bsm.0','lzma','iconv.2.4.0','xcselect','poll','sandbox.1','gcc_s.1','iodbc.2','curl','Xplugin','krb4','hunspell-1.2','stdc++','netsnmptrapd.25','rpcsvc','pam','clapack','tcl','mecabra','sasl2.2.0.21','resolv.9','compression','charset.1','icucore.A','pgtypes','DHCPServer','systemstats','TelephonyUtilDynamic','ruby.2.0.0','system_notify','system_c','system_secinit','system_dnssd','removefile','system_malloc','system_blocks','copyfile','xpc','mathCommon','unwind','system_platform','dyld','system_network','system_sandbox','dispatch','system_trace','system_info','keymgr','system_kernel','mathCommon.A','system_networkextension','system_coreservices','system_asl','unc','launch','system_coretls','dispatch','system_pthread','system_m','system_configuration','kxld','quarantine','corecrypto','macho','commonCrypto','system_pthread','compiler_rt','cache','sqlite3.0','stdc++.6','xslt.1','mecab.1.0.0','curses','Accelerate','Accounts','AddressBook','AGL','AppKit','AppKitScripting','AppleScriptKit','AppleScriptObjC','ApplicationServices','AudioToolbox','AudioUnit','AudioVideoBridging','Automator','AVFoundation','AVKit','CalendarStore','Carbon','CFNetwork','CloudKit','Cocoa','Collaboration','Contacts','ContactsUI','CoreAudio','CoreAudioKit','CoreBluetooth','CoreData','CoreFoundation','CoreGraphics','CoreImage','CoreLocation','CoreMedia','CoreMediaIO','CoreMIDI','CoreMIDIServer','CoreServices','CoreTelephony','CoreText','CoreVideo','CoreWLAN','CryptoTokenKit','DirectoryService','DiscRecording','DiscRecordingUI','DiskArbitration','DrawSprocket','DVComponentGlue','DVDPlayback','EventKit','ExceptionHandling','FinderSync','ForceFeedback','Foundation','FWAUserLib','GameController','GameKit','GameplayKit','GLKit','GLUT','GSS','Hypervisor','ICADevices','ImageCaptureCore','ImageIO','IMServicePlugIn','InputMethodKit','InstallerPlugins','InstantMessage','IOBluetooth','IOBluetoothUI','IOKit','IOSurface','JavaFrameEmbedding','JavaScriptCore','JavaVM','Kerberos','Kernel','LatentSemanticMapping','LDAP','LocalAuthentication','MapKit','MediaAccessibility','MediaLibrary','MediaToolbox','Message','Metal','MetalKit','ModelIO','MultipeerConnectivity','NetFS','NetworkExtension','NotificationCenter','OpenAL','OpenCL','OpenDirectory','OpenGL','OSAKit','PCSC','Photos','PhotosUI','PreferencePanes','PubSub','Python','QTKit','QuartzCore','Quartz','QuickLook','QuickTime','Ruby','SceneKit','ScreenSaver','ScriptingBridge','Scripting','SecurityFoundation','Security','SecurityInterface','ServiceManagement','Social','SpriteKit','StoreKit','SyncServices','SystemConfiguration','System','Tcl','Tk','TWAIN','vecLib','VideoDecodeAcceleration','VideoToolbox','vmnet','WebKit'] + allowedFlags: ["-ObjC","-ObjC++","-Wa,{{comma_separated_arg}}","-W{{warning}}","-ansi","--ansi","-std-default={{arg}}","-stdlib=(libstdc\\+\\+|libc\\+\\+)","-w","-std=(c89|c99|c\\+\\+0x|c\\+\\+11|c\\+\\+14|c\\+\\+17)","-Wp,{{comma_separated_arg}}","-W{{warning}}","--extra-warnings","--warn-{{warning}}","--warn-={{warning}}","-ferror-limit={{number}}","-O([0-4]?|fast|s|z)"] + compileCmd: 'clang++ -c -arch i386 -target x86_64-apple-darwin11 -isysroot /opt/MacOSX.sdk/ -m32 -O2 -g -mmacosx-version-min=10.7 {{#defines}}-D{{{.}}} {{/defines}} {{#flags}}{{{.}}} {{/flags}} {{#ext.includes}}-I{{{.}}} {{/ext.includes}} {{#ext.frameworkPaths}}-F{{{.}}} {{/ext.frameworkPaths}} {{#includes}}-I{{{.}}} {{/includes}} {{src}} -o{{tgt}}' + linkCmd: 'clang++ -arch i386 -target x86_64-apple-darwin11 -isysroot /opt/MacOSX.sdk/ -m32 -O2 -g -mmacosx-version-min=10.7 -o {{tgt}} {{#linkFlags}}{{{.}}} {{/linkFlags}} {{#ext.libPaths}}-L{{{.}}} {{/ext.libPaths}} {{#libs}}-l{{{.}}} {{/libs}} {{#ext.libs}}-l{{{.}}} {{/ext.libs}} {{#ext.frameworkPaths}}-F{{{.}}} {{/ext.frameworkPaths}} {{#ext.frameworks}}-framework {{{.}}} {{/ext.frameworks}} {{#frameworks}}-framework {{{.}}} {{/frameworks}} {{#libPaths}}-L{{{.}}} {{/libPaths}} {{#engineLibs}}-l{{{.}}} {{/engineLibs}} {{#src}}{{{.}}} {{/src}}' + libCmd: 'llvm-ar rcs {{tgt}} {{#objs}}{{{.}}} {{/objs}}' armv7-android: context: @@ -94,22 +97,26 @@ platforms: engineLibs: ["engine_main", "engine_foo"] libPaths: ["{{dynamo_home}}/lib/armv7-android", "{{dynamo_home}}/ext/lib/armv7-android"] - exePrefix: 'lib' - exeExt: '.so' - shlibRe: 'lib(.+).so' - stlibRe: 'lib(.+).a' - sourceRe: '(?i).+(\.cpp|\.c|\.cc|\.cxx|\.c\+\+)$' - javaSourceRe: '(?i).+(\.java)$' - allowedLibs: ["gnustl_static","supc\\+\\+","c","m","m_hard","stdc\\+\\+",] - allowedFlags: ["-Wa,{{comma_separated_arg}}","-W{{warning}}","-ansi","--ansi","-std-default={{arg}}","-stdlib=(libstdc\\+\\+|libc\\+\\+)","-w","-std=(c89|c99|c\\+\\+0x|c\\+\\+11|c\\+\\+14|c\\+\\+17)","-Wp,{{comma_separated_arg}}","-W{{warning}}","--extra-warnings","--warn-{{warning}}","--warn-={{warning}}","-ferror-limit={{number}}","-O([0-4]?|fast|s|z)"] - compileCmd: 'arm-linux-androideabi-g++ -c -g -gdwarf-2 -fpic -ffunction-sections -fstack-protector -Wno-psabi -march=armv7-a -mfloat-abi=softfp -mfpu=vfp -fomit-frame-pointer -fno-strict-aliasing -finline-limit=64 -fno-exceptions -funwind-tables --sysroot={{android_sysroot}} -DANDROID -Wa,--noexecstack {{#defines}}-D{{.}} {{/defines}} {{#ext.includes}}-I{{.}} {{/ext.includes}} {{#includes}}-I{{.}} {{/includes}} {{#platformIncludes}}-I{{.}} {{/platformIncludes}} {{src}} -o{{tgt}}' - linkCmd: 'arm-linux-androideabi-g++ --sysroot={{android_sysroot}} -lEGL -lGLESv1_CM -lGLESv2 {{#src}}{{.}} {{/src}} -o {{tgt}} -Wl,-soname=libdmengine.so {{#defines}}-D{{.}} {{/defines}} -Wl,--fix-cortex-a8 -Wl,--no-undefined -Wl,-z,noexecstack -landroid -fpic -z text {{#ext.libPaths}}-L{{.}} {{/ext.libPaths}} -Wl,-Bstatic -Wl,--start-group {{#ext.libs}}-l{{.}} {{/ext.libs}} -Wl,--end-group {{#libPaths}}-L{{.}} {{/libPaths}} -Wl,-Bstatic {{#engineLibs}}-l{{.}} {{/engineLibs}} -Wl,-Bdynamic -lOpenSLES -lm -llog -lc -Wl,--no-undefined -Wl,-z,noexecstack -Wl,-z,relro -Wl,-z,now -shared' - libCmd: 'arm-linux-androideabi-ar rcs {{tgt}} {{#objs}}{{.}} {{/objs}}' - javacCmd: 'javac -source 1.6 -target 1.6 -d {{classesDir}} -classpath {{classPath}} @{{sourcesListFile}}' - jarCmd: 'jar cvf {{outputJar}} -C {{classesDir}} .' - dxCmd: 'dx --dex --output {{classes_dex}} {{#jars}}{{.}} {{/jars}} {{#engineJars}}{{.}} {{/engineJars}}' + exePrefix: 'lib' + exeExt: '.so' + shlibRe: 'lib(.+)\.so' + stlibRe: 'lib(.+)\.a' + sourceRe: '(?i).+(\.cpp|\.c|\.cc|\.cxx|\.c\+\+)$' + javaSourceRe: '(?i).+(\.java)$' + writeLibPattern: 'lib%s.a' + writeExePattern: 'libdmengine.so' + allowedLibs: ["gnustl_static","supc\\+\\+","c","m","m_hard","stdc\\+\\+",] + allowedFlags: ["-Wa,{{comma_separated_arg}}","-W{{warning}}","-ansi","--ansi","-std-default={{arg}}","-stdlib=(libstdc\\+\\+|libc\\+\\+)","-w","-std=(c89|c99|c\\+\\+0x|c\\+\\+11|c\\+\\+14|c\\+\\+17)","-Wp,{{comma_separated_arg}}","-W{{warning}}","--extra-warnings","--warn-{{warning}}","--warn-={{warning}}","-ferror-limit={{number}}","-O([0-4]?|fast|s|z)"] + compileCmd: 'arm-linux-androideabi-g++ -c -g -gdwarf-2 -fpic -ffunction-sections -fstack-protector -Wno-psabi -march=armv7-a -mfloat-abi=softfp -mfpu=vfp -fomit-frame-pointer -fno-strict-aliasing -finline-limit=64 -fno-exceptions -funwind-tables --sysroot={{android_sysroot}} -DANDROID -Wa,--noexecstack {{#defines}}-D{{.}} {{/defines}} {{#ext.includes}}-I{{.}} {{/ext.includes}} {{#includes}}-I{{.}} {{/includes}} {{#platformIncludes}}-I{{.}} {{/platformIncludes}} {{src}} -o{{tgt}}' + linkCmd: 'arm-linux-androideabi-g++ --sysroot={{android_sysroot}} -lEGL -lGLESv1_CM -lGLESv2 {{#src}}{{.}} {{/src}} -o {{tgt}} -Wl,-soname=libdmengine.so {{#defines}}-D{{.}} {{/defines}} -Wl,--fix-cortex-a8 -Wl,--no-undefined -Wl,-z,noexecstack -landroid -fpic -z text {{#ext.libPaths}}-L{{.}} {{/ext.libPaths}} -Wl,-Bstatic -Wl,--start-group {{#ext.libs}}-l{{.}} {{/ext.libs}} -Wl,--end-group {{#libPaths}}-L{{.}} {{/libPaths}} -Wl,-Bstatic {{#engineLibs}}-l{{.}} {{/engineLibs}} -Wl,-Bdynamic -lOpenSLES -lm -llog -lc -Wl,--no-undefined -Wl,-z,noexecstack -Wl,-z,relro -Wl,-z,now -shared' + libCmd: 'arm-linux-androideabi-ar rcs {{tgt}} {{#objs}}{{.}} {{/objs}}' + javacCmd: 'javac -source 1.6 -target 1.6 -d {{classesDir}} -classpath {{classPath}} @{{sourcesListFile}}' + jarCmd: 'jar cvf {{outputJar}} -C {{classesDir}} .' + dxCmd: 'dx --dex --output {{classes_dex}} {{#jars}}{{.}} {{/jars}} {{#engineJars}}{{.}} {{/engineJars}}' js-web: + env: + EM_CACHE: "{{build_folder}}" context: engineJsLibs: [] engineLibs: ["engine_main", "engine_foo"] @@ -119,13 +126,43 @@ platforms: emscriptenFlags: ["PRECISE_F32=2", "AGGRESSIVE_VARIABLE_ELIMINATION=1", "TOTAL_MEMORY=268435456", "DISABLE_EXCEPTION_CATCHING=1", "EXPORTED_FUNCTIONS=[\"_main\"]"] libs: [] - exePrefix: '' - exeExt: '.js' - shlibRe: 'lib(.+).so' - stlibRe: 'lib(.+).a' - sourceRe: '(?i).*(\.cpp|\.c|\.cc|\.cxx|\.c\+\+)' - allowedLibs: [] - allowedFlags: ["-Wa,{{comma_separated_arg}}","-W{{warning}}","-ansi","--ansi","-std-default={{arg}}","-stdlib=(libstdc\\+\\+|libc\\+\\+)","-w","-std=(c89|c99|c\\+\\+0x|c\\+\\+11|c\\+\\+14|c\\+\\+17)","-Wp,{{comma_separated_arg}}","-W{{warning}}","--extra-warnings","--warn-{{warning}}","--warn-={{warning}}","-ferror-limit={{number}}","-O([0-4]?|fast|s|z)"] - compileCmd: 'em++ -c -O3 -g {{#defines}}-D{{{.}}} {{/defines}} {{#flags}}{{{.}}} {{/flags}} {{#ext.includes}}-I{{{.}}} {{/ext.includes}} {{#includes}}-I{{{.}}} {{/includes}} {{src}} -o {{tgt}}' - linkCmd: 'em++ {{#src}}{{{.}}} {{/src}} -o {{tgt}} -O3 {{#linkFlags}}{{{.}}} {{/linkFlags}} {{#emscriptenFlags}}-s {{{.}}} {{/emscriptenFlags}} {{#ext.libPaths}}-L{{{.}}} {{/ext.libPaths}} {{#libPaths}}-L{{{.}}} {{/libPaths}} {{#libs}}-l{{{.}}} {{/libs}} {{#ext.libs}}-l{{{.}}} {{/ext.libs}} {{#engineLibs}}-l{{{.}}} {{/engineLibs}} {{#ext.jsLibs}}--js-library {{{.}}} {{/ext.jsLibs}} {{#engineJsLibs}}--js-library {{dynamo_home}}/lib/js-web/js/library_{{{.}}}.js {{/engineJsLibs}}' - libCmd: 'emar rcs {{tgt}} {{#objs}}{{{.}}} {{/objs}}' + exePrefix: '' + exeExt: '.js' + shlibRe: 'lib(.+)\.so' + stlibRe: 'lib(.+)\.a' + sourceRe: '(?i).*(\.cpp|\.c|\.cc|\.cxx|\.c\+\+)' + writeLibPattern: 'lib%s.a' + writeExePattern: 'dmengine.js' + allowedLibs: [] + allowedFlags: ["-Wa,{{comma_separated_arg}}","-W{{warning}}","-ansi","--ansi","-std-default={{arg}}","-stdlib=(libstdc\\+\\+|libc\\+\\+)","-w","-std=(c89|c99|c\\+\\+0x|c\\+\\+11|c\\+\\+14|c\\+\\+17)","-Wp,{{comma_separated_arg}}","-W{{warning}}","--extra-warnings","--warn-{{warning}}","--warn-={{warning}}","-ferror-limit={{number}}","-O([0-4]?|fast|s|z)"] + compileCmd: 'em++ -c -O3 -g {{#defines}}-D{{{.}}} {{/defines}} {{#flags}}{{{.}}} {{/flags}} {{#ext.includes}}-I{{{.}}} {{/ext.includes}} {{#includes}}-I{{{.}}} {{/includes}} {{src}} -o {{tgt}}' + linkCmd: 'em++ {{#src}}{{{.}}} {{/src}} -o {{tgt}} -O3 {{#linkFlags}}{{{.}}} {{/linkFlags}} {{#emscriptenFlags}}-s {{{.}}} {{/emscriptenFlags}} {{#ext.libPaths}}-L{{{.}}} {{/ext.libPaths}} {{#libPaths}}-L{{{.}}} {{/libPaths}} {{#libs}}-l{{{.}}} {{/libs}} {{#ext.libs}}-l{{{.}}} {{/ext.libs}} {{#engineLibs}}-l{{{.}}} {{/engineLibs}} {{#ext.jsLibs}}--js-library {{{.}}} {{/ext.jsLibs}} {{#engineJsLibs}}--js-library {{dynamo_home}}/lib/js-web/js/library_{{{.}}}.js {{/engineJsLibs}}' + libCmd: 'emar rcs {{tgt}} {{#objs}}{{{.}}} {{/objs}}' + + x86_64-win32: + env: + TMP: "{{build_folder}}" + TEMP: "{{build_folder}}" + WINEPATH: "C:/Program Files (x86)/MSBuild/14.0/bin;C:/Program Files (x86)/Microsoft Visual Studio 14.0/Common7/IDE/;C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/BIN/x86_amd64;C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/BIN;C:/Program Files (x86)/Microsoft Visual Studio 14.0/Common7/Tools;C:/WINDOWS/Microsoft.NET/Framework/v4.0.30319;C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/VCPackages;C:/Program Files (x86)/HTML Help Workshop;C:/Program Files (x86)/Microsoft Visual Studio 14.0/Team Tools/Performance Tools;C:/ProgramFilesx86/WindowsKits/8.1/bin/x64;C:/Program Files (x86)/Microsoft SDKs/Windows/v10.0A/bin/NETFX 4.6.1 Tools/" + context: + engineLibs: ["engine_main", "engine_foo"] + libPaths: ["{{dynamo_home}}/lib/x86_64-win32","{{dynamo_home}}/ext/lib/x86_64-win32","C:/ProgramFilesx86/MicrosoftVisualStudio14.0/VC/LIB/amd64","C:/ProgramFilesx86/MicrosoftVisualStudio14.0/VC/ATLMFC/LIB/amd64","C:/ProgramFilesx86/WindowsKits/10/lib/10.0.10240.0/ucrt/x64","C:/ProgramFilesx86/WindowsKits/NETFXSDK/4.6.1/lib/um/x64","C:/ProgramFilesx86/WindowsKits/8.1/lib/winv6.3/um/x64"] + platformIncludes: ["C:/ProgramFilesx86/MicrosoftVisualStudio14.0/VC/INCLUDE","C:/ProgramFilesx86/MicrosoftVisualStudio14.0/VC/ATLMFC/INCLUDE","C:/ProgramFilesx86/WindowsKits/10/include/10.0.10240.0/ucrt","C:/ProgramFilesx86/WindowsKits/NETFXSDK/4.6.1/include/um","C:/ProgramFilesx86/WindowsKits/8.1/include/shared","C:/ProgramFilesx86/WindowsKits/8.1/include/um","C:/ProgramFilesx86/WindowsKits/8.1/include/winrt"] + defines: ["DM_PLATFORM_WINDOWS"] + flags: [] + linkFlags: [] + libs: ["OpenGL32", "User32", "shell32", "Xinput9_1_0", "WS2_32", "IPHlpApi"] + + exePrefix: '' + exeExt: '.exe' + shlibRe: '(.+)\.(dll|Dll|DLL)' + stlibRe: '(.+)\.(lib|Lib|LIB)' + sourceRe: '(?i).*(\.cpp|\.c|\.cc|\.cxx|\.c\+\+)' + writeLibPattern: '%s.lib' + writeExePattern: 'dmengine.exe' + allowedLibs: ["comsupp.lib","comsuppd.lib","comsuppw.lib","comsuppwd.lib","concrt.lib","concrtd.lib","delayimp.lib","iso_stdio_wide_specifiers.lib","legacy_stdio_definitions.lib","legacy_stdio_wide_specifiers.lib","libcmt.lib","libcmtd.lib","libconcrt.lib","libconcrt1.lib","libconcrtd.lib","libconcrtd0.lib","libconcrtd1.lib","libcpmt.lib","libcpmt1.lib","libcpmtd.lib","libcpmtd0.lib","libcpmtd1.lib","libvcruntime.lib","libvcruntimed.lib","msvcmrt.lib","msvcmrtd.lib","msvcprt.lib","msvcprtd.lib","msvcrt.lib","msvcrtd.lib","msvcurt.lib","msvcurtd.lib","oldnames.lib","pgobootrun.lib","pgort.lib","ptrustm.lib","ptrustmd.lib","ptrustu.lib","ptrustud.lib","vcamp.lib","vcampd.lib","vccorlib.lib","vccorlibd.lib","vcomp.lib","vcompd.lib","vcruntime.lib","vcruntimed.lib","VsGraphicsHelper.lib","atls.lib","comsupp.lib","comsuppd.lib","comsuppw.lib","comsuppwd.lib","concrt.lib","concrtd.lib","delayimp.lib","iso_stdio_wide_specifiers.lib","legacy_stdio_definitions.lib","legacy_stdio_wide_specifiers.lib","libcmt.lib","libcmtd.lib","libconcrt.lib","libconcrt1.lib","libconcrtd.lib","libconcrtd0.lib","libconcrtd1.lib","libcpmt.lib","libcpmt1.lib","libcpmtd.lib","libcpmtd0.lib","libcpmtd1.lib","libvcruntime.lib","libvcruntimed.lib","msvcmrt.lib","msvcmrtd.lib","msvcprt.lib","msvcprtd.lib","msvcrt.lib","msvcrtd.lib","msvcurt.lib","msvcurtd.lib","oldnames.lib","pgobootrun.lib","pgort.lib","ptrustm.lib","ptrustmd.lib","ptrustu.lib","ptrustud.lib","vcamp.lib","vcampd.lib","vccorlib.lib","vccorlibd.lib","vcomp.lib","vcompd.lib","vcruntime.lib","vcruntimed.lib","VsGraphicsHelper.lib","atls.lib","libucrt.lib","libucrtd.lib","ucrt.lib","ucrtd.lib","alink.lib","corguids.lib","format.lib","mscoree.lib","mscorsn.lib","tlbref.lib","AclUI.Lib","ActiveDS.Lib","ADSIid.Lib","AdvAPI32.Lib","advpack.Lib","ahadmin.lib","alink.lib","amstrmid.lib","api-ms-win-net-isolation-l1-1-0.lib","appmgmts.lib","appmgr.lib","appnotify.lib","audiobaseprocessingobject.lib","audioeng.lib","audiomediatypecrt.lib","AuthZ.Lib","aux_ulib.lib","avifil32.Lib","avrt.lib","basesrv.lib","bcrypt.lib","Bits.Lib","BluetoothApis.lib","bthprops.lib","BufferOverflow.lib","BufferOverflowU.lib","Cabinet.Lib","certadm.lib","certca.lib","certcli.lib","CertIdl.Lib","CertPolEng.Lib","cfgmgr32.lib","clfsmgmt.lib","clfsw32.lib","ClusApi.Lib","ComCtl32.Lib","ComDlg32.Lib","CompPkgSup.lib","compstui.lib","ComSvcs.Lib","corguids.lib","corrEngine.lib","credui.lib","Crypt32.Lib","cryptdll.lib","CryptNet.Lib","cryptui.lib","cryptxml.lib","cscapi.lib","cscdll.lib","d2d1.lib","d3d10.lib","d3d10_1.lib","d3d11.lib","d3d9.lib","d3dcompiler.lib","d3dcsx.lib","d3dcsxd.lib","davclnt.lib","DbgEng.Lib","DbgHelp.Lib","dciman32.lib","dcomp.lib","ddraw.lib","devenum.lib","deviceaccess.lib","devmgr.lib","dflayout.lib","DhcpCSvc.Lib","DhcpCSvc6.Lib","dhcpsapi.lib","difxapi.lib","dinput8.lib","dloadhelper.lib","dmoguids.lib","DnsAPI.Lib","dnscrcli.lib","dnslib.lib","dnsperf.lib","dnsrpc.lib","dnsrslvr.lib","dpx.lib","drt.lib","drtprov.lib","drttransport.lib","dsound.lib","DSProp.Lib","dssec.lib","dststlog.lib","DSUIExt.Lib","DtcHelp.Lib","dwmapi.lib","dwrite.lib","dxgi.lib","dxguid.lib","dxtmsft.lib","dxtrans.lib","dxva2.lib","eappcfg.lib","eappprxy.lib","easregprov.lib","efswrt.lib","ehstorguids.lib","elfapi.lib","els.lib","ElsCore.lib","esent.lib","evr.lib","evr_vista.lib","FaultRep.Lib","feclient.lib","FhSvcCtl.lib","fileextd.lib","fltLib.lib","fontsub.lib","format.lib","FrameDyd.Lib","FrameDyn.Lib","fwpuclnt.lib","fxsutility.lib","Gdi32.Lib","gdiplus.lib","glmf32.lib","GlU32.Lib","GPEdit.Lib","gpmuuid.lib","hbaapi.lib","hhsetup.lib","hid.lib","HLink.Lib","Htmlhelp.Lib","httpapi.lib","iashlpr.lib","Icm32.Lib","Icmui.Lib","IEPMAPI.Lib","iesetup.lib","ImageHlp.Lib","imgutil.Lib","Imm32.Lib","infocardapi.Lib","inseng.lib","IPHlpApi.Lib","Iprop.Lib","irprops.lib","iscsidsc.lib","jsrt.lib","kerbcli.lib","kernel32.Lib","KSProxy.Lib","ksuser.lib","ktmw32.lib","LoadPerf.Lib","locationapi.lib","Lz32.Lib","magnification.lib","MAPI32.Lib","mbnapi_uuid.lib","mciole32.lib","MDMRegistration.lib","Mf.lib","Mfcore.lib","Mfplat.lib","Mfplat_vista.lib","mfplay.lib","mfreadwrite.lib","Mfsrcsnk.lib","mfuuid.lib","Mf_vista.lib","MgmtAPI.Lib","mi.lib","mincore.lib","mincore_downlevel.lib","MMC.Lib","mmdevapi.lib","Mpr.Lib","Mprapi.Lib","mprsnap.lib","MqOA.Lib","MqRt.Lib","msaatext.lib","MSAcm32.Lib","Mscms.Lib","mscoree.lib","mscorsn.lib","MsCtfMonitor.lib","msdasc.lib","msdelta.lib","msdmo.lib","msdrm.lib","Msi.Lib","MSImg32.Lib","mspatcha.lib","mspatchc.lib","mspbase.lib","msports.lib","MSRating.Lib","MSTask.Lib","msv1_0.lib","msvfw32.Lib","MsWSock.Lib","MsXml2.Lib","msxml6.lib","Mtx.Lib","mtxdm.lib","muiload.lib","ncrypt.lib","nddeapi.lib","ndfapi.lib","ndproxystub.lib","NetAPI32.Lib","netlib.lib","NetSh.Lib","newdev.lib","ninput.lib","normaliz.lib","nt.lib","ntdll.lib","ntdsa.lib","NtDsAPI.Lib","ntdsatq.lib","ntdsetup.lib","ntfrsapi.lib","ntlanman.lib","ntmarta.lib","NtQuery.Lib","ntstc_libcmt.lib","ntstc_msvcrt.lib","objsel.lib","odbc32.lib","odbcbcp.lib","odbccp32.lib","OemLicense.lib","Ole32.Lib","OleAcc.Lib","OleAut32.Lib","olecli32.lib","oledb.lib","OleDlg.Lib","olesvr32.lib","ondemandconnroutehelper.lib","OpenGL32.Lib","osptk.lib","p2p.lib","p2pgraph.lib","pathcch.lib","Pdh.Lib","PeerDist.lib","PhotoAcquireUID.lib","PortableDeviceGuids.lib","powrprof.lib","prntvpt.lib","propsys.lib","Psapi.Lib","quartz.lib","query.lib","qutil.lib","qwave.lib","RASAPI32.Lib","RASDlg.Lib","rasuser.lib","resutils.lib","rometadata.lib","rpcexts.lib","Rpcns4.Lib","rpcproxy.lib","RpcRT4.Lib","rpcutil.lib","rstrtmgr.lib","Rtm.Lib","rtutils.lib","RTWorkQ.lib","runtimeobject.lib","samlib.lib","samsrv.lib","SAPI.Lib","sas.lib","sbtsv.lib","SCardDlg.Lib","scecli.lib","scesrv.lib","schannel.lib","ScrnSave.Lib","ScrnSavW.Lib","SearchSDK.lib","Secur32.Lib","security.lib","sens.lib","SensAPI.Lib","sensorsapi.lib","SetupAPI.Lib","Sfc.Lib","shcore.lib","shdocvw.lib","shell32.lib","ShFolder.Lib","ShLwApi.Lib","sisbkup.lib","slc.lib","slcext.lib","slwga.lib","SnmpAPI.Lib","spoolss.lib","SpOrder.Lib","SrClient.lib","ssdpapi.lib","Sti.Lib","strmbase.lib","strmiids.lib","strsafe.lib","structuredquery.lib","Svcguid.Lib","swdevice.lib","synchronization.lib","t2embed.lib","Tapi32.Lib","tapi32l.lib","taskschd.lib","tbs.lib","tdh.lib","tlbref.lib","Traffic.Lib","TranscodeImageUID.lib","tsec.lib","tspubplugincom.lib","twinapi.lib","txfw32.lib","ualapi.lib","UIAutomationCore.lib","umpdddi.lib","Urlmon.Lib","User32.Lib","UserEnv.Lib","USP10.Lib","Uuid.Lib","Uxtheme.lib","vccomsup.lib","vds_uuid.lib","Version.Lib","Vfw32.Lib","Virtdisk.Lib","vscmgr.lib","vssapi.lib","vss_uuid.lib","vstorinterface.lib","wbemuuid.lib","wcmapi.lib","wcmguid.lib","wdsbp.lib","wdsClientAPI.LIB","wdsmc.lib","wdspxe.lib","wdstptc.lib","WebServices.lib","websocket.lib","wecapi.lib","WER.LIB","wevtapi.lib","WiaGuid.Lib","wiaservc.lib","wiautil.lib","WinBio.lib","windows.data.pdf.lib","windows.networking.lib","windows.ui.lib","windowscodecs.lib","windowssideshowguids.lib","winfax.lib","winhttp.lib","WinInet.Lib","WinMM.Lib","winsatapi.lib","winscard.lib","WinSpool.Lib","winsta.lib","WinStrm.Lib","WinTrust.Lib","winusb.lib","wlanapi.lib","wlanui.lib","Wldap32.Lib","wmcodecdspuuid.lib","wmdrmsdk.lib","wmip.lib","wmiutils.lib","wmvcore.lib","wnvapi.lib","workspaceax.lib","WS2_32.Lib","wsbapp_uuid.Lib","wsbonline.lib","wscapi.lib","wsclient.lib","wsdapi.lib","wsmsvc.lib","WSnmp32.Lib","WSock32.Lib","WtsApi32.Lib","wuguid.lib","xapobase.lib","xaswitch.lib","xaudio2.lib","Xinput.lib","Xinput9_1_0.lib","xmllite.lib","xolehlp.lib","xpsprint.lib"] + allowedFlags: ["//W([0-4]?|all|X)", "//w([1-4]?|d|e|o)[0-9]{4}", "//O([1-2]?|b|d|g|i|s)", "//openmp"] + compileCmd: 'wine cl.exe /nologo /TP /O2 /Oy- /Z7 /MT /D__STDC_LIMIT_MACROS /DWINVER=0x0600 /D_WIN32_WINNT=0x0600 /DWIN32 /D_CRT_SECURE_NO_WARNINGS /wd4200 /W3 /EHsc {{#defines}}/D{{{.}}} {{/defines}} {{#flags}}{{{.}}} {{/flags}} {{#ext.includes}}/I{{{.}}} {{/ext.includes}} {{#includes}}/I{{{.}}} {{/includes}} {{#platformIncludes}}/I{{.}} {{/platformIncludes}} {{src}} /c /Fo{{tgt}}' + linkCmd: 'wine link.exe {{#src}}{{{.}}} {{/src}} /OUT:{{tgt}} /NOLOGO /MANIFEST {{#ext.libPaths}}/LIBPATH:{{{.}}} {{/ext.libPaths}} {{#libPaths}}/LIBPATH:{{{.}}} {{/libPaths}} {{#libs}}{{{.}}}.lib {{/libs}} {{#ext.libs}}{{{.}}}.lib {{/ext.libs}} {{#engineLibs}}{{{.}}}.lib {{/engineLibs}}' + libCmd: 'wine lib.exe /nologo /OUT:{{tgt}} {{#objs}}{{{.}}} {{/objs}}' + mtCmd: 'wine mt.exe /nologo -manifest {{tgt}}.manifest -outputresource:{{tgt}};1' diff --git a/server/test-data/sdk/a/defoldsdk/lib/js-web/libengine_foo.a b/server/test-data/sdk/a/defoldsdk/lib/js-web/libengine_foo.a new file mode 100644 index 00000000..a4398952 Binary files /dev/null and b/server/test-data/sdk/a/defoldsdk/lib/js-web/libengine_foo.a differ diff --git a/server/test-data/sdk/a/defoldsdk/lib/js-web/libengine_main.a b/server/test-data/sdk/a/defoldsdk/lib/js-web/libengine_main.a new file mode 100644 index 00000000..dd0329eb Binary files /dev/null and b/server/test-data/sdk/a/defoldsdk/lib/js-web/libengine_main.a differ diff --git a/server/test-data/sdk/a/defoldsdk/lib/x86-win32/engine_foo.lib b/server/test-data/sdk/a/defoldsdk/lib/x86-win32/engine_foo.lib new file mode 100644 index 00000000..748a097c Binary files /dev/null and b/server/test-data/sdk/a/defoldsdk/lib/x86-win32/engine_foo.lib differ diff --git a/server/test-data/sdk/a/defoldsdk/lib/x86-win32/engine_main.lib b/server/test-data/sdk/a/defoldsdk/lib/x86-win32/engine_main.lib new file mode 100644 index 00000000..91f38d94 Binary files /dev/null and b/server/test-data/sdk/a/defoldsdk/lib/x86-win32/engine_main.lib differ diff --git a/server/test-data/sdk/a/defoldsdk/lib/x86_64-win32/engine_foo.lib b/server/test-data/sdk/a/defoldsdk/lib/x86_64-win32/engine_foo.lib new file mode 100644 index 00000000..e157a469 Binary files /dev/null and b/server/test-data/sdk/a/defoldsdk/lib/x86_64-win32/engine_foo.lib differ diff --git a/server/test-data/sdk/a/defoldsdk/lib/x86_64-win32/engine_main.lib b/server/test-data/sdk/a/defoldsdk/lib/x86_64-win32/engine_main.lib new file mode 100644 index 00000000..e29c0271 Binary files /dev/null and b/server/test-data/sdk/a/defoldsdk/lib/x86_64-win32/engine_main.lib differ diff --git a/server/test-data/testproject_appmanifest/ext/lib/arm64-ios/libalib.a b/server/test-data/testproject_appmanifest/ext/lib/arm64-ios/libalib.a index 14880873..8194d730 100644 Binary files a/server/test-data/testproject_appmanifest/ext/lib/arm64-ios/libalib.a and b/server/test-data/testproject_appmanifest/ext/lib/arm64-ios/libalib.a differ diff --git a/server/test-data/testproject_appmanifest/ext/lib/armv7-android/libalib.a b/server/test-data/testproject_appmanifest/ext/lib/armv7-android/libalib.a index e76050b4..286fbb92 100644 Binary files a/server/test-data/testproject_appmanifest/ext/lib/armv7-android/libalib.a and b/server/test-data/testproject_appmanifest/ext/lib/armv7-android/libalib.a differ diff --git a/server/test-data/testproject_appmanifest/ext/lib/armv7-ios/libalib.a b/server/test-data/testproject_appmanifest/ext/lib/armv7-ios/libalib.a index c7f2efdd..ef2db10a 100644 Binary files a/server/test-data/testproject_appmanifest/ext/lib/armv7-ios/libalib.a and b/server/test-data/testproject_appmanifest/ext/lib/armv7-ios/libalib.a differ diff --git a/server/test-data/testproject_appmanifest/ext/lib/js-web/libalib.a b/server/test-data/testproject_appmanifest/ext/lib/js-web/libalib.a index 9657a6f7..dc4b7d7e 100644 Binary files a/server/test-data/testproject_appmanifest/ext/lib/js-web/libalib.a and b/server/test-data/testproject_appmanifest/ext/lib/js-web/libalib.a differ diff --git a/server/test-data/testproject_appmanifest/ext/lib/x86-osx/libalib.a b/server/test-data/testproject_appmanifest/ext/lib/x86-osx/libalib.a index 6e12ce3d..1cb1f6c1 100644 Binary files a/server/test-data/testproject_appmanifest/ext/lib/x86-osx/libalib.a and b/server/test-data/testproject_appmanifest/ext/lib/x86-osx/libalib.a differ diff --git a/server/test-data/testproject_appmanifest/ext/lib/x86-win32/alib.lib b/server/test-data/testproject_appmanifest/ext/lib/x86-win32/alib.lib new file mode 100644 index 00000000..ca89957e Binary files /dev/null and b/server/test-data/testproject_appmanifest/ext/lib/x86-win32/alib.lib differ diff --git a/server/test-data/testproject_appmanifest/ext/lib/x86_64-osx/libalib.a b/server/test-data/testproject_appmanifest/ext/lib/x86_64-osx/libalib.a index 69e6ba65..d6c83bba 100644 Binary files a/server/test-data/testproject_appmanifest/ext/lib/x86_64-osx/libalib.a and b/server/test-data/testproject_appmanifest/ext/lib/x86_64-osx/libalib.a differ diff --git a/server/test-data/testproject_appmanifest/ext/lib/x86_64-win32/alib.lib b/server/test-data/testproject_appmanifest/ext/lib/x86_64-win32/alib.lib new file mode 100644 index 00000000..27fb8979 Binary files /dev/null and b/server/test-data/testproject_appmanifest/ext/lib/x86_64-win32/alib.lib differ diff --git a/server/test-data/testproject_appmanifest/ext2/lib/arm64-ios/libblib.a b/server/test-data/testproject_appmanifest/ext2/lib/arm64-ios/libblib.a index 13463bc2..e5e845c8 100644 Binary files a/server/test-data/testproject_appmanifest/ext2/lib/arm64-ios/libblib.a and b/server/test-data/testproject_appmanifest/ext2/lib/arm64-ios/libblib.a differ diff --git a/server/test-data/testproject_appmanifest/ext2/lib/armv7-android/libblib.a b/server/test-data/testproject_appmanifest/ext2/lib/armv7-android/libblib.a index 1e8cec81..1ab5a9dd 100644 Binary files a/server/test-data/testproject_appmanifest/ext2/lib/armv7-android/libblib.a and b/server/test-data/testproject_appmanifest/ext2/lib/armv7-android/libblib.a differ diff --git a/server/test-data/testproject_appmanifest/ext2/lib/armv7-ios/libblib.a b/server/test-data/testproject_appmanifest/ext2/lib/armv7-ios/libblib.a index e53c1f07..1d1a90aa 100644 Binary files a/server/test-data/testproject_appmanifest/ext2/lib/armv7-ios/libblib.a and b/server/test-data/testproject_appmanifest/ext2/lib/armv7-ios/libblib.a differ diff --git a/server/test-data/testproject_appmanifest/ext2/lib/js-web/libblib.a b/server/test-data/testproject_appmanifest/ext2/lib/js-web/libblib.a index f9f5accb..b394d973 100644 Binary files a/server/test-data/testproject_appmanifest/ext2/lib/js-web/libblib.a and b/server/test-data/testproject_appmanifest/ext2/lib/js-web/libblib.a differ diff --git a/server/test-data/testproject_appmanifest/ext2/lib/x86-osx/libblib.a b/server/test-data/testproject_appmanifest/ext2/lib/x86-osx/libblib.a index bb71a321..a79cdc5a 100644 Binary files a/server/test-data/testproject_appmanifest/ext2/lib/x86-osx/libblib.a and b/server/test-data/testproject_appmanifest/ext2/lib/x86-osx/libblib.a differ diff --git a/server/test-data/testproject_appmanifest/ext2/lib/x86-win32/blib.lib b/server/test-data/testproject_appmanifest/ext2/lib/x86-win32/blib.lib new file mode 100644 index 00000000..66bfb636 Binary files /dev/null and b/server/test-data/testproject_appmanifest/ext2/lib/x86-win32/blib.lib differ diff --git a/server/test-data/testproject_appmanifest/ext2/lib/x86_64-osx/libblib.a b/server/test-data/testproject_appmanifest/ext2/lib/x86_64-osx/libblib.a index ea0544c7..40686ccc 100644 Binary files a/server/test-data/testproject_appmanifest/ext2/lib/x86_64-osx/libblib.a and b/server/test-data/testproject_appmanifest/ext2/lib/x86_64-osx/libblib.a differ diff --git a/server/test-data/testproject_appmanifest/ext2/lib/x86_64-win32/blib.lib b/server/test-data/testproject_appmanifest/ext2/lib/x86_64-win32/blib.lib new file mode 100644 index 00000000..9393dd10 Binary files /dev/null and b/server/test-data/testproject_appmanifest/ext2/lib/x86_64-win32/blib.lib differ