aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormescalinum <mescalinum@users.sourceforge.net>2009-09-16 09:34:42 +0000
committermescalinum <mescalinum@users.sourceforge.net>2009-09-16 09:34:42 +0000
commit391659ab8b58230e86ce4aaf23d90ebb2d44e7d2 (patch)
tree72f099fa15e29116a723f1cc5f9eadc1761535c6
parent722a70135e8878c6145f06d7899be8551db059ad (diff)
add tcl package logic
svn path=/trunk/externals/tclpd/; revision=12365
-rw-r--r--bitmap.tcl2
-rw-r--r--tcl_setup.cxx1
-rw-r--r--vslider2.tcl2
3 files changed, 5 insertions, 0 deletions
diff --git a/bitmap.tcl b/bitmap.tcl
index 5641da6..a415e14 100644
--- a/bitmap.tcl
+++ b/bitmap.tcl
@@ -1,3 +1,5 @@
+package require Tclpd 0.2.1
+
source pdlib.tcl
set ::script_path [file dirname [info script]]
diff --git a/tcl_setup.cxx b/tcl_setup.cxx
index a1c66bb..93ba404 100644
--- a/tcl_setup.cxx
+++ b/tcl_setup.cxx
@@ -39,6 +39,7 @@ void tclpd_setup(void) {
Tcl_SetVar(tcl_for_pd, "DIR", dirresult, 0);
Tcl_Eval(tcl_for_pd, "set auto_path [linsert $auto_path $DIR]");
+ Tcl_Eval(tcl_for_pd, "package provide Tclpd " TCLPD_VERSION);
if(Tcl_Eval(tcl_for_pd, "source $DIR/tcl.tcl") == TCL_OK) {
post("Tcl loader: loaded %s/tcl.tcl", dirresult);
diff --git a/vslider2.tcl b/vslider2.tcl
index 1414ef4..0119c01 100644
--- a/vslider2.tcl
+++ b/vslider2.tcl
@@ -1,3 +1,5 @@
+package require Tclpd 0.2.1
+
source pdlib.tcl
set ::script_path [file dirname [info script]]