summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrmanfredi <rmanfredi@2592e710-e01b-42a5-8df0-11608a6cc53d>2012-02-07 17:44:54 +0000
committerrmanfredi <rmanfredi@2592e710-e01b-42a5-8df0-11608a6cc53d>2012-02-07 17:44:54 +0000
commitfb770085ce9b54451589585b1d4be253dc982c43 (patch)
treec662f7c6ec32093d450c3f534e240ddedb0a9908
parent522a57d5cd2c6bc5882cd390142c9a7b8f211da8 (diff)
The -s command can change some parts of the exe on Cygwin, so cannot use cmp.
Use a size comparison only to check whether the install program strips. git-svn-id: svn://svn.code.sf.net/p/dist/code/trunk/dist@122 2592e710-e01b-42a5-8df0-11608a6cc53d
-rw-r--r--mcon/U/install.U11
1 files changed, 8 insertions, 3 deletions
diff --git a/mcon/U/install.U b/mcon/U/install.U
index 5b4fdf9..aec3b0c 100644
--- a/mcon/U/install.U
+++ b/mcon/U/install.U
@@ -16,7 +16,7 @@
?RCS: patch45: created
?RCS:
?MAKE:install installdir: Loc Oldconfig Getfile cat test startsh rm +cc \
- eunicefix package contains mkdir echo n c
+ eunicefix package contains mkdir echo n c awk wc
?MAKE: -pick add $@ %<
?S:install:
?S: This variable contains the name of an install program that can accept
@@ -35,7 +35,7 @@
?S: resort, setting the variable to './install -d'. Otherwise, it is set to
?S: plain 'mkdir', and cross your fingers!
?S:.
-?T:dir file tryit prog creatdir either
+?T:dir file tryit prog creatdir either try_wc d_try_wc tryns_wc d_tryns_wc
?F:!tryinst
: locate a BSD compatible install program
echo " "
@@ -91,7 +91,12 @@ EOS
fi
@end
(ls -l d/try >try.ls; ls -l d/try.ns >tryno.ls) 2>/dev/null
- if (cmp -s d/try try && cmp -s d/try.ns try.ns && \
+ try_wc=`$wc -c try | $awk '{ print $1}' 2>/dev/null`
+ tryns_wc=`$wc -c try.ns | $awk '{ print $1}' 2>/dev/null`
+ d_try_wc=`$wc -c d/try | $awk '{ print $1}' 2>/dev/null`
+ d_tryns_wc=`$wc -c d/try.ns | $awk '{ print $1}' 2>/dev/null`
+ if ($test "X$try_wc" = "X$d_try_wc" && \
+ $test "X$tryns_wc" = "X$d_tryns_wc" && \
$contains 'rwxrw-r--' tryno.ls && \
$contains 'rw-r---w-' try.ls) >/dev/null 2>&1
then