Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm Sender: cygwin-owner AT sourceware DOT cygnus DOT com Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com Message-ID: <4DFDC11EA426D2118D480008C71E309BF26B38@FL-EXCHANGE-04> From: David DOT Smith AT syntegra DOT bt DOT co DOT uk To: cygwin AT sourceware DOT cygnus DOT com Subject: [Q:] Question About strip.exe? Date: Fri, 19 Feb 1999 15:24:09 -0000 X-Mailer: Internet Mail Service (5.5.2232.9) Hi, This might be a silly question, but should strip work across symbolic links? For example, I executed the following sequence of commands in bash (comments added later) and found that the files striped via a symbolic link are truncated and unexecutable. Is this "normal" behaviour or a bug? I am executing the following command and finding that my cygwin installation is no longer usable afterwards. bash-$ find /usr/local/cygwin-b20.1 \( -name "*.dll" -or -name "*.exe" \) -print -exec strip --strip-all {} \; Regards, David # Create 2 copies of strip.exe. bash-$ cp strip.exe a1.exe bash-$ cp strip.exe a2.exe # Create 2 symbolic links to the 2 copies of strip.exe. bash-$ ln -s ./a1.exe ./l1.exe bash-$ ln -s ./a2.exe ./l2.exe # Execute the files via the symbolic links to check they work. bash-$ ./l1 --version GNU strip 2.9.4 Copyright 1997, 1998 Free Software Foundation, Inc. This program is free software; you may redistribute it under the terms of the GNU General Public License. This program has absolutely no warranty. bash-$ ./l2 --version GNU strip 2.9.4 Copyright 1997, 1998 Free Software Foundation, Inc. This program is free software; you may redistribute it under the terms of the GNU General Public License. This program has absolutely no warranty. # Now strip the first executable directly. bash-$ ./strip --strip-all ./a1.exe # Now strip the second executable via the symbolic link. bash-$ ./strip --strip-all ./l2.exe # Execute the files again via the symbolic links to check they work. bash-$ ./l1 --version GNU strip 2.9.4 Copyright 1997, 1998 Free Software Foundation, Inc. This program is free software; you may redistribute it under the terms of the GNU General Public License. This program has absolutely no warranty. # The one striped via the symbolic link fails. bash-$ ./l2 --version bash: ./l2: Permission denied bash-$ # Have a quick look at the file sizes. bash-$ ls -l total 856 -rwxr-xr-x 1 544 None 312832 Feb 19 15:01 a1.exe -rwxr-xr-x 1 544 None 4136 Feb 19 15:01 a2.exe lrw-r--r-- 1 544 None 19 Feb 19 15:01 l1.exe -> ./a1.exe lrw-r--r-- 1 544 None 19 Feb 19 15:01 l2.exe -> ./a2.exe -rwxr-xr-x 1 544 None 1409057 Feb 19 14:35 strip.exe bash-$ -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com