pganalyze / pg_query_go

Go library to parse and normalize SQL queries using the PostgreSQL query parser
BSD 3-Clause "New" or "Revised" License
663 stars 79 forks source link

Guard pg_query.go with not windows as well #105

Closed anuraaga closed 1 year ago

anuraaga commented 1 year ago

This is a followup to #102, in https://github.com/sqlc-dev/sqlc/pull/3027 we are trying to allow sqlc to run on windows using the wasm pgquery, even when cgo is enabled (this would allow windows to support both postgresql engine and wasmtime plugins). So it turned out we need to guard the cgo build from this repository against windows as well since it otherwise tries to compile and fail as we found in https://github.com/sqlc-dev/sqlc/pull/3035/files

I didn't add to the test files like before since it didn't seem necessary but let me know

/cc @kyleconroy