Skip to content

Commit

Permalink
Add Emsdk 3.1.65 version and update Node.js requirements
Browse files Browse the repository at this point in the history
Added Emsdk version 3.1.65 with corresponding source details in conandata.yml and config.yml. Updated Node.js to version 20.16.0 in emsdk's build requirements and ensured TypeScript installation using npm. Enhanced Node.js recipe by appending new paths to build and environment info.

Contributes to NP-346
  • Loading branch information
jellespijker committed Oct 2, 2024
1 parent 1714c84 commit e15b699
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 2 deletions.
3 changes: 3 additions & 0 deletions recipes/emsdk/all/conandata.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
sources:
"3.1.65":
url: "https://github.com/emscripten-core/emsdk/archive/3.1.65.tar.gz"
sha256: "6000c66fc5ca81117cbf9f0fd72e288992915bc16df9e6d77c607fab05b472eb"
"3.1.50":
url: "https://github.com/emscripten-core/emsdk/archive/3.1.50.tar.gz"
sha256: "7491a881eb5ee15fe81bbabcfff1fd571e45ccdb24a81890af429f9970cbd1f3"
Expand Down
5 changes: 3 additions & 2 deletions recipes/emsdk/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ def _settings_build(self):
def layout(self):
basic_layout(self, src_folder="src")

def requirements(self):
self.requires("nodejs/16.3.0")
def build_requirements(self):
self.test_requires("nodejs/20.16.0")
# self.requires("python") # FIXME: Not available as Conan package
# self.requires("wasm") # FIXME: Not available as Conan package

Expand Down Expand Up @@ -129,6 +129,7 @@ def package(self):
# the line below forces emscripten to accept the cache as-is, even after re-location
# https://github.com/emscripten-core/emscripten/issues/15053#issuecomment-920950710
os.remove(os.path.join(self._em_cache, "sanity.txt"))
self.run("npm install -g typescript", env=["conanemsdk", "conanrun", "conanbuild"])

def _define_tool_var(self, value):
suffix = ".bat" if self.settings.os == "Windows" else ""
Expand Down
2 changes: 2 additions & 0 deletions recipes/emsdk/config.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
versions:
"3.1.65":
folder: all
"3.1.50":
folder: all
3 changes: 3 additions & 0 deletions recipes/nodejs/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,3 +64,6 @@ def package_info(self):
# TODO: Legacy, to be removed on Conan 2.0
bin_dir = os.path.join(self.package_folder, "bin")
self.env_info.PATH.append(bin_dir)
self.buildenv_info.append_path("PATH", bin_dir)
self.env_info.PATH.append(os.path.join(self.package_folder, "lib", "node_modules", ".bin"))
self.buildenv_info.append_path("PATH", os.path.join(self.package_folder, "lib", "node_modules", ".bin"))

0 comments on commit e15b699

Please sign in to comment.