bblfsh / libuast

Apache License 2.0
20 stars 15 forks source link

Change the way how libuast header is generated #90

Closed dennwc closed 5 years ago

dennwc commented 5 years ago

Previously, the build script was using the libuast.h header generated by cgo. But the generated header had some problems:

The previous solution was using sed to cut some pieces from the file generated by cgo. This approach works but is not portable.

This PR adds a Go script that generates a custom header using Go source code, the same way as cgo does. It allows using proper argument names and as a bonus, embedding (manually written) uast.h into the final libuast.h.

Signed-off-by: Denys Smirnov denys@sourced.tech