Add directory build/include/wasmtime#82
Conversation
Following the update to Wasmtime's new C API in bytecodealliance#81, the header files are now not only in build/local, but also in build/local/wasmtime. This commit adds the directory "build/include/wasmtime" as a valid empty go package, like it was done in bytecodealliance#45 for the other build directories. It also addapts `ci/local.sh` to: - copy the additional header files in build/include/wasmtime - stop this script from removing the "empty.go" files.
|
Thanks for the PR! I am personally still pretty confused by the Does this mean that everyone has to import with a |
It depends if you use dependency vendoring. By default, you don't, and everything is fine. Your don't have to import anything but However, some projects use You can try
At least one project uses this But it's because they decided to use this vendor feature; that's not the case for the majority of go projects. |
|
Ah ok that makes sense, thanks for the info! Is it possible to move those In either case, though, I'd ideally like to add a test on CI that this works. This is something that I'll undoubtedly regress and break in the future otherwise after I forget... |
Yes, that's way better!
Sure, I'll add a CI test for that. |
- Import build packages, to prevent `go mod vendor` from pruning the build directories; - Update download-wasmtime.py to re-create the "empty.go" files and keep the Go packages in "build" - Add a CI test to check that wasmtime-go can be used by Go projects using dependency vendoring
|
I've updated the PR:
If an |
|
Bazel is failing. I guess I should add the import in |
|
Looks great to me! But yeah unfortunately I don't really know much about |
|
Ok. I'm testing it locally with Bazel. |
|
I've moved the "_" imports to a unused file (not in Bazel, and excluded from build by a build constraint); it seems to fix the Bazel issue, and it still makes |
|
Looks great to me, thanks again for this! |
Following the update to Wasmtime's new C API in #81, the header files are now not only in build/local, but also in build/local/wasmtime.
This commit adds the directory "build/include/wasmtime" as a valid empty go package, like it was done in #45 for the other build directories.
It also addapts
ci/local.shto: