all: use baremetal build tag

This simplifies adding more baremetal targets, like a GameBoy Advance,
or baremetal x86 for unikernels.
This commit is contained in:
Ayke van Laethem
2019-07-31 20:32:18 +02:00
committed by Ron Evans
parent f76385850d
commit 54169c714f
19 changed files with 19 additions and 19 deletions
+1 -1
View File
@@ -226,7 +226,7 @@ func (c *Compiler) Compile(mainPath string) []error {
return path
} else if path == "syscall" {
for _, tag := range c.BuildTags {
if tag == "avr" || tag == "cortexm" || tag == "darwin" || tag == "riscv" {
if tag == "baremetal" || tag == "darwin" {
return path
}
}
+1 -1
View File
@@ -18,7 +18,7 @@ func (c *Compiler) needsStackObjects() bool {
return false
}
for _, tag := range c.BuildTags {
if tag == "cortexm" || tag == "tinygo.riscv" {
if tag == "baremetal" {
return false
}
}
+1 -1
View File
@@ -1,4 +1,4 @@
// +build !stm32f4disco,!hifive1b
// +build avr nrf sam stm32,!stm32f4disco
package machine
+1 -1
View File
@@ -1,4 +1,4 @@
// +build !avr,!nrf,!sam,!sifive,!stm32
// +build !baremetal
package machine
+1 -1
View File
@@ -1,4 +1,4 @@
// +build !stm32f407,!avr,!hifive1b
// +build nrf sam stm32,!stm32f407
package machine
+1 -1
View File
@@ -1,4 +1,4 @@
// +build avr cortexm tinygo.riscv wasm
// +build baremetal wasm
package os
+1 -1
View File
@@ -1,4 +1,4 @@
// +build darwin linux,!avr,!cortexm,!tinygo.riscv
// +build darwin linux,!baremetal
package os
+1 -1
View File
@@ -1,4 +1,4 @@
// +build arm,!avr,!cortexm,!tinygo.riscv
// +build arm,!baremetal
package runtime
+1 -1
View File
@@ -1,4 +1,4 @@
// +build avr cortexm tinygo.riscv
// +build baremetal
package runtime
+1 -1
View File
@@ -1,5 +1,5 @@
// +build gc.conservative
// +build cortexm tinygo.riscv
// +build baremetal
package runtime
+1 -1
View File
@@ -1,5 +1,5 @@
// +build gc.conservative
// +build !cortexm,!tinygo.riscv
// +build !baremetal
package runtime
+1 -1
View File
@@ -1,5 +1,5 @@
// +build gc.conservative
// +build !cortexm,!tinygo.riscv
// +build !baremetal
package runtime
+1 -1
View File
@@ -1,5 +1,5 @@
// +build gc.conservative
// +build cortexm tinygo.riscv
// +build baremetal
package runtime
+1 -1
View File
@@ -1,4 +1,4 @@
// +build darwin linux,!avr,!cortexm,!tinygo.riscv
// +build darwin linux,!baremetal
package runtime
+1 -1
View File
@@ -1,4 +1,4 @@
// +build avr cortexm
// +build baremetal
package syscall
+1 -1
View File
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// +build avr cortexm
// +build baremetal
package syscall
+1 -1
View File
@@ -1,5 +1,5 @@
{
"build-tags": ["avr", "linux", "arm"],
"build-tags": ["avr", "baremetal", "linux", "arm"],
"goos": "linux",
"goarch": "arm",
"compiler": "avr-gcc",
+1 -1
View File
@@ -1,5 +1,5 @@
{
"build-tags": ["cortexm", "linux", "arm"],
"build-tags": ["cortexm", "baremetal", "linux", "arm"],
"goos": "linux",
"goarch": "arm",
"compiler": "clang",
+1 -1
View File
@@ -2,7 +2,7 @@
"llvm-target": "riscv32--none",
"goos": "linux",
"goarch": "arm",
"build-tags": ["tinygo.riscv", "linux", "arm"],
"build-tags": ["tinygo.riscv", "baremetal", "linux", "arm"],
"gc": "conservative",
"compiler": "riscv64-unknown-elf-gcc",
"linker": "riscv64-unknown-elf-ld",