all: remove the build tag 'ebitencbackend'

This also automatically enables 'egl' when 'nintendosdk' is specified.

Updates #2242
This commit is contained in:
Hajime Hoshi 2022-08-12 12:40:23 +09:00
parent c85d319471
commit e7c0a121c4
41 changed files with 83 additions and 85 deletions

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build nintendosdk || ebitencbackend //go:build nintendosdk
// +build nintendosdk ebitencbackend // +build nintendosdk
package audio package audio

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !nintendosdk && !ebitencbackend //go:build !nintendosdk
// +build !nintendosdk,!ebitencbackend // +build !nintendosdk
package audio package audio

4
doc.go
View File

@ -93,5 +93,7 @@
// They must be called from the main thread or the same goroutine as the given game's callback functions like Update // They must be called from the main thread or the same goroutine as the given game's callback functions like Update
// to RunGame. // to RunGame.
// //
// `microsoftgdk` is for Microsoft GDK (Xbox). // `microsoftgdk` is for Microsoft GDK (e.g. Xbox).
//
// `nintendosdk` is for NintendoSDK (e.g. Nintendo Switch).
package ebiten package ebiten

View File

@ -12,11 +12,11 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build example && (ebitencbackend || (windows && cgo)) //go:build example && (nintendosdk || microsoftgdk)
// +build example // +build example
// +build ebitencbackend windows,cgo // +build nintendosdk microsoftgdk
// This file is for some special environments using `ebitencbackend`. // This file is for some special environments using 'nintendosdk' or 'microsoftgdk'.
// You usually don't have to care about this file. // You usually don't have to care about this file.
// Actually this example works without this file in usual cases. // Actually this example works without this file in usual cases.

View File

@ -825,12 +825,12 @@ func main() {
buildTag = "//go:build !js" + buildTag = "//go:build !js" +
"\n// +build !js" "\n// +build !js"
case filepath.Join("internal", "ui", "keys_mobile.go"): case filepath.Join("internal", "ui", "keys_mobile.go"):
buildTag = "//go:build (android || ios) && !nintendosdk && !ebitencbackend" + buildTag = "//go:build (android || ios) && !nintendosdk" +
"\n// +build android ios" + "\n// +build android ios" +
"\n// +build !nintendosdk,!ebitencbackend" "\n// +build !nintendosdk"
case filepath.Join("internal", "ui", "keys_glfw.go"): case filepath.Join("internal", "ui", "keys_glfw.go"):
buildTag = "//go:build !android && !ios && !js && !nintendosdk && !ebitencbackend" + buildTag = "//go:build !android && !ios && !js && !nintendosdk" +
"\n// +build !android,!ios,!js,!nintendosdk,!ebitencbackend" "\n// +build !android,!ios,!js,!nintendosdk"
} }
// NOTE: According to godoc, maps are automatically sorted by key. // NOTE: According to godoc, maps are automatically sorted by key.
if err := tmpl.Execute(f, struct { if err := tmpl.Execute(f, struct {

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build nintendosdk || ebitencbackend //go:build nintendosdk
// +build nintendosdk ebitencbackend // +build nintendosdk
package cbackend package cbackend

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !nintendosdk && !ebitencbackend //go:build !nintendosdk
// +build !nintendosdk,!ebitencbackend // +build !nintendosdk
package gamepad package gamepad

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build ios && !nintendosdk && !ebitencbackend //go:build ios && !nintendosdk
// +build ios,!nintendosdk,!ebitencbackend // +build ios,!nintendosdk
package gamepad package gamepad

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !android && !nintendosdk && !ebitencbackend //go:build !android && !nintendosdk
// +build !android,!nintendosdk,!ebitencbackend // +build !android,!nintendosdk
package gamepad package gamepad

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !nintendosdk && !ebitencbackend //go:build !nintendosdk
// +build !nintendosdk,!ebitencbackend // +build !nintendosdk
package gamepad package gamepad

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !nintendosdk && !ebitencbackend //go:build !nintendosdk
// +build !nintendosdk,!ebitencbackend // +build !nintendosdk
package gamepad package gamepad

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !nintendosdk && !ebitencbackend //go:build !nintendosdk
// +build !nintendosdk,!ebitencbackend // +build !nintendosdk
package gamepad package gamepad

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !ios && !nintendosdk && !ebitencbackend //go:build !ios && !nintendosdk
// +build !ios,!nintendosdk,!ebitencbackend // +build !ios,!nintendosdk
package gamepad package gamepad

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !nintendosdk && !ebitencbackend //go:build !nintendosdk
// +build !nintendosdk,!ebitencbackend // +build !nintendosdk
package gamepad package gamepad

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build ios && !nintendosdk && !ebitencbackend //go:build ios && !nintendosdk
// +build ios,!nintendosdk,!ebitencbackend // +build ios,!nintendosdk
package gamepad package gamepad

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !android && !nintendosdk && !ebitencbackend //go:build !android && !nintendosdk
// +build !android,!nintendosdk,!ebitencbackend // +build !android,!nintendosdk
package gamepad package gamepad

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build nintendosdk || ebitencbackend //go:build nintendosdk
// +build nintendosdk ebitencbackend // +build nintendosdk
package gamepad package gamepad

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !nintendosdk && !ebitencbackend //go:build !nintendosdk
// +build !nintendosdk,!ebitencbackend // +build !nintendosdk
package gamepad package gamepad

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !nintendosdk && !ebitencbackend //go:build !nintendosdk
// +build !nintendosdk,!ebitencbackend // +build !nintendosdk
package gamepad package gamepad

View File

@ -5,7 +5,7 @@
package gl package gl
// #cgo linux,!nintendosdk,!ebitencbackend freebsd,!nintendosdk,!ebitencbackend openbsd,!nintendosdk,!ebitencbackend pkg-config: gl // #cgo linux,!nintendosdk freebsd,!nintendosdk openbsd,!nintendosdk pkg-config: gl
// //
// #ifndef APIENTRY // #ifndef APIENTRY
// #define APIENTRY // #define APIENTRY

View File

@ -19,10 +19,10 @@ package gl
/* /*
#cgo linux freebsd openbsd CFLAGS: -DTAG_POSIX #cgo linux freebsd openbsd CFLAGS: -DTAG_POSIX
#cgo linux,!nintendosdk,!ebitencbackend freebsd,!nintendosdk,!ebitencbackend openbsd,!nintendosdk,!ebitencbackend pkg-config: gl #cgo linux,!nintendosdk freebsd,!nintendosdk openbsd,!nintendosdk pkg-config: gl
#cgo egl CFLAGS: -DTAG_EGL #cgo egl nintendosdk CFLAGS: -DTAG_EGL
#cgo egl,!nintendosdk,!ebitencbackend pkg-config: egl #cgo egl,!nintendosdk pkg-config: egl
#cgo nintendosdk ebitencbackend LDFLAGS: -Wl,-unresolved-symbols=ignore-all #cgo nintendosdk LDFLAGS: -Wl,-unresolved-symbols=ignore-all
// Check the EGL tag first as it takes priority over the platform's default // Check the EGL tag first as it takes priority over the platform's default
// configuration of WGL/GLX/CGL. // configuration of WGL/GLX/CGL.

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !nintendosdk && !ebitencbackend //go:build !nintendosdk
// +build !nintendosdk,!ebitencbackend // +build !nintendosdk
package ui package ui

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !windows || nintendosdk || ebitencbackend //go:build !windows || nintendosdk
// +build !windows nintendosdk ebitencbackend // +build !windows nintendosdk
package ui package ui

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !nintendosdk && !ebitencbackend //go:build !nintendosdk
// +build !nintendosdk,!ebitencbackend // +build !nintendosdk
package ui package ui

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !android && !ios && !js && !nintendosdk && !ebitencbackend //go:build !android && !ios && !js && !nintendosdk
// +build !android,!ios,!js,!nintendosdk,!ebitencbackend // +build !android,!ios,!js,!nintendosdk
package ui package ui

View File

@ -12,10 +12,9 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build (android || ios) && !nintendosdk && !ebitencbackend //go:build (android || ios) && !nintendosdk
// +build android ios // +build android ios
// +build !nintendosdk // +build !nintendosdk
// +build !ebitencbackend
package ui package ui

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build nintendosdk || ebitencbackend //go:build nintendosdk
// +build nintendosdk ebitencbackend // +build nintendosdk
package ui package ui

View File

@ -14,8 +14,8 @@
// Code generated by genkeys.go using 'go generate'. DO NOT EDIT. // Code generated by genkeys.go using 'go generate'. DO NOT EDIT.
//go:build !android && !ios && !js && !nintendosdk && !ebitencbackend //go:build !android && !ios && !js && !nintendosdk
// +build !android,!ios,!js,!nintendosdk,!ebitencbackend // +build !android,!ios,!js,!nintendosdk
package ui package ui

View File

@ -14,10 +14,9 @@
// Code generated by genkeys.go using 'go generate'. DO NOT EDIT. // Code generated by genkeys.go using 'go generate'. DO NOT EDIT.
//go:build (android || ios) && !nintendosdk && !ebitencbackend //go:build (android || ios) && !nintendosdk
// +build android ios // +build android ios
// +build !nintendosdk // +build !nintendosdk
// +build !ebitencbackend
package ui package ui

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !android && !ios && !js && !nintendosdk && !ebitencbackend && !ebitenginesinglethread && !ebitensinglethread //go:build !android && !ios && !js && !nintendosdk && !ebitenginesinglethread && !ebitensinglethread
// +build !android,!ios,!js,!nintendosdk,!ebitencbackend,!ebitenginesinglethread,!ebitensinglethread // +build !android,!ios,!js,!nintendosdk,!ebitenginesinglethread,!ebitensinglethread
package ui package ui

View File

@ -12,12 +12,11 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !android && !ios && !js && !nintendosdk && !ebitencbackend && (ebitenginesinglethread || ebitensinglethread) //go:build !android && !ios && !js && !nintendosdk && (ebitenginesinglethread || ebitensinglethread)
// +build !android // +build !android
// +build !ios // +build !ios
// +build !js // +build !js
// +build !nintendosdk // +build !nintendosdk
// +build !ebitencbackend
// +build ebitenginesinglethread ebitensinglethread // +build ebitenginesinglethread ebitensinglethread
package ui package ui

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !android && !ios && !js && !nintendosdk && !ebitencbackend //go:build !android && !ios && !js && !nintendosdk
// +build !android,!ios,!js,!nintendosdk,!ebitencbackend // +build !android,!ios,!js,!nintendosdk
package ui package ui

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !ios && !nintendosdk && !ebitencbackend //go:build !ios && !nintendosdk
// +build !ios,!nintendosdk,!ebitencbackend // +build !ios,!nintendosdk
package ui package ui

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !android && !darwin && !js && !windows && !nintendosdk && !ebitencbackend //go:build !android && !darwin && !js && !windows && !nintendosdk
// +build !android,!darwin,!js,!windows,!nintendosdk,!ebitencbackend // +build !android,!darwin,!js,!windows,!nintendosdk
package ui package ui

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !nintendosdk && !ebitencbackend //go:build !nintendosdk
// +build !nintendosdk,!ebitencbackend // +build !nintendosdk
package ui package ui

View File

@ -12,10 +12,9 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build (android || ios) && !nintendosdk && !ebitencbackend //go:build (android || ios) && !nintendosdk
// +build android ios // +build android ios
// +build !nintendosdk // +build !nintendosdk
// +build !ebitencbackend
package ui package ui

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build nintendosdk || ebitencbackend //go:build nintendosdk
// +build nintendosdk ebitencbackend // +build nintendosdk
package ui package ui

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !android && !ios && !js && !nintendosdk && !ebitencbackend //go:build !android && !ios && !js && !nintendosdk
// +build !android,!ios,!js,!nintendosdk,!ebitencbackend // +build !android,!ios,!js,!nintendosdk
package ui package ui

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build !nintendosdk && !ebitencbackend //go:build !nintendosdk
// +build !nintendosdk,!ebitencbackend // +build !nintendosdk
package vibrate package vibrate

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build ios && !nintendosdk && !ebitencbackend //go:build ios && !nintendosdk
// +build ios,!nintendosdk,!ebitencbackend // +build ios,!nintendosdk
package vibrate package vibrate

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build (!android && !ios && !js) || nintendosdk || ebitencbackend //go:build (!android && !ios && !js) || nintendosdk
// +build !android,!ios,!js nintendosdk ebitencbackend // +build !android,!ios,!js nintendosdk
package vibrate package vibrate