TCL, but not TK

Started by Mikhail Teterinover 25 years ago3 messagesbugs
Jump to latest
#1Mikhail Teterin
mi@privatelabs.com

The following patch adds --without-tk switch to 7.0.2's configure.
Currently, if the TK is present at build time, it will be linked
in, which makes it more difficult to build on one's workstation and
deploy on the X11-less server, where TCL is still desirable.

This patches let you disable Tk even if you have it installed and
makes sure the TCL-library is added as a dependency for libpgtcl.
--- interfaces/libpgtcl/Makefile.in	Tue Mar  7 20:58:36 2000
+++ interfaces/libpgtcl/Makefile.in	Wed Sep 20 08:57:28 2000
@@ -29,3 +29,3 @@
-SHLIB_LINK+= $(LIBPQ)
+SHLIB_LINK+= $(LIBPQ) @TCL_LIB_SPEC@
--- configure	Wed Sep 20 08:53:57 2000
+++ configure	Wed Sep 20 09:01:00 2000
@@ -948,2 +948,17 @@
+if test USE_TCL = true
+then
+	echo $ac_n "checking setting USE_TK""... $ac_c" 1>&6
+	echo "configure:952: checking setting USE_TK" >&5
+	# Check whether --with-tk or --without-tk was given.
+	if test "${with_tk+set}" = set; then
+	  withval="$with_tk"
+	  
+		case "$withval" in
+		y | ye | yes)		USE_TK=true; echo "$ac_t""enabled" 1>&6 ;;
+		*)			USE_TK=n; echo "$ac_t""disabled" 1>&6 ;;
+		esac
+	fi
+fi
+
@@ -7090,3 +7105,3 @@
 		echo "$ac_t""$TCL_CONFIG_SH" 1>&6
-		
+		. ${TCL_CONFIG_SH}
 	fi
@@ -7094,3 +7118,5 @@
-USE_TK=$USE_TCL		# If TCL is disabled, disable TK
+USE_TK=${USE_TK:=$USE_TCL}		# If TCL is disabled, disable TK,
+					# otherwise -- enable unless explicitly
+					# disabled
@@ -8359,2 +8385,3 @@
 s%@expanded_libdir@%$expanded_libdir%g
+s%@TCL_LIB_SPEC@%$TCL_LIB_SPEC%g
#2Bruce Momjian
bruce@momjian.us
In reply to: Mikhail Teterin (#1)
Re: TCL, but not TK

I don't think this would be of general use for users. Sorry.

The following patch adds --without-tk switch to 7.0.2's configure.
Currently, if the TK is present at build time, it will be linked
in, which makes it more difficult to build on one's workstation and
deploy on the X11-less server, where TCL is still desirable.

This patches let you disable Tk even if you have it installed and
makes sure the TCL-library is added as a dependency for libpgtcl.
--- interfaces/libpgtcl/Makefile.in	Tue Mar  7 20:58:36 2000
+++ interfaces/libpgtcl/Makefile.in	Wed Sep 20 08:57:28 2000
@@ -29,3 +29,3 @@
-SHLIB_LINK+= $(LIBPQ)
+SHLIB_LINK+= $(LIBPQ) @TCL_LIB_SPEC@
--- configure	Wed Sep 20 08:53:57 2000
+++ configure	Wed Sep 20 09:01:00 2000
@@ -948,2 +948,17 @@
+if test USE_TCL = true
+then
+	echo $ac_n "checking setting USE_TK""... $ac_c" 1>&6
+	echo "configure:952: checking setting USE_TK" >&5
+	# Check whether --with-tk or --without-tk was given.
+	if test "${with_tk+set}" = set; then
+	  withval="$with_tk"
+	  
+		case "$withval" in
+		y | ye | yes)		USE_TK=true; echo "$ac_t""enabled" 1>&6 ;;
+		*)			USE_TK=n; echo "$ac_t""disabled" 1>&6 ;;
+		esac
+	fi
+fi
+
@@ -7090,3 +7105,3 @@
echo "$ac_t""$TCL_CONFIG_SH" 1>&6
-		
+		. ${TCL_CONFIG_SH}
fi
@@ -7094,3 +7118,5 @@
-USE_TK=$USE_TCL		# If TCL is disabled, disable TK
+USE_TK=${USE_TK:=$USE_TCL}		# If TCL is disabled, disable TK,
+					# otherwise -- enable unless explicitly
+					# disabled
@@ -8359,2 +8385,3 @@
s%@expanded_libdir@%$expanded_libdir%g
+s%@TCL_LIB_SPEC@%$TCL_LIB_SPEC%g
-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026
#3Tom Lane
tgl@sss.pgh.pa.us
In reply to: Bruce Momjian (#2)
Re: TCL, but not TK

Bruce Momjian <pgman@candle.pha.pa.us> writes:

I don't think this would be of general use for users. Sorry.

The following patch adds --without-tk switch to 7.0.2's configure.

More to the point, Peter already put in exactly this switch ;-)

regards, tom lane