1 |
On Wed, Feb 19, 2014 at 12:34:22PM +0100, yac wrote: |
2 |
> On Sat, 15 Feb 2014 16:44:09 -0600 |
3 |
> William Hubbs <williamh@g.o> wrote: |
4 |
> |
5 |
> > On Sat, Feb 15, 2014 at 12:48:44AM +0100, yac wrote: |
6 |
> > > On Fri, 14 Feb 2014 11:02:49 -0500 |
7 |
> > > Emery Hemingway <emery@×××××××.net> wrote: |
8 |
> > > > The default GOROOT that go looks at for base libraries seems to be |
9 |
> > > > compiled in so this should be pretty easy, like python but |
10 |
> > > > simplier. |
11 |
> > > |
12 |
> > > I'm not sure what you are trying to solve here. Afaik GOROOT is |
13 |
> > > used to determine where to install and it can be overriden from env. |
14 |
> > |
15 |
> > Not overridden, but extended. See go help gopath. |
16 |
> > |
17 |
> > > > An eclass could look at a GO_MINIMUM variable and install for each |
18 |
> > > > version go that is present and matches. |
19 |
> > > |
20 |
> > > It might be good idea to learn from others who'd been through this |
21 |
> > > and I think the new python eclasses are good ones, going with |
22 |
> > > something like PYTHON_TARGETS array (GOLANG_TARGETS ?) |
23 |
> > |
24 |
> > I would prefer go_targets if this becomes an issue, |
25 |
> |
26 |
> golang is more search friendly |
27 |
> |
28 |
> > but it isn't at |
29 |
> > this point because there is only one target, go1, and we do not know |
30 |
> > if there will be a go2 or not. |
31 |
> |
32 |
> There still are different compilers at least, even if changing minor |
33 |
> version would be a non-issue. But I'm not familiar with those, I think |
34 |
> those are used for compiling for other than the supported archs (iirc |
35 |
> only x86 and x86_64) |
36 |
|
37 |
Also add arm to the supported list along with amd64/x86-fbsd. |
38 |
|
39 |
The only other compiler is gccgo [1], but it is part of the gcc |
40 |
toolchain, so I have no idea what they are doing there, or if our |
41 |
toolchain guys are even supporting it. Also, if you look at the comments |
42 |
on that page, it is a bit behind dev-lang/go. It is not clear to me |
43 |
either whether gccgo works on other architectures, and whether it is a |
44 |
compiler or a front end like the old cfront used to be for c++. Also, I |
45 |
don't know whether it will even share the same libraries as dev-lang/go; |
46 |
it may just use standard libraries stored in /usr/lib. |
47 |
|
48 |
In short, I have no clue how gccgo works. ;-) |
49 |
|
50 |
> |
51 |
> > > > Dropping old versions of go |
52 |
> > > > will be easy because linking wont break, and new releases should |
53 |
> > > > be forwards compatible. |
54 |
> > > |
55 |
> > > So far yes I think but I guess that may be quite different with in |
56 |
> > > the future with >1.x, and "should be" so there may be corner cases |
57 |
> > > where the user does need to use earlier version. |
58 |
> > |
59 |
> > Highly unlikely in the context of go1, and again, we don't know if |
60 |
> > there is going to even be a go2 or not. The only reason there will be |
61 |
> > a go2 is if there needs to be a change at the source level which can |
62 |
> > only be done in a backward incompatible way. |
63 |
> > |
64 |
> > The question really should be, do we want a system-wide workspace to |
65 |
> > store third-party libraries [1]? |
66 |
> > and if so, where do we put it -- maybe /usr/lib/go-gentoo should exist |
67 |
> > along side /usr/lib/go? |
68 |
> |
69 |
> I assume you are talking about thirdparty packages installed by |
70 |
> portage, not by localy/manually by user. Well, without the system-wide |
71 |
> workspace to store the libraries, this whole go eclass would be kinda |
72 |
> pointless, no? |
73 |
> |
74 |
> Currently /usr/lib/go/gentoo is used and I see no reason to change it. |
75 |
|
76 |
Well, I was suggesting go-gentoo to keep third party libraries out of |
77 |
the standard go tree and based on the definition of a workspace from the |
78 |
go documentation. |
79 |
|
80 |
|
81 |
> > The catch would be that every time you upgrade dev-lang/go, everything |
82 |
> > stored in /usr/lib/go-gentoo has to be recompiled because there is no |
83 |
> > guarantee that the libraries we have there are compatible with each |
84 |
> > minor release of go1, only the source. |
85 |
> > |
86 |
> > Then, the executables we have in /usr/bin will still run, but it would |
87 |
> > be good to rebuild them as well to get the new libraries linked into |
88 |
> > them. |
89 |
> > |
90 |
> > If we had a work space in, say, /usr/lib/go-gentoo, we could leave the |
91 |
> > executables in there and symlink them to /usr/bin. If we did that, it |
92 |
> > would be easy for a user to rebuild everything in the workspace for |
93 |
> > the new go by doing |
94 |
> > |
95 |
> > emerge /usr/lib/go-gentoo/bin |
96 |
> |
97 |
> Good idea. |
98 |
> |
99 |
> > Thoughts? |
100 |
> > |
101 |
> > William |
102 |
> > |
103 |
> > [1] http://golang.org/doc/code.html |
104 |
> |
105 |
> |
106 |
> |
107 |
> --- |
108 |
> Jan Matějka | Gentoo Developer |
109 |
> https://gentoo.org | Gentoo Linux |
110 |
> GPG: A33E F5BC A9F6 DAFD 2021 6FB6 3EBF D45B EEB6 CA8B |
111 |
|
112 |
|
113 |
[1] http://golang.org/doc/install/gccgo |