This is the mail archive of the
insight@sourceware.org
mailing list for the Insight project.
[PATCH/itcl] Fix running in builddir
- From: Keith Seitz <keiths at redhat dot com>
- To: insight <insight at sourceware dot org>
- Date: Fri, 23 Mar 2012 15:13:03 -0700
- Subject: [PATCH/itcl] Fix running in builddir
Hi,
I haven't been using built-in tcl et al for a while, but with the recent
patch submissions, I decided to give it a whirl.
Turns out that insight would no longer run from the build directory. I
tracked this down to a failure to instantiate an iwidgets::scrolledtext
widget. This happens because the auto_path for iwidgets is set relative
to the build directory, and that's not where the actual scripts files are.
To run from the build directory, we also need to add the source
directory to the auto_path. This is what this patch does.
Keith
itcl/iwidgets/ChangeLog
2012-03-23 Keith Seitz <keiths@redhat.com>
* iwidgets.tcl.in: Add source directories to the auto_path.
Index: itcl/iwidgets/iwidgets.tcl.in
===================================================================
RCS file: /cvs/src/src/itcl/iwidgets/iwidgets.tcl.in,v
retrieving revision 1.2
diff -u -p -r1.2 iwidgets.tcl.in
--- itcl/iwidgets/iwidgets.tcl.in 22 Jul 2008 20:32:46 -0000 1.2
+++ itcl/iwidgets/iwidgets.tcl.in 23 Mar 2012 20:39:53 -0000
@@ -25,7 +25,13 @@ namespace eval ::iwidgets {
variable version @VERSION@
}
+set cvsSrcDir [file join $iwidgets::library .. .. .. src itcl iwidgets]
+set gitSrcDir [file join $iwidgets::library .. .. .. gdb itcl iwidgets]
lappend auto_path $iwidgets::library \
[file join $iwidgets::library generic] \
- [file join $iwidgets::library scripts]
+ [file join $iwidgets::library scripts] \
+ [file join $cvsSrcDir generic] \
+ [file join $cvsSrcDir scripts] \
+ [file join $gitSrcDir generic] \
+ [file join $gitSrcDir scripts]
package provide Iwidgets $iwidgets::version