GCC="@GCC@"
CXX="@CXX@"
LD="@SHARED_LD@"
+srcdir=@top_srcdir@
+builddir=@top_builddir@
cross_compiling=@cross_compiling@
target=@host_alias@
static_flag=@STATIC_FLAG@
+# return the absolute path prepending builddir to it if needed
+makeabs()
+{
+ path=$1
+ # TODO: this only works under Unix and even there it could be
+ # enhanced to remove ".." and "."
+ if [ `echo $path | sed 's/^\(.\).*/\1/'` != "/" ]; then
+ if [ $path = "." ]; then
+ path=$builddir
+ else
+ path="$builddir/$path"
+ fi
+ fi
+
+ echo $path
+}
+
usage()
{
cat <<EOF
-Usage: wx-config [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--static]
- [--libs] [--gl-libs]
+Usage: wx-config [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--release]
+ [--basename] [--static] [--libs] [--gl-libs]
[--cppflags] [--cflags] [--cxxflags] [--ldflags] [--rezflags]
[--cc] [--cxx] [--ld]
package building and bleeding edge developers. To do so, use it like
this:
-${wx_builddir}/wx-config --prefix=${wx_srcdir} --exec-prefix=${wx_builddir}
+\${wx_builddir}/wx-config --prefix=\${wx_srcdir} --exec-prefix=\${wx_builddir}
Note that any other options supplied must come *after* the prefix
specification for it to take effect.
esac
case $1 in
+ --inplace)
+ prefix=`makeabs $srcdir`
+ exec_prefix=`makeabs $builddir`
+ exec_prefix_set=yes
+ ;;
--prefix=*)
prefix=$optarg
if test $exec_prefix_set = no ; then
--version)
echo @WX_MAJOR_VERSION_NUMBER@.@WX_MINOR_VERSION_NUMBER@.@WX_RELEASE_NUMBER@
;;
+ --release)
+ # Should echo @WX_RELEASE@ instead, but that doesn't seem to be replaced after
+ # configure has run on this file.
+ echo @WX_MAJOR_VERSION_NUMBER@.@WX_MINOR_VERSION_NUMBER@
+ ;;
+ --basename)
+ echo @WX_LIBRARY_BASENAME@
+ ;;
--static)
static_flag=yes
;;
echo @LDFLAGS_EXE@
;;
--rezflags)
- echo @LIBWXMACRESWXCONFIG@
+ echo @MACRESWXCONFIG@
;;
--libs)
if test "@libdir@" != "/usr/lib" \