2
0
mirror of synced 2025-02-23 06:48:15 +00:00

cmd/gomobile: tidy a few unused code and variables

Change-Id: I979589adf74ec0cd097ef7acc6c120f6557c8f25
Reviewed-on: https://go-review.googlesource.com/c/mobile/+/369201
Run-TryBot: Hyang-Ah Hana Kim <hyangah@gmail.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Bryan Mills <bcmills@google.com>
Reviewed-by: David Chase <drchase@google.com>
Reviewed-by: Hyang-Ah Hana Kim <hyangah@gmail.com>
This commit is contained in:
Changkun Ou 2021-12-05 16:21:52 +01:00 committed by Hyang-Ah Hana Kim
parent ce6a79cf6a
commit 50dca8fc07
3 changed files with 3 additions and 28 deletions

View File

@ -271,11 +271,6 @@ func addBuildFlagsNVXWork(cmd *command) {
cmd.flag.BoolVar(&buildWork, "work", false, "") cmd.flag.BoolVar(&buildWork, "work", false, "")
} }
type binInfo struct {
hasPkgApp bool
hasPkgAL bool
}
func init() { func init() {
addBuildFlags(cmdBuild) addBuildFlags(cmdBuild)
addBuildFlagsNVXWork(cmdBuild) addBuildFlagsNVXWork(cmdBuild)

View File

@ -15,12 +15,8 @@ import (
// General mobile build environment. Initialized by envInit. // General mobile build environment. Initialized by envInit.
var ( var (
gomobilepath string // $GOPATH/pkg/gomobile gomobilepath string // $GOPATH/pkg/gomobile
androidEnv map[string][]string // android arch -> []string androidEnv map[string][]string // android arch -> []string
appleEnv map[string][]string appleEnv map[string][]string
androidArmNM string
appleNM string appleNM string
) )

View File

@ -208,12 +208,6 @@ func installOpenAL(gomobilepath string) error {
return nil return nil
} }
var commonPkgs = []string{
"golang.org/x/mobile/gl",
"golang.org/x/mobile/app",
"golang.org/x/mobile/exp/app/debug",
}
func mkdir(dir string) error { func mkdir(dir string) error {
if buildX || buildN { if buildX || buildN {
printcmd("mkdir -p %s", dir) printcmd("mkdir -p %s", dir)
@ -237,16 +231,6 @@ func symlink(src, dst string) error {
return os.Symlink(src, dst) return os.Symlink(src, dst)
} }
func rm(name string) error {
if buildX || buildN {
printcmd("rm %s", name)
}
if buildN {
return nil
}
return os.Remove(name)
}
func doCopyAll(dst, src string) error { func doCopyAll(dst, src string) error {
return filepath.Walk(src, func(path string, info os.FileInfo, errin error) (err error) { return filepath.Walk(src, func(path string, info os.FileInfo, errin error) (err error) {
if errin != nil { if errin != nil {