Exclude VNC server from js, ios, and android builds

This commit is contained in:
Viktor Liu
2026-05-17 09:48:06 +02:00
parent 4f884d9f30
commit da37a28951
23 changed files with 46 additions and 35 deletions

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package internal
import (

View File

@@ -1,13 +1,15 @@
//go:build (!windows && !darwin && !freebsd && !(linux && !android)) || (darwin && ios)
//go:build js || ios || android
package internal
import vncserver "github.com/netbirdio/netbird/client/vnc/server"
import (
mgmProto "github.com/netbirdio/netbird/shared/management/proto"
)
func newPlatformVNC() (vncserver.ScreenCapturer, vncserver.InputInjector, bool) {
return nil, nil, false
}
type vncServer interface{}
func vncNeedsServiceMode() bool {
return false
}
func (e *Engine) updateVNC(_ *mgmProto.SSHConfig) error { return nil }
func (e *Engine) updateVNCServerAuth(_ *mgmProto.VNCAuth) {}
func (e *Engine) stopVNCServer() error { return nil }

View File

@@ -1,4 +1,4 @@
//go:build (linux && !android) || freebsd
//go:build unix && !darwin && !ios && !android
package server

View File

@@ -1,4 +1,4 @@
//go:build (linux && !android) || freebsd
//go:build unix && !darwin && !ios && !android
package server

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
import (

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
import (

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
import (

View File

@@ -1,4 +1,4 @@
//go:build (linux && !android) || freebsd
//go:build unix && !darwin && !ios && !android
package server

View File

@@ -1,4 +1,4 @@
//go:build (linux && !android) || freebsd
//go:build unix && !darwin && !ios && !android
package server

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
import "testing"

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
import (

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
import (

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
// QEMU Extended Key Event carries hardware scancodes encoded as PC AT Set 1.

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
import "testing"

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
import (

View File

@@ -1,21 +0,0 @@
//go:build (!windows && !darwin && !freebsd && !(linux && !android)) || (darwin && ios)
package server
func (s *Server) platformInit() {
// no-op on unsupported platforms
}
// serviceAcceptLoop is not supported on non-Windows platforms.
func (s *Server) serviceAcceptLoop() {
s.log.Warn("service mode not supported on this platform, falling back to direct mode")
s.acceptLoop()
}
func (s *Server) platformSessionManager() virtualSessionManager {
return nil
}
func (s *Server) platformShutdown() {
// no-op on this platform
}

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
import (

View File

@@ -1,4 +1,4 @@
//go:build (linux && !android) || freebsd
//go:build unix && !darwin && !ios && !android
package server

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
import (

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
import (

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
import "unsafe"

View File

@@ -1,3 +1,5 @@
//go:build !js && !ios && !android
package server
import (

View File

@@ -1,4 +1,4 @@
//go:build (linux && !android) || freebsd
//go:build unix && !darwin && !ios && !android
package server