[mobile] cmd/gomobile: add a flag to manually specify a work dir

266 views
Skip to first unread message

Gerrit Bot (Gerrit)

unread,
Nov 26, 2020, 3:51:44 AM11/26/20
to goph...@pubsubhelper.golang.org, golang-co...@googlegroups.com

Gerrit Bot has uploaded this change for review.

View Change

cmd/gomobile: add a flag to manually specify a work dir

Added a flag to manually specify a work dir to avoid having to rebuild everything from scratch when using gomobile through go module.

Particularly useful in the context of a large project that takes several tens of minutes to build, especially when only one or two packages need to be recompiled.

Fixes https://github.com/golang/go/issues/37902

Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
GitHub-Last-Rev: cf4536637fc0debdf5de56c4042ec5b9651d5cc9
GitHub-Pull-Request: golang/mobile#58
---
M cmd/gomobile/bind.go
M cmd/gomobile/build.go
M cmd/gomobile/env.go
M cmd/gomobile/install.go
4 files changed, 25 insertions(+), 7 deletions(-)

diff --git a/cmd/gomobile/bind.go b/cmd/gomobile/bind.go
index ef62d05..d2709b0 100644
--- a/cmd/gomobile/bind.go
+++ b/cmd/gomobile/bind.go
@@ -60,6 +60,9 @@
control the bootstrap classpath and the classpath for Go wrappers to Java
classes.

+The -cache flag specifies the build cache directory. If not specified,
+ioutil.TempDir() is used.
+
The -v flag provides verbose output, including the list of packages built.

The build flags -a, -n, -x, -gcflags, -ldflags, -tags, -trimpath, and -work
diff --git a/cmd/gomobile/build.go b/cmd/gomobile/build.go
index 4811ab7..163d2b3 100644
--- a/cmd/gomobile/build.go
+++ b/cmd/gomobile/build.go
@@ -58,6 +58,9 @@
The -o flag specifies the output file name. If not specified, the
output file name depends on the package built.

+The -cache flag specifies the build cache directory. If not specified,
+ioutil.TempDir() is used.
+
The -v flag provides verbose output, including the list of packages built.

The build flags -a, -i, -n, -x, -gcflags, -ldflags, -tags, -trimpath, and -work are
@@ -224,6 +227,7 @@
buildTarget string // -target
buildTrimpath bool // -trimpath
buildWork bool // -work
+ buildCache string // -cache
buildBundleID string // -bundleid
buildIOSVersion string // -iosversion
buildAndroidAPI int // -androidapi
@@ -245,11 +249,12 @@
cmd.flag.Var(&buildTags, "tags", "")
}

-func addBuildFlagsNVXWork(cmd *command) {
+func addBuildFlagsNVXWorkCache(cmd *command) {
cmd.flag.BoolVar(&buildN, "n", false, "")
cmd.flag.BoolVar(&buildV, "v", false, "")
cmd.flag.BoolVar(&buildX, "x", false, "")
cmd.flag.BoolVar(&buildWork, "work", false, "")
+ cmd.flag.StringVar(&buildCache, "cache", "", "")
}

type binInfo struct {
@@ -259,17 +264,17 @@

func init() {
addBuildFlags(cmdBuild)
- addBuildFlagsNVXWork(cmdBuild)
+ addBuildFlagsNVXWorkCache(cmdBuild)

addBuildFlags(cmdInstall)
- addBuildFlagsNVXWork(cmdInstall)
+ addBuildFlagsNVXWorkCache(cmdInstall)

- addBuildFlagsNVXWork(cmdInit)
+ addBuildFlagsNVXWorkCache(cmdInit)

addBuildFlags(cmdBind)
- addBuildFlagsNVXWork(cmdBind)
+ addBuildFlagsNVXWorkCache(cmdBind)

- addBuildFlagsNVXWork(cmdClean)
+ addBuildFlagsNVXWorkCache(cmdClean)
}

func goBuild(src string, env []string, args ...string) error {
diff --git a/cmd/gomobile/env.go b/cmd/gomobile/env.go
index 6dacc63..d81e499 100644
--- a/cmd/gomobile/env.go
+++ b/cmd/gomobile/env.go
@@ -61,11 +61,18 @@
fmt.Printf("WORK=%s\n", tmpdir)
return
}
- removeAll(tmpdir)
+ if buildCache == "" {
+ removeAll(tmpdir)
+ }
}
if buildN {
tmpdir = "$WORK"
cleanupFn = func() {}
+ } else if buildCache != "" {
+ tmpdir = buildCache
+ if err = os.MkdirAll(tmpdir, 0700); err != nil {
+ return nil, err
+ }
} else {
tmpdir, err = ioutil.TempDir("", "gomobile-work-")
if err != nil {
diff --git a/cmd/gomobile/install.go b/cmd/gomobile/install.go
index beb7e52..a1481a3 100644
--- a/cmd/gomobile/install.go
+++ b/cmd/gomobile/install.go
@@ -23,6 +23,9 @@

Only -target android is supported. The 'adb' tool must be on the PATH.

+The -cache flag specifies the build cache directory. If not specified,
+ioutil.TempDir() is used.
+
The build flags -a, -i, -n, -x, -gcflags, -ldflags, -tags, -trimpath, and -work are
shared with the build command.
For documentation, see 'go help build'.

To view, visit change 273406. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: mobile
Gerrit-Branch: master
Gerrit-Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
Gerrit-Change-Number: 273406
Gerrit-PatchSet: 1
Gerrit-Owner: Gerrit Bot <letsus...@gmail.com>
Gerrit-MessageType: newchange

Gerrit Bot (Gerrit)

unread,
Mar 22, 2021, 1:20:43 PM3/22/21
to goph...@pubsubhelper.golang.org, golang-co...@googlegroups.com

Attention is currently required from: Hyang-Ah Hana Kim.

Gerrit Bot uploaded patch set #2 to this change.

View Change

cmd/gomobile: add a flag to manually specify a work dir

Added a flag to manually specify a work dir to avoid having to rebuild everything from scratch when using gomobile through go module.

Particularly useful in the context of a large project that takes several tens of minutes to build, especially when only one or two packages need to be recompiled.

Fixes https://github.com/golang/go/issues/37902

Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
GitHub-Last-Rev: bfaf3f599c258f105d375229058338e443fba8aa

GitHub-Pull-Request: golang/mobile#58
---
M cmd/gomobile/bind.go
M cmd/gomobile/build.go
M cmd/gomobile/env.go
M cmd/gomobile/install.go
4 files changed, 25 insertions(+), 7 deletions(-)

To view, visit change 273406. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: mobile
Gerrit-Branch: master
Gerrit-Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
Gerrit-Change-Number: 273406
Gerrit-PatchSet: 2
Gerrit-Owner: Gerrit Bot <letsus...@gmail.com>
Gerrit-Reviewer: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-CC: Go Bot <go...@golang.org>
Gerrit-Attention: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-MessageType: newpatchset

Hajime Hoshi (Gerrit)

unread,
Apr 13, 2021, 2:24:57 AM4/13/21
to Gerrit Bot, goph...@pubsubhelper.golang.org, Hyang-Ah Hana Kim, Go Bot, golang-co...@googlegroups.com

Attention is currently required from: Hyang-Ah Hana Kim.

Patch set 2:Run-TryBot +1

View Change

1 comment:

  • File cmd/gomobile/bind.go:

    • Patch Set #2, Line 63: The -cache flag specifies the build cache directory. If not specified,

      I feel like -workdir sounds better rather than -cache.

To view, visit change 273406. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: mobile
Gerrit-Branch: master
Gerrit-Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
Gerrit-Change-Number: 273406
Gerrit-PatchSet: 2
Gerrit-Owner: Gerrit Bot <letsus...@gmail.com>
Gerrit-Reviewer: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Reviewer: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-CC: Go Bot <go...@golang.org>
Gerrit-Attention: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-Comment-Date: Tue, 13 Apr 2021 06:24:52 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment

Hyang-Ah Hana Kim (Gerrit)

unread,
Apr 14, 2021, 8:45:11 AM4/14/21
to Gerrit Bot, goph...@pubsubhelper.golang.org, Go Bot, Hajime Hoshi, Hyang-Ah Hana Kim, golang-co...@googlegroups.com

Attention is currently required from: Hajime Hoshi.

View Change

1 comment:

  • File cmd/gomobile/bind.go:

    • Patch Set #2, Line 63: The -cache flag specifies the build cache directory. If not specified,

      I feel like -workdir sounds better rather than -cache.

    • There is -work flag already, so it may be confusing.

      Is the purpose to possibly reuse the temporary results, or to just control the temp directory access? If the former, we need proper design to handle how to invalidate/clean stale data, how to determine the data there can be reused, and how to handle existing directory. (`go help cache` may be inspiring?). If the later, you can control the temporary directory by setting TMPDIR or TMP (https://golang.org/pkg/os/#TempDir)

To view, visit change 273406. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: mobile
Gerrit-Branch: master
Gerrit-Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
Gerrit-Change-Number: 273406
Gerrit-PatchSet: 2
Gerrit-Owner: Gerrit Bot <letsus...@gmail.com>
Gerrit-Reviewer: Go Bot <go...@golang.org>
Gerrit-Reviewer: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Reviewer: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-Attention: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Comment-Date: Wed, 14 Apr 2021 12:45:04 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Hajime Hoshi <hajim...@gmail.com>
Gerrit-MessageType: comment

Antoine Eddi (Gerrit)

unread,
Apr 14, 2021, 5:50:09 PM4/14/21
to Gerrit Bot, goph...@pubsubhelper.golang.org, Go Bot, Hajime Hoshi, Hyang-Ah Hana Kim, golang-co...@googlegroups.com

Attention is currently required from: Hyang-Ah Hana Kim, Hajime Hoshi.

View Change

1 comment:

  • File cmd/gomobile/bind.go:

    • There is -work flag already, so it may be confusing. […]

      Yes I actually named it -cache instead of -workdir to avoid confusion with the -work flag.

      The purpose is indeed to reuse the temporary results / not rebuild the whole codebase and its dependencies every time a change was made. On our project, we use Gomobile as a module since the support has been added.
      Before that, when we made a small change, Gomobile would rebuild only the impacted module and those for which it was a dependency, so it took a few seconds on a computer that already built the project.
      Since the switch to module, because Gomobile put everything in a random temporary directory, the slightest change required to rebuild everything which took a good ten minutes.

      I don't know if there is a cleaner way to achieve this result but today we use this branch via a replace in our go.mod and it saves us a lot of time.

To view, visit change 273406. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: mobile
Gerrit-Branch: master
Gerrit-Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
Gerrit-Change-Number: 273406
Gerrit-PatchSet: 2
Gerrit-Owner: Gerrit Bot <letsus...@gmail.com>
Gerrit-Reviewer: Go Bot <go...@golang.org>
Gerrit-Reviewer: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Reviewer: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-CC: Antoine Eddi <antoi...@gmail.com>
Gerrit-Attention: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-Attention: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Comment-Date: Wed, 14 Apr 2021 21:08:52 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Hyang-Ah Hana Kim <hya...@gmail.com>

Hyang-Ah Hana Kim (Gerrit)

unread,
Apr 20, 2021, 8:42:53 AM4/20/21
to Gerrit Bot, Antoine Eddi, goph...@pubsubhelper.golang.org, Go Bot, Hajime Hoshi, Hyang-Ah Hana Kim, golang-co...@googlegroups.com

Attention is currently required from: Antoine Eddi, Hajime Hoshi.

View Change

1 comment:

  • File cmd/gomobile/bind.go:

    • Yes I actually named it -cache instead of -workdir to avoid confusion with the -work flag. […]

      Thanks for the info. Good to know it helps improving the speed, which is promising. Since we still don't fully understand what in the directory can be reliably reusable or not, how about rolling this out as an environment variable now (EXPERIMENTAL_GOBIND_CODEGEN_CACHE maybe?) and once we have better understanding and satisfied, promoting it as a supported flag? What do you think?

To view, visit change 273406. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: mobile
Gerrit-Branch: master
Gerrit-Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
Gerrit-Change-Number: 273406
Gerrit-PatchSet: 2
Gerrit-Owner: Gerrit Bot <letsus...@gmail.com>
Gerrit-Reviewer: Go Bot <go...@golang.org>
Gerrit-Reviewer: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Reviewer: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-CC: Antoine Eddi <antoi...@gmail.com>
Gerrit-Attention: Antoine Eddi <antoi...@gmail.com>
Gerrit-Attention: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Comment-Date: Tue, 20 Apr 2021 12:42:48 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Hyang-Ah Hana Kim <hya...@gmail.com>
Comment-In-Reply-To: Antoine Eddi <antoi...@gmail.com>

Antoine Eddi (Gerrit)

unread,
Apr 20, 2021, 11:45:41 AM4/20/21
to Gerrit Bot, goph...@pubsubhelper.golang.org, Go Bot, Hajime Hoshi, Hyang-Ah Hana Kim, golang-co...@googlegroups.com

Attention is currently required from: Hyang-Ah Hana Kim, Hajime Hoshi.

View Change

1 comment:

  • File cmd/gomobile/bind.go:

    • Thanks for the info. Good to know it helps improving the speed, which is promising. […]

      Sounds good to me.
      I don't know exactly what needs to be reused either, but this change seems to make the behavior identical in terms of build/rebuild between gomobile as a module or not.
      Do you want me to take care of removing the flag and adding the env variable you suggest?

To view, visit change 273406. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: mobile
Gerrit-Branch: master
Gerrit-Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
Gerrit-Change-Number: 273406
Gerrit-PatchSet: 2
Gerrit-Owner: Gerrit Bot <letsus...@gmail.com>
Gerrit-Reviewer: Go Bot <go...@golang.org>
Gerrit-Reviewer: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Reviewer: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-CC: Antoine Eddi <antoi...@gmail.com>
Gerrit-Attention: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-Attention: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Comment-Date: Tue, 20 Apr 2021 15:45:36 +0000

Gerrit Bot (Gerrit)

unread,
Jun 24, 2021, 4:18:17 AM6/24/21
to Antoine Eddi, goph...@pubsubhelper.golang.org, golang-co...@googlegroups.com

Attention is currently required from: Hyang-Ah Hana Kim, Hajime Hoshi.

Gerrit Bot uploaded patch set #3 to this change.

View Change

cmd/gomobile: add a flag to manually specify a work dir

Added a flag to manually specify a work dir to avoid having to rebuild everything from scratch when using gomobile through go module.

Particularly useful in the context of a large project that takes several tens of minutes to build, especially when only one or two packages need to be recompiled.

Fixes https://github.com/golang/go/issues/37902

Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
GitHub-Last-Rev: e7699dcc678afce05643f6aa63bce82cf8ea20e9

GitHub-Pull-Request: golang/mobile#58
---
M cmd/gomobile/bind.go
M cmd/gomobile/build.go
M cmd/gomobile/env.go
M cmd/gomobile/install.go
4 files changed, 25 insertions(+), 7 deletions(-)

To view, visit change 273406. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: mobile
Gerrit-Branch: master
Gerrit-Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
Gerrit-Change-Number: 273406
Gerrit-PatchSet: 3
Gerrit-Owner: Gerrit Bot <letsus...@gmail.com>
Gerrit-Reviewer: Go Bot <go...@golang.org>
Gerrit-Reviewer: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Reviewer: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-CC: Antoine Eddi <antoi...@gmail.com>
Gerrit-Attention: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-Attention: Hajime Hoshi <hajim...@gmail.com>
Gerrit-MessageType: newpatchset

Gerrit Bot (Gerrit)

unread,
Jun 24, 2021, 4:23:33 AM6/24/21
to Antoine Eddi, goph...@pubsubhelper.golang.org, golang-co...@googlegroups.com

Attention is currently required from: Hyang-Ah Hana Kim, Hajime Hoshi.

Gerrit Bot uploaded patch set #4 to this change.

View Change

cmd/gomobile: add a flag to manually specify a work dir

Added a flag to manually specify a work dir to avoid having to rebuild everything from scratch when using gomobile through go module.

Particularly useful in the context of a large project that takes several tens of minutes to build, especially when only one or two packages need to be recompiled.

Fixes https://github.com/golang/go/issues/37902

Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
GitHub-Last-Rev: bfaf3f599c258f105d375229058338e443fba8aa

GitHub-Pull-Request: golang/mobile#58
---
M cmd/gomobile/bind.go
M cmd/gomobile/build.go
M cmd/gomobile/env.go
M cmd/gomobile/install.go
4 files changed, 25 insertions(+), 7 deletions(-)

To view, visit change 273406. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: mobile
Gerrit-Branch: master
Gerrit-Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
Gerrit-Change-Number: 273406
Gerrit-PatchSet: 4

Gerrit Bot (Gerrit)

unread,
May 10, 2022, 5:23:41 AM5/10/22
to Antoine Eddi, goph...@pubsubhelper.golang.org, golang-co...@googlegroups.com

Attention is currently required from: Hyang-Ah Hana Kim.

Gerrit Bot uploaded patch set #5 to this change.

View Change

cmd/gomobile: add a flag to manually specify a work dir

Added a flag to manually specify a work dir to avoid having to rebuild everything from scratch when using gomobile through go module.

Particularly useful in the context of a large project that takes several tens of minutes to build, especially when only one or two packages need to be recompiled.

Fixes https://github.com/golang/go/issues/37902

Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
GitHub-Last-Rev: 2ebcbb6bfc10e67234bccbbef1693ec538893f24

GitHub-Pull-Request: golang/mobile#58
---
M cmd/gomobile/bind.go
M cmd/gomobile/build.go
M cmd/gomobile/env.go
M cmd/gomobile/install.go
4 files changed, 42 insertions(+), 7 deletions(-)

To view, visit change 273406. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: mobile
Gerrit-Branch: master
Gerrit-Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
Gerrit-Change-Number: 273406
Gerrit-PatchSet: 5
Gerrit-Owner: Gerrit Bot <letsus...@gmail.com>
Gerrit-Reviewer: Gopher Robot <go...@golang.org>
Gerrit-Reviewer: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Reviewer: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-CC: Antoine Eddi <antoi...@gmail.com>
Gerrit-Attention: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-MessageType: newpatchset

Antoine Eddi (Gerrit)

unread,
May 10, 2022, 6:23:33 AM5/10/22
to Gerrit Bot, goph...@pubsubhelper.golang.org, Gopher Robot, Hajime Hoshi, Hyang-Ah Hana Kim, golang-co...@googlegroups.com

Attention is currently required from: Hajime Hoshi, Hyang-Ah Hana Kim.

View Change

1 comment:

  • File cmd/gomobile/bind.go:

    • Sounds good to me. […]

      Hello, we are still waiting for an answer from you to know what to do.

To view, visit change 273406. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: mobile
Gerrit-Branch: master
Gerrit-Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
Gerrit-Change-Number: 273406
Gerrit-PatchSet: 5
Gerrit-Owner: Gerrit Bot <letsus...@gmail.com>
Gerrit-Reviewer: Gopher Robot <go...@golang.org>
Gerrit-Reviewer: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Reviewer: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-CC: Antoine Eddi <antoi...@gmail.com>
Gerrit-Attention: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-Attention: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Comment-Date: Tue, 10 May 2022 10:23:28 +0000

Gerrit Bot (Gerrit)

unread,
Jul 6, 2022, 5:19:30 AM7/6/22
to Antoine Eddi, goph...@pubsubhelper.golang.org, golang-co...@googlegroups.com

Attention is currently required from: Hajime Hoshi, Hyang-Ah Hana Kim.

Gerrit Bot uploaded patch set #6 to this change.

View Change

cmd/gomobile: add a flag to manually specify a work dir

Added a flag to manually specify a work dir to avoid having to rebuild everything from scratch when using gomobile through go module.

Particularly useful in the context of a large project that takes several tens of minutes to build, especially when only one or two packages need to be recompiled.

Fixes https://github.com/golang/go/issues/37902

Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
GitHub-Last-Rev: b169a720413b692240ffcfee1354dd23de7dcd6e

GitHub-Pull-Request: golang/mobile#58
---
M cmd/gomobile/bind.go
M cmd/gomobile/build.go
M cmd/gomobile/env.go
M cmd/gomobile/init.go
M cmd/gomobile/install.go
5 files changed, 50 insertions(+), 7 deletions(-)

To view, visit change 273406. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: mobile
Gerrit-Branch: master
Gerrit-Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
Gerrit-Change-Number: 273406
Gerrit-PatchSet: 6
Gerrit-Owner: Gerrit Bot <letsus...@gmail.com>
Gerrit-Reviewer: Gopher Robot <go...@golang.org>
Gerrit-Reviewer: Hajime Hoshi <hajim...@gmail.com>
Gerrit-Reviewer: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-CC: Antoine Eddi <antoi...@gmail.com>
Gerrit-Attention: Hyang-Ah Hana Kim <hya...@gmail.com>
Gerrit-Attention: Hajime Hoshi <hajim...@gmail.com>
Gerrit-MessageType: newpatchset

Gerrit Bot (Gerrit)

unread,
Jul 6, 2022, 5:51:59 AM7/6/22
to Antoine Eddi, goph...@pubsubhelper.golang.org, golang-co...@googlegroups.com

Attention is currently required from: Hajime Hoshi, Hyang-Ah Hana Kim.

Gerrit Bot uploaded patch set #7 to this change.

View Change

cmd/gomobile: add a flag to manually specify a work dir

Added a flag to manually specify a work dir to avoid having to rebuild everything from scratch when using gomobile through go module.

Particularly useful in the context of a large project that takes several tens of minutes to build, especially when only one or two packages need to be recompiled.

Fixes https://github.com/golang/go/issues/37902

Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
GitHub-Last-Rev: bee19d45b5f8487de96d19e6df2d8ca2df64ae72

GitHub-Pull-Request: golang/mobile#58
---
M cmd/gomobile/bind.go
M cmd/gomobile/build.go
M cmd/gomobile/env.go
M cmd/gomobile/init.go
M cmd/gomobile/install.go
5 files changed, 50 insertions(+), 7 deletions(-)

To view, visit change 273406. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: mobile
Gerrit-Branch: master
Gerrit-Change-Id: I23fb636fc6d5c0e6f9cb953a5795bad36a9cbda3
Gerrit-Change-Number: 273406
Gerrit-PatchSet: 7
Reply all
Reply to author
Forward
0 new messages