aboutsummaryrefslogtreecommitdiff
path: root/externals
diff options
context:
space:
mode:
authormescalinum <mescalinum@users.sourceforge.net>2009-09-03 14:05:08 +0000
committermescalinum <mescalinum@users.sourceforge.net>2009-09-03 14:05:08 +0000
commit8281a9243bd4343add28c1140762beea587e258a (patch)
tree90e02baed3dff97a8d193930ffc0d6b1f1e648f2 /externals
parent6128337e726aa5d665a91b4c7e97f9644c265fc9 (diff)
add two variables to Makefile (TCL_RUNTIME_VERSION and TCL_HEADERS_VERSION), and conditionally add tclpd only if OS == linux AND tcl-dev >= 8.5
svn path=/trunk/; revision=12210
Diffstat (limited to 'externals')
-rw-r--r--externals/Makefile7
1 files changed, 7 insertions, 0 deletions
diff --git a/externals/Makefile b/externals/Makefile
index 865cb135..26248222 100644
--- a/externals/Makefile
+++ b/externals/Makefile
@@ -86,6 +86,9 @@ endif
CXXFLAGS = $(CFLAGS)
+TCL_RUNTIME_VERSION=$(shell echo 'puts $$tcl_version' | tclsh)
+TCL_HEADERS_VERSION=$(shell sed -n 's|^#define TCL_VERSION.*"\([0-9]\.[0-9][0-9]*\)".*|\1|p' /usr/include/tcl.h)
+
### C++ files
%.$(EXTENSION): %.cpp
%.$(EXTENSION): %.cc
@@ -139,6 +142,10 @@ else
else
# GNU/Linux, BSD, IRIX, etc.
LIB_TARGETS += hid pdp pidip gem2pdp iem16 pdp_opengl pdvjtools postlude sixaxis
+ # externals that depend on Tcl 8.5 or greater
+ ifeq ($(TCL_HEADERS_VERSION),8.5)
+ LIB_TARGETS += tclpd
+ endif
endif
endif