aboutsummaryrefslogtreecommitdiff
path: root/irc/weechat/files/patch-configure.in
blob: 5510d034332d7c2ddc57ec892ee6c98e172e6564 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
--- configure.in.orig	2009-09-06 08:01:26.000000000 +0000
+++ configure.in	2009-11-12 14:46:30.000000000 +0000
@@ -137,6 +137,7 @@
 AC_ARG_WITH(lua-inc,        [  --with-lua-inc=DIR,     lua include files are in DIR (default=autodetect)],lua_inc=$withval,lua_inc='')
 AC_ARG_WITH(lua-lib,        [  --with-lua-lib=DIR,     lua library files are in DIR (default=autodetect)],lua_lib=$withval,lua_lib='')
 AC_ARG_WITH(lua-suffix,     [  --with-lua-suffix=ARG   lua is suffixed with ARG (default=autodetect)],lua_suffix=$withval,lua_suffix='')
+AC_ARG_WITH(tclconfig,      [  --with-tclconfig=DIR    directory containing tcl configuration (tclConfig.sh)],tclconfig=$withval,tclconfig='')
 AC_ARG_ENABLE(doc,          [  --disable-doc           turn off documentation (default=built)],enable_doc=$enableval,enable_doc=yes)
 AC_ARG_WITH(debug,          [  --with-debug            debugging: 0=no debug, 1=debug compilation (default=1)],debug=$withval,debug=1)
 
@@ -682,6 +683,9 @@
     AC_MSG_CHECKING(for tclConfig.sh)
     tcl_found="no"
     tcl_dirs="/lib /usr/lib /usr/tcl/lib /usr/lib/tcl8.5 /usr/lib/tcl8.4 /usr/lib/tcl8.3 /usr/local/lib /usr/local/tcl-8.5/lib /usr/local/tcl-8.4/lib /usr/local/tcl-8.3/lib /usr/local/tcl/lib /opt/lib"
+    if test "x$tclconfig" != "x" ; then
+        tcl_dirs="$tclconfig $tcl_dirs"
+    fi
     for tcl_dir in $tcl_dirs ; do
         if test -f ${tcl_dir}/tclConfig.sh ; then
             . ${tcl_dir}/tclConfig.sh
@@ -870,7 +874,7 @@
     AC_MSG_RESULT(no)
 fi
 
-CFLAGS=`echo $CFLAGS | sed 's/ -g //g'`
+CFLAGS=`echo $CFLAGS | sed 's/ -g / /g'`
 CFLAGS=`echo $CFLAGS | sed 's/^-g //g'`
 CFLAGS=`echo $CFLAGS | sed 's/ -g$//g'`
 CFLAGS=`echo $CFLAGS | sed 's/^-g$//g'`