From 8e6e40b37e6ac0a1e7c4a23b9ef687ff4acd4a92 Mon Sep 17 00:00:00 2001 From: Jordan Last Date: Thu, 29 Aug 2024 18:53:30 -0500 Subject: [PATCH] clean up remaining wasmedge_quickjs stuff --- .eslintignore | 1 - .gitignore | 1 - .npmignore | 1 - .prettierignore | 1 - .../commands/compile/javascript.ts | 41 +++++++++---------- 5 files changed, 19 insertions(+), 26 deletions(-) diff --git a/.eslintignore b/.eslintignore index 4b1bdec12a..fe97082244 100644 --- a/.eslintignore +++ b/.eslintignore @@ -9,4 +9,3 @@ declarations property_tests/tests/**/src/* dist static_canister_template_licenses.yml -wasmedge_quickjs diff --git a/.gitignore b/.gitignore index 21cd734771..a25a888abd 100644 --- a/.gitignore +++ b/.gitignore @@ -6,4 +6,3 @@ dist node_modules target -wasmedge_quickjs diff --git a/.npmignore b/.npmignore index 9ef4d3f989..0958955d01 100644 --- a/.npmignore +++ b/.npmignore @@ -30,4 +30,3 @@ !package.json !README.md !server.did -!wasmedge_quickjs/** diff --git a/.prettierignore b/.prettierignore index 2dcec44090..521b488aa0 100644 --- a/.prettierignore +++ b/.prettierignore @@ -7,4 +7,3 @@ target /the_azle_book/book /docs static_canister_template_licenses.yml -/wasmedge_quickjs diff --git a/src/build/experimental/commands/compile/javascript.ts b/src/build/experimental/commands/compile/javascript.ts index 9b0d10461a..f31c4ceeb4 100644 --- a/src/build/experimental/commands/compile/javascript.ts +++ b/src/build/experimental/commands/compile/javascript.ts @@ -93,9 +93,6 @@ export function getBuildOptions( esmAliases: Record, esmExternals: string[] ): BuildOptions { - const finalWasmedgeQuickJsPath = - process.env.AZLE_WASMEDGE_QUICKJS_PATH ?? WASMEDGE_QUICKJS_PATH; - const externalImplemented = [ '_node:fs', '_node:os', @@ -134,25 +131,25 @@ export function getBuildOptions( return { ...stableBuildOptions, alias: { - internal: `${finalWasmedgeQuickJsPath}/modules/internal`, - util: `${finalWasmedgeQuickJsPath}/modules/util`, - fs: `${finalWasmedgeQuickJsPath}/modules/fs`, - fmt: `${finalWasmedgeQuickJsPath}/modules/fmt`, - assert: `${finalWasmedgeQuickJsPath}/modules/assert.js`, - buffer: `${finalWasmedgeQuickJsPath}/modules/buffer.js`, - path: `${finalWasmedgeQuickJsPath}/modules/path.js`, - stream: `${finalWasmedgeQuickJsPath}/modules/stream.js`, - process: `${finalWasmedgeQuickJsPath}/modules/process.js`, - url: `${finalWasmedgeQuickJsPath}/modules/url.js`, - events: `${finalWasmedgeQuickJsPath}/modules/events.js`, - string_decoder: `${finalWasmedgeQuickJsPath}/modules/string_decoder.js`, - punycode: `${finalWasmedgeQuickJsPath}/modules/punycode.js`, - querystring: `${finalWasmedgeQuickJsPath}/modules/querystring.js`, - whatwg_url: `${finalWasmedgeQuickJsPath}/modules/whatwg_url.js`, - encoding: `${finalWasmedgeQuickJsPath}/modules/encoding.js`, - http: `${finalWasmedgeQuickJsPath}/modules/http.js`, - os: `${finalWasmedgeQuickJsPath}/modules/os.js`, - // crypto: `${finalWasmedgeQuickJsPath}/modules/crypto.js`, // TODO waiting on wasi-crypto + internal: `${WASMEDGE_QUICKJS_PATH}/modules/internal`, + util: `${WASMEDGE_QUICKJS_PATH}/modules/util`, + fs: `${WASMEDGE_QUICKJS_PATH}/modules/fs`, + fmt: `${WASMEDGE_QUICKJS_PATH}/modules/fmt`, + assert: `${WASMEDGE_QUICKJS_PATH}/modules/assert.js`, + buffer: `${WASMEDGE_QUICKJS_PATH}/modules/buffer.js`, + path: `${WASMEDGE_QUICKJS_PATH}/modules/path.js`, + stream: `${WASMEDGE_QUICKJS_PATH}/modules/stream.js`, + process: `${WASMEDGE_QUICKJS_PATH}/modules/process.js`, + url: `${WASMEDGE_QUICKJS_PATH}/modules/url.js`, + events: `${WASMEDGE_QUICKJS_PATH}/modules/events.js`, + string_decoder: `${WASMEDGE_QUICKJS_PATH}/modules/string_decoder.js`, + punycode: `${WASMEDGE_QUICKJS_PATH}/modules/punycode.js`, + querystring: `${WASMEDGE_QUICKJS_PATH}/modules/querystring.js`, + whatwg_url: `${WASMEDGE_QUICKJS_PATH}/modules/whatwg_url.js`, + encoding: `${WASMEDGE_QUICKJS_PATH}/modules/encoding.js`, + http: `${WASMEDGE_QUICKJS_PATH}/modules/http.js`, + os: `${WASMEDGE_QUICKJS_PATH}/modules/os.js`, + // crypto: `${WASMEDGE_QUICKJS_PATH}/modules/crypto.js`, // TODO waiting on wasi-crypto crypto: 'crypto-browserify', // TODO we really want the wasmedge-quickjs version once wasi-crypto is working zlib: 'pako', 'internal/deps/acorn/acorn/dist/acorn': join(