github.com/wbrown/gpt_bpe@v0.0.0-20250709161131-1571a6e8ad2d/Makefile (about)

     1  GO_VERSION := 1.17.9
     2  #GOPHERJS_VERSION := 1.17.2
     3  GOPHERJS_VERSION := f2ebe46
     4  GO := go${GO_VERSION}
     5  ARCH := $(shell uname)
     6  
     7  lib: clean gopherjs
     8  	cd js; gopherjs build --minify --verbose -o gpt_bpe.js
     9  
    10  clean:
    11  	cd js; rm -f gpt_bpe.js
    12  
    13  go:
    14  	go install golang.org/dl/${GO}@latest
    15  	go mod tidy
    16  	${GO} install
    17  
    18  embeds:
    19  	cd resources/embedder; go run generate.go
    20  
    21  gopherjs: go embeds
    22  	$(eval GOPHERJS_GOROOT := $(shell ${GO} env GOROOT))
    23  	$(eval GOROOT := $(shell ${GO} env GOROOT))
    24  	#${GO} install github.com/gopherjs/gopherjs@v${GOPHERJS_VERSION}+${GO}
    25  	${GO} install github.com/gopherjs/gopherjs@${GOPHERJS_VERSION}