mage: always build the plugin on linux
This commit is contained in:
parent
ea931db0b2
commit
2074d01b9e
7
mage.go
7
mage.go
|
@ -54,7 +54,7 @@ func goBuildPlugin(ctx context.Context, dir, pkgname, fname string) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
shouldWork(ctx, nil, dir, "go", "build", "-buildmode=plugin", "-o=fname", pkgBase+pkgname)
|
shouldWork(ctx, nil, dir, "go", "build", "-buildmode=plugin", "-o="+fname, pkgBase+pkgname)
|
||||||
}
|
}
|
||||||
|
|
||||||
func buildBins(goos string) {
|
func buildBins(goos string) {
|
||||||
|
@ -79,6 +79,7 @@ func buildBins(goos string) {
|
||||||
// Linux builds binaries for linux
|
// Linux builds binaries for linux
|
||||||
func Linux() {
|
func Linux() {
|
||||||
buildBins("linux")
|
buildBins("linux")
|
||||||
|
Plugin()
|
||||||
}
|
}
|
||||||
|
|
||||||
// Windows builds binaries for windows
|
// Windows builds binaries for windows
|
||||||
|
@ -94,6 +95,10 @@ func Darwin() {
|
||||||
// Build builds the binaries for route and routed.
|
// Build builds the binaries for route and routed.
|
||||||
func Build() {
|
func Build() {
|
||||||
buildBins(runtime.GOOS)
|
buildBins(runtime.GOOS)
|
||||||
|
|
||||||
|
if runtime.GOOS == "linux" {
|
||||||
|
Plugin()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Plugin builds all of the plugins for programs wanting to augment themselves with route.
|
// Plugin builds all of the plugins for programs wanting to augment themselves with route.
|
||||||
|
|
Loading…
Reference in New Issue