summaryrefslogtreecommitdiffhomepage
path: root/examples/rust/Makefile (follow)
AgeCommit message (Collapse)AuthorFilesLines
2025-05-14rust: Fix building of unit-wasm and rust examplesAndrew Clayton1-8/+11
When building the rust stuff we were getting the following compiler error error: failed to run `rustc` to learn about target-specific information ... --- stderr error: Error loading target specification: Could not find specification for target "wasm32-wasi". Run `rustc --print target-list` for a list of built-in targets This is due to wasm32-wasi being renamed to wasm32-wasip1, with wasm32-wasi being kept clear for an eventual WASI 1.0 release. Signed-off-by: Andrew Clayton <a.clayton@nginx.com>
2023-09-25examples: Add C and Rust examples of handling large uploadsAndrew Clayton1-1/+8
The programs demonstrate handling requests with payloads larger than 4GiB which means they need to be written out to disk and so also demonstrates the use of the file-system access mechanism. Signed-off-by: Andrew Clayton <a.clayton@nginx.com>
2023-08-29examples/rust: Fix building of the hello world demoAndrew Clayton1-2/+2
When I renamed it from minimal to hello-world, it stopped being built due to the make target name being the same as the directory name (hello-world). Rename the make target to rust-hello-world which also matches the naming of the rest of the targets. Fixes: 656c036 ("examples/rust: Add a minimal hello world rust example") Signed-off-by: Andrew Clayton <a.clayton@nginx.com>
2023-08-29examples/rust: Add a minimal hello world rust exampleAndrew Clayton1-3/+7
This is about the smallest it can be. Its Unit application config would look like "applications": { "rust-hello-world": { "type": "wasm", "module": "/path/to/unit-wasm/examples/rust/hello-world/target/wasm32-wasi/debug/rust_hello_world.wasm", "request_handler": "uwr_request_handler", "malloc_handler": "luw_malloc_handler", "free_handler": "luw_free_handler" } } Signed-off-by: Andrew Clayton <a.clayton@nginx.com>
2023-08-21Initial commitv0.1.0Andrew Clayton1-0/+17
libunit-wasm and example C and Rust WebAssembly modules for NGINX Unit. Co-developed-by: Timo Stark <t.stark@nginx.com> Co-developed-by: Liam Crilly <liam@nginx.com> Signed-off-by: Andrew Clayton <a.clayton@nginx.com>