From c3fab81d8dca10d9686e5273bdbe66e33144d63c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=91=D1=80=D0=B0=D0=BD=D0=B8=D0=BC=D0=B8=D1=80=20=D0=9A?= =?UTF-8?q?=D0=B0=D1=80=D0=B0=D1=9F=D0=B8=D1=9B?= Date: Sat, 15 Jun 2019 12:01:26 -0700 Subject: [PATCH] Cleanup. --- scripts/toolchain.lua | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/scripts/toolchain.lua b/scripts/toolchain.lua index 0ab28be..a757749 100644 --- a/scripts/toolchain.lua +++ b/scripts/toolchain.lua @@ -236,13 +236,13 @@ function toolchain(_buildDir, _libDir) elseif "asmjs" == _OPTIONS["gcc"] then - if not os.getenv("EMSCRIPTEN") then - print("Set EMSCRIPTEN environment variable.") + if not os.getenv("EMSDK") then + print("Set EMSDK environment variable.") end - premake.gcc.cc = "\"$(EMSCRIPTEN)/emcc\"" - premake.gcc.cxx = "\"$(EMSCRIPTEN)/em++\"" - premake.gcc.ar = "\"$(EMSCRIPTEN)/emar\"" + premake.gcc.cc = "\"$(EMSDK)/fastcomp/bin/emcc\"" + premake.gcc.cxx = "\"$(EMSDK)/fastcomp/bin/em++\"" + premake.gcc.ar = "\"$(EMSDK)/fastcomp/bin/emar\"" premake.gcc.llvm = true location (path.join(_buildDir, "projects", _ACTION .. "-asmjs")) @@ -926,9 +926,7 @@ function toolchain(_buildDir, _libDir) objdir (path.join(_buildDir, "asmjs/obj")) libdirs { path.join(_libDir, "lib/asmjs") } buildoptions { - "-isystem \"$(EMSCRIPTEN)/system/include\"", - "-isystem \"$(EMSCRIPTEN)/system/include/libcxx\"", - "-isystem \"$(EMSCRIPTEN)/system/include/libc\"", + "-isystem \"$(EMSDK)/fastcomp/emscripten\"", "-Wunused-value", "-Wundef", } @@ -1230,7 +1228,7 @@ function strip() configuration { "asmjs" } postbuildcommands { "$(SILENT) echo Running asmjs finalize.", - "$(SILENT) \"$(EMSCRIPTEN)/emcc\" -O2 " + "$(SILENT) \"$(EMSDK)/fastcomp/bin/emcc\" -O2 " -- .. "-s ALLOW_MEMORY_GROWTH=1 " -- .. "-s ASSERTIONS=2 "