blob: f6f2195c4e640e65c8646d2c4989959b167a6610 [file] [log] [blame]
cristy3ed852e2009-09-05 21:47:34 +00001#!/bin/sh
2#
3# Configure options script for re-calling MagickWand compilation options
4# required to use the MagickWand library.
5#
6
7prefix=@prefix@
8exec_prefix=@exec_prefix@
9libdir=@libdir@
10includedir=@includedir@/ImageMagick
11
12usage="\
13Usage: MagickWand-config [--cflags] [--cppflags] [--exec-prefix] [--ldflags] [--libs] [--prefix] [--version]"
14
15if test $# -eq 0; then
cristy549177c2010-11-11 13:51:21 +000016 echo "${usage}" 1>&2
17 echo "Example: gcc \`MagickWand-config --cflags --cppflags\` -o wand wand.c \`MagickWand-config --ldflags --libs\`" 1>&2
cristy3ed852e2009-09-05 21:47:34 +000018 exit 1
19fi
20
21while test $# -gt 0; do
22 case "$1" in
cristy549177c2010-11-11 13:51:21 +000023 -*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
cristy3ed852e2009-09-05 21:47:34 +000024 *) optarg= ;;
25 esac
26 case $1 in
27 --prefix=*)
28 prefix=$optarg
29 ;;
30 --prefix)
cristy549177c2010-11-11 13:51:21 +000031 echo $prefix
cristy3ed852e2009-09-05 21:47:34 +000032 ;;
33 --exec-prefix=*)
34 exec_prefix=$optarg
35 ;;
36 --exec-prefix)
cristy549177c2010-11-11 13:51:21 +000037 echo $exec_prefix
cristy3ed852e2009-09-05 21:47:34 +000038 ;;
39 --version)
cristy549177c2010-11-11 13:51:21 +000040 echo '@PACKAGE_VERSION@ Q@QUANTUM_DEPTH@ @MAGICK_HDRI@'
cristy3ed852e2009-09-05 21:47:34 +000041 ;;
42 --cflags)
cristy549177c2010-11-11 13:51:21 +000043 echo "-I${includedir} @MAGICK_PCFLAGS@"
cristy3ed852e2009-09-05 21:47:34 +000044 ;;
45 --cxxflags)
cristy549177c2010-11-11 13:51:21 +000046 echo '@MAGICK_CXXFLAGS@'
cristy3ed852e2009-09-05 21:47:34 +000047 ;;
48 --cppflags)
cristy549177c2010-11-11 13:51:21 +000049 echo '@MAGICK_CPPFLAGS@'
cristy3ed852e2009-09-05 21:47:34 +000050 ;;
51 --ldflags)
cristy549177c2010-11-11 13:51:21 +000052 echo '@MAGICK_LDFLAGS@'
cristy3ed852e2009-09-05 21:47:34 +000053 ;;
54 --libs)
cristy549177c2010-11-11 13:51:21 +000055 echo "-L${libdir} -lMagickWand @MAGICK_LIBS@"
cristy3ed852e2009-09-05 21:47:34 +000056 ;;
57 *)
58 echo "${usage}" 1>&2
59 exit 1
60 ;;
61 esac
62 shift
63done
64