Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 27 Nov 1999 10:31:43 -0500 (EST)
From:      "Chris D. Faulhaber" <jedgar@fxp.org>
To:        Marc van Woerkom <van.woerkom@netcologne.de>
Cc:        freebsd-ports@freebsd.org
Subject:   Re: INSTALL_PROGRAM considered harmful for Linux apps
Message-ID:  <Pine.BSF.4.10.9911271026030.39322-100000@pawn.primelocation.net>
In-Reply-To: <199911271454.PAA00924@oranje.my.domain>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 27 Nov 1999, Marc van Woerkom wrote:

> In case it is not already in the handbook, could some add a remark
> to the INSTALL_PROGRAM makro, or even better think of some way to
> make it foolproof?
> 
> Im just testing the q3test port, and got a dozen of reboots due
> to the fact that I used INSTALL_PROGRAM for executables and shared
> libs:
> 
> This makro will not only install, but also strip the binaries!
> 

I would have to agree.  The handbook says (immediately above the INSTALL_*
macros descriptions) that binaries should be stripped; however, it fails
to let the porter know that INSTALL_PROGRAM will normally strip the binary
during install.  (See patch below)

> Good in case of FreeBSD native stuff, very bad in case of Linux,
> because the branding information gets stripped as well BIGBADABOOM!
> 
> I resorted to INSTALL_DATA plus CHMOD u+rx for the meanwhile.
> 

Since it is not a native FreeBSD binary, stripping with with the FreeBSD 
strip would be bad (as you have seen).  In this case, wouldn't 
INSTALL_SCRIPT be more appropriate since INSTALL_SCRIPT installs, chmods, 
but doesn't strip...


-----
Chris D. Faulhaber <jedgar@fxp.org>  |  All the true gurus I've met never
System/Network Administrator,        |  claimed they were one, and always
Reality Check Information, Inc.      |  pointed to someone better.

Index: chapter.sgml
===================================================================
RCS file: /home/ncvs/doc/en_US.ISO_8859-1/books/handbook/ports/chapter.sgml,v
retrieving revision 1.62
diff -u -r1.62 chapter.sgml
--- chapter.sgml	1999/11/24 17:38:11	1.62
+++ chapter.sgml	1999/11/27 15:23:16
@@ -3059,7 +3059,10 @@
 	<title>Strip Binaries</title>
 
 	<para>Do strip binaries.  If the original source already strips the
-	  binaries, fine; otherwise you should add a
+	  binaries, fine; otherwise you should use
+          <makevar>INSTALL_PROGRAM</makevar> if the port's
+          <filename>Makefile</filename> has an
+          <literal>install</literal> target or add a
 	  <literal>post-install</literal> rule to to it yourself.  Here is an
 	  example;</para>
 
@@ -3081,8 +3084,8 @@
 
 	<itemizedlist>
 	  <listitem>
-	    <para><makevar>INSTALL_PROGRAM</makevar> is a command to install
-	      binary executables.</para>
+	    <para><makevar>INSTALL_PROGRAM</makevar> is a command to strip
+	      and install binary executables.</para>
 	  </listitem>
 
 	  <listitem>




To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.10.9911271026030.39322-100000>