NetBSD Problem Report #12057
Received: (qmail 10433 invoked from network); 27 Jan 2001 21:47:36 -0000
Message-Id: <20010127214732.A60584@proven.weird.com>
Date: Sat, 27 Jan 2001 16:47:32 -0500 (EST)
From: woods@proven.weird.com
Reply-To: woods@planix.com
To: gnats-bugs@gnats.netbsd.org
Subject: package makefiles should never explicitly strip binaries!
X-Send-Pr-Version: 3.95
>Number: 12057
>Category: pkg
>Synopsis: package makefiles should never explicitly strip binaries!
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: pkg-manager
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat Jan 27 21:48:00 +0000 2001
>Closed-Date: Sun Jan 28 04:06:00 +0000 2001
>Last-Modified: Sun Jan 28 04:06:00 +0000 2001
>Originator: Greg A. Woods
>Release: pkgsrc-2001/01/27
>Organization:
Planix, Inc.; Toronto, Ontario; Canada
>Environment:
>Description:
I see that net/fping/Makefile still explicitly tries to strip
the installed binary in the post-install target.
pkgsrc module makefiles should *NEVER* explicitly strip
anything! I suspect occurances of this are leftovers from
FreeBSD package conversions....
pkgsrc may support stripping of binaries if, and only if,
${STRIPFLAG} is set to a non-nil value (eg. '-s') via
bsd.prefs.mk.
>How-To-Repeat:
try debugging a fping core dump and find it's not possible with
the installed binary....
>Fix:
all pkgsrc modules makefiles should be checked for errant uses
of strip or ${STRIP} without testing ${STRIPFLAG}, like this
particularly nasty one that hides the fact it was done!
Index: Makefile
===================================================================
RCS file: /most/spare/cvs.NetBSD.ORG/pkgsrc/net/fping/Makefile,v
retrieving revision 1.1.1.1
diff -c -r1.1.1.1 Makefile
*** Makefile 2000/05/19 10:20:35 1.1.1.1
--- Makefile 2001/01/27 18:54:08
***************
*** 16,22 ****
EXTRACT_CMD= zcat ${DOWNLOADED_DISTFILE} | ${SED} -e '1,/Archive-Name/d' | ${SH}
NO_WRKSUBDIR= yes
- post-install:
- @strip ${PREFIX}/sbin/fping
-
.include "../../mk/bsd.pkg.mk"
--- 16,19 ----
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed
State-Changed-By: hubertf
State-Changed-When: Sat Jan 27 20:03:42 PST 2001
State-Changed-Why:
The proposed fix has the problem that it doesn't allow stripping
the binary, which is usually wanted. The right solution to this
is to use the BSD_INSTALL_* macros, which use $STRIPFLAG. I've
committed a fix that implements that, have a look at patch-aa.
- Hubert
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.