You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Use Cargo hyperlight to build rust guests
Signed-off-by: James Sturtevant <jsturtevant@gmail.com>
* Fixed typo in README
Signed-off-by: Simon Davies <simongdavies@users.noreply.github.com>
---------
Signed-off-by: James Sturtevant <jsturtevant@gmail.com>
Signed-off-by: Simon Davies <simongdavies@users.noreply.github.com>
Co-authored-by: Simon Davies <simongdavies@users.noreply.github.com>
**Note**: Guest applications require a specific build configuration. Create a `.cargo/config.toml` file in your guest project with the following content:
108
-
109
-
```toml
110
-
[build]
111
-
target = "x86_64-unknown-none"
112
-
113
-
[target.x86_64-unknown-none]
114
-
rustflags = [
115
-
"-C",
116
-
"code-model=small",
117
-
"-C",
118
-
"link-args=-e entrypoint",
119
-
]
120
-
linker = "rust-lld"
121
-
122
-
[profile.release]
123
-
panic = "abort"
124
-
125
-
[profile.dev]
126
-
panic = "abort"
107
+
Build the guest using [cargo-hyperlight](https://github.com/hyperlight-dev/cargo-hyperlight):
108
+
109
+
```
110
+
cargo install --locked cargo-hyperlight
111
+
cargo hyperlight build
127
112
```
128
113
129
114
For additional examples of using the Hyperlight host Rust library, see
0 commit comments