Hello!
Taking the plunge with BRL-CAD. Thank you, thank you. I am reporting a bug I see on Ubuntu 20.04/archer, both in the binary download, and the build from source code. I want to help get it working here.
System:
In short, 2 CPU VMware Fusion, 4GB, Ubuntu 20.04. Details are in the attached sysinfo.txt
Console messages (same for downloaded and for my build):
(base) cuz@ubuntu:~/Downloads/brlcad-7.32.2$ ./build/bin/archer
invalid command name "::hv3::formmanager"
Unexpected error encountered while running Archer.
Aborting.
NOTE:
Build went down perfectly on Ubuntu 20.04 once I ran:
sudo apt-get install xorg-dev
cmake .. -DBRLCAD_BUNDLED_LIBS=ON -DCMAKE_BUILD_TYPE=Release
...
sudo make install
All tests look okay, make check, test, etc. on my build. mged launches okay.
/usr/brlcad/rel-7.32.2/bin is in PATH:
(base) cuz@ubuntu:~/Downloads/brlcad-7.32.2/build$ echo $PATH
/home/cuz/zx/bin:/home/cuz/zx/bin:/home/cuz/anaconda3/bin:/home/cuz/anaconda3/condabin:/home/cuz/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/home/cuz/julia-1.6.0-rc1/bin:/home/cuz/bin:/usr/brlcad/rel-7.32.2/bin:/home/cuz/julia-1.6.0-rc1/bin:/home/cuz/bin
GDB output:
(I set a breakpoint on 'exit' so we can see stack trace)
(base) cuz@ubuntu:~/Downloads/brlcad-7.32.2/build$ gdb archer
GNU gdb (Ubuntu 9.2-0ubuntu1~20.04) 9.2
...
Reading symbols from archer...
(gdb) run
Starting program: /usr/brlcad/rel-7.32.2/bin/archer
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7ffff1e72700 (LWP 265698)]
invalid command name "::hv3::formmanager"
Unexpected error encountered while running Archer.
Aborting.
[Thread 0x7ffff1e72700 (LWP 265698) exited]
[Inferior 1 (process 265691) exited with code 01]
(gdb) b _exit
Breakpoint 1 at 0x7ffff7e94290: file ../sysdeps/unix/sysv/linux/_exit.c, line 27.
(gdb) run
Starting program: /usr/brlcad/rel-7.32.2/bin/archer
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7ffff1e72700 (LWP 265702)]
invalid command name "::hv3::formmanager"
Unexpected error encountered while running Archer.
Aborting.
[Thread 0x7ffff1e72700 (LWP 265702) exited]
Thread 1 "archer" hit Breakpoint 1, __GI__exit (status=status@entry=1) at ../sysdeps/unix/sysv/linux/_exit.c:27
27 ../sysdeps/unix/sysv/linux/_exit.c: No such file or directory.
(gdb) bt
#0 __GI__exit (status=status@entry=1) at ../sysdeps/unix/sysv/linux/_exit.c:27
#1 0x00007ffff7df7b42 in __run_exit_handlers (status=status@entry=1, listp=<optimized out>, run_list_atexit=run_list_atexit@entry=true,
run_dtors=run_dtors@entry=true) at exit.c:132
#2 0x00007ffff7df7be0 in __GI_exit (status=status@entry=1) at exit.c:139
#3 0x00007ffff7c3fdb5 in Tcl_Exit (status=1) at /home/cuz/Downloads/brlcad-7.32.2/src/other/tcl/generic/tclEvent.c:995
#4 0x00007ffff7bc7407 in Tcl_ExitObjCmd (dummy=<optimized out>, interp=<optimized out>, objc=<optimized out>, objv=<optimized out>)
at /home/cuz/Downloads/brlcad-7.32.2/src/other/tcl/generic/tclCmdAH.c:1057
#5 0x00007ffff7bb7f52 in TclNRRunCallbacks (interp=interp@entry=0x55555560fe60, result=0, rootPtr=0x0)
at /home/cuz/Downloads/brlcad-7.32.2/src/other/tcl/generic/tclBasic.c:4492
#6 0x00007ffff7bb7fd5 in Tcl_EvalObjv (interp=interp@entry=0x55555560fe60, objc=objc@entry=3, objv=objv@entry=0x55555561d760, flags=flags@entry=2097168)
at /home/cuz/Downloads/brlcad-7.32.2/src/other/tcl/generic/tclBasic.c:4215
#7 0x00007ffff7bb944c in TclEvalEx (interp=interp@entry=0x55555560fe60,
script=0x555555d95070 "#", ' ' <repeats 16 times>, "A R C H E R _ I N I T . T C L\n# BRL-CAD\n#\n# Copyright (c) 2002-2021 United States Government as represented by\n# the U.S. Army Research Laboratory.\n#\n# This library is free software; "..., numBytes=<optimized out>, flags=flags@entry=0,
line=<optimized out>, line@entry=1, clNextOuter=clNextOuter@entry=0x0,
outerScript=0x555555d95070 "#", ' ' <repeats 16 times>, "A R C H E R _ I N I T . T C L\n# BRL-CAD\n#\n# Copyright (c) 2002-2021 United States Government as represented by\n# the U.S. Army Research Laboratory.\n#\n# This library is free software; "...)
at /home/cuz/Downloads/brlcad-7.32.2/src/other/tcl/generic/tclBasic.c:5361
#8 0x00007ffff7c7e219 in Tcl_FSEvalFileEx (encodingName=<optimized out>, pathPtr=0x5555556f2330, interp=0x55555560fe60)
at /home/cuz/Downloads/brlcad-7.32.2/src/other/tcl/generic/tclIOUtil.c:1824
#9 Tcl_FSEvalFileEx (interp=0x55555560fe60, pathPtr=0x5555556f2330, encodingName=<optimized out>)
at /home/cuz/Downloads/brlcad-7.32.2/src/other/tcl/generic/tclIOUtil.c:1724
#10 0x00007ffff7c7e39c in Tcl_EvalFile (interp=0x55555560fe60, fileName=<optimized out>)
at /home/cuz/Downloads/brlcad-7.32.2/src/other/tcl/generic/tclIOUtil.c:424
#11 0x0000555555555419 in main (argc=<optimized out>, argv=0x7fffffffddf0) at /home/cuz/Downloads/brlcad-7.32.2/src/archer/archer.c:116
(gdb)
Are there any variations on BRLCAD_OPTIONS that might shed some light, or other steps that I can take?
THANK YOU
I see the (aboutArcher.png) splash screen, so I set archer_launch.tcl -> createSplashScreen {} -> useImage to 0. Same crash.
I then set:
after 1500 destroySplashScreen; # 1.5 more secto
after 7500 destroySplashScreen; # 1.5 more secand there was no change in timing. Means nothing, any form of changes to createSplashScreen {}, including immediately returning, does nothing.
Last edit: Clark Dunson 2021-05-18
This:
$ mged -obrings up archer successfully! That is certainly a clue.
Attempts to source-debug archer_launch.tcl through
initBgerrorfailed.But in main ():
we never get to "First1 Block". This is probably obvious to some of you. I have no idea what this line means. (yet)
Last edit: Clark Dunson 2021-05-18
In /usr/brlcad/rel-7.32.2/share/tclscripts/archer/Archer.tcl, this is the bogey line:
which traces down to: /usr/brlcad/rel-7.32.2/share/tclscripts/hv3/hv3.tcl, line 1144
Execution appears to never enter the constructor for: /usr/brlcad/rel-7.32.2/share/tclscripts/hv3/hv3_form.tcl, for the class/snit defined at line 1609
The sourced path for hv3_form.tcl in: /usr/brlcad/rel-7.32.2/share/tclscripts/hv3/hv3.tcl is: /usr/brlcad/rel-7.32.2/share/tclscripts/hv3/hv3_form.tcl, and is correct.
I couldn't believe you guys would be captive on sourceforce. On a hunch, I guthub'd you and voila. Better. I build tag rel-7-32-2, installed in /usr/brlcad/rel-7-32-2, and ended up duplicating my problem, invalid command name "::hv3::formmanager". Consistency, blessed be.
I also noticed a GSOC from 2014 where a built in TCL8.5 and compatibility thereof is of great concern.
Unfortunately I am new to TCL, but I do see that the formmanager is the only one without a namespace locally defined within hv3.tcl:
This leads me to suspect that I am with some newer Tcl (Ubuntu 20.04) and breaking new ground. I built and diff'd rel-7-32-0, which make install'd everything into /usr/local (wished I's made a snapshot 1st). There Archer does not produce the above error, but it rather hangs and no window ever shows.
It would be cool to know what it does successfully build on, I'll make a fresh Fedora, try that, also I have some older Debians. cheers.
Now for some seriously deep dukey. I can puts successfully all the way up to line 256 of hv3_form.tcl. There we find this:
(The leading '::' has been omitted so that it will show here)
No puts statements work after that. But what is really hard for me to quaff, is that it doesn't matter how I mangle the rest of the file after that (including changing ::snit to ::snot) there is no error message other than:
In fact, no matter what syntax error I introduce into this file at all, that's all I get. That's quite janky man, though a proper puts works early in the file. This would place Tcl above both Make and PERL for cryptic error messages. I honestly can't believe it.
So I tried this at the top of the file:
and it works:
But eliminating the close quote:
gets me only:
Conclusion: If something is going wrong inside hv3_form.tcl, then it is not being reported.
That's something to work with, I guess.
Last edit: Clark Dunson 2021-05-23
I have the same issue on two systems: a Thinkpad X220 with OpenBSD and a Ryzen 5 2400g system running Ubuntu 20.04. I am able to launch Archer with mged -o but if I do launch kosher Archer I get the ::hv3::formmanager error and a tcl8.6 complaint, even though I pass all tcl8.6 functionality tests on either system.
I really do think there's probably something with this hv3_form.tcl script that needs addressing. Kudos to letting me configure and compile 7.32 on OpenBSD on the first try.
I finally circled around to this again. On my Ubuntu 20.04 machine I have:
Oops, anaconda might be my problem? OK:
As I stated, I built for other Linux, in this case:
Here on Debian 10, following INSTALL.new, I got a perfect build and archer runs just fine!
Note:
For those wishing to duplicate, here is a full list of packages that I installed (many are unrelated):
Now I can proceed to learn Archer (one of my original goals).
@cbryn what is your tcl version?
Removing Anaconda fixed naught:
but I seem to remember installing something for tcl:
Let me go for vanilla 20.04
Last edit: Clark Dunson 2021-06-12
Quite the buildfest this morning, all successful! First I built the bare minimum, on a fresh Ubuntu 20.04:
And no tcl of course:
This build worked, got me mged command line.
Next, I built the full graphics build (sans qt)
This build launches both mged and archer just fine. Note that it works with TCL 8.6.10:
So, the full brl-cad build steps on a fresh Ubuntu 20.04 are:
That's it. The issue with ::hv3::formmanager did not appear here. Just for completeness, here are the breaking changes listed in TCL 8.6.9->8.6.10 release notes:
I will build qt while I am at it (next post).
Last edit: Clark Dunson 2021-06-12
(OH, qt is experimental, skip.) Now that I have brl-cad build on Ubuntu 20.04 working, I will close this ticket. Ooops, don't see how, sorry.
Last edit: Clark Dunson 2021-06-12
hi brl-caders,
I compiled BRL CAD last night on Ubuntu jammy and face the same problem. Run archer -use then ENTER, will pop up the archer window.
regards,
Jos