]> git.saurik.com Git - wxWidgets.git/blame_incremental - wx-config.in
Put the vertical limit back in for the AutoCOmp list box
[wxWidgets.git] / wx-config.in
... / ...
CommitLineData
1#!/bin/sh
2
3prefix=@prefix@
4exec_prefix=@exec_prefix@
5exec_prefix_set=no
6CC="@CC@"
7CXX="@CXX@"
8LD="@SHARED_LD@"
9cross_compiling=@cross_compiling@
10
11usage()
12{
13 cat <<EOF
14Usage: wx-config [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version]
15 [--libs] [--gl-libs] [--cppflags] [--cflags] [--cxxflags] [--rezflags]
16 [--cc] [--cxx] [--ld]
17
18wx-config returns configuration information about the installed
19version of wxWindows. It may be used to query its version and
20installation directories and also retrieve the C and C++ compilers
21and linker which were used for its building and the corresponding
22flags.
23EOF
24
25 exit $1
26}
27
28cppflags()
29{
30 if test "${cross_compiling}" != "yes" \
31 -a @includedir@ != /usr/include \
32 -a @includedir@ != /usr/include/c++ ;
33 then
34 includes=-I@includedir@
35 fi
36 includes="-I@libdir@/wx/include/@TOOLCHAIN_NAME@ $includes"
37 echo $includes @WXDEBUG_DEFINE@ @TOOLCHAIN_DEFS@ @WXCONFIG_INCLUDE@
38}
39
40if test $# -eq 0; then
41 usage 1 1>&2
42fi
43
44while test $# -gt 0; do
45 case "$1" in
46 -*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
47 *) optarg= ;;
48 esac
49
50 case $1 in
51 --prefix=*)
52 prefix=$optarg
53 if test $exec_prefix_set = no ; then
54 exec_prefix=$optarg
55 fi
56 ;;
57 --prefix)
58 echo $prefix
59 ;;
60 --exec-prefix=*)
61 exec_prefix=$optarg
62 exec_prefix_set=yes
63 ;;
64 --exec-prefix)
65 echo $exec_prefix
66 ;;
67 --version)
68 echo @WX_MAJOR_VERSION_NUMBER@.@WX_MINOR_VERSION_NUMBER@.@WX_RELEASE_NUMBER@
69 ;;
70 --cppflags)
71 cppflags
72 ;;
73 --cflags)
74 echo `cppflags` @CODE_GEN_FLAGS@
75 ;;
76 --cxxflags)
77 echo `cppflags` @CODE_GEN_FLAGS@ @CODE_GEN_FLAGS_CXX@
78 ;;
79 --rezflags)
80 echo @LIBWXMACRESWXCONFIG@
81 ;;
82 --libs)
83 if test "${cross_compiling}" != "yes" \
84 -a @libdir@ != /usr/lib ;
85 then
86 libs="-L@libdir@"
87 fi
88 echo $libs @WXCONFIG_LIBS@ @EXTRA_LIBS@
89 ;;
90 --gl-libs)
91 echo @WXCONFIG_LIBS_GL@
92 ;;
93 --cc)
94 echo $CC
95 ;;
96 --cxx)
97 echo $CXX
98 ;;
99 --ld)
100 echo $LD
101 ;;
102 *)
103 usage 1 1>&2
104 ;;
105 esac
106 shift
107done
108