summaryrefslogtreecommitdiff
path: root/scripts/phpize.in
diff options
context:
space:
mode:
authorfoobar <sniper@php.net>2003-07-01 15:55:09 +0000
committerfoobar <sniper@php.net>2003-07-01 15:55:09 +0000
commit063e4e251e23bdbabd8fc4640c890a5be75e6d21 (patch)
treee0e07b1f88b9bff380e4996a63d404f9355c8c6a /scripts/phpize.in
parente7ff808fb850b8c7c422a3cf78ab2099a3db840b (diff)
downloadphp-git-063e4e251e23bdbabd8fc4640c890a5be75e6d21.tar.gz
Added --help to phpize
Diffstat (limited to 'scripts/phpize.in')
-rw-r--r--scripts/phpize.in26
1 files changed, 17 insertions, 9 deletions
diff --git a/scripts/phpize.in b/scripts/phpize.in
index 7a4fdb759a..051d334d7e 100644
--- a/scripts/phpize.in
+++ b/scripts/phpize.in
@@ -12,20 +12,28 @@ CLEAN_FILES="$FILES *.lo *.la *.o .deps .libs/ build/ include/ modules/ install-
aclocal.m4 config.h config.h.in conftest* ltmain.sh libtool config.cache \
config.log config.status Makefile Makefile.fragments Makefile.objects"
-if test ! -r config.m4; then
+# Sanity check
+if test ! -r config.m4 && test "$1" != "--help"; then
echo "Cannot find config.m4. "
echo "Make sure that you run $0 in the top level source directory of the module"
exit 1
fi
-# Cleanup
-if test "$1" = "--clean"; then
- echo "Cleaning.."
- for i in $CLEAN_FILES; do
- test -e && rm -rf $i
- done
- exit 0
-fi
+# Usage
+case "$args" in
+ --clean)
+ # Cleanup
+ echo "Cleaning.."
+ for i in $CLEAN_FILES; do
+ test -e $i && rm -rf $i
+ done
+ exit 0
+ ;;
+ --help)
+ echo "Usage: $0 [--clean|--help]"
+ exit 1
+ ;;
+esac
test -d build || mkdir build