summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLloyd Hilaiel <lloyd@hilaiel.com>2015-09-24 13:16:46 -0600
committerLloyd Hilaiel <lloyd@hilaiel.com>2015-09-24 13:16:46 -0600
commit5e3a7856e643b4d6410ddc3f84bc2f38174f2872 (patch)
treed93f9cb6106c54a2cece11b2f68778e897be62d7
parent12ee82ae5138ac86252c41f3ae8f9fd9880e4284 (diff)
parenta30c6f7e8c780ab38d70732b830dd1fa8563c352 (diff)
downloadyajl-master.tar.gz
Merge pull request #157 from setempler/bugfix-configureHEADmaster
Fixed configure script to accept "-h" and "--prefix".
-rwxr-xr-xconfigure16
1 files changed, 8 insertions, 8 deletions
diff --git a/configure b/configure
index 716e7d1..d308c12 100755
--- a/configure
+++ b/configure
@@ -15,18 +15,18 @@
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
prefix="/usr/local"
-if [ "$1" = "--help" ]
-then
- cat <<EOS
-Usage: configure [options]
+usage="Usage: configure [options]
-p, --prefix PATH Set installation prefix
- -h, --help Output usage summary
-EOS
+ -h, --help Output usage summary"
+if [ "$1" = "-h" ] || [ "$1" = "--help" ]
+then
+ echo "$usage"
exit 0
fi
-if [ "$1" = "-p" ]; then
+if [ "$1" = "-p" ] || [ "$1" = "--prefix" ]
+then
if [ "$#" != 2 ]; then
- ./configure.sh --help
+ echo "$usage"
exit 1
fi
prefix="$2"