Skip to content

Remove requirement that the module to link exports _start.#60

Merged
peterhuene merged 2 commits intobytecodealliance:mainfrom
peterhuene:fix-wasmlink
Aug 9, 2021
Merged

Remove requirement that the module to link exports _start.#60
peterhuene merged 2 commits intobytecodealliance:mainfrom
peterhuene:fix-wasmlink

Conversation

@peterhuene
Copy link
Member

This PR removes the requirement that the root module being linked
exports a _start function.

Instead, it now simply reexports all exported functions. This will
enable use of the linked modules from profiles where a start function
isn't necessary (i.e. the host will call some other function).

Updated the CLI to remove references to a "main" module.

Fixes #59.

This commit removes the requirement that the root module being linked
exports a `_start` function.

Instead, it now simply reexports all exported functions.  This will
enable use of the linked modules from profiles where a start function
isn't necessary (i.e. the host will call some other function).

Updated the CLI to remove references to a "main" module.

Fixes bytecodealliance#59.
@peterhuene
Copy link
Member Author

cc @radu-matei

This commit also adds exporting any exported memories from the root
module after linking.
@peterhuene peterhuene merged commit a67ab5d into bytecodealliance:main Aug 9, 2021
@peterhuene peterhuene deleted the fix-wasmlink branch August 9, 2021 22:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Using linked module from the Wasmtime generated code results in missing canonical_abi_free export

3 participants