com php-src: Fix #77041: buildconf should output error messages to stderr: build/buildcheck.sh build/genif.sh buildconf makedist
| From: | Peter Kokot | Date: | Sat, 20 Oct 2018 07:42:56 +0000 |
| Subject: | com php-src: Fix #77041: buildconf should output error messages to stderr: build/buildcheck.sh build/genif.sh buildconf makedist | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-103517@lists.php.net to get a copy of this message | ||
Commit: 9f5cb626ed4bede914b57ec8e233808030671ee5
Author: Mizunashi Mana <mizunashi-mana@noreply.git> Sat, 20 Oct 2018 09:42:56 +0200
Committer: Peter Kokot <peterkokot@gmail.com> Sat, 20 Oct 2018 09:42:56 +0200
Parents: 4be0528476763d8c6bfb7a47ad62278c187ef400
Branches: PHP-7.1 PHP-7.2 PHP-7.3 master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=9f5cb626ed4bede914b57ec8e233808030671ee5
Log:
Fix #77041: buildconf should output error messages to stderr
Bugs:
https://bugs.php.net/77041
Changed paths:
M build/buildcheck.sh
M build/genif.sh
M buildconf
M makedist
Diff:
diff --git a/build/buildcheck.sh b/build/buildcheck.sh
index b210d5e..515a45d 100755
--- a/build/buildcheck.sh
+++ b/build/buildcheck.sh
@@ -31,16 +31,16 @@ fi
# autoconf 2.59 or newer
ac_version=
$PHP_AUTOCONF --version 2>/dev/null|head -n 1|sed -e 's/^[^0-9]*//'
-e 's/[a-z]* *$//'
if test -z "$ac_version"; then
-echo "buildconf: autoconf not found."
-echo " You need autoconf version 2.59 or newer installed"
-echo " to build PHP from Git."
+echo "buildconf: autoconf not found." >&2
+echo " You need autoconf version 2.59 or newer installed" >&2
+echo " to build PHP from Git." >&2
exit 1
fi
IFS=.; set $ac_version; IFS=' '
if test "$1" = "2" -a "$2" -lt "59" || test "$1"
-lt "2"; then
-echo "buildconf: autoconf version $ac_version found."
-echo " You need autoconf version 2.59 or newer installed"
-echo " to build PHP from Git."
+echo "buildconf: autoconf version $ac_version found." >&2
+echo " You need autoconf version 2.59 or newer installed" >&2
+echo " to build PHP from Git." >&2
exit 1
else
echo "buildconf: autoconf version $ac_version (ok)"
diff --git a/build/genif.sh b/build/genif.sh
index 4a9c0fa..c150c4c 100644
--- a/build/genif.sh
+++ b/build/genif.sh
@@ -13,7 +13,7 @@ awk=$1
shift
if test -z "$infile" || test -z "$srcdir"; then
- echo "please supply infile and srcdir"
+ echo "please supply infile and srcdir" >&2
exit 1
fi
diff --git a/buildconf b/buildconf
index 9344b07..939b2ea 100755
--- a/buildconf
+++ b/buildconf
@@ -28,8 +28,8 @@ while test $# -gt 0; do
done
if test "$dev" = "0" -a "$devok" = "0"; then
- echo "You should not run buildconf in a release package."
- echo "use buildconf --force to override this check."
+ echo "You should not run buildconf in a release package." >&2
+ echo "use buildconf --force to override this check." >&2
exit 1
fi
diff --git a/makedist b/makedist
index 8384899..797b18e 100755
--- a/makedist
+++ b/makedist
@@ -65,8 +65,8 @@ DIR=php-$VER
DIRPATH=$MY_OLDPWD/$DIR
if test -d "$DIRPATH"; then
- echo "The directory $DIR"
- echo "already exists, rename or remove it and run makedist again."
+ echo "The directory $DIR" >&2
+ echo "already exists, rename or remove it and run makedist again." >&2
exit 1
fi