SolarLune / masterplan

MasterPlan is a project management software / visual idea board software. It attempts to be easy to use, lightweight, and fun.
https://solarlune.itch.io/masterplan
512 stars 46 forks source link

Cannot compile on Windows due to several issues #93

Open Sparkwave2 opened 1 year ago

Sparkwave2 commented 1 year ago

When trying to compile using go run ./ the following errors display:

github.com/veandco/go-sdl2/gfx: build constraints exclude all Go files in C:\Users\Plazm\go\pkg\mod\github.com\veandco\go-sdl2@v0.4.35\gfx
github.com/veandco/go-sdl2/img: build constraints exclude all Go files in C:\Users\Plazm\go\pkg\mod\github.com\veandco\go-sdl2@v0.4.35\img
github.com/veandco/go-sdl2/ttf: build constraints exclude all Go files in C:\Users\Plazm\go\pkg\mod\github.com\veandco\go-sdl2@v0.4.35\ttf

I tried compiling using go run ./build_script/main.go -b and it behaved differently, instead outputting this

< Beginning build to "bin\windows-0.8-Release-64" for windows. >
<Assets copied.>
<Building binary with args:  [go build -ldflags -s -w -H windowsgui -tags release -o bin\windows-0.8-Release-64\MasterPlan.exe ./] .>
<ERROR:  exit status 1>
< Beginning build to "bin\windows-0.8-Demo-64" for windows. >
<Assets copied.>
<Building binary with args:  [go build -ldflags -s -w -H windowsgui -tags demo -o bin\windows-0.8-Demo-64\MasterPlan.exe ./] .>
<ERROR:  exit status 1>

My Go version is 1.21.0, and I'm building this on Windows 10

skejeton commented 8 months ago

Same issue, you have to follow instructions in go-sdl2 go module on installing SDL2 for MinGW. The issue would be resolved except for one - it also requires SDL2_gfx which is an unofficial module so you need to build it yourself.