GithubHelp home page GithubHelp logo

Comments (5)

davecheney avatar davecheney commented on August 19, 2024

Can you check with the latest version, I think I fixed this problem last
night.

To be fair, -goos and -goarch aren't rrally tested, but I know -goroot works

On Sat, 2 May 2015 09:36 Mark Wolfe [email protected] wrote:

Just tried to add -R to override the project root and ran into the fact
that the flags are not evaluated till after the plugins.

After adding a bit of debugging *goroot, *goos, *goarch will only ever
get set to the default values.

https://github.com/constabulary/gb/blob/master/cmd/gb/main.go#L77

vs flags evaluated on

https://github.com/constabulary/gb/blob/master/cmd/gb/main.go#L100


Reply to this email directly or view it on GitHub
#26.

from gb.

wolfeidau avatar wolfeidau commented on August 19, 2024

I pulled down the latest changes and added.

    gb.Infof("goroot=%s goos=%s goarch=%s", *goroot, *goos, *goarch)
    tc, err := gb.NewGcToolchain(*goroot, *goos, *goarch)

Passed in arm as goarch and it is still set to amd64.

gb build -goarch=arm -goos=linux all

got

2015/05/02 10:18:38 INFO goroot=/usr/local/Cellar/go/1.4.2/libexec goos=darwin goarch=amd64

from gb.

davecheney avatar davecheney commented on August 19, 2024

Yup, that's a bug. I haven't tested GOOS/GOARCH only changing the toolchain
via -goroot, there is a chance those former values are hard coded.

I'll fix it.

On Sat, 2 May 2015 10:19 Mark Wolfe [email protected] wrote:

I pulled down the latest changes and added.

gb.Infof("goroot=%s goos=%s goarch=%s", *goroot, *goos, *goarch)
tc, err := gb.NewGcToolchain(*goroot, *goos, *goarch)

Passed in arm as goarch and it is still set to amd64.

gb build -goarch=arm -goos=linux all

got

2015/05/02 10:18:38 INFO goroot=/usr/local/Cellar/go/1.4.2/libexec goos=darwin goarch=amd64


Reply to this email directly or view it on GitHub
#26 (comment).

from gb.

davecheney avatar davecheney commented on August 19, 2024

Note, unless you're using go1.5, to do cross compiles you'll have to do
that 'christen your cross compile toolchain dance', gb wont save you from
that, and in fact, it might make it worse as we always consider the
standard library to be up to date irrespective of the toolchain.

On Sat, 2 May 2015 10:22 Dave Cheney [email protected] wrote:

Yup, that's a bug. I haven't tested GOOS/GOARCH only changing the
toolchain via -goroot, there is a chance those former values are hard
coded.

I'll fix it.

On Sat, 2 May 2015 10:19 Mark Wolfe [email protected] wrote:

I pulled down the latest changes and added.

gb.Infof("goroot=%s goos=%s goarch=%s", *goroot, *goos, *goarch)
tc, err := gb.NewGcToolchain(*goroot, *goos, *goarch)

Passed in arm as goarch and it is still set to amd64.

gb build -goarch=arm -goos=linux all

got

2015/05/02 10:18:38 INFO goroot=/usr/local/Cellar/go/1.4.2/libexec goos=darwin goarch=amd64


Reply to this email directly or view it on GitHub
#26 (comment).

from gb.

davecheney avatar davecheney commented on August 19, 2024

@wolfeidau what i'm going to do is close this issue by removing -goarch and -goos. I'll open a new issue to make them work properly.

from gb.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.