forked from vikunja/vikunja
Add cross-compiling for freebsd
This commit is contained in:
parent
568cc16797
commit
adeff54d32
|
@ -467,6 +467,7 @@ func (Release) Release(ctx context.Context) error {
|
|||
errs.Go((Release{}).Windows)
|
||||
errs.Go((Release{}).Linux)
|
||||
errs.Go((Release{}).Darwin)
|
||||
errs.Go((Release{}).FreeBSD)
|
||||
if err := errs.Wait(); err != nil {
|
||||
return err
|
||||
}
|
||||
|
@ -510,6 +511,9 @@ func runXgo(targets string) error {
|
|||
if strings.HasPrefix(targets, "darwin") {
|
||||
extraLdflags = ""
|
||||
}
|
||||
if strings.HasPrefix(targets, "freebsd") {
|
||||
extraLdflags = ""
|
||||
}
|
||||
|
||||
runAndStreamOutput("xgo",
|
||||
"-dest", RootPath+"/"+DIST+"/binaries",
|
||||
|
@ -546,6 +550,11 @@ func (Release) Darwin() error {
|
|||
return runXgo("darwin-10.15/*")
|
||||
}
|
||||
|
||||
// Builds binaries for freebsd
|
||||
func (Release) FreeBSD() error {
|
||||
return runXgo("freebsd/amd64")
|
||||
}
|
||||
|
||||
func (Release) Xgo(target string) error {
|
||||
parts := strings.Split(target, "/")
|
||||
if len(parts) < 2 {
|
||||
|
|
Loading…
Reference in New Issue