Configuring Samsung Emscripten SDK for Tizen Studio
This section describes how to select and configure an instance of the Samsung Emscripten SDK for developing WebAssembly modules in Web applications.
The Samsung Emscripten SDK can be configured for both a Web application project that holds WebAssembly modules and for the modules individually. Once it is configured for any Web application project, each newly added WebAssembly module inherits and uses that setting by default.
To select and set up an instance of the Samsung Emscripten SDK for developing WebAssembly modules in Web applications:
Right-click the WebAssembly module you want to configure the SDK for.
Select "WebAssembly > Configure WebAssembly Toolchain".
In the "Configuration file" field, either manually enter the absolute path to the Samsung Emscripten SDK configuration file, or click "Browse" to select it from the file dialog.NoteSetting the path to the configuration file is required: without a properly configured Emscripten SDK, you are not able to build WebAssembly modules.
The configuration file is created when the Samsung Emscripten SDK is activated and it is typically located in the user's home directory:
- Linux: /home/<user>/.emscripten
- macOS: /Users/<user>/.emscripten
- Windows®: C:\Users\<user>\.emscripten
In the "Cache directory" field, either manually enter the absolute path to the cache directory to be used by the Emscripten SDK, or click "Browse" to select it from the file system of your device. It is strongly recommended that you set a different cache directory for each different version of the Samsung Emscripten SDK installed on your computer - otherwise build errors can occur.
You must also set a different cache directory for each WebAssembly module, since it can sometimes be necessary to clear the cache and such a setup ensures that the clearing does not impact other modules.NoteThe cache directory does not need to exist prior to selecting it, it is created during the first build if it does not exist. However, a cache directory is also created during the Samsung Emscripten SDK activation and selected libraries can be pre-cached there, speeding up subsequent builds. Consequently, select the same cache directory as was created during the activation. It is usually located in the home directory, similar to the configuration file. If the
EM_CACHEenvironment variable was defined prior to the activation, its value is used instead and the cache directory is created at that location.