From owner-FreeBSD-users-jp@jp.freebsd.org  Sun Jul  8 16:01:47 2001
Received: (from daemon@localhost)
	by castle.jp.freebsd.org (8.9.3+3.2W/8.7.3) id QAA50523;
	Sun, 8 Jul 2001 16:01:47 +0900 (JST)
	(envelope-from owner-FreeBSD-users-jp@jp.FreeBSD.org)
Received: from localhost.jp.FreeBSD.org (1Cust234.tnt1.hanno.jp.da.uu.net [63.12.195.234])
	by castle.jp.freebsd.org (8.9.3+3.2W/8.7.3) with ESMTP id QAA50518
	for <FreeBSD-users-jp@jp.freebsd.org>; Sun, 8 Jul 2001 16:01:46 +0900 (JST)
	(envelope-from toshi@jp.FreeBSD.org)
Date: Sun, 8 Jul 2001 12:23:20 +0900 (JST)
Message-Id: <200107080323.f683NKV20461.toshi@jp.FreeBSD.org>
From: Toshihiko ARAI <toshi@jp.freebsd.org>
To: FreeBSD-users-jp@jp.freebsd.org
In-Reply-To: <ow1yntagzj.fsf@wish.box2.kmc.kyoto-u.ac.jp>
References: <owith69pzm.fsf@wish.box2.kmc.kyoto-u.ac.jp>
	<20010707.005158.41705227.hrs@eos.ocn.ne.jp>
	<200107061708.f66H8Pb93101.toshi@jp.FreeBSD.org>
	<ow1yntagzj.fsf@wish.box2.kmc.kyoto-u.ac.jp>
X-Mailer: VM 5.96 (beta) / Mule 2.3 (SUETSUMUHANA) based on 19.34.1
Mime-Version: 1.0 (generated by tm-edit 7.106)
Content-Type: text/plain; charset=ISO-2022-JP
Reply-To: FreeBSD-users-jp@jp.freebsd.org
Precedence: list
X-Distribute: distribute version 2.1 (Alpha) patchlevel 24e+010328
X-Sequence: FreeBSD-users-jp 62813
Subject: [FreeBSD-users-jp 62813] Re: GNU make
 =?ISO-2022-JP?B?GyRCJEgbKEI=?= make
 =?ISO-2022-JP?B?GyRCJEc1c0YwJCwwYyQmGyhC?= script
Errors-To: owner-FreeBSD-users-jp@jp.freebsd.org
Sender: owner-FreeBSD-users-jp@jp.freebsd.org
X-Originator: toshi@jp.freebsd.org

$B?70f$G$9!#(B

+ [FreeBSD-users-jp 62798] $B$N5-;v$G(B KITAGAWA Takurou $B$5$s$O=q$-$^$7$?!#(B

> $B$5$F!"LdBj$K$J$C$?85$N(B Makefile $B$r$I$C$A$G$bF0$/$h$&$K=$@5$7$h$&$H$7$?(B
> $B$H$3$m!"$b$&0l$DIT2D2r$JE@$,=P$F$-$^$7$?!#(B

$B=$@5<+BN$O!"(Bset +e; $B$r$O$5$`$N$,0lHV3Z$=$&$G$9$,!"(B

> % sh -ec "if true; then false && true; fi; true"
> $B$O(B exit status 1 $B$G=*N;$7$F$7$^$$$^$9!#(B

$B$3$l$O;EMMDL$j$G$9$M!#(B-x $B$bIU$1$F<B9T$7$F$_$l$P$9$0J,$+$k$H(B
$B;W$$$^$9$,!"(B

% sh -ecx "if true; then false && true; fi; true"
+ true
+ false
Exit 1

$B$H$J$j(B false $B$G=*N;$7$^$9!#$3$N(B && $B$,(B || $B$J$i(B true $B$K<B9T$,(B
$B0z$-7Q$,$l$^$9$,!"(B&& $B$J$i(B false $B$N(B exit status $B$,$3$N%3%^%s%I(B
$BNsA4BN$N(B exit status $B$K$J$j$^$9!#(B

> $BB>$N(B shell $B$G<B83$7$?$H$3$m!"(BSolaris7 $B$N(B /bin/sh $B$d(B bash 2.04
> $B$G$O:G8e$NNc$b(B exit status 0 $B$G=*N;$7$^$9!#(B
> pdksh $B$d(B OpenBSD $B$N(B /bin/sh $B$G$O(B FreeBSD $B$N(B /bin/sh $B$HF1$8$/(B
> exit status 1 $B$K$J$j$^$7$?!#(B

> $B$3$l$bC1$J$k!V;EMM$N0c$$!W$G$7$g$&$+(B?
> POSIX $BE*$K$O$I$C$A$,@5$7$$$H$+7h$^$C$F$J$$$N$G$7$g$&$+(B?

POSIX $B$K$OAB$$$N$G$h$&J,$+$i$J$$$G$9$,!"(B

sh(1)
     -e errexit
             Exit immediately if any untested command fails in non-interactive
             mode.  The exit status of a command is considered to be explicit-
             ly tested if the command is used to control an if, elif, while,
             or until; or if the command is the left hand operand of an ``&&''
             or ``||'' operator.

info bash
    `-e'
          Exit immediately if a simple command (*note Simple
          Commands::) exits with a non-zero status, unless the command
          that fails is part of an `until' or `while' loop, part of an
          `if' statement, part of a `&&' or `||' list, or if the
          command's return status is being inverted using `!'.

$B$H$$$&$3$H$G!"!V;EMM$N0c$$!W$H$$$&$3$H$G$O$J$$$G$7$g$&$+!#(B
$B%_%=$O(B ``used to control'' $B$K$"$k$h$&$G$9!#(B

--
Toshihiko ARAI / $B?70fMxI'(B / toshi@FreeBSD.org
