Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Passing the link of empack_env_meta.json file #640

Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 16 additions & 4 deletions wasm_patches/post.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,23 @@ Module.ERRNO_CODES = ERRNO_CODES;
Module['async_init'] = async function(
kernel_root_url,
pkg_root_url,
verbose) {
verbose,
empack_env_meta_link = '') {

/* It should work with any kernel so we have to keep logic for this too
by default it will work with local empack_env_meta.json
*/
let packages_json_url = `${kernel_root_url}/empack_env_meta.json`;

// if we host empack_env_meta somewhere else then we have to proceed it
if (empack_env_meta_link) {
packages_json_url = empack_env_meta_link;
}

Module['bootstrap_from_empack_packed_environment']
return Module['bootstrap_from_empack_packed_environment'](
`${kernel_root_url}/empack_env_meta.json`, /* packages_json_url */
packages_json_url,
pkg_root_url, /* package_tarballs_root_url */
verbose /* verbose */
verbose, /* verbose */
);
}
}
Loading