Skip to content

Commit

Permalink
Remove $PATH/glow requirement for running go generate (#158)
Browse files Browse the repository at this point in the history
  • Loading branch information
myaaaaaaaaa authored Oct 21, 2023
1 parent 726fda9 commit 07e5d0e
Show file tree
Hide file tree
Showing 100 changed files with 219 additions and 182 deletions.
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,6 @@ It is required to have `glow` source in a sibling directory to `go-gl/gl` since
For non-module-aware cases, this means `glow` needs to be in the same Go workspace as `go-gl/gl`.
For module-aware cases, `go-gl/glow` needs to be checked out parallel to `go-gl/gl`.

In either case, the `glow` binary must be in your `$PATH`. Doable with `go get -u github.com/go-gl/glow` if your `$GOPATH/bin` is in your `$PATH`.

Perform generation with the following:

```bash
Expand Down
1 change: 1 addition & 0 deletions all-core/gl/KHR/dummy.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
//go:build required
// +build required

// Package dummy prevents go tooling from stripping the c dependencies.
Expand Down
1 change: 1 addition & 0 deletions all-core/gl/build_cgo_hack.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
//go:build required
// +build required

package gl
Expand Down
6 changes: 3 additions & 3 deletions all-core/gl/conversions.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion all-core/gl/package.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions all-core/gl/procaddr.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions generate.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
// +build gen

//go:generate -command glow go run ../glow/
//go:generate glow generate -out=./v2.1/gl/ -api=gl -version=2.1 -xml=../glow/xml/ -tmpl=../glow/tmpl/
//go:generate glow generate -out=./all-core/gl/ -api=gl -version=all -profile=core -lenientInit -xml=../glow/xml/ -tmpl=../glow/tmpl/
//go:generate glow generate -out=./v3.2-core/gl/ -api=gl -version=3.2 -profile=core -xml=../glow/xml/ -tmpl=../glow/tmpl/
Expand Down
1 change: 1 addition & 0 deletions v2.1/gl/KHR/dummy.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
//go:build required
// +build required

// Package dummy prevents go tooling from stripping the c dependencies.
Expand Down
1 change: 1 addition & 0 deletions v2.1/gl/build_cgo_hack.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
//go:build required
// +build required

package gl
Expand Down
6 changes: 3 additions & 3 deletions v2.1/gl/conversions.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion v2.1/gl/package.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions v2.1/gl/procaddr.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions v3.0/gles2/conversions.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion v3.0/gles2/package.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions v3.0/gles2/procaddr.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions v3.1/gles2/KHR/dummy.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
//go:build required
// +build required

// Package dummy prevents go tooling from stripping the c dependencies.
Expand Down
1 change: 1 addition & 0 deletions v3.1/gles2/build_cgo_hack.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
//go:build required
// +build required

package gles2
Expand Down
6 changes: 3 additions & 3 deletions v3.1/gles2/conversions.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion v3.1/gles2/package.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions v3.1/gles2/procaddr.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions v3.2-compatibility/gl/KHR/dummy.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
//go:build required
// +build required

// Package dummy prevents go tooling from stripping the c dependencies.
Expand Down
1 change: 1 addition & 0 deletions v3.2-compatibility/gl/build_cgo_hack.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
//go:build required
// +build required

package gl
Expand Down
6 changes: 3 additions & 3 deletions v3.2-compatibility/gl/conversions.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion v3.2-compatibility/gl/package.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions v3.2-compatibility/gl/procaddr.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions v3.2-core/gl/KHR/dummy.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
//go:build required
// +build required

// Package dummy prevents go tooling from stripping the c dependencies.
Expand Down
1 change: 1 addition & 0 deletions v3.2-core/gl/build_cgo_hack.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
//go:build required
// +build required

package gl
Expand Down
6 changes: 3 additions & 3 deletions v3.2-core/gl/conversions.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 07e5d0e

Please sign in to comment.