[pkg-go] dh-golang and _link_contents()

Michael Stapelberg stapelberg at debian.org
Wed May 13 23:03:37 UTC 2015


Please don’t drop pkg-go-maintainers from the CC, this conversation is
interesting for everyone.

One option to solve your issue is to just delete usr/share/gocode, as one
of the examples I linked to does (sorry, don’t recall which one).

On Wed, May 13, 2015 at 8:53 PM, Chas Williams III <
Charles.Williams at brocade.com> wrote:

> Thank you for the links.
>
> If I have multiple packages that are related but want to go into
> separate debian packages, like a server package and some debugging utils
> that you might optionally want to install.
>
> If I don't have an *.install, I get a .deb file with:
>
> drwxr-xr-x root/root         0 2015-05-13 11:45 ./usr/share/gocode/
> drwxr-xr-x root/root         0 2015-05-13 11:45 ./usr/share/gocode/src/
> drwxr-xr-x root/root         0 2015-05-13 11:45
> ./usr/share/gocode/src/myutil/
> drwxr-xr-x root/root         0 2015-05-13 11:45
> ./usr/share/gocode/src/myutil/src/
> drwxr-xr-x root/root         0 2015-05-13 11:45
> ./usr/share/gocode/src/myutil/src/myutil/
> -rw-r--r-- root/root       128 2015-05-13 11:45
> ./usr/share/gocode/src/myutil/src/myutil/myutil.go
> drwxr-xr-x root/root         0 2015-05-13 11:45 ./usr/bin/
> -rwxr-xr-x root/root   1357256 2015-05-13 11:45 ./usr/bin/myutil
>
> I don't want to ship the gocode.
>
> On Wed, 2015-05-13 at 12:30 -0600, Michael Stapelberg wrote:
> > Here are a couple binary-only packages:
> >
> >
> > http://anonscm.debian.org/cgit/pkg-go/packages/etcd.git/
> > http://anonscm.debian.org/cgit/pkg-go/packages/heartbleeder.git/
> >
> > http://anonscm.debian.org/cgit/pkg-go/packages/skydns.git/
> >
> >
> >
> > Why do you need an install file at all if you’re just dealing with a
> > binary-only package?
> >
> > On Wed, May 13, 2015 at 8:22 PM, Chas Williams III
> > <Charles.Williams at brocade.com> wrote:
> >         See attached.  I can build the golang-stringutils package
> >         fine.
> >         myutil builds but I am unable to create a binary package that
> >         only
> >         contains the utility myutil.  I don't need to ship myutil's as
> >         a
> >         development package.
> >
> >         I have been unable to find an example of dh-golang used to
> >         build a
> >         binary only package.
> >
> >         On Wed, 2015-05-13 at 12:04 -0600, Michael Stapelberg wrote:
> >         > Without seeing your packaging it’s very hard to help. Maybe
> >         taking a
> >         > look at the existing pkg-go packages helps?
> >         >
> >         > On Wed, May 13, 2015 at 7:21 PM, Chas Williams III
> >         > <Charles.Williams at brocade.com> wrote:
> >         >         I think I have it figured out now.  I wasn't setting
> >         DH_GOPKG
> >         >         on the
> >         >         non-library package.
> >         >
> >         >         How do you write an *.install file to match file
> >         paths?  The
> >         >         files don't
> >         >         seem to be installed in the temporary root and the
> >         typical
> >         >         paths I would
> >         >         use don't seem to work.
> >         >
> >         >         On Tue, 2015-05-12 at 14:06 -0600, Michael
> >         Stapelberg wrote:
> >         >         > Why woulud the build system need to write
> >         >         to /usr/share/gocode? You
> >         >         > shouldn’t need to touch your dependencies during
> >         build.
> >         >         >
> >         >         >
> >         >         > Can you make your packaging available? Without
> >         seeing the
> >         >         code, it’s
> >         >         > hard to help.
> >         >         >
> >         >         > On Tue, May 12, 2015 at 7:44 PM, Chas Williams III
> >         >         > <Charles.Williams at brocade.com> wrote:
> >         >         >         Hello,
> >         >         >
> >         >         >         I have managed to produce a golang Debian
> >         package,
> >         >         but I still
> >         >         >         can't
> >         >         >         seem to figure out how to use this package
> >         to build
> >         >         my Go
> >         >         >         application.
> >         >         >
> >         >         >         Buildsystem/golang.pm says want I want to
> >         hear:
> >         >         >
> >         >         >
> >         >         >
> >         >
> >
>  ############################################################################
> >         >         >         # Symlink all available libraries
> >         >         from /usr/share/gocode/src
> >         >         >         into our
> >         >         >         # buildroot.
> >         >         >
> >         >
> >
>  ############################################################################
> >         >         >
> >         >         >         But _link_contents() doesn't really seem
> >         to do that.
> >         >         It
> >         >         >         symlinks
> >         >         >         the directories, but shouldn't it really
> >         create the
> >         >         >         directories and
> >         >         >         symlinks the source files (*.go) since
> >         it's unlikely
> >         >         the build
> >         >         >         system
> >         >         >         can write to /usr/share/gocode?
> >         >         >
> >         >         >
> >         >         >
> >         >         >
> >         >         >
> >         >         >
> >         >         >
> >         >         >
> >         >         > --
> >         >         > Best regards,
> >         >         > Michael
> >         >
> >         >
> >         >
> >         >
> >         >
> >         >
> >         > --
> >         > Best regards,
> >         > Michael
> >
> >
> >
> >
> >
> >
> > --
> > Best regards,
> > Michael
>
>
>


-- 
Best regards,
Michael
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/pkg-go-maintainers/attachments/20150514/6a2c577b/attachment-0001.html>


More information about the Pkg-go-maintainers mailing list