File: 2003_no_wasm.patch

package info (click to toggle)
rust-swc-core 22.2.1~ds-1
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 62,436 kB
  • sloc: javascript: 853; xml: 538; sh: 307; makefile: 35; python: 5
file content (114 lines) | stat: -rw-r--r-- 3,565 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
Description: avoid WASM-only crates
Author: Jonas Smedegaard <dr@jones.dk>
Forwarded: not-needed
Last-Update: 2024-04-12
---
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
--- a/crates/binding_macros/Cargo.toml
+++ b/crates/binding_macros/Cargo.toml
@@ -12,24 +12,6 @@
 
 [features]
 binding_native = []
-binding_wasm = [
-  # SWC features
-  "swc",
-  "swc_common",
-  "swc_ecma_transforms",
-  "swc_ecma_ast",
-  "swc_ecma_visit",
-
-  # Optional packages
-  "once_cell",
-  "wasm-bindgen",
-  "wasm-bindgen-futures",
-  "js-sys",
-  "serde",
-  "serde-wasm-bindgen",
-  "anyhow",
-  "console_error_panic_hook",
-]
 
 [dependencies]
 # Common deps for the SWC imports
@@ -38,21 +20,3 @@
 swc_ecma_ast        = { optional = true, version = "8.1.1", path = "../swc_ecma_ast" }
 swc_ecma_transforms = { optional = true, version = "15.0.0", path = "../swc_ecma_transforms" }
 swc_ecma_visit      = { optional = true, version = "8.0.0", path = "../swc_ecma_visit" }
-
-# Optional deps for the wasm binding macro
-anyhow                   = { workspace = true, optional = true }
-console_error_panic_hook = { workspace = true, optional = true }
-js-sys                   = { workspace = true, optional = true }
-once_cell                = { workspace = true, optional = true }
-serde                    = { workspace = true, features = ["derive"], optional = true }
-serde-wasm-bindgen       = { workspace = true, optional = true }
-
-
-  [dependencies.wasm-bindgen]
-  features  = ["enable-interning"]
-  optional  = true
-  workspace = true
-
-  [dependencies.wasm-bindgen-futures]
-  optional  = true
-  workspace = true
--- a/crates/swc_core/Cargo.toml
+++ b/crates/swc_core/Cargo.toml
@@ -175,7 +175,6 @@
 trace_macro = ["swc_trace_macro"]
 
 binding_macro_native = ["__binding_macros", "binding_macros/binding_native"]
-binding_macro_wasm   = ["__binding_macros", "binding_macros/binding_wasm"]
 
 ## Plugins
 # Top level features should be enabled to write plugins for the custom transform.
@@ -203,12 +202,6 @@
 # native feature is for the host environment does not have, or cannot access
 # to the wasm runtime (i.e cli, or @swc/core node bindings).
 # js feature is for the environment can access wasm runtime (i.e @swc/wasm)
-plugin_transform_host_js = [
-  # Dependent features
-  "__plugin_transform_host",
-  "__plugin_transform_host_schema_v1",
-  "__plugin_transform_env_js",
-]
 plugin_transform_host_native = [
   # Dependent features
   "__plugin_transform_host",
@@ -306,11 +299,6 @@
   "swc_plugin_runner/plugin_transform_host_native",
 ]
 
-__plugin_transform_env_js = [
-  "swc/plugin_transform_host_js",
-  "swc_plugin_runner/plugin_transform_host_js",
-]
-
 # Do not use: testing purpose only
 # Force enable different version of AST schema
 __plugin_transform_schema_test = [
--- a/crates/swc_plugin_runner/Cargo.toml
+++ b/crates/swc_plugin_runner/Cargo.toml
@@ -15,11 +15,6 @@
 
 [features]
 default = ["filesystem_cache", "plugin_transform_host_native"]
-plugin_transform_host_js = [
-  "wasmer/js-default",
-  "wasmer-wasix/js-default",
-  "wasmer-compiler-cranelift/wasm",
-]
 plugin_transform_host_native = [
   "wasmer/default",
   "wasmer-wasix/sys",
--- a/crates/swc_fast_ts_strip/Cargo.toml
+++ b/crates/swc_fast_ts_strip/Cargo.toml
@@ -14,7 +14,6 @@
 [dependencies]
 anyhow       = { workspace = true }
 serde        = { workspace = true, features = ["derive"] }
-wasm-bindgen = { workspace = true, optional = true }
 
 swc_allocator = { version = "4.0.0", path = "../swc_allocator", default-features = false }