[pkg-go] Building and distributing Go packages as shared libraries

Michael Stapelberg stapelberg at debian.org
Wed Oct 29 22:06:28 UTC 2014


On Wed, Oct 29, 2014 at 8:46 AM, Michael Hudson-Doyle
<michael.hudson at canonical.com> wrote:
> Hi there,
>
> I'm Michael, I work for Canonical and very soon I'm going to be working
> on implementing shared libraries for the gc toolchain.  The reason
> Canonical is getting me to work on this is that we want to distribute
> applications written in Go as part of Ubuntu and be able to deliver
> updates to them and the components they depend on in a way that's more
> familiar to the security team and others who do this sort of thing.
That was also the reason which was stated when the discussion about
“do we want static or shared linking of go packages” in Debian
happened. To this day, I’m not convinced that it’s a good reason :).

>
> As your name is on https://wiki.debian.org/MichaelStapelberg/GoPackaging
> (and this even says "in case go supports shared libraries") I thought
> I'd send you an email to ask if you've thought much about how this might
> work in practice, or if not, if you have time to bounce some ideas
> around with me.  Obviously there are toolchain changes needed, but those
The state of the world hasn’t changed since I wrote that package as
far as I’m concerned — but I haven’t been following Go upstream
closely except for enjoying the new features.

> are the fun technical bit :) I think I'm a bit more concerned right now
> about the build system side: the changes to the go tool and making sure
> that dh-golang can make use of them.
>
> I'm planning on following Ian Lance Taylor's document at
>
> https://docs.google.com/document/d/1nr-TQHw_er6GOQRsF6T43GGhFDelrAP0NqSS_00RgZQ/edit
I’ve read that document, and I don’t see an execution mode that
describes “all go modules built as a shared library”. The shared
library parts of the document refer to plugin interfaces AFAICT, which
seems more specific than what you’re talking about.

>
> I guess the things I'm most unsure of at this point are:
>
>  1) Where the shared objects will end up on the file system, and
>  2) The usual shared library fun of things being compiled in one place
>     in the knowledge that they will end up somewhere else.
>
> Anyway, I've probably rambled a bit much, I just wanted to let you know
> that I'm working on this and I'm interested in your input.  I hope
> you're interested in this topic too :)
I appreciate that you contacted me early on, so thanks for that.
However, I also have to mention that my involvement in Debian is
gradually shrinking for multiple reasons, and I’ve never been able to
implement much of the plans I’ve had for pkg-go. Therefore, don’t
expect more collaboration than the bare minimum my current spare time
permits. That said, I don’t want to be a blocker for your work, so I
hope I can mostly get out of the way :).

-- 
Best regards,
Michael



More information about the Pkg-go-maintainers mailing list