Commit Graph

117 Commits

Author SHA1 Message Date
Ivan Enderlin
b045b415f6 chore(c-api) Update the header files. 2020-12-14 13:42:29 +01:00
Ivan Enderlin
f75eb29620 chore(c-api) Update the header files. 2020-12-14 11:17:46 +01:00
Ivan Enderlin
2ce2c9c7d5 feat(c-api) Add the WASMER_VERSION_{MAJOR|MINOR|PATCH|PRE} constants in C. 2020-12-11 11:03:01 +01:00
Ivan Enderlin
fdeb4a6845 feat(c-api) Add the WASMER_VERSION constant in C. 2020-12-11 10:51:40 +01:00
Ivan Enderlin
18f388df9a Merge branch 'master' into feat-c-api-version 2020-12-11 10:35:26 +01:00
jubianchi
62fa2e506e chore: update wamser_wasm.h 2020-12-10 18:42:41 +01:00
Ivan Enderlin
685ef32c29 chore(c-api) Update the header files. 2020-12-10 17:08:32 +01:00
jubianchi
98a283f327 chore: Add a target to test all the C examples 2020-12-04 18:57:10 +01:00
Mark McCaskey
cd55746864 Update docs on wat2wasm function 2020-12-01 12:28:18 -08:00
Mark McCaskey
3e4b416909 Update lib/c-api/wasmer_wasm.h
Co-authored-by: nlewycky <nick@wasmer.io>
2020-12-01 12:26:36 -08:00
Mark McCaskey
deec77d2df Fix memory leak in wat2wasm function 2020-12-01 11:41:28 -08:00
Mark McCaskey
d0c44c6491 Merge pull request #1842 from wasmerio/host-env-prototype-export-change 2020-11-30 15:41:50 -08:00
Mark McCaskey
40eec3fbd6 Address feedback: misc clean ups 2020-11-25 14:19:29 -08:00
Mark McCaskey
7013163829 WIP attempt to make an Export wrapper type
I can't figure out how we can ever use the non-wrapped type though
2020-11-25 10:59:04 -08:00
Mark McCaskey
de6cb9c4c4 Merge branch 'master' into feature/host-env-prototype 2020-11-20 15:54:35 -08:00
Syrus
2d2b9069c7 Fix comments 2020-11-18 11:05:18 -08:00
Syrus
afbaf129b8 Added deprecated flag to the wasm c api crate 2020-11-18 09:59:12 -08:00
Mark McCaskey
3580f165e8 Rename WasmerEnv::finish to WasmerEnv::init_with_instance 2020-11-17 17:14:11 -08:00
Mark McCaskey
655ac093a2 Fix up helpers generated by WasmerEnv; add unchecked variant 2020-11-17 11:19:42 -08:00
Mark McCaskey
2690e5e8f6 Merge branch 'master' into feature/host-env-prototype 2020-11-16 15:13:29 -08:00
Ivan Enderlin
2e52e1139b chore(c-api) Update wasmer_wasm.h. 2020-11-16 15:19:17 +01:00
Ivan Enderlin
1d208af530 test(c-api) Create a tests/wasmer_wasm.h file.
Remove the `build.rs` hack to add helper functions that are used only
in our tests. Now the tests can use the `tests/wasmer_wasm.h` file,
which simplifies the test workflow: No need to hack the build script
or anything if we want to add a helper function.
2020-11-03 10:41:00 +01:00
Ivan Enderlin
059dfceb60 chore(c-api) Update the header files. 2020-11-02 17:46:36 +01:00
bors[bot]
591691bc17 Merge #1765
1765: doc(c-api) Update documentation. r=Hywan a=Hywan

# Description

This patch adds documentation to the  `engine.rs` module.

# Review

- [ ] ~Add a short description of the the change to the CHANGELOG.md file~ not necessary


Co-authored-by: Ivan Enderlin <ivan@mnt.io>
2020-10-30 10:05:52 +00:00
Mark McCaskey
be3ab95688 Add error handling to host init logic 2020-10-28 17:39:37 -07:00
Mark McCaskey
adc40aeae3 Merge branch 'master' into feature/add-table-example 2020-10-27 11:57:08 -07:00
Ivan Enderlin
ce525e7e90 doc(c-api) Update documentation. 2020-10-27 13:53:47 +01:00
Nick Lewycky
1b3254cf6a Move the generated-by comment up to the first comment. 2020-10-23 11:16:30 -07:00
Nick Lewycky
8ab49df7ab Ahem. 2020-10-23 11:15:31 -07:00
Nick Lewycky
9085480ad0 Update the generated file too, of course. 2020-10-23 11:14:06 -07:00
Mark McCaskey
729a044c75 Add misc updates from feedback 2020-10-21 16:34:27 -07:00
Mark McCaskey
6d326233f7 Merge branch 'master' into fix/create-exe-genearted-code-bugs 2020-10-19 10:03:05 -07:00
Mark McCaskey
1ee99d394c Address feedback and fix small issue with cfg logic 2020-10-16 17:38:59 -07:00
Ivan Enderlin
d7d40e542f Merge branch 'master' into feat-c-api-update-wasm-h 2020-10-16 10:18:46 +02:00
bors[bot]
c5d5ac7bfe Merge #1693
1693: Add `wasmer create-exe` r=MarkMcCaskey a=MarkMcCaskey

This adds the `wasmer create-exe` subcommand.  This subcommand is a combination of `wasmer compile --object-file` and linking that compiled Wasm with a main function and libwasmer.  Put more plainly: it lets us transform Wasm modules into native executables in one step.

In order for this to work we need:
- [x] Ship wasm.h with Wasmer or use different mechanism to find it
- [x] Ship wasmer_wasm.h with Wasmer
- [x] Requires up to date libwasmer... had to build one and copy it over, may fail in CI because of this... will be fixed with next release though
- [x] More gracefully handle wasmer installed without WASMER_DIR, etc (even if just error messages, should be tested)
- [x] Add tests

# Review

- [ ] Add a short description of the the change to the CHANGELOG.md file


Co-authored-by: Mark McCaskey <mark@wasmer.io>
Co-authored-by: Mark McCaskey <5770194+MarkMcCaskey@users.noreply.github.com>
2020-10-13 21:46:16 +00:00
Ivan Enderlin
f866ea39fd fixup 2020-10-12 18:02:45 +02:00
Ivan Enderlin
b9f98ce1f6 feat(c-api) Update .h files. 2020-10-12 17:54:21 +02:00
Ivan Enderlin
437426d8b1 feat(c-api) Update wasmer_wasm.h. 2020-10-12 13:34:55 +02:00
Mark McCaskey
ba7b24f696 Add --dir and --mapdir support to native executable 2020-10-09 17:38:14 -07:00
Mark McCaskey
02c0df5101 Update to cbindgen 0.15.0
Manually specify that items should be sorted by name in the header
file. We do this because cbindgen 0.15.0 removed sorting by default.
2020-10-08 14:42:00 -07:00
Mark McCaskey
65265dbd73 Add first draft of wasmer create-exe 2020-10-08 14:13:54 -07:00
Mark McCaskey
ea8bb1ee79 Merge branch 'master' into feature/engine-object-file 2020-10-06 17:50:55 -07:00
Mark McCaskey
aa2e8f7b4d Address more feedback, clean up code 2020-10-06 12:13:59 -07:00
Ivan Enderlin
ded3132b44 feat(c-api) Implement wat2wasm. 2020-10-06 11:09:35 +02:00
Mark McCaskey
ab153fc642 Improve error messages around memory creation 2020-10-05 15:45:52 -07:00
Mark McCaskey
0f8d68652f Finish merge with C API refactor 2020-10-05 12:30:58 -07:00
Mark McCaskey
1572ae1d5c Merge branch 'master' into feature/engine-object-file 2020-10-02 17:31:06 -07:00
Ivan Enderlin
3a81643ff0 chore(c-api) Update header files. 2020-10-01 21:23:06 +02:00
Ivan Enderlin
a2854ebfea fix(c-api) Adjust cbindgen metadata for header files. 2020-10-01 21:20:13 +02:00
Mark McCaskey
5ac0f89d92 Add small clean up 2020-09-30 17:10:05 -07:00