Advertisement
FlyFar

makefile

Dec 17th, 2023
850
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Make 0.52 KB | Cybersecurity | 0 0
  1. BUILD=go build -ldflags="-w -s"
  2.  
  3. default: build
  4.  
  5. build:
  6.     @echo "Building cry..."
  7.     $(BUILD) -o bin/cry.exe
  8.     @echo "Building server..."
  9.     cd web/ && $(BUILD) -o ../bin/web.exe
  10.  
  11. clean:
  12.     @rm -rf bin/
  13.     @rm -f debug debug.test web/debug web/debug.test
  14.  
  15. all:
  16.     GOOS=windows GOARCH=amd64 $(BUILD) -o bin/windows_amd64.exe
  17.     GOOS=windows GOARCH=386 $(BUILD) -o bin/windows_x86.exe
  18.     GOOS=linux GOARCH=amd64 $(BUILD) -o bin/linux_amd64
  19.     GOOS=linux GOARCH=386 $(BUILD) -o bin/linux_x86
  20.     GOOS=darwin GOARCH=amd64 $(BUILD) -o bin/macos
Tags: makefile
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement