Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 24 Oct 2015 15:41:00 +0000
From:      Alexey Dokuchaev <danfe@FreeBSD.org>
To:        Kris Moore <kris@pcbsd.org>
Cc:        Kris Moore <kmoore@FreeBSD.org>, ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   Re: svn commit: r400121 - head/net-im/teamwords
Message-ID:  <20151024154100.GA2659@FreeBSD.org>
In-Reply-To: <562B9F65.4010603@pcbsd.org>
References:  <201510241406.t9OE6uXi043030@repo.freebsd.org> <20151024142932.GB69999@FreeBSD.org> <562B9F65.4010603@pcbsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Oct 24, 2015 at 11:10:29AM -0400, Kris Moore wrote:
> On 10/24/2015 10:29, Alexey Dokuchaev wrote:
> > On Sat, Oct 24, 2015 at 02:06:56PM +0000, Kris Moore wrote:
> >> [...]
> >>  do-install:
> >>  	${STRIP_CMD} ${WRKSRC}/teamwords
> >>  	${INSTALL} ${WRKSRC}/teamwords ${STAGEDIR}${PREFIX}/bin
> > 
> > Wait, what?  You strip the binary first and then install it?  Why not
> > use ${INSTALL_PROGRAM} which DTRT itself?
> 
> It's what was suggested when I built the port with DEVELOPER=yes. Is the
> end-result the same or is this just for the sake of minimalism?

I'm not sure where does this suggestion come from; it makes little sense
to me.  INSTALL_PROGRAM correctly respects your stripping policy, i.e.:

  $ make -V INSTALL_PROGRAM
  install  -s -m 555
  $ make -V INSTALL_PROGRAM STRIP=''
  install   -m 555

As for stripping binaries explicitly in the Makefile: I'm actually against
it; it made sense in pre-staging times when we've been installing stuff
directly into user's filesystem, but now with staging we ideally should be
just dumping unstripped binaries to staging area, and stripping should be
done upon "make install" by the framework.  Those ${STRIP_CMD}'s just make
Makefiles more imperative and hard to control.  Think of what would I have
to do if I want to build debug package? -- patching individual ports on an
ad-hoc basis in many little places instead of setting some universal knob
like NO_STRIP in /etc/make.conf or something.

So far consensus is to use ${INSTALL_PROGRAM} and/or set INSTALL_TARGET
to `install-strip' when supported instead of doing it correctly.  Oh well.

> That being said, I've changed it now.

Thank you.

./danfe



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20151024154100.GA2659>