This content has been updated. You will be momentarily redirected to the current version.


Moved! I now blog at http://www.saicharan.in

Sunday, March 01, 2009

NS2 nam error

I have been bothered by this error while running ns/nam for a long time now. Finally found that tk needed patching :( Here is the error that I got and the solution that helped me fix it.

[root@localhost]# nam:
[code omitted because of length]
: no event type or button # or keysym
while executing
"bind Listbox {

%W yview scroll [expr {- (%D / 120) * 4}] units


invoked from within

"if {[tk windowingsystem] eq "classic" || [tk windowingsystem] eq "aqua"} {
bind Listbox {
%W yview scroll [expr {- (%D)}] units


bind Li..."

And, I got the solution to this on: http://forums.fedoraforum.org/showthread.php?t=206795.
Essentially you need to patch tk8.4.18 with the patches from: http://bugs.gentoo.org/show_bug.cgi?id=225999

Details of how to patch are available at: http://forums.fedoraforum.org/showpost.php?s=a2bb89875669ff26ed61cd371399a517&p=1131049&postcount=3

1 comment:

Mitra Anvari said...

i wrote a new agent and modified the relevant files (makefile,packet.h,ns-default.tcl ) ,then i make clean and make the ns-2.34 i get this error (no rule to make target 'vanet.o' needed by ns) and when i want to run my tcl file i get this error (ns: [code ommited because of length] : invalid command name "Agent/Vanet" while executing "Agent/Vanet set packetSize_ 64").

will u pls help me out with this error.
i appreciate any help.
ps: tcl/tk 8.4.18 has already been installed.