Revision: 78030
http://sourceforge.net/p/brlcad/code/78030
Author: starseeker
Date: 2020-12-19 19:46:38 +0000 (Sat, 19 Dec 2020)
Log Message:
-----------
Merge from trunk - r77975 through r78028
Modified Paths:
--------------
brlcad/branches/extbuild/CHANGES
brlcad/branches/extbuild/NEWS
brlcad/branches/extbuild/TODO
brlcad/branches/extbuild/bench/pixcmp.c
brlcad/branches/extbuild/doc/README.Windows
brlcad/branches/extbuild/doc/docbook/system/mann/facetize.xml
brlcad/branches/extbuild/doc/docbook/system/mann/quit.xml
brlcad/branches/extbuild/include/bu/app.h
brlcad/branches/extbuild/include/bu/exit.h
brlcad/branches/extbuild/include/ged/defines.h
brlcad/branches/extbuild/src/adrt/isst.c
brlcad/branches/extbuild/src/archer/archer.c
brlcad/branches/extbuild/src/archer/archer_launch.tcl
brlcad/branches/extbuild/src/archer/plugins/Utility/attrGroupsDisplayUtilityP.tcl
brlcad/branches/extbuild/src/archer/plugins/Utility/botUtilityP.tcl
brlcad/branches/extbuild/src/archer/plugins/Utility/lodUtilityP.tcl
brlcad/branches/extbuild/src/archer/plugins/Wizards/humanwizard.tcl
brlcad/branches/extbuild/src/archer/plugins/Wizards/tankwizard.tcl
brlcad/branches/extbuild/src/archer/plugins/Wizards/tirewizard.tcl
brlcad/branches/extbuild/src/brlman/brlman.c
brlcad/branches/extbuild/src/brlman/brlman.tcl
brlcad/branches/extbuild/src/burst/burst.cpp
brlcad/branches/extbuild/src/conv/gcv/gcv.c
brlcad/branches/extbuild/src/gtools/gsh.cpp
brlcad/branches/extbuild/src/gtools/tests/CMakeLists.txt
brlcad/branches/extbuild/src/libanalyze/tests/nhit.cpp
brlcad/branches/extbuild/src/libbg/spsr/SPSR.cpp
brlcad/branches/extbuild/src/libbn/tests/CMakeLists.txt
brlcad/branches/extbuild/src/libbn/tests/plot3.c
brlcad/branches/extbuild/src/libbu/backtrace.c
brlcad/branches/extbuild/src/libbu/brlcad_path.c
brlcad/branches/extbuild/src/libbu/crashreport.c
brlcad/branches/extbuild/src/libbu/dir.c
brlcad/branches/extbuild/src/libbu/tests/progname.c
brlcad/branches/extbuild/src/libbu/vfont.c
brlcad/branches/extbuild/src/libbu/whereami.h
brlcad/branches/extbuild/src/libdm/dm_init.cpp
brlcad/branches/extbuild/src/libdm/osgl/dm-osgl.cpp
brlcad/branches/extbuild/src/libdm/osgl/if_osgl.cpp
brlcad/branches/extbuild/src/libgcv/gcv.c
brlcad/branches/extbuild/src/libged/concat/concat.cpp
brlcad/branches/extbuild/src/libged/ged_init.cpp
brlcad/branches/extbuild/src/libged/ged_util.c
brlcad/branches/extbuild/src/libged/gqa/gqa.cpp
brlcad/branches/extbuild/src/libged/help/help.cpp
brlcad/branches/extbuild/src/libged/rt/rt.c
brlcad/branches/extbuild/src/libged/rtcheck/rtcheck.c
brlcad/branches/extbuild/src/libged/rtwizard/rtwizard.c
brlcad/branches/extbuild/src/libged/tests/ged_tests.g
brlcad/branches/extbuild/src/librt/gdiam/gdiam.cpp
brlcad/branches/extbuild/src/librt/primitives/primitive_util.c
brlcad/branches/extbuild/src/libtclcad/auto_path.c
brlcad/branches/extbuild/src/libtclcad/bu.c
brlcad/branches/extbuild/src/libtclcad/command_io.cpp
brlcad/branches/extbuild/src/mged/cmd.c
brlcad/branches/extbuild/src/mged/mged.c
brlcad/branches/extbuild/src/mged/plot.c
brlcad/branches/extbuild/src/mged/set.c
brlcad/branches/extbuild/src/mged/setup.c
brlcad/branches/extbuild/src/nirt/main.cpp
brlcad/branches/extbuild/src/nirt/nirt.c
brlcad/branches/extbuild/src/qged/cadimport.cpp
brlcad/branches/extbuild/src/rtwizard/main.c
brlcad/branches/extbuild/src/tclscripts/archer/Archer.tcl
brlcad/branches/extbuild/src/tclscripts/archer/ArcherCore.tcl
brlcad/branches/extbuild/src/tclscripts/archer/ShaderEdit.tcl
brlcad/branches/extbuild/src/tclscripts/geometree/GeometryBrowser.tcl
brlcad/branches/extbuild/src/tclscripts/igraph/GraphEditor.tcl
brlcad/branches/extbuild/src/tclscripts/lib/Ged.tcl
brlcad/branches/extbuild/src/tclscripts/lib/GeometryIO.tcl
brlcad/branches/extbuild/src/tclscripts/lib/RtImage.tcl
brlcad/branches/extbuild/src/tclscripts/lib/gui_conversion.tcl
brlcad/branches/extbuild/src/tclscripts/man_browser.tcl
brlcad/branches/extbuild/src/tclscripts/mged/asc2g.tcl
brlcad/branches/extbuild/src/tclscripts/mged/dbupgrade.tcl
brlcad/branches/extbuild/src/tclscripts/mged/g2asc.tcl
brlcad/branches/extbuild/src/tclscripts/mged/help.tcl
brlcad/branches/extbuild/src/tclscripts/mged/man.tcl
brlcad/branches/extbuild/src/tclscripts/mged/mged.tcl
brlcad/branches/extbuild/src/tclscripts/mged/mike.tcl
brlcad/branches/extbuild/src/tclscripts/mged/mview.tcl
brlcad/branches/extbuild/src/tclscripts/mged/openw.tcl
brlcad/branches/extbuild/src/tclscripts/mged/points.tcl
brlcad/branches/extbuild/src/tclscripts/mged/rt.tcl
brlcad/branches/extbuild/src/tclscripts/mged/shaders.tcl
brlcad/branches/extbuild/src/tclscripts/rtwizard/lib/FbPage.itk
brlcad/branches/extbuild/src/tclscripts/rtwizard/lib/PictureTypeA.itcl
brlcad/branches/extbuild/src/tclscripts/rtwizard/lib/PictureTypeB.itcl
brlcad/branches/extbuild/src/tclscripts/rtwizard/lib/PictureTypeC.itcl
brlcad/branches/extbuild/src/tclscripts/rtwizard/lib/PictureTypeD.itcl
brlcad/branches/extbuild/src/tclscripts/rtwizard/lib/PictureTypeE.itcl
brlcad/branches/extbuild/src/tclscripts/rtwizard/lib/PictureTypeF.itcl
brlcad/branches/extbuild/src/tclscripts/rtwizard/rtwizard
brlcad/branches/extbuild/src/util/morphedit.tcl
brlcad/branches/extbuild/src/util/plot3-dm.c
Property Changed:
----------------
brlcad/branches/extbuild/
brlcad/branches/extbuild/CHANGES
brlcad/branches/extbuild/NEWS
brlcad/branches/extbuild/bench/
brlcad/branches/extbuild/doc/
brlcad/branches/extbuild/include/
brlcad/branches/extbuild/src/libbu/
brlcad/branches/extbuild/src/other/
brlcad/branches/extbuild/src/tclscripts/archer/
Index: brlcad/branches/extbuild
===================================================================
--- brlcad/branches/extbuild 2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild 2020-12-19 19:46:38 UTC (rev 78030)
Property changes on: brlcad/branches/extbuild
___________________________________________________________________
Modified: svn:mergeinfo
## -11,4 +11,4 ##
/brlcad/branches/osg:62110-62113
/brlcad/branches/prep-cache:68236-68933
/brlcad/branches/tcltk86:68300-75257
-/brlcad/trunk:77547-77974
\ No newline at end of property
+/brlcad/trunk:77547-78028
\ No newline at end of property
Modified: brlcad/branches/extbuild/CHANGES
===================================================================
--- brlcad/branches/extbuild/CHANGES 2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/CHANGES 2020-12-19 19:46:38 UTC (rev 78030)
@@ -129,6 +129,10 @@
7.32
----
+include/bu/app.h
+ bu_brlcad_root: replaced by bu_dir
+ bu_brlcad_dir: replaced by bu_dir
+
include/bg/chull.h
All functions returning point arrays instead of index arrays.
Will be replaced by similarly named functions returning
@@ -137,6 +141,13 @@
bg_polyline_2d_chull, bg_2d_chull, bg_3d_coplanar_chull,
bg_3d_chull
+include/bu/exit.h
+ bu_backtrace and bu_crashreport will be replaced with versions
+ that take an optional parameter to pass in a full path from
+ the calling application. (Currently available as
+ bu_backtrace_app and bu_crashreport_app, these will
+ replace existing versions after deprecation is complete.)
+
MGED gui
The following will be removed from MGED's menu bar (unused
features, can be accomplished another way, or will be exposed
Property changes on: brlcad/branches/extbuild/CHANGES
___________________________________________________________________
Modified: svn:mergeinfo
## -1,3 +1,4 ##
/brlcad/branches/RELEASE/CHANGES:70323-70333,71915-72242,72525-72534,72826-72858,74376-74454,74964-75140
/brlcad/branches/brep-debug/CHANGES:69168,69927,69995-69996,70148-70149,70347-70349,70377,70526-70527,71006-71007,71009-71022,71046-71047,71049,71096-71100
-/brlcad/branches/dm-fb-merge/CHANGES:75426-76198
\ No newline at end of property
+/brlcad/branches/dm-fb-merge/CHANGES:75426-76198
+/brlcad/trunk/CHANGES:77975-78028
\ No newline at end of property
Modified: brlcad/branches/extbuild/NEWS
===================================================================
--- brlcad/branches/extbuild/NEWS 2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/NEWS 2020-12-19 19:46:38 UTC (rev 78030)
@@ -13,6 +13,14 @@
--- 2020-xx-xx Release 7.32.2 ---
----------------------------------------------------------------------
+* fixed reporting of MGED "vars" command - Cliff Yapp
+* updated MGED to not open non-.g-files as databases - Cliff Yapp
+* fixed problems with command I/O management in MGED - Cliff Yapp
+* added decimation control examples to facetize man page - Cliff Yapp
+* changed gcv converter to append to existing .g files - Cliff Yapp
+* added a '-f' forcing option to MGED's quit command - Cliff Yapp
+* changed MGED's quit command to wait for subprocesses - Cliff Yapp
+* removed obscure MGED menu entries for unused features - Cliff Yapp
* fixed crash when trying to shade invalid breps - Cliff Yapp
* changed 'mvall' to rename all refs even w/ no object - Sean Morrison
* fixed MGED search command crash on empty database - Sean Morrison
Property changes on: brlcad/branches/extbuild/NEWS
___________________________________________________________________
Modified: svn:mergeinfo
## -9,4 +9,4 ##
/brlcad/branches/osg/NEWS:62110-62113
/brlcad/branches/prep-cache/NEWS:68236-68933
/brlcad/branches/tcltk86/NEWS:68300-75257
-/brlcad/trunk/NEWS:77547-77657,77660-77689,77700-77770,77946-77956
\ No newline at end of property
+/brlcad/trunk/NEWS:77547-77657,77660-77689,77700-77770,77946-77956,77975-78028
\ No newline at end of property
Modified: brlcad/branches/extbuild/TODO
===================================================================
--- brlcad/branches/extbuild/TODO 2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/TODO 2020-12-19 19:46:38 UTC (rev 78030)
@@ -18,14 +18,13 @@
THESE TASKS SHOULD HAPPEN BEFORE THE NEXT RELEASE
-------------------------------------------------
-* bounding box reduction command
+* check thread safety history of gqa + plot calls (pl_color)
+ UPDATE - breakage was identified as having been introduced
+ during the libbu semaphore system update circa commit r73078
-* MGED asynchronous subprocess management appears to be broken with
- both mged -c and gui mode on Mac. MGED is blocking when running
- "rt" command until after the framebuffer window is closed.
-* Update libgcv plugin installation location - now that its
- available, they belong with the other plugins in libexec
+THESE TASKS SHOULD HAPPEN WITHIN TWO RELEASE ITERATIONS
+-------------------------------------------------------
* The following will be removed from MGED's menu bar (unused
features, can be accomplished another way, or will be exposed
@@ -32,48 +31,15 @@
only as lower level settings when there are sensible defaults
that are seldom changed.)
- ViewRing menu and entries.
- Modes->Persistent Sweep Rectangle
- Modes->Collaborate
- Modes->Rateknobs
Modes->Display Lists
Misc->Keystroke Forwarding
Misc->Depth Cueing
Misc->Z Buffer
Misc->Lighting
- Settings->Mouse Behavior->Sweep Raytrace-Rectangle
- Settings->Mouse Behavior->Sweep Paint-Rectangle
- Settings->Mouse Behavior->Sweep Zoom-Rectangle
- Settings->Apply To->Local Panes
- Settings->Apply To->Listed Panes
- Settings->Framebuffer->Rectangle Area
-* The embedded framebuffer for the X display manager is not working
- with Tcl/Tk 8.6 - it brings down mged with an Xerror when it tries
- to XFlush after X24_blit. Better solution is to replace the X
- dm/fb with a cross platform software rasterizing solution of some
- sort.
-
-* Implement new behavior for quit command in MGED - if bu_subprocess
- commands are running, by default refuse to quit and print out a
- list of currently running processes and instructions on how to abort
- them. Implement a -f option to forcibly quite even if there are
- subprocesses running, and (perhaps) a --wait option to quite after
- all subprocesses complete.
-
- Also of interest in this context (but not critical for the basic
- functionality) is designing a general mechanism or protocol for
- applications to communicate progress back to bu_subprocess.
-
* implement uv-mapping callback so we can texture-map BoT, NMG, and
NURBS geometry
-* check thread safety history of gqa + plot calls (pl_color)
-
-* mged> nirt -? needs to provide help
-
-* mged> nirt -f fmt doesn't seem to work at all
-
* modify libfb's default memory buffer allocation to be dynamic
* create a BRL-CAD .g with all possible object types embedded.
@@ -85,48 +51,6 @@
* attribute normalization is drastically slowing down
region creation - need to fix or back out
-* g-obj not exporting colors
-
-* finish testing of libbu bu_dir API and matching bu_dir TCL function.
- bu_dir bin and lib don't work when the MGED prompt's working directory
- is changed to (e.g.) the user's home directory.
- bu_brlcad_root and bu_brlcad_data will need verbose deprecation process.
-
-* Need to eliminate bu_argv0_full_path and rework the bu_brlcad_*
- functions that currently rely on it to take that path as a
- parameter from the calling application. The library shouldn't be
- responsible for managing that path - there are too many issues
- with doing so. The current approach fixes some concerns but
- breaks if an application changes its notion of the current working
- directory after initialization, for example.
-
-* tree command shouldn't infinite loop when encountering a cyclic
- path - need to print a warning and stop walking. Requries full
- path awareness in tree command walk.
-
- Consider implementing a corollary to FTS instead of dirent for
- simplified tree traversal with cyclic awareness.
-
-
https://keramida.wordpress.com/2009/07/05/fts3-or-avoiding-to-reinvent-the-wheel/
-
-* move the rt_*_timer timing facilities to libbu and rework to allow
- contexts, allowing for more than one timer to be active. Make sure
- the old librt API can be obsoleted cleanly.
-
-* check that dbconcat supports objects created with the bo cmd
-
-* libgcv should add objects to an existing .g if one is specified
- as the output target - right now it's overwriting the old file
-
-* consolidate dbconcat, clone, make_name, and any other .g I/O
- routines that need to autogenerate names to use the new
- bu_vls_incr/bu_vls_simplify functions.
-
-* f_dbopen in MGED doesn't seem to be reporting failure
- if a non-.g file is fed to opendb. That doesn't seem
- right... shouldn't the open process completely fail
- if the file isn't a valid .g?
-
* add regression test for directional light sources
* bundle primary rays in rt front end into postage stamps, shoot via
@@ -157,18 +81,48 @@
* make sure we can run db_dirbuild() multiple times without creating
duplicate entries.
+* tree command shouldn't infinite loop when encountering a cyclic
+ path - need to print a warning and stop walking. Requries full
+ path awareness in tree command walk.
+
+ Consider implementing a corollary to FTS instead of dirent for
+ simplified tree traversal with cyclic awareness.
+
+
https://keramida.wordpress.com/2009/07/05/fts3-or-avoiding-to-reinvent-the-wheel/
+
+* bounding box reduction command
+
+* consolidate dbconcat, clone, make_name, and any other .g I/O
+ routines that need to autogenerate names to use the new
+ bu_vls_incr/bu_vls_simplify functions.
+
+* g-obj not exporting colors
+
* heap unit test needs to actually compare performance against system
allocation, not just do some work
+* mged> nirt -? needs to provide help
-THESE TASKS SHOULD HAPPEN WITHIN TWO RELEASE ITERATIONS
--------------------------------------------------------
+* mged> nirt -f fmt doesn't seem to work at all
+* move the rt_*_timer timing facilities to libbu and rework to allow
+ contexts, allowing for more than one timer to be active. Make sure
+ the old librt API can be obsoleted cleanly.
+* investigate problems with struct parsing running the MGED
+ "vars" command - most visible on OpenBSD, but Linux valgrind can
+ also see issues.
+
THESE ARE UNSCHEDULED BACKLOG TASKS
-----------------------------------
+* The embedded framebuffer for the X display manager is not working
+ with Tcl/Tk 8.6 - it brings down mged with an Xerror when it tries
+ to XFlush after X24_blit. Better solution is to replace the X
+ dm/fb with a cross platform software rasterizing solution of some
+ sort.
+
* extract a skin or other exterior surface for a given model. 3 options:
1. Implement a "shrinkwrap" feature that calculates a concave hull
2. Shoot rays from outside, construct exterior mesh based on hits
Index: brlcad/branches/extbuild/bench
===================================================================
--- brlcad/branches/extbuild/bench 2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/bench 2020-12-19 19:46:38 UTC (rev 78030)
Property changes on: brlcad/branches/extbuild/bench
___________________________________________________________________
Modified: svn:mergeinfo
## -8,4 +8,4 ##
/brlcad/branches/osg/bench:62110-62113
/brlcad/branches/prep-cache/bench:68236-68933
/brlcad/branches/tcltk86/bench:68300-75257
-/brlcad/trunk/bench:77700-77770
\ No newline at end of property
+/brlcad/trunk/bench:77700-77770,77975-78028
\ No newline at end of property
Modified: brlcad/branches/extbuild/bench/pixcmp.c
===================================================================
--- brlcad/branches/extbuild/bench/pixcmp.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/bench/pixcmp.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -201,8 +201,8 @@
FILE *f1 = NULL;
FILE *f2 = NULL;
- struct stat sf1 = {0};
- struct stat sf2 = {0};
+ struct stat sf1;
+ struct stat sf2;
size_t matching = 0;
size_t off1 = 0;
Index: brlcad/branches/extbuild/doc
===================================================================
--- brlcad/branches/extbuild/doc 2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/doc 2020-12-19 19:46:38 UTC (rev 78030)
Property changes on: brlcad/branches/extbuild/doc
___________________________________________________________________
Modified: svn:mergeinfo
## -9,4 +9,4 ##
/brlcad/branches/osg/doc:62110-62113
/brlcad/branches/prep-cache/doc:68236-68933
/brlcad/branches/tcltk86/doc:68300-75257
-/brlcad/trunk/doc:77547-77659,77784-77829
\ No newline at end of property
+/brlcad/trunk/doc:77547-77659,77784-77829,77975-78028
\ No newline at end of property
Modified: brlcad/branches/extbuild/doc/README.Windows
===================================================================
--- brlcad/branches/extbuild/doc/README.Windows 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/doc/README.Windows 2020-12-19 19:46:38 UTC (rev
78030)
@@ -90,14 +90,40 @@
=== Tracking down the source of a header inclusion ===
-If a Windows system header is reporting an error, it can be helpful to
-identify where the header is being included from. By default MSVC
-doesn't report this, but in Visual Studio there is a "ShowIncludes"
-setting that may be enabled to find this information:
+If a Windows system header is reporting an error, it can be helpful to identify
+where the header is being included from. By default MSVC doesn't report this,
+but in Visual Studio there is a "ShowIncludes" setting that may be enabled to
+find this information:
https://stackoverflow.com/a/1138045
+This setting may also be added to the compilation flags directly
+in CMake as "/showIncludes":
+https://docs.microsoft.com/en-us/cpp/build/reference/showincludes-list-include-files
+
+Note that the output of this can be very verbose, especially if applied
+globally to all targets - you may want to consider applying it specifically to
+an individual target with target_compile_options. This flag is a very useful
+tool when trying to determine *why* a particular header is present in an error
+message.
+
+=========================================================
+
+=== Debugging build outputs from a Ninja compilation ===
+
+Normally, Visual Studio is used to debug Windows executables. However,
+another alternative is available called WinDbg:
+
+https://docs.microsoft.com/en-us/windows-hardware/drivers/debugger/debugger-download-tools
+
+This has been used successfully to debug Ninja produced executables.
+Note that if debugging an issue unique to Release builds, you will
+want to set the CMake variable ENABLE_ALL_CONFIG_TYPES to ON
+and the specific build type to RelWithDebInfo
+
+cmake.exe -G Ninja -ENABLE_ALL_CONFIG_TYPES=ON
-DCMAKE_BUILD_TYPE=RelWithDebInfo
+
===========================================
=== Notes on Visual Studio 14 2015 ===
Modified: brlcad/branches/extbuild/doc/docbook/system/mann/facetize.xml
===================================================================
--- brlcad/branches/extbuild/doc/docbook/system/mann/facetize.xml
2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/doc/docbook/system/mann/facetize.xml
2020-12-19 19:46:38 UTC (rev 78030)
@@ -148,6 +148,41 @@
</para>
</example>
+
+ <example>
+ <title>Increase Decimation in CM Mode</title>
+ <para>
+ <prompt>mged> </prompt><userinput>facetize --CM --feature-size 0.06
--decimation-feature-size 2.0 ellipse.r ell.bot</userinput>
+ <literallayout class="normal">
+CM: completed in 16 seconds with size 0.06
+CM: completed in 23 seconds with size 0.054
+CM: timed out after 30 seconds with size 0.0486
+CM: successfully created 6960500 faces, feature size 0.054
+CM: decimation succeeded, final BoT has 104 faces
+ </literallayout>
+ </para>
+ <para>
+ The default settings on this object in CM mode will produce a little
over 8000 faces in the final bot, but the addition of the
<option>decimation-feature-size</option> option with a >1.5 value has
dramatically reduced the count to 104.
+ </para>
+ </example>
+
+ <example>
+ <title>Decrease Decimation in CM Mode</title>
+ <para>
+ <prompt>mged> </prompt><userinput>facetize --CM --feature-size 0.06
--decimation-feature-size .01 ellipse.r ell.bot</userinput>
+ <literallayout class="normal">
+CM: completed in 16 seconds with size 0.06
+CM: completed in 23 seconds with size 0.054
+CM: timed out after 30 seconds with size 0.0486
+CM: successfully created 6960500 faces, feature size 0.054
+CM: decimation succeeded, final BoT has 247642 faces
+ </literallayout>
+ </para>
+ <para>
+ If the intent is preserve a more detailed mesh, reducing
<option>decimation-feature-size</option> will keep more of the original
triangles - in the above example, almost 250 thousand of the original 6.9
million faces were retained. NOTE: use lower values here cautiously, as
extremely large meshes can be very difficult for many tools to deal with.
+ </para>
+ </example>
+
</refsection>
<refsection xml:id="methodology">
@@ -193,7 +228,10 @@
process its initial mesh with a decimation routine to remove triangles
which are not necessary to actual
feature representation. This process is also feature-size based, and by
default is set to 1.5x the feature size.
However, if the user wishes to preserve more triangles than the default
behavior they may manually
- override this parameter with the
<emphasis>--decimation-feature-size</emphasis> option.
+ override this parameter with the
<emphasis>--decimation-feature-size</emphasis> option. Generally
+ speaking smaller values will lead to more meshes being retained in the
final output mesh, but experimentation
+ will likely be needed to zero in on desired results. See CM examples
above for an illustration using
+ the moss.g ellipsoid region.
</para>
<para>
Both NMG and CM assume a geometry hierarchy containing only
@@ -215,6 +253,9 @@
</para>
</refsection>
+
+
+
<refsection xml:id="util">
<title>USEFUL TRICKS</title>
<para>
Modified: brlcad/branches/extbuild/doc/docbook/system/mann/quit.xml
===================================================================
--- brlcad/branches/extbuild/doc/docbook/system/mann/quit.xml 2020-12-19
19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/doc/docbook/system/mann/quit.xml 2020-12-19
19:46:38 UTC (rev 78030)
@@ -22,12 +22,22 @@
<refsection xml:id="description"><title>DESCRIPTION</title>
- <para>Ends the MGED process. Note that there is no write database
- command in MGED. All changes are made to the database as the user
performs
- them. Therefore, a <command>quit</command> command will not restore the
database to its pre-edited state.
- This is a synonym for the <command>q</command> command.
+<para>
+ Ends the MGED process. Note that there is no write database
+ command in MGED. All changes are made to the database as the
+ user performs them. Therefore, a <command>quit</command>
+ command will not restore the database to its pre-edited
+ state. This is a synonym for the <command>q</command>
+ command.
+</para>
- </para>
+<para>
+ By default, the quit command will not exit if there are
+ active subprocess commands running. To exit regardless
+ of those commands, add the <option>f</option> option to
+ force quitting.
+</para>
+
</refsection>
<refsection xml:id="examples"><title>EXAMPLES</title>
Index: brlcad/branches/extbuild/include
===================================================================
--- brlcad/branches/extbuild/include 2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/include 2020-12-19 19:46:38 UTC (rev 78030)
Property changes on: brlcad/branches/extbuild/include
___________________________________________________________________
Modified: svn:mergeinfo
## -10,4 +10,4 ##
/brlcad/branches/osg/include:62110-62113
/brlcad/branches/prep-cache/include:68236-68933
/brlcad/branches/tcltk86/include:68300-75257
-/brlcad/trunk/include:77660-77699,77784-77829,77838-77865,77934-77945
\ No newline at end of property
+/brlcad/trunk/include:77660-77699,77784-77829,77838-77865,77934-77945,77975-78028
\ No newline at end of property
Modified: brlcad/branches/extbuild/include/bu/app.h
===================================================================
--- brlcad/branches/extbuild/include/bu/app.h 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/include/bu/app.h 2020-12-19 19:46:38 UTC (rev
78030)
@@ -51,7 +51,7 @@
* identified but should never return NULL. this routine is not
* thread-safe.
*/
-BU_EXPORT extern const char *bu_argv0_full_path(void);
+DEPRECATED BU_EXPORT extern const char *bu_argv0_full_path(void);
/**
* Routine for obtaining the current working directory.
@@ -204,7 +204,7 @@
* call bu_strdup() or make other provisions to save the returned
* string, before calling again.
*/
-BU_EXPORT extern const char *bu_brlcad_dir(const char *dirkey, int
fail_quietly);
+DEPRECATED BU_EXPORT extern const char *bu_brlcad_dir(const char *dirkey, int
fail_quietly);
/**
* @brief
@@ -224,7 +224,7 @@
* call bu_strdup() or make other provisions to save the returned
* string, before calling again.
*/
-BU_EXPORT extern const char *bu_brlcad_root(const char *rhs, int fail_quietly);
+DEPRECATED BU_EXPORT extern const char *bu_brlcad_root(const char *rhs, int
fail_quietly);
typedef enum {
Modified: brlcad/branches/extbuild/include/bu/exit.h
===================================================================
--- brlcad/branches/extbuild/include/bu/exit.h 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/include/bu/exit.h 2020-12-19 19:46:38 UTC (rev
78030)
@@ -51,6 +51,15 @@
*/
BU_EXPORT extern int bu_backtrace(FILE *fp);
+/**
+ * A version of bu_backtrace where the caller provides their own
+ * full path to their executable for passing to GDB, rather than
+ * having libbu attempt to determine that path.
+ *
+ * Passing NULL to argv0 makes the behavior identical to
+ * that of bu_backtrace.
+ */
+BU_EXPORT extern int bu_backtrace_app(FILE *fp, const char *argv0);
/**
* Adds a hook to the list of bu_bomb hooks. The top (newest) one of these
@@ -138,6 +147,17 @@
*/
BU_EXPORT extern int bu_crashreport(const char *filename);
+/**
+ * A version of bu_crashreport where the caller provides their own
+ * full path to their executable for passing to GDB, rather than
+ * having libbu attempt to determine that path.
+ *
+ * Passing NULL to argv0 makes the behavior identical to
+ * that of bu_crashreport.
+ */
+BU_EXPORT extern int bu_crashreport_app(const char *filename, const char
*argv0);
+
+
/** @} */
__END_DECLS
Modified: brlcad/branches/extbuild/include/ged/defines.h
===================================================================
--- brlcad/branches/extbuild/include/ged/defines.h 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/include/ged/defines.h 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -129,6 +129,9 @@
void *chan;
int aborted;
struct ged *gedp;
+ int stdin_active;
+ int stdout_active;
+ int stderr_active;
};
/* FIXME: should be private */
Modified: brlcad/branches/extbuild/src/adrt/isst.c
===================================================================
--- brlcad/branches/extbuild/src/adrt/isst.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/adrt/isst.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -653,8 +653,8 @@
argv++; argc--;
tclcad_set_argv(interp, argc, argv);
- isst_tcl = bu_brlcad_root("share/tclscripts/isst/isst.tcl", 1);
Tcl_DStringInit(&temp);
+ isst_tcl = bu_dir(NULL, 0, BU_DIR_DATA, "tclscripts", "isst", "isst.tcl",
NULL);
fullname = Tcl_TranslateFileName(interp, isst_tcl, &temp);
status = Tcl_EvalFile(interp, fullname);
Tcl_DStringFree(&temp);
Modified: brlcad/branches/extbuild/src/archer/archer.c
===================================================================
--- brlcad/branches/extbuild/src/archer/archer.c 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/archer/archer.c 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -95,7 +95,7 @@
}
bu_vls_free(&tlog);
- archer_tcl = bu_brlcad_root("share/tclscripts/archer/archer_launch.tcl",
1);
+ archer_tcl = bu_dir(NULL, 0, BU_DIR_DATA, "tclscripts", "archer",
"archer_launch.tcl", NULL);
Tcl_DStringInit(&temp);
fullname = Tcl_TranslateFileName(interp, archer_tcl, &temp);
status = Tcl_EvalFile(interp, fullname);
Modified: brlcad/branches/extbuild/src/archer/archer_launch.tcl
===================================================================
--- brlcad/branches/extbuild/src/archer/archer_launch.tcl 2020-12-19
19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/archer/archer_launch.tcl 2020-12-19
19:46:38 UTC (rev 78030)
@@ -39,7 +39,7 @@
# already exists in the configured install path, all tcl scripts
# will be pulled from the installed location and not the local
# build location. This is an inevitable consequence of how
-# bu_brlcad_root has to work (there are security implication to
+# BRL-CAD's path lookup has to work (there are security implication to
# NOT using the installed files if they are present) but it also
# makes for a subtle and vexing problem if a developer is trying
# to tweak tcl scripts in the source tree and forgets that
@@ -48,7 +48,7 @@
# installed file will be loaded instead of the edited version.
# Warn if it looks like this situation is occurring by checking
# the root path against the argv0 path.
-set check_root_dir [file normalize [bu_brlcad_root [bu_brlcad_dir bin]]]
+set check_root_dir [file normalize [bu_dir bin]]
set check_bin_dir [file dirname [file normalize $argv0]]
# Because there are conditions where we don't know our argv0 full path
@@ -57,20 +57,12 @@
if {[file exists [file normalize $argv0]]} {
set dir_same [string compare $check_root_dir $check_bin_dir]
if {!$dir_same == 0} {
- puts "WARNING - bu_brlcad_root is set to [file dirname
$check_root_dir], but binary being run is located in [file dirname
$check_bin_dir]. This probably means you are running [file tail $argv0] from a
non-install directory with BRL-CAD already present in [file dirname
$check_root_dir] - be aware that .tcl files from [file dirname $check_root_dir]
will be loaded INSTEAD OF local files. Tcl script changes made to source files
for testing purposes will not be loaded, even though [file tail $argv0] will
most likely 'work'. To test local changes, either clear [file dirname
$check_root_dir], specify a different install prefix (i.e. a directory
*without* BRL-CAD installed) while building, or manually set the BRLCAD_ROOT
environment variable."
+ puts "WARNING - bu_dir's bin value is set to [file dirname
$check_root_dir], but binary being run is located in [file dirname
$check_bin_dir]. This probably means you are running [file tail $argv0] from a
non-install directory with BRL-CAD already present in [file dirname
$check_root_dir] - be aware that .tcl files from [file dirname $check_root_dir]
will be loaded INSTEAD OF local files. Tcl script changes made to source files
for testing purposes will not be loaded, even though [file tail $argv0] will
most likely 'work'. To test local changes, either clear [file dirname
$check_root_dir], specify a different install prefix (i.e. a directory
*without* BRL-CAD installed) while building, or manually set the BRLCAD_ROOT
environment variable."
}
}
# Itk's default class doesn't keep the menu, but Archer needs it - redefine
itk:Toplevel
-set itk_file [file join [bu_brlcad_root "share/tclscripts"] archer
itk_redefines.tcl]
-if { ![file exists $itk_file] } {
- #try src tree
- set itk_file [file join [bu_brlcad_root "src"] tclscripts archer
itk_redefines.tcl]
- if { ![file exists $itk_file] } {
- #try local relative
- set itk_file [file join src tclscripts archer itk_redefines.tcl]
- }
-}
+set itk_file [file join [bu_dir data] "tclscripts" archer itk_redefines.tcl]
source $itk_file
# Set ttk theme
@@ -150,16 +142,7 @@
set useImage 1
if {$useImage} {
- # try installed, uninstalled
- set imgfile [file join [bu_brlcad_root "share/tclscripts"] archer
images aboutArcher.png]
- if { ![file exists $imgfile] } {
- # try src tree
- set imgfile [file join [bu_brlcad_root "src"] archer images
aboutArcher.png]
- if { [!file exists $imgfile] } {
- # try local relative
- set imgfile [file join tclscripts archer images aboutArcher.png]
- }
- }
+ set imgfile [file join [bu_dir data] tclscripts archer images
aboutArcher.png]
set image [image create photo -file $imgfile]
set ::ArcherCore::splash [Splash .splash -image $image]
} else {
@@ -241,7 +224,7 @@
wm title $::ArcherCore::application "Archer $brlcad_version"
if {$tcl_platform(os) == "Windows NT"} {
wm iconbitmap $::ArcherCore::application -default \
- [file join [bu_brlcad_root "share/icons"] archer.ico]
+ [file join [bu_dir data] icons archer.ico]
}
set size [wm maxsize $::ArcherCore::application]
set w [lindex $size 0]
@@ -260,7 +243,7 @@
wm title . "Archer $brlcad_version"
if {$tcl_platform(os) == "Windows NT"} {
wm iconbitmap . -default \
- [file join [bu_brlcad_root "share/html"] manuals archer
archer.ico]
+ [file join [bu_dir data] html manuals archer archer.ico]
}
set ::ArcherCore::application [Archer .\#auto]
set size [wm maxsize .]
Modified:
brlcad/branches/extbuild/src/archer/plugins/Utility/attrGroupsDisplayUtilityP.tcl
===================================================================
---
brlcad/branches/extbuild/src/archer/plugins/Utility/attrGroupsDisplayUtilityP.tcl
2020-12-19 19:40:31 UTC (rev 78029)
+++
brlcad/branches/extbuild/src/archer/plugins/Utility/attrGroupsDisplayUtilityP.tcl
2020-12-19 19:46:38 UTC (rev 78030)
@@ -23,15 +23,9 @@
# This is a script for loading/registering the attribute groups display
utility.
#
-set brlcadDataPath [bu_brlcad_root "share/plugins"]
-# puts "pwd is [pwd], path is $brlcadDataPath"
+set brlcadDataPath [file join [bu_dir data] plugins]
set filename [file join $brlcadDataPath archer Utility
attrGroupsDisplayUtilityP AttrGroupsDisplayUtilityP.tcl]
if { ![file exists $filename] } {
- # non-tclscript resource, look in the source invocation path
- set brlcadDataPath [bu_brlcad_root "src"]
- set filename [file join $brlcadDataPath archer plugins Utility
attrGroupsDisplayUtilityP AttrGroupsDisplayUtilityP.tcl]
-}
-if { ![file exists $filename] } {
puts "Could not load the AttrGroupsDisplayUtilityP plugin, skipping
$filename"
return
}
Modified: brlcad/branches/extbuild/src/archer/plugins/Utility/botUtilityP.tcl
===================================================================
--- brlcad/branches/extbuild/src/archer/plugins/Utility/botUtilityP.tcl
2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/archer/plugins/Utility/botUtilityP.tcl
2020-12-19 19:46:38 UTC (rev 78030)
@@ -23,12 +23,8 @@
# This is a script for loading/registering the bot editor utility.
#
-set filename [file join [bu_brlcad_root "share/plugins"] archer Utility
botUtilityP BotUtilityP.tcl]
+set filename [file join [bu_dir data] plugins archer Utility botUtilityP
BotUtilityP.tcl]
if { ![file exists $filename] } {
- # non-tclscript resource, look in the source invocation path
- set filename [file join [bu_brlcad_root "src"] archer plugins Utility
botUtilityP BotUtilityP.tcl]
-}
-if { ![file exists $filename] } {
puts "Could not load the BotUtilityP plugin, skipping $filename"
return
}
Modified: brlcad/branches/extbuild/src/archer/plugins/Utility/lodUtilityP.tcl
===================================================================
--- brlcad/branches/extbuild/src/archer/plugins/Utility/lodUtilityP.tcl
2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/archer/plugins/Utility/lodUtilityP.tcl
2020-12-19 19:46:38 UTC (rev 78030)
@@ -24,12 +24,8 @@
# configuration utility.
#
-set filename [file join [bu_brlcad_root "share/plugins"] archer Utility
lodUtilityP LODUtilityP.tcl]
+set filename [file join [bu_dir data] plugins archer Utility lodUtilityP
LODUtilityP.tcl]
if { ![file exists $filename] } {
- # non-tclscript resource, look in the source invocation path
- set filename [file join [bu_brlcad_root "src"] archer plugins Utility
lodUtilityP LODUtilityP.tcl]
-}
-if { ![file exists $filename] } {
puts "Could not load the LODUtilityP plugin, skipping $filename"
return
}
Modified: brlcad/branches/extbuild/src/archer/plugins/Wizards/humanwizard.tcl
===================================================================
--- brlcad/branches/extbuild/src/archer/plugins/Wizards/humanwizard.tcl
2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/archer/plugins/Wizards/humanwizard.tcl
2020-12-19 19:46:38 UTC (rev 78030)
@@ -23,15 +23,10 @@
# This is a script for loading/registering the human wizard.
#
-set brlcadDataPath [bu_brlcad_root "share/plugins"]
+set brlcadDataPath [file join [bu_dir data] plugins]
# puts "pwd is [pwd], path is $brlcadDataPath"
set filename [file join $brlcadDataPath archer Wizards humanwizard
HumanWizard.tcl]
if { ![file exists $filename] } {
- # non-tclscript resource, look in the source invocation path
- set brlcadDataPath [bu_brlcad_root "src"]
- set filename [file join $brlcadDataPath archer plugins Wizards humanwizard
HumanWizard.tcl]
-}
-if { ![file exists $filename] } {
puts "Could not load the HumanWizard plugin, skipping $filename"
return
}
Modified: brlcad/branches/extbuild/src/archer/plugins/Wizards/tankwizard.tcl
===================================================================
--- brlcad/branches/extbuild/src/archer/plugins/Wizards/tankwizard.tcl
2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/archer/plugins/Wizards/tankwizard.tcl
2020-12-19 19:46:38 UTC (rev 78030)
@@ -26,15 +26,10 @@
# This is a script for loading/registering the tank wizard.
#
-set brlcadDataPath [bu_brlcad_root "share/plugins"]
+set brlcadDataPath [file join [bu_dir data] plugins]
# puts "pwd is [pwd], path is $brlcadDataPath"
set filename [file join $brlcadDataPath archer Wizards tankwizard
TankWizard.tcl]
if { ![file exists $filename] } {
- # non-tclscript resource, look in the source invocation path
- set brlcadDataPath [bu_brlcad_root "src"]
- set filename [file join $brlcadDataPath archer plugins Wizards tankwizard
TankWizard.tcl]
-}
-if { ![file exists $filename] } {
puts "Could not load the TankWizard plugin, skipping $filename"
return
}
Modified: brlcad/branches/extbuild/src/archer/plugins/Wizards/tirewizard.tcl
===================================================================
--- brlcad/branches/extbuild/src/archer/plugins/Wizards/tirewizard.tcl
2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/archer/plugins/Wizards/tirewizard.tcl
2020-12-19 19:46:38 UTC (rev 78030)
@@ -23,15 +23,10 @@
# This is a script for loading/registering the tire wizard.
#
-set brlcadDataPath [bu_brlcad_root "share/plugins"]
+set brlcadDataPath [file join [bu_dir data] plugins]
# puts "pwd is [pwd], path is $brlcadDataPath"
set filename [file join $brlcadDataPath archer Wizards tirewizard
TireWizard.tcl]
if { ![file exists $filename] } {
- # non-tclscript resource, look in the source invocation path
- set brlcadDataPath [bu_brlcad_root "src"]
- set filename [file join $brlcadDataPath archer plugins Wizards tirewizard
TireWizard.tcl]
-}
-if { ![file exists $filename] } {
puts "Could not load the TireWizard plugin, skipping $filename"
return
}
Modified: brlcad/branches/extbuild/src/brlman/brlman.c
===================================================================
--- brlcad/branches/extbuild/src/brlman/brlman.c 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/brlman/brlman.c 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -421,11 +421,11 @@
(void)Tcl_Eval(interp, bu_vls_addr(&tcl_cmd));
} else {
- bu_vls_sprintf(&tcl_cmd, "set ::data_dir %s/html",
bu_brlcad_dir("doc", 1));
+ bu_vls_sprintf(&tcl_cmd, "set ::data_dir %s/html", bu_dir(NULL, 0,
BU_DIR_DOC, NULL));
(void)Tcl_Eval(interp, bu_vls_addr(&tcl_cmd));
}
- brlman_tcl = bu_brlcad_root("share/tclscripts/brlman/brlman.tcl", 1);
+ brlman_tcl = bu_dir(NULL, 0, BU_DIR_DATA, "tclscripts", "brlman",
"brlman.tcl", NULL);
Tcl_DStringInit(&temp);
fullname = Tcl_TranslateFileName(interp, brlman_tcl, &temp);
status = Tcl_EvalFile(interp, fullname);
Modified: brlcad/branches/extbuild/src/brlman/brlman.tcl
===================================================================
--- brlcad/branches/extbuild/src/brlman/brlman.tcl 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/brlman/brlman.tcl 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -42,7 +42,7 @@
if {[info exists ::man_file]} {
$w select $man_file
} else {
- set intro_file [file join [bu_brlcad_root "share/$::data_dir"]
mann/Introduction.html]
+ set intro_file [file join [bu_dir doc] html mann Introduction.html]
$w loadPage $intro_file
}
Modified: brlcad/branches/extbuild/src/burst/burst.cpp
===================================================================
--- brlcad/branches/extbuild/src/burst/burst.cpp 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/burst/burst.cpp 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -1786,7 +1786,7 @@
if (argc == 0 || !argv) return -1;
- /* Let bu_brlcad_root and friends know where we are */
+ /* Let libbu know where we are */
bu_setprogname(argv[0]);
/* Initialize */
Modified: brlcad/branches/extbuild/src/conv/gcv/gcv.c
===================================================================
--- brlcad/branches/extbuild/src/conv/gcv/gcv.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/conv/gcv/gcv.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -357,9 +357,8 @@
if (bu_file_exists(argv[0], NULL)) {
if (msg) {
- bu_vls_sprintf(msg, "Error - file %s already exists!\n", argv[0]);
+ bu_vls_sprintf(msg, "Note - file %s already exists, appending
conversion output\n", argv[0]);
}
- return -1;
}
if (file_set)
Modified: brlcad/branches/extbuild/src/gtools/gsh.cpp
===================================================================
--- brlcad/branches/extbuild/src/gtools/gsh.cpp 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/gtools/gsh.cpp 2020-12-19 19:46:38 UTC (rev
78030)
@@ -57,7 +57,7 @@
if (argc == 0 || !argv) return -1;
- /* Let bu_brlcad_root and friends know where we are */
+ /* Let libbu know where we are */
bu_setprogname(argv[0]);
/* Done with program name */
Modified: brlcad/branches/extbuild/src/gtools/tests/CMakeLists.txt
===================================================================
--- brlcad/branches/extbuild/src/gtools/tests/CMakeLists.txt 2020-12-19
19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/gtools/tests/CMakeLists.txt 2020-12-19
19:46:38 UTC (rev 78030)
@@ -7,6 +7,24 @@
set_property(TEST slow-bigdb_1gb PROPERTY SKIP_RETURN_CODE 123)
set_property(TEST slow-bigdb_5gb PROPERTY SKIP_RETURN_CODE 123)
+# Test GQA's ability to write out valid plot files, both in single and
+# multithreaded modes.
+
+set(GQA_GFILE "${CMAKE_CURRENT_SOURCE_DIR}/../../libged/tests/ged_tests.g")
+
+set(GQA_PFILE "${CMAKE_CURRENT_BINARY_DIR}/ovlp_overlaps.plot3")
+BRLCAD_ADD_TEST(NAME gqa_plot COMMAND gqa -P 1 -Ao -p ovlp_ "${GQA_GFILE}"
ovlp)
+BRLCAD_ADD_TEST(NAME gqa_plot_verify COMMAND bn_plot3 -b "${GQA_PFILE}")
+set_property(TEST gqa_plot_verify PROPERTY DEPENDS gqa_plot)
+DISTCLEAN("${GQA_PFILE}")
+
+set(GQA_MULTI_PFILE "${CMAKE_CURRENT_BINARY_DIR}/ovlpmulti_overlaps.plot3")
+BRLCAD_ADD_TEST(NAME gqa_plot_multithreaded COMMAND gqa -Ao -p ovlpmulti_
"${GQA_GFILE}" ovlp)
+BRLCAD_ADD_TEST(NAME gqa_plot_verify_multithreaded COMMAND bn_plot3 -b
"${GQA_MULTI_PFILE}")
+set_property(TEST gqa_plot_verify_multithreaded PROPERTY DEPENDS
gqa_plot_multithreaded)
+DISTCLEAN("${GQA_MULTI_PFILE}")
+
+
CMAKEFILES(CMakeLists.txt)
# Local Variables:
Modified: brlcad/branches/extbuild/src/libanalyze/tests/nhit.cpp
===================================================================
--- brlcad/branches/extbuild/src/libanalyze/tests/nhit.cpp 2020-12-19
19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/libanalyze/tests/nhit.cpp 2020-12-19
19:46:38 UTC (rev 78030)
@@ -103,7 +103,7 @@
if (argc == 0 || !argv)
return -1;
- /* Let bu_brlcad_root and friends know where we are */
+ /* Let libbu know where we are */
bu_setprogname(argv[0]);
argv++; argc--;
Modified: brlcad/branches/extbuild/src/libbg/spsr/SPSR.cpp
===================================================================
--- brlcad/branches/extbuild/src/libbg/spsr/SPSR.cpp 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libbg/spsr/SPSR.cpp 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -55,9 +55,11 @@
# pragma clang diagnostic ignored "-Wunused-variable"
# pragma clang diagnostic ignored "-Wsign-compare"
# pragma clang diagnostic ignored "-Wunused-value"
-# pragma clang diagnostic ignored "-Wmisleading-indentation"
# pragma clang diagnostic ignored "-Wparentheses"
# pragma clang diagnostic ignored "-Wreturn-type"
+# if (__clang_major__ >= 10)
+# pragma clang diagnostic ignored "-Wmisleading-indentation"
+# endif
#endif
#include "SPSR.h"
Modified: brlcad/branches/extbuild/src/libbn/tests/CMakeLists.txt
===================================================================
--- brlcad/branches/extbuild/src/libbn/tests/CMakeLists.txt 2020-12-19
19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/libbn/tests/CMakeLists.txt 2020-12-19
19:46:38 UTC (rev 78030)
@@ -1143,6 +1143,14 @@
BRLCAD_ADD_TEST(NAME bn_vlist_cmd_cnt_45 COMMAND bn_test vlist 45)
BRLCAD_ADD_TEST(NAME bn_vlist_cmd_cnt_500 COMMAND bn_test vlist 500)
+#
+# *************** plot3.c ***************
+#
+# Tests to detect validity/invalidity of plot3 files
+#
+BRLCAD_ADD_TEST(NAME bn_plot3_valid COMMAND bn_plot3 -b
"${CMAKE_CURRENT_SOURCE_DIR}/valid.plot3")
+BRLCAD_ADD_TEST(NAME bn_plot3_invalid COMMAND bn_plot3 -i -b
"${CMAKE_CURRENT_SOURCE_DIR}/invalid.plot3")
+
CMAKEFILES(
CMakeLists.txt
bntester.dat
Modified: brlcad/branches/extbuild/src/libbn/tests/plot3.c
===================================================================
--- brlcad/branches/extbuild/src/libbn/tests/plot3.c 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libbn/tests/plot3.c 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -37,12 +37,14 @@
int print_help = 0;
int binary_mode = 0;
int text_mode = 0;
+ int expect_invalid = 0;
int mode = -1;
- struct bu_opt_desc d[4];
- BU_OPT(d[0], "h", "help", "", NULL, &print_help, "Print help and
exit");
- BU_OPT(d[1], "b", "binary", "", NULL, &binary_mode, "Process plot file as
binary plot data (default)");
- BU_OPT(d[2], "t", "text", "", NULL, &text_mode, "Process plot file as
text plot data");
- BU_OPT_NULL(d[3]);
+ struct bu_opt_desc d[5];
+ BU_OPT(d[0], "h", "help", "", NULL, &print_help, "Print help and
exit");
+ BU_OPT(d[1], "b", "binary", "", NULL, &binary_mode, "Process plot
file as binary plot data (default)");
+ BU_OPT(d[2], "t", "text", "", NULL, &text_mode, "Process plot
file as text plot data");
+ BU_OPT(d[3], "i", "invalid", "", NULL, &expect_invalid, "Expect to detect
an invalid file");
+ BU_OPT_NULL(d[4]);
bu_setprogname(argv[0]);
@@ -75,10 +77,19 @@
ret = plot3_invalid(fp, mode);
- if (ret) {
- bu_log("INVALID: %s\n", argv[0]);
+ if (expect_invalid) {
+ if (ret) {
+ bu_log("INVALID (expected): %s\n", argv[0]);
+ } else {
+ bu_log("VALID (unexpected): %s\n", argv[0]);
+ }
+ ret = (ret) ? 0 : 1;
} else {
- bu_log("VALID: %s\n", argv[0]);
+ if (ret) {
+ bu_log("INVALID: %s\n", argv[0]);
+ } else {
+ bu_log("VALID: %s\n", argv[0]);
+ }
}
return ret;
Index: brlcad/branches/extbuild/src/libbu
===================================================================
--- brlcad/branches/extbuild/src/libbu 2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/libbu 2020-12-19 19:46:38 UTC (rev 78030)
Property changes on: brlcad/branches/extbuild/src/libbu
___________________________________________________________________
Modified: svn:mergeinfo
## -3,4 +3,4 ##
/brlcad/branches/brep-debug/src/libbu:69168,69927,69995-69996,70148-70149,70347-70349,70377,70526-70527,71006-71007,71009-71022,71046-71047,71049,71096-71100
/brlcad/branches/dm-fb-merge/src/libbu:75426-76198
/brlcad/branches/tcltk86/src/libbu:68300-75257
-/brlcad/trunk/src/libbu:77547-77657,77690-77770,77784-77835,77838-77857
\ No newline at end of property
+/brlcad/trunk/src/libbu:77547-77657,77690-77770,77784-77835,77838-77857,77975-78028
\ No newline at end of property
Modified: brlcad/branches/extbuild/src/libbu/backtrace.c
===================================================================
--- brlcad/branches/extbuild/src/libbu/backtrace.c 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libbu/backtrace.c 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -395,7 +395,7 @@
int
-bu_backtrace(FILE *fp)
+bu_backtrace_app(FILE *fp, const char *argv0)
{
if (!fp) {
fp = stdout;
@@ -440,11 +440,17 @@
#endif
if (have_gdb) {
+ const char *gdb_path = NULL;
bu_strlcpy(debugger_args[0], path_gdb, MAXPATHLEN);
/* MUST give gdb path to binary, otherwise attach bug causes
* process kill on some platforms (e.g., FreeBSD9+AMD64)
*/
- bu_strlcpy(debugger_args[1], bu_argv0_full_path(), MAXPATHLEN);
+ if (argv0) {
+ gdb_path = argv0;
+ } else {
+ gdb_path = bu_dir(NULL, 0, BU_DIR_BIN, bu_getprogname(),
BU_DIR_EXT, NULL);
+ }
+ bu_strlcpy(debugger_args[1], gdb_path, MAXPATHLEN);
} else if (have_lldb) {
bu_strlcpy(debugger_args[0], path_lldb, MAXPATHLEN);
}
@@ -535,6 +541,11 @@
return 1;
}
+int
+bu_backtrace(FILE *fp)
+{
+ return bu_backtrace_app(fp, NULL);
+}
/*
* Local Variables:
Modified: brlcad/branches/extbuild/src/libbu/brlcad_path.c
===================================================================
--- brlcad/branches/extbuild/src/libbu/brlcad_path.c 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libbu/brlcad_path.c 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -28,6 +28,8 @@
#include <string.h>
#include "bio.h"
+#include "whereami.h"
+
#include "bu/app.h"
#include "bu/debug.h"
#include "bu/file.h"
@@ -200,11 +202,14 @@
return NULL;
}
+extern int _bu_dir_join_path(char result[MAXPATHLEN], const char *lhs, const
char *rhs, struct bu_vls *searched, const char *where);
+
const char *
bu_brlcad_root(const char *rhs, int fail_quietly)
{
static char result[MAXPATHLEN] = {0};
const char *lhs;
+ int length, dirname_length;
struct bu_vls searched = BU_VLS_INIT_ZERO;
char where[MAX_WHERE_SIZE] = {0};
@@ -229,28 +234,35 @@
}
/* run-time path identification */
- lhs = bu_argv0_full_path();
- snprintf(where, MAX_WHERE_SIZE, "\trun-time path identification
[UNKNOWN]\n");
- if (lhs) {
- char *dirpath;
- char *real_path = bu_file_realpath(lhs, NULL);
- dirpath = bu_path_dirname(real_path);
- snprintf(real_path, MAXPATHLEN, "%s", dirpath);
- bu_free(dirpath, "free bu_path_dirname");
- dirpath = bu_path_dirname(real_path);
- snprintf(real_path, MAXPATHLEN, "%s", dirpath);
- bu_free(dirpath, "free bu_path_dirname");
- if (join_path(result, real_path, rhs, &searched, where)) {
- if (UNLIKELY(bu_debug & BU_DEBUG_PATHS)) {
- bu_log("Found: Run-time path identification [%s]\n", result);
+ length = wai_getExecutablePath(NULL, 0, &dirname_length);
+ if (length > 0) {
+ char *plhs = (char *)bu_calloc(length+1, sizeof(char), "program path");
+ wai_getExecutablePath(plhs, length, &dirname_length);
+ plhs[length] = '\0';
+ snprintf(where, MAX_WHERE_SIZE, "\trun-time path identification
[UNKNOWN]\n");
+ if (strlen(plhs)) {
+ char *dirpath;
+ char *real_path = bu_file_realpath(plhs, NULL);
+ dirpath = bu_path_dirname(real_path);
+ snprintf(real_path, MAXPATHLEN, "%s", dirpath);
+ bu_free(dirpath, "free bu_path_dirname");
+ dirpath = bu_path_dirname(real_path);
+ snprintf(real_path, MAXPATHLEN, "%s", dirpath);
+ bu_free(dirpath, "free bu_path_dirname");
+ if (_bu_dir_join_path(result, real_path, rhs, &searched, where)) {
+ if (UNLIKELY(bu_debug & BU_DEBUG_PATHS)) {
+ bu_log("Found: Run-time path identification [%s]\n",
result);
+ }
+ bu_vls_free(&searched);
+ bu_free(real_path, "free real_path");
+ bu_free(plhs, "free plhs");
+ return result;
}
- bu_vls_free(&searched);
bu_free(real_path, "free real_path");
- return result;
+ } else {
+ bu_vls_strcat(&searched, where);
}
- bu_free(real_path, "free real_path");
- } else {
- bu_vls_strcat(&searched, where);
+ bu_free(plhs, "free plhs");
}
/* BRLCAD_ROOT compile-time path */
Modified: brlcad/branches/extbuild/src/libbu/crashreport.c
===================================================================
--- brlcad/branches/extbuild/src/libbu/crashreport.c 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libbu/crashreport.c 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -50,7 +50,7 @@
int
-bu_crashreport(const char *filename)
+bu_crashreport_app(const char *filename, const char *argv0)
{
if (UNLIKELY(!filename || strlen(filename) == 0)) {
return 0;
@@ -59,7 +59,11 @@
/* vat time ist? */
(void)time(&now);
- path = bu_argv0_full_path();
+ if (argv0) {
+ path = argv0;
+ } else {
+ path = bu_dir(NULL, 0, BU_DIR_BIN, bu_getprogname(), BU_DIR_EXT, NULL);
+ }
/* do our own expansion to avoid heap allocation */
snprintf(buffer, CR_BUFSIZE,
"******************************************\n\n"
@@ -181,6 +185,12 @@
return 1;
}
+int
+bu_crashreport(const char *filename)
+{
+ return bu_crashreport_app(filename, NULL);
+}
+
/*
* Local Variables:
* tab-width: 8
Modified: brlcad/branches/extbuild/src/libbu/dir.c
===================================================================
--- brlcad/branches/extbuild/src/libbu/dir.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/libbu/dir.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -303,7 +303,8 @@
*
* @return boolean on whether a match was found.
*/
-static int
+// TODO - this can be static once bu_brlcad_root is removed
+int
_bu_dir_join_path(char result[MAXPATHLEN], const char *lhs, const char *rhs,
struct bu_vls *searched, const char *where)
{
size_t llen, rlen;
@@ -420,7 +421,7 @@
char where[MAX_WHERE_SIZE] = {0};
if (UNLIKELY(bu_debug & BU_DEBUG_PATHS)) {
- bu_log("bu_brlcad_root: searching for [%s]\n", rhs?rhs:"");
+ bu_log("_bu_dir_brlcad_root: searching for [%s]\n", rhs?rhs:"");
}
/* BRLCAD_ROOT environment variable if set */
Modified: brlcad/branches/extbuild/src/libbu/tests/progname.c
===================================================================
--- brlcad/branches/extbuild/src/libbu/tests/progname.c 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libbu/tests/progname.c 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -24,6 +24,8 @@
#include <stdio.h>
#include <string.h>
+#include "../whereami.h"
+
#include "bu.h"
@@ -35,6 +37,8 @@
const char *ans;
const char *res;
char *tbasename;
+ int length, dirname_length;
+ char *plhs = NULL;
bu_setprogname(av[0]);
@@ -42,6 +46,13 @@
fprintf(stderr, "Usage: %s\n", av[0]);
return 1;
}
+ length = wai_getExecutablePath(NULL, 0, &dirname_length);
+ if (length > 0) {
+ label = "CASE 4";
+ plhs = (char *)bu_calloc(length+1, sizeof(char), "program path");
+ wai_getExecutablePath(plhs, length, &dirname_length);
+ plhs[length] = '\0';
+ }
tbasename = (char *)bu_calloc(strlen(av[0]), sizeof(char), "bu_progname
basename");
@@ -103,10 +114,10 @@
/* CASE 4: set full, then get */
label = "CASE 4";
bu_setprogname(av[0]);
- bu_setprogname(bu_argv0_full_path());
+ bu_setprogname(plhs);
res = bu_getprogname();
- ans = bu_argv0_full_path();
- tbasename = (char *)bu_calloc(strlen(bu_argv0_full_path()), sizeof(char),
"bu_progname basename");
+ ans = plhs;
+ tbasename = (char *)bu_calloc(strlen(plhs), sizeof(char), "bu_progname
basename");
bu_path_basename(ans, tbasename);
if (BU_STR_EQUAL(res, ans ? ans : "") || BU_STR_EQUAL(res, tbasename)) {
@@ -132,7 +143,7 @@
/* CASE 6: set 2x full path, then get */
label = "CASE 6";
- bu_setprogname(bu_argv0_full_path());
+ bu_setprogname(plhs);
bu_setprogname("/monkey/see/monkey/do");
res = bu_getprogname();
ans = "do";
@@ -147,7 +158,7 @@
/* CASE 7: get the full path */
label = "CASE 7";
bu_setprogname(av[0]);
- res = bu_argv0_full_path();
+ res = plhs;
bu_path_basename(res, tbasename);
if (res[0] == BU_DIR_SEPARATOR || (strlen(res) > 3 && res[1] == ':' &&
(res[2] == BU_DIR_SEPARATOR || res[2] == '/'))) {
@@ -157,19 +168,8 @@
fail++;
}
- /* CASE 8: make sure bu_getprogname leaves a full path */
- label = "CASE 8";
- bu_setprogname("/monkey/see/monkey/do");
- res = bu_getprogname();
- res = bu_argv0_full_path();
- if (BU_STR_EQUAL(res, "/monkey/see/monkey/do")) {
- printf("%s: %24s -> %24s [PASSED]\n", label, res, res);
- } else {
- printf("%24s -> %24s (should match %s) [FAIL]\n", label, res,
"/monkey/see/monkey/do");
- fail++;
- }
-
bu_free(tbasename, "bu_progname basename");
+ bu_free(plhs, "wai Executable Path");
return fail;
}
Modified: brlcad/branches/extbuild/src/libbu/vfont.c
===================================================================
--- brlcad/branches/extbuild/src/libbu/vfont.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/libbu/vfont.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -49,7 +49,7 @@
if (fontname[0] != '/') {
/* absolute path */
- const char *vfont = bu_brlcad_root("share/vfont", 1);
+ const char *vfont = bu_dir(NULL, 0, BU_DIR_DATA, "vfont", NULL);
if (vfont)
snprintf(fname, FONTNAMESZ, "%s/%s", vfont, fontname);
else
@@ -138,7 +138,7 @@
/* Open the file and read in the header information. */
if ((fp = fopen(const_font, "rb")) == NULL) {
- snprintf(fname, FONTNAMESZ, "%s/%s", (char
*)bu_brlcad_root("share/vfont", 0), const_font);
+ snprintf(fname, FONTNAMESZ, "%s/%s", bu_dir(NULL, 0, BU_DIR_DATA,
"vfont", NULL), const_font);
if ((fp = fopen(fname, "rb")) == NULL) {
snprintf(fname, FONTNAMESZ, "%s/%s", FONTDIR2, const_font);
if ((fp = fopen(fname, "rb")) == NULL) {
Modified: brlcad/branches/extbuild/src/libbu/whereami.h
===================================================================
--- brlcad/branches/extbuild/src/libbu/whereami.h 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libbu/whereami.h 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -24,6 +24,10 @@
#include "common.h"
+/* NOTE - this is only included so we can BU_EXPORT getExecutablePath for
+ * libbu's testing - whereami should NOT be considered public libbu API */
+#include "bu/defines.h"
+
#ifdef __cplusplus
extern "C" {
#endif
@@ -54,7 +58,7 @@
* @return the length of the executable path on success (without a terminal NUL
* character), otherwise `-1`
*/
-WAI_FUNCSPEC
+BU_EXPORT WAI_FUNCSPEC
int WAI_PREFIX(getExecutablePath)(char* out, int capacity, int*
dirname_length);
/**
Modified: brlcad/branches/extbuild/src/libdm/dm_init.cpp
===================================================================
--- brlcad/branches/extbuild/src/libdm/dm_init.cpp 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libdm/dm_init.cpp 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -168,6 +168,8 @@
}
+ bu_argv_free(nfiles, filenames);
+ bu_vls_free(&plugin_pattern);
dm_backends = (void *)&dm_map;
Modified: brlcad/branches/extbuild/src/libdm/osgl/dm-osgl.cpp
===================================================================
--- brlcad/branches/extbuild/src/libdm/osgl/dm-osgl.cpp 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libdm/osgl/dm-osgl.cpp 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -688,7 +688,7 @@
return DM_NULL;
}
privvars->fontNormal = FONS_INVALID;
- privvars->fontNormal = fonsAddFont(privvars->fs, "sans",
bu_brlcad_root("share/fonts/ProFont.ttf", 0));
+ privvars->fontNormal = fonsAddFont(privvars->fs, "sans", bu_dir(NULL, 0,
BU_DIR_DATA, "fonts", "ProFont.ttf", NULL));
/* This is the applications display list offset */
dmp->i->dm_displaylist = glGenLists(0);
Modified: brlcad/branches/extbuild/src/libdm/osgl/if_osgl.cpp
===================================================================
--- brlcad/branches/extbuild/src/libdm/osgl/if_osgl.cpp 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libdm/osgl/if_osgl.cpp 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -506,8 +506,8 @@
std::string ppath = std::string(bu_dir(NULL, 0, BU_DIR_LIB,
"osgPlugins"));
osgDB::FilePathList paths =
osgDB::Registry::instance()->getLibraryFilePathList();
if (ppath.length()) {
- /* The first entry is the final installed path - prefer that to the
local
- * bu_brlcad_root lib directory. This means our new path should be
the
+ /* The first entry is the final installed path - prefer that to the
+ * local lib directory. This means our new path should be the
* second entry in the list - insert it accordingly. */
osgDB::FilePathList::iterator in_itr=++(paths.begin());
paths.insert(in_itr, ppath);
Modified: brlcad/branches/extbuild/src/libgcv/gcv.c
===================================================================
--- brlcad/branches/extbuild/src/libgcv/gcv.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/libgcv/gcv.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -87,7 +87,13 @@
const struct gcv_opts *UNUSED(gcv_options), const void
*UNUSED(options_data),
const char *dest_path)
{
- struct rt_wdb * const out_wdbp = wdb_fopen(dest_path);
+ struct rt_wdb * out_wdbp = NULL;
+ if (!bu_file_exists(dest_path, NULL)) {
+ out_wdbp = wdb_fopen(dest_path);
+ } else {
+ struct db_i *dbip = db_open(dest_path, DB_OPEN_READWRITE);
+ out_wdbp = wdb_dbopen(dbip, RT_WDB_TYPE_DB_DISK_APPEND_ONLY);
+ }
if (!out_wdbp) {
bu_log("wdb_fopen() failed for '%s'\n", dest_path);
Modified: brlcad/branches/extbuild/src/libged/concat/concat.cpp
===================================================================
--- brlcad/branches/extbuild/src/libged/concat/concat.cpp 2020-12-19
19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/libged/concat/concat.cpp 2020-12-19
19:46:38 UTC (rev 78030)
@@ -283,6 +283,10 @@
return GED_ERROR;
}
+ /* db_diradd doesn't produce the correct major type for binary objects -
+ * make sure they match. */
+ new_dp->d_major_type = input_dp->d_major_type;
+
if (rt_db_put_internal(new_dp, curr_dbip, &ip, &rt_uniresource) < 0) {
bu_vls_printf(gedp->ged_result_str,
"Failed to write new object (%s) to database -
aborting!!\n",
Modified: brlcad/branches/extbuild/src/libged/ged_init.cpp
===================================================================
--- brlcad/branches/extbuild/src/libged/ged_init.cpp 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libged/ged_init.cpp 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -245,6 +245,8 @@
cmd_funcs.insert(dl_handle);
}
}
+ bu_argv_free(nfiles, filenames);
+ bu_vls_free(&plugin_pattern);
ged_cmds = (void *)&cmd_map;
}
Modified: brlcad/branches/extbuild/src/libged/ged_util.c
===================================================================
--- brlcad/branches/extbuild/src/libged/ged_util.c 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libged/ged_util.c 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -1339,7 +1339,8 @@
struct ged_subprocess *rrtp = (struct ged_subprocess *)clientData;
int count = 0;
int retcode = 0;
- int read_failed = 0;
+ int read_failed_stderr = 0;
+ int read_failed_stdout = 0;
char line[RT_MAXLINE+1] = {0};
if ((rrtp == (struct ged_subprocess *)NULL) || (rrtp->gedp == (struct ged
*)NULL))
@@ -1350,19 +1351,22 @@
struct ged *gedp = rrtp->gedp;
/* Get data from rt */
- if (bu_process_read((char *)line, &count, rrtp->p, BU_PROCESS_STDERR,
RT_MAXLINE) <= 0) {
- if (bu_process_read((char *)line, &count, rrtp->p, BU_PROCESS_STDOUT,
RT_MAXLINE) <= 0) {
- read_failed = 1;
- }
+ if (rrtp->stderr_active && bu_process_read((char *)line, &count, rrtp->p,
BU_PROCESS_STDERR, RT_MAXLINE) <= 0) {
+ read_failed_stderr = 1;
}
+ if (rrtp->stdout_active && bu_process_read((char *)line, &count, rrtp->p,
BU_PROCESS_STDOUT, RT_MAXLINE) <= 0) {
+ read_failed_stdout = 1;
+ }
- if (read_failed) {
+ if (read_failed_stderr || read_failed_stdout) {
int aborted;
/* Done watching for output, undo subprocess I/O hooks. */
if (gedp->ged_delete_io_handler) {
- (*gedp->ged_delete_io_handler)(rrtp, BU_PROCESS_STDERR);
- (*gedp->ged_delete_io_handler)(rrtp, BU_PROCESS_STDOUT);
+ if (rrtp->stderr_active)
+ (*gedp->ged_delete_io_handler)(rrtp, BU_PROCESS_STDERR);
+ if (rrtp->stdout_active)
+ (*gedp->ged_delete_io_handler)(rrtp, BU_PROCESS_STDOUT);
}
@@ -1485,6 +1489,9 @@
BU_GET(run_rtp, struct ged_subprocess);
run_rtp->magic = GED_CMD_MAGIC;
+ run_rtp->stdin_active = 0;
+ run_rtp->stdout_active = 0;
+ run_rtp->stderr_active = 0;
bu_ptbl_ins(&gedp->ged_subp, (long *)run_rtp);
run_rtp->p = p;
@@ -1494,7 +1501,6 @@
/* If we know how, set up hooks so the parent process knows to watch for
output. */
if (gedp->ged_create_io_handler) {
(*gedp->ged_create_io_handler)(run_rtp, BU_PROCESS_STDERR,
_ged_rt_output_handler, (void *)run_rtp);
- (*gedp->ged_create_io_handler)(run_rtp, BU_PROCESS_STDOUT,
_ged_rt_output_handler, (void *)run_rtp);
}
return GED_OK;
}
Modified: brlcad/branches/extbuild/src/libged/gqa/gqa.cpp
===================================================================
--- brlcad/branches/extbuild/src/libged/gqa/gqa.cpp 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libged/gqa/gqa.cpp 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -2410,6 +2410,7 @@
/* initialize some stuff */
state.sem_worker = bu_semaphore_register("gqa_sem_worker");
state.sem_stats = bu_semaphore_register("gqa_sem_stats");
+ state.sem_lists = bu_semaphore_register("gqa_sem_lists");
state.rtip = rtip;
state.first = 1;
allocate_per_region_data(&state, start_objs, argc, argv);
Modified: brlcad/branches/extbuild/src/libged/help/help.cpp
===================================================================
--- brlcad/branches/extbuild/src/libged/help/help.cpp 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libged/help/help.cpp 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -249,7 +249,7 @@
return -1;
/* get our doc dir */
- dir = bu_strdup(bu_brlcad_dir("doc", 0));
+ dir = bu_strdup(bu_dir(NULL, 0, BU_DIR_DOC, NULL));
/* get recursive list of documentation files */
count = help_files(dir, &entries);
Modified: brlcad/branches/extbuild/src/libged/rt/rt.c
===================================================================
--- brlcad/branches/extbuild/src/libged/rt/rt.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/libged/rt/rt.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -65,7 +65,7 @@
args = argc + 7 + 2 + ged_who_argc(gedp);
gd_rt_cmd = (char **)bu_calloc(args, sizeof(char *), "alloc gd_rt_cmd");
- bin = bu_brlcad_root("bin", 1);
+ bin = bu_dir(NULL, 0, BU_DIR_BIN, NULL);
if (bin) {
snprintf(rt, 256, "%s/%s", bin, argv[0]);
}
Modified: brlcad/branches/extbuild/src/libged/rtcheck/rtcheck.c
===================================================================
--- brlcad/branches/extbuild/src/libged/rtcheck/rtcheck.c 2020-12-19
19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/libged/rtcheck/rtcheck.c 2020-12-19
19:46:38 UTC (rev 78030)
@@ -199,7 +199,7 @@
/* initialize result */
bu_vls_trunc(gedp->ged_result_str, 0);
- bin = bu_brlcad_root("bin", 1);
+ bin = bu_dir(NULL, 0, BU_DIR_BIN, NULL);
if (bin) {
snprintf(rtcheck, 256, "%s/%s", bin, argv[0]);
}
@@ -272,6 +272,10 @@
rtcp->rrtp->p = p;
rtcp->rrtp->aborted = 0;
rtcp->rrtp->gedp = gedp;
+ rtcp->rrtp->stdin_active = 0;
+ rtcp->rrtp->stdout_active = 0;
+ rtcp->rrtp->stderr_active = 0;
+
if (gedp->ged_create_io_handler) {
(*gedp->ged_create_io_handler)(rtcp->rrtp, BU_PROCESS_STDOUT,
rtcheck_vector_handler, (void *)rtcp);
}
Modified: brlcad/branches/extbuild/src/libged/rtwizard/rtwizard.c
===================================================================
--- brlcad/branches/extbuild/src/libged/rtwizard/rtwizard.c 2020-12-19
19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/libged/rtwizard/rtwizard.c 2020-12-19
19:46:38 UTC (rev 78030)
@@ -57,6 +57,9 @@
BU_GET(run_rtp, struct ged_subprocess);
run_rtp->magic = GED_CMD_MAGIC;
+ run_rtp->stdin_active = 0;
+ run_rtp->stdout_active = 0;
+ run_rtp->stderr_active = 0;
bu_ptbl_ins(&gedp->ged_subp, (long *)run_rtp);
run_rtp->p = p;
@@ -108,7 +111,7 @@
gd_rt_cmd = (char **)bu_calloc(args, sizeof(char *), "alloc gd_rt_cmd");
- bin = bu_brlcad_root("bin", 1);
+ bin = bu_dir(NULL, 0, BU_DIR_BIN, NULL);
if (bin) {
snprintf(rtscript, 256, "%s/rtwizard", bin);
} else {
Modified: brlcad/branches/extbuild/src/libged/tests/ged_tests.g
===================================================================
(Binary files differ)
Modified: brlcad/branches/extbuild/src/librt/gdiam/gdiam.cpp
===================================================================
--- brlcad/branches/extbuild/src/librt/gdiam/gdiam.cpp 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/librt/gdiam/gdiam.cpp 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -1428,7 +1428,7 @@
*( in[ ind ] ) ) ) {
area = Area( *( ch[ jnd ] ), *( ch[ jnd + 1 ] ),
*( in[ ind ] ) );
- if ( fabs( area ) < 1e-12 )
+ if ( fabsl( area ) < 1e-12 )
continue;
printf( "Failure in progress!\n\n" );
print_pnt( ch[ jnd ] );
Modified: brlcad/branches/extbuild/src/librt/primitives/primitive_util.c
===================================================================
--- brlcad/branches/extbuild/src/librt/primitives/primitive_util.c
2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/librt/primitives/primitive_util.c
2020-12-19 19:46:38 UTC (rev 78030)
@@ -555,8 +555,7 @@
programs = (cl_program*)bu_calloc(count, sizeof(cl_program), "programs");
for (i=0; i<count; i++) {
- snprintf(file, MAXPATHLEN, "%s%c%s", "share/" BRLCAD_OPENCL_DIR,
BU_DIR_SEPARATOR, filenames[i]);
- snprintf(path, MAXPATHLEN, "%s", bu_brlcad_root(file, 0));
+ snprintf(path, MAXPATHLEN, "%s", bu_dir(NULL, 0, BU_DIR_DATA,
BRLCAD_OPENCL_DIR, filenames[i], NULL));
pc_string = clt_read_code(path, &pc_length);
programs[i] = clCreateProgramWithSource(context, 1, &pc_string,
&pc_length, &error);
@@ -654,7 +653,7 @@
if (error != CL_SUCCESS) bu_bomb("failed to create an OpenCL command
queue");
/* locate opencl directory */
- snprintf(path, MAXPATHLEN, "%s", bu_brlcad_root("share/"
BRLCAD_OPENCL_DIR, 0));
+ snprintf(path, MAXPATHLEN, "%s", bu_dir(NULL, 0, BU_DIR_DATA,
BRLCAD_OPENCL_DIR, NULL));
/* compile opencl programs */
snprintf(args, MAXPATHLEN, "-I %s -D RT_SINGLE_HIT=1", path);
Modified: brlcad/branches/extbuild/src/libtclcad/auto_path.c
===================================================================
--- brlcad/branches/extbuild/src/libtclcad/auto_path.c 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/libtclcad/auto_path.c 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -216,13 +216,15 @@
bu_vls_sprintf(&buffer, "tclscripts%clod", BU_DIR_SEPARATOR);
p = bu_strdup(bu_vls_cstr(&buffer));
bu_ptbl_ins(&data_subpaths, (long *)p);
+
+ bu_vls_free(&buffer);
}
// First off, see what's in BU_DIR_LIB.
char libdir[MAXPATHLEN] = {0};
- struct bu_vls lib_path = BU_VLS_INIT_ZERO;
bu_dir(libdir, MAXPATHLEN, BU_DIR_LIB, NULL);
{
+ struct bu_vls lib_path = BU_VLS_INIT_ZERO;
struct bu_ptbl found_subpaths = BU_PTBL_INIT_ZERO;
if (strlen(libdir)) {
// Have a library directory, see what's in it
@@ -241,17 +243,22 @@
// better...
for (size_t i = 0; i < BU_PTBL_LEN(&found_subpaths); i++) {
bu_ptbl_rm(&lib_subpaths, BU_PTBL_GET(&found_subpaths, i));
+ // Since lib_subpaths cleanup won't be seeing this string,
+ // we need to free it now.
+ char *str = (char *)BU_PTBL_GET(&found_subpaths, i);
+ bu_free(str, "subpath string");
}
}
+ bu_vls_free(&lib_path);
bu_ptbl_free(&found_subpaths);
}
// Now that we've looked for the libs, handle the data dirs.
- struct bu_vls data_path = BU_VLS_INIT_ZERO;
char datadir[MAXPATHLEN] = {0};
bu_dir(datadir, MAXPATHLEN, BU_DIR_DATA, NULL);
if (strlen(datadir)) {
// Have a directory, see what's in it
+ struct bu_vls data_path = BU_VLS_INIT_ZERO;
for (size_t i = 0; i < BU_PTBL_LEN(&data_subpaths); i++) {
const char *fname = (const char *)BU_PTBL_GET(&data_subpaths, i);
bu_vls_sprintf(&data_path, "%s%c%s", datadir, BU_DIR_SEPARATOR,
fname);
@@ -263,6 +270,7 @@
bu_log("Warning: data path %s is not present in directory
%s\n", fname, datadir);
}
}
+ bu_vls_free(&data_path);
}
/* Iterate over the paths set and modify the real Tcl auto_path */
Modified: brlcad/branches/extbuild/src/libtclcad/bu.c
===================================================================
--- brlcad/branches/extbuild/src/libtclcad/bu.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/libtclcad/bu.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -391,8 +391,37 @@
bu_log("Usage: bu_brlcad_dir dirkey\n");
return BRLCAD_ERROR;
}
- Tcl_AppendResult(interp, bu_brlcad_dir(argv[1], 1), NULL);
- return BRLCAD_OK;
+ if (BU_STR_EQUAL(argv[1], "bin")) {
+ Tcl_AppendResult(interp, bu_dir(NULL, 0, BU_DIR_BIN, NULL), NULL);
+ return BRLCAD_OK;
+ }
+ if (BU_STR_EQUAL(argv[1], "lib")) {
+ Tcl_AppendResult(interp, bu_dir(NULL, 0, BU_DIR_LIB, NULL), NULL);
+ return BRLCAD_OK;
+ }
+ if (BU_STR_EQUAL(argv[1], "include")) {
+ Tcl_AppendResult(interp, bu_dir(NULL, 0, BU_DIR_INCLUDE, NULL), NULL);
+ return BRLCAD_OK;
+ }
+ if (BU_STR_EQUAL(argv[1], "data")) {
+ Tcl_AppendResult(interp, bu_dir(NULL, 0, BU_DIR_DATA, NULL), NULL);
+ return BRLCAD_OK;
+ }
+ if (BU_STR_EQUAL(argv[1], "share")) {
+ Tcl_AppendResult(interp, bu_dir(NULL, 0, BU_DIR_DATA, NULL), NULL);
+ return BRLCAD_OK;
+ }
+ if (BU_STR_EQUAL(argv[1], "doc")) {
+ Tcl_AppendResult(interp, bu_dir(NULL, 0, BU_DIR_DOC, NULL), NULL);
+ return BRLCAD_OK;
+ }
+
+ if (BU_STR_EQUAL(argv[1], "man")) {
+ Tcl_AppendResult(interp, bu_dir(NULL, 0, BU_DIR_MAN, NULL), NULL);
+ return BRLCAD_OK;
+ }
+
+ return BRLCAD_ERROR;
}
/**
@@ -414,7 +443,19 @@
bu_log("Usage: bu_brlcad_root subdir\n");
return BRLCAD_ERROR;
}
- Tcl_AppendResult(interp, bu_brlcad_root(argv[1], 1), NULL);
+ if (argv[1][0] == '/') {
+ Tcl_AppendResult(interp, argv[1], NULL);
+ return BRLCAD_OK;
+ }
+ const char *bdir = bu_dir(NULL, 0, BU_DIR_BIN, NULL);
+ struct bu_vls wpath = BU_VLS_INIT_ZERO;
+ if (!bu_path_component(&wpath, bdir, BU_PATH_DIRNAME)) {
+ bu_vls_free(&wpath);
+ return BRLCAD_ERROR;
+ }
+ const char *npath = bu_dir(NULL, 0, bu_vls_cstr(&wpath), argv[1], NULL);
+ Tcl_AppendResult(interp, npath, NULL);
+ bu_vls_free(&wpath);
return BRLCAD_OK;
}
Modified: brlcad/branches/extbuild/src/libtclcad/command_io.cpp
===================================================================
--- brlcad/branches/extbuild/src/libtclcad/command_io.cpp 2020-12-19
19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/libtclcad/command_io.cpp 2020-12-19
19:46:38 UTC (rev 78030)
@@ -79,6 +79,17 @@
if (fdp) {
struct tclcad_io_data *t_iod = (struct tclcad_io_data
*)p->gedp->ged_io_data;
Tcl_CreateFileHandler(*fdp, t_iod->io_mode, callback, (ClientData)data);
+ switch (d) {
+ case BU_PROCESS_STDIN:
+ p->stdin_active = 1;
+ break;
+ case BU_PROCESS_STDOUT:
+ p->stdout_active = 1;
+ break;
+ case BU_PROCESS_STDERR:
+ p->stderr_active = 1;
+ break;
+ }
}
}
@@ -92,6 +103,17 @@
Tcl_DeleteFileHandler(*fdp);
close(*fdp);
}
+ switch (d) {
+ case BU_PROCESS_STDIN:
+ p->stdin_active = 0;
+ break;
+ case BU_PROCESS_STDOUT:
+ p->stdout_active = 0;
+ break;
+ case BU_PROCESS_STDERR:
+ p->stderr_active = 0;
+ break;
+ }
}
@@ -118,6 +140,7 @@
if (fdp) {
switch (d) {
case BU_PROCESS_STDIN:
+ p->stdin_active = 1;
if (!pchan->cstdin) {
pchan->cstdin = Tcl_MakeFileChannel(*fdp, t_iod->io_mode);
Tcl_CreateChannelHandler(pchan->cstdin, t_iod->io_mode,
callback, (ClientData)data);
@@ -124,6 +147,7 @@
}
break;
case BU_PROCESS_STDOUT:
+ p->stdout_active = 1;
if (!pchan->cstdout) {
pchan->cstdout = Tcl_MakeFileChannel(*fdp, t_iod->io_mode);
Tcl_CreateChannelHandler(pchan->cstdout, t_iod->io_mode,
callback, (ClientData)data);
@@ -130,6 +154,7 @@
}
break;
case BU_PROCESS_STDERR:
+ p->stderr_active = 1;
if (!pchan->cstderr) {
pchan->cstderr = Tcl_MakeFileChannel(*fdp, t_iod->io_mode);
Tcl_CreateChannelHandler(pchan->cstderr, t_iod->io_mode,
callback, (ClientData)data);
@@ -152,7 +177,7 @@
return;
}
pchan = (*pmap)[p];
- if (!pchan->cstdin && !pchan->cstdout && !pchan->cstdout) {
+ if (!pchan->cstdin && !pchan->cstdout && !pchan->cstderr) {
// All subprocess channels destroyed; we're done with the I/O from this
subprocess, clean up
BU_PUT(pchan, struct tclcad_process_channels);
pmap->erase(p);
@@ -160,25 +185,28 @@
switch (d) {
case BU_PROCESS_STDIN:
- if (pchan->cstdin) {
+ if (p->stdin_active && pchan->cstdin) {
Tcl_DeleteChannelHandler(pchan->cstdin, NULL, (ClientData)NULL);
Tcl_Close(t_iod->interp, pchan->cstdin);
pchan->cstdin = NULL;
}
+ p->stdin_active = 0;
break;
case BU_PROCESS_STDOUT:
- if (pchan->cstdout) {
+ if (p->stdout_active && pchan->cstdout) {
Tcl_DeleteChannelHandler(pchan->cstdout, NULL,
(ClientData)NULL);
Tcl_Close(t_iod->interp, pchan->cstdout);
pchan->cstdout = NULL;
}
+ p->stdout_active = 0;
break;
case BU_PROCESS_STDERR:
- if (pchan->cstderr) {
+ if (p->stderr_active && pchan->cstderr) {
Tcl_DeleteChannelHandler(pchan->cstderr, NULL,
(ClientData)NULL);
Tcl_Close(t_iod->interp, pchan->cstderr);
pchan->cstderr = NULL;
}
+ p->stderr_active = 0;
break;
}
}
Modified: brlcad/branches/extbuild/src/mged/cmd.c
===================================================================
--- brlcad/branches/extbuild/src/mged/cmd.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/mged/cmd.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -1259,7 +1259,9 @@
int
f_quit(ClientData UNUSED(clientData), Tcl_Interp *interpreter, int argc, const
char *argv[])
{
- if (argc < 1 || 1 < argc) {
+ int force_quit = 0;
+
+ if (argc < 1 || argc > 2) {
struct bu_vls vls = BU_VLS_INIT_ZERO;
bu_vls_printf(&vls, "help %s", argv[0]);
@@ -1268,6 +1270,21 @@
return TCL_ERROR;
}
+ if (argc > 1) {
+ if (BU_STR_EQUAL(argv[1], "-f"))
+ force_quit = 1;
+ }
+
+ /* Check if we have any ged subprocesses running. If we do, unless we're
forcing, don't
+ * quite yet. */
+ if (GEDP && BU_PTBL_LEN(&GEDP->ged_subp) && !force_quit) {
+ struct bu_vls vls = BU_VLS_INIT_ZERO;
+ bu_vls_sprintf(&vls, " attempting to quit while GED subprocesses are
running.\n\nTo list running processes, use the 'process list' command.\n\nTo
exit despite the running subprocesses, add the '-f' option to the quit
command.");
+ Tcl_AppendResult(interpreter, bu_vls_cstr(&vls), (char *)NULL);
+ bu_vls_free(&vls);
+ return TCL_ERROR;
+ }
+
if (STATE != ST_VIEW)
button(BE_REJECT);
Modified: brlcad/branches/extbuild/src/mged/mged.c
===================================================================
--- brlcad/branches/extbuild/src/mged/mged.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/mged/mged.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -1474,9 +1474,9 @@
status = Tcl_Eval(INTERP, bu_vls_addr(&vls));
} else {
Tcl_DString temp;
- const char *archer =
bu_brlcad_root("share/tclscripts/archer/archer_launch.tcl", 1);
const char *archer_trans;
Tcl_DStringInit(&temp);
+ const char *archer = bu_dir(NULL, 0, BU_DIR_DATA, "tclscripts",
"archer", "archer_launch.tcl", NULL);
archer_trans = Tcl_TranslateFileName(INTERP, archer, &temp);
tclcad_set_argv(INTERP, argc, (const char **)argv);
status = Tcl_EvalFile(INTERP, archer_trans);
@@ -2733,6 +2733,14 @@
} else {
/* Opened existing database file */
+ /* If dbi_version < 0, file isn't a valid .g file - don't proceed */
+ if (DBIP->dbi_version < 0) {
+ bu_free(DBIP->dbi_filename, "free filename");
+ DBIP = DBI_NULL;
+ Tcl_AppendResult(interpreter, "opendb: ", argv[1], " is not a
valid database\n", (char *)NULL);
+ return TCL_ERROR;
+ }
+
/* Scan geometry database and build in-memory directory */
(void)db_dirbuild(DBIP);
}
Modified: brlcad/branches/extbuild/src/mged/plot.c
===================================================================
--- brlcad/branches/extbuild/src/mged/plot.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/mged/plot.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -151,7 +151,7 @@
}
if ((pid1 = fork()) == 0) {
- const char *cad_boundp = bu_brlcad_root("bin/cad_boundp", 1);
+ const char *cad_boundp = bu_dir(NULL, 0, BU_DIR_BIN, "cad_boundp",
BU_DIR_EXT, NULL);
dup2(fd1[0], fileno(stdin));
dup2(fd2[1], fileno(stdout));
@@ -167,7 +167,7 @@
}
if ((pid2 = fork()) == 0) {
- const char *cad_parea = bu_brlcad_root("bin/cad_parea", 1);
+ const char *cad_parea = bu_dir(NULL, 0, BU_DIR_BIN, "cad_parea",
BU_DIR_EXT, NULL);
dup2(fd2[0], fileno(stdin));
dup2(fd3[1], fileno(stdout));
Modified: brlcad/branches/extbuild/src/mged/set.c
===================================================================
--- brlcad/branches/extbuild/src/mged/set.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/mged/set.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -97,6 +97,7 @@
#define MV_O(_m) bu_offsetof(struct _mged_variables, _m)
#define LINE RT_MAXLINE
struct bu_structparse mged_vparse[] = {
+ {"%d", 1, "rc", MV_O(mv_rc),
BU_STRUCTPARSE_FUNC_NULL, NULL, NULL },
{"%d", 1, "autosize", MV_O(mv_autosize),
BU_STRUCTPARSE_FUNC_NULL, NULL, NULL },
{"%d", 1, "rateknobs", MV_O(mv_rateknobs),
BU_STRUCTPARSE_FUNC_NULL, NULL, NULL },
{"%d", 1, "sliders", MV_O(mv_sliders),
set_scroll_private, NULL, NULL },
@@ -293,7 +294,7 @@
}
mged_vls_struct_parse_old(&vls, "mged variables", mged_vparse,
- (char *)&mged_variables, argc, argv);
+ (char *)mged_variables, argc, argv);
Tcl_AppendResult(interp, bu_vls_addr(&vls), (char *)NULL);
bu_vls_free(&vls);
@@ -425,7 +426,7 @@
}
/* found a dlp2 that is actively using dlp1's display lists
*/
- if (dlp2->dm_mged_variables->mv_dlist) {
+ if (dlp2 && dlp2->dm_mged_variables->mv_dlist) {
dlp2 = m_dmp;
break;
}
Modified: brlcad/branches/extbuild/src/mged/setup.c
===================================================================
--- brlcad/branches/extbuild/src/mged/setup.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/mged/setup.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -426,7 +426,7 @@
{
struct bu_vls str = BU_VLS_INIT_ZERO;
struct bu_vls tlog = BU_VLS_INIT_ZERO;
- const char *name = bu_argv0_full_path();
+ const char *name = bu_dir(NULL, 0, BU_DIR_BIN, bu_getprogname(),
BU_DIR_EXT, NULL);
/* locate our run-time binary (must be called before Tcl_CreateInterp()) */
if (name) {
Modified: brlcad/branches/extbuild/src/nirt/main.cpp
===================================================================
--- brlcad/branches/extbuild/src/nirt/main.cpp 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/nirt/main.cpp 2020-12-19 19:46:38 UTC (rev
78030)
@@ -151,7 +151,7 @@
struct bu_vls fl = BU_VLS_INIT_ZERO;
/* get a nirt directory listing */
- bu_vls_printf(&nfp, "%s", bu_brlcad_root("share/nirt", 0));
+ bu_vls_printf(&nfp, "%s", bu_dir(NULL, 0, BU_DIR_DATA, "nirt", NULL));
files = bu_file_list(bu_vls_addr(&nfp), suffix, &filearray);
if (names)
*names = filearray;
@@ -233,7 +233,7 @@
if (!file.is_open()) {
struct bu_vls str = BU_VLS_INIT_ZERO;
- bu_vls_printf(&str, "%s/%s.nrt", bu_brlcad_root("share/nirt", 0),
argv[0]);
+ bu_vls_printf(&str, "%s/%s.nrt", bu_dir(NULL, 0, BU_DIR_DATA, "nirt",
NULL), argv[0]);
file.open(bu_vls_addr(&str));
bu_vls_free(&str);
@@ -644,7 +644,7 @@
bu_vls_printf(&launch_cmd, "%s", argv[argc-1]);
}
- /* Let bu_brlcad_root and friends know where we are */
+ /* Let libbu know where we are */
bu_setprogname(argv[0]);
argv++; argc--;
Modified: brlcad/branches/extbuild/src/nirt/nirt.c
===================================================================
--- brlcad/branches/extbuild/src/nirt/nirt.c 2020-12-19 19:40:31 UTC (rev
78029)
+++ brlcad/branches/extbuild/src/nirt/nirt.c 2020-12-19 19:46:38 UTC (rev
78030)
@@ -144,7 +144,7 @@
struct bu_vls vlsfileline = BU_VLS_INIT_ZERO;
/* get a nirt directory listing */
- bu_vls_printf(&nirtfilespath, "%s", bu_brlcad_root("share/nirt", 0));
+ bu_vls_printf(&nirtfilespath, "%s", bu_dir(NULL, 0, BU_DIR_DATA, "nirt",
NULL));
files = bu_file_list(bu_vls_addr(&nirtfilespath), suffix, &filearray);
if (names)
*names = filearray;
@@ -258,7 +258,7 @@
cfPtr = fopen(bu_vls_addr(&str), "rb");
if (cfPtr == NULL) {
bu_vls_trunc(&str, 0);
- bu_vls_printf(&str, "%s/%s.nrt", bu_brlcad_root("share/nirt", 0),
string);
+ bu_vls_printf(&str, "%s/%s.nrt", bu_dir(NULL, 0, BU_DIR_DATA,
"nirt", NULL), string);
cfPtr = fopen(bu_vls_addr(&str), "rb");
if (cfPtr != NULL) {
fclose(cfPtr);
Index: brlcad/branches/extbuild/src/other
===================================================================
--- brlcad/branches/extbuild/src/other 2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/other 2020-12-19 19:46:38 UTC (rev 78030)
Property changes on: brlcad/branches/extbuild/src/other
___________________________________________________________________
Modified: svn:mergeinfo
## -9,4 +9,4 ##
/brlcad/branches/osg/src/other:62110-62113
/brlcad/branches/prep-cache/src/other:68236-68933
/brlcad/branches/tcltk86/src/other:68300-75257
-/brlcad/trunk/src/other:77547-77657,77836-77857,77870-77920,77924-77956
\ No newline at end of property
+/brlcad/trunk/src/other:77547-77657,77836-77857,77870-77920,77924-77956,77975-78028
\ No newline at end of property
Modified: brlcad/branches/extbuild/src/qged/cadimport.cpp
===================================================================
--- brlcad/branches/extbuild/src/qged/cadimport.cpp 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/qged/cadimport.cpp 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -109,10 +109,7 @@
QString
RhinoImportDialog::command()
{
- QString prog_name(bu_brlcad_dir("bin", 1));
- prog_name.append("/3dm-g");
- prog_name.append(EXECUTABLE_SUFFIX);
- prog_name = QString(bu_brlcad_root((const char *)prog_name.toLocal8Bit(),
1));
+ QString prog_name(bu_dir(NULL, 0, BU_DIR_BIN, "3dm-g", BU_DIR_EXT, NULL));
return prog_name;
}
@@ -190,10 +187,7 @@
QString
STEPImportDialog::command()
{
- QString prog_name(bu_brlcad_dir("bin", 1));
- prog_name.append("/step-g");
- prog_name.append(EXECUTABLE_SUFFIX);
- prog_name = QString(bu_brlcad_root((const char *)prog_name.toLocal8Bit(),
1));
+ QString prog_name(bu_dir(NULL, 0, BU_DIR_BIN, "step-g", BU_DIR_EXT, NULL));
return prog_name;
}
Modified: brlcad/branches/extbuild/src/rtwizard/main.c
===================================================================
--- brlcad/branches/extbuild/src/rtwizard/main.c 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/rtwizard/main.c 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -1136,7 +1136,7 @@
/* We're using this path on the file system, not in Tcl: translate it
* to the appropriate form before doing the eval */
Tcl_DStringInit(&temp);
- rtwizard = bu_brlcad_root("share/tclscripts/rtwizard/rtwizard", 1);
+ rtwizard = bu_dir(NULL, 0, BU_DIR_DATA, "tclscripts", "rtwizard",
"rtwizard", NULL);
fullname = Tcl_TranslateFileName(interp, rtwizard, &temp);
status = Tcl_EvalFile(interp, fullname);
Tcl_DStringFree(&temp);
Index: brlcad/branches/extbuild/src/tclscripts/archer
===================================================================
--- brlcad/branches/extbuild/src/tclscripts/archer 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/tclscripts/archer 2020-12-19 19:46:38 UTC
(rev 78030)
Property changes on: brlcad/branches/extbuild/src/tclscripts/archer
___________________________________________________________________
Modified: svn:mergeinfo
## -1,2 +1,3 ##
/brlcad/branches/RELEASE/src/tclscripts/archer:70323-70333,71915-71935,72826-72858,74376-74454
-/brlcad/branches/brep-debug/src/tclscripts/archer:69168,69927,69995-69996,70148-70149,70347-70349,70377,70526-70527,71006-71007,71009-71022,71046-71047,71049,71096-71100
\ No newline at end of property
+/brlcad/branches/brep-debug/src/tclscripts/archer:69168,69927,69995-69996,70148-70149,70347-70349,70377,70526-70527,71006-71007,71009-71022,71046-71047,71049,71096-71100
+/brlcad/trunk/src/tclscripts/archer:77975-78028
\ No newline at end of property
Modified: brlcad/branches/extbuild/src/tclscripts/archer/Archer.tcl
===================================================================
--- brlcad/branches/extbuild/src/tclscripts/archer/Archer.tcl 2020-12-19
19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/tclscripts/archer/Archer.tcl 2020-12-19
19:46:38 UTC (rev 78030)
@@ -37,13 +37,7 @@
set extraMgedCommands ""
set corePluginInit ""
- set pluginsdir [file join [bu_brlcad_root "share/plugins"] archer]
- if {![file exists $pluginsdir]} {
- # searching 'src' is only necessary for items installed to a
- # different hierarchy.
- set pluginsdir [file join [bu_brlcad_root "src"] archer plugins]
- }
-
+ set pluginsdir [file join [bu_dir data] plugins archer]
foreach plugin_type {Core Commands} {
if {[file exists [file join $pluginsdir $plugin_type]]} {
set savePwd [pwd]
@@ -679,15 +673,8 @@
set pwd [::pwd]
# developer & user plugins
- set pluginPath [file join [bu_brlcad_root "share/plugins"] archer]
+ set pluginPath [file join [bu_dir data] plugins archer]
if { ![file exists $pluginPath] } {
- # try a source dir invocation
-
- # searching 'src' is only necessary for items installed to a
- # different hierarchy.
- set pluginPath [file join [bu_brlcad_root "src"] archer plugins]
- }
- if { ![file exists $pluginPath] } {
# give up on loading any plugins
return
}
@@ -2422,7 +2409,7 @@
} {}
# About Info
- set imgfile [file join [bu_brlcad_root "share/tclscripts"] archer images
aboutArcher.png]
+ set imgfile [file join [bu_dir data] tclscripts archer images
aboutArcher.png]
set aboutImg [image create photo -file $imgfile]
itk_component add aboutInfo {
::ttk::label $itk_component(aboutDialogTabs).aboutInfo \
@@ -2440,7 +2427,7 @@
-textbackground $SystemButtonFace
} {}
- set brlcadLicenseFile [file join [bu_brlcad_root "share"] COPYING]
+ set brlcadLicenseFile [file join [bu_dir data] COPYING]
if {![catch {open $brlcadLicenseFile "r"} fd]} {
set brlcadLicenseInfo [read $fd]
close $fd
@@ -2459,7 +2446,7 @@
-textbackground $SystemButtonFace
} {}
- set ackFile [file join [bu_brlcad_root "share/doc"] archer_ack.txt]
+ set ackFile [file join [bu_dir doc] archer_ack.txt]
if {![catch {open $ackFile "r"} fd]} {
set ackInfo [read $fd]
close $fd
@@ -2471,8 +2458,7 @@
::frame $itk_component(aboutDialogTabs).mikeInfo
} {}
- # try installed, uninstalled
- set imgfile [file join [bu_brlcad_root "share/tclscripts"] mged
mike-tux.png]
+ set imgfile [file join [bu_dir data] tclscripts mged mike-tux.png]
set mikeImg [image create photo -file $imgfile]
itk_component add mikePic {
::label $itk_component(mikeF).pic \
@@ -2500,7 +2486,7 @@
-textbackground $SystemButtonFace
} {}
- set mikeInfoFile [file join [bu_brlcad_root "share/tclscripts"] mged
mike-dedication.txt]
+ set mikeInfoFile [file join [bu_dir data] tclscripts mged
mike-dedication.txt]
if {![catch {open $mikeInfoFile "r"} fd]} {
set mikeInfo [read -nonewline $fd]
close $fd
@@ -2538,7 +2524,7 @@
proc Archer::get_html_man_data {cmdname} {
global archer_help_data
- set help_fd [open [file join [bu_brlcad_root "share/doc/html"] mann
$cmdname.html]]
+ set help_fd [open [file join [bu_dir doc] html mann $cmdname.html]]
set archer_help_data [read $help_fd]
close $help_fd
}
@@ -2561,7 +2547,7 @@
if {[catch {regexp {(home://blank)(.+)} $origurl match prefix tempurl}
msg]} {
tk_messageBox -message "html_help_display: regexp failed, msg - $msg"
}
- set url [bu_brlcad_root "share/doc/html"]
+ set url [file join [bu_dir doc] html]
append url $tempurl
get_html_data $url
$htmlviewer reset
@@ -2570,7 +2556,7 @@
proc Archer::mkHelpTkImage {file} {
- set fullpath [file join [bu_brlcad_root "share/doc/html"] manuals $file]
+ set fullpath [file join [bu_dir doc] html manuals $file]
set name [image create photo -file $fullpath]
return [list $name [list image delete $name]]
}
@@ -2614,8 +2600,8 @@
set tlparent [$itk_component(archerHelp) childsite]
- if {[file exists [file join [bu_brlcad_root "share/doc/html"] books
BRL-CAD_Tutorial_Series-VolumeI.html]] &&
- [file exists [file join [bu_brlcad_root "share/doc/html"] toc.html]] } {
+ if {[file exists [file join [bu_dir doc] html books
BRL-CAD_Tutorial_Series-VolumeI.html]] &&
+ [file exists [file join [bu_dir doc] html toc.html]] } {
# Table of Contents
itk_component add archerHelpToC {
@@ -2628,7 +2614,7 @@
set docstoclist [::hv3::hv3 $docstoc.htmlview -width 250 -requestcmd
Archer::html_help_display]
set docstochtml [$docstoclist html]
$docstochtml configure -parsemode html
- set help_fd [lindex [list [file join [bu_brlcad_root "share/doc/html"]
toc.html]] 0]
+ set help_fd [lindex [list [file join [bu_dir doc] html toc.html]] 0]
get_html_data $help_fd
$docstochtml parse $archer_help_data
@@ -2656,7 +2642,7 @@
set htmlviewer [$hv3htmlviewer html]
$htmlviewer configure -parsemode html
$htmlviewer configure -imagecmd Archer::mkHelpTkImage
- set help_fd [lindex [list [file join [bu_brlcad_root "share/doc/html"]
books BRL-CAD_Tutorial_Series-VolumeI.html]] 0]
+ set help_fd [lindex [list [file join [bu_dir doc] html books
BRL-CAD_Tutorial_Series-VolumeI.html]] 0]
get_html_data $help_fd
$htmlviewer parse $archer_help_data
Modified: brlcad/branches/extbuild/src/tclscripts/archer/ArcherCore.tcl
===================================================================
--- brlcad/branches/extbuild/src/tclscripts/archer/ArcherCore.tcl
2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/tclscripts/archer/ArcherCore.tcl
2020-12-19 19:46:38 UTC (rev 78030)
@@ -1091,7 +1091,7 @@
set env(DISPLAY) ":0"
}
- set mImgDir [file join [bu_brlcad_root "share/tclscripts"] archer images]
+ set mImgDir [file join [bu_dir data] tclscripts archer images]
if {[llength $args] == 1} {
set args [lindex $args 0]
Modified: brlcad/branches/extbuild/src/tclscripts/archer/ShaderEdit.tcl
===================================================================
--- brlcad/branches/extbuild/src/tclscripts/archer/ShaderEdit.tcl
2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/tclscripts/archer/ShaderEdit.tcl
2020-12-19 19:46:38 UTC (rev 78030)
@@ -1017,7 +1017,7 @@
foreach s { 0 1 2 3 4 5 6 7 8 9 } {
set lightImages(light_i${i}_v${v}_s${s}) \
[image create photo -file \
- [file join [bu_brlcad_root "share/tclscripts"]
archer images l_i${i}_v${v}_s${s}.gif]]
+ [file join [bu_dir data] tclscripts archer images
l_i${i}_v${v}_s${s}.gif]]
}
}
}
Modified: brlcad/branches/extbuild/src/tclscripts/geometree/GeometryBrowser.tcl
===================================================================
--- brlcad/branches/extbuild/src/tclscripts/geometree/GeometryBrowser.tcl
2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/tclscripts/geometree/GeometryBrowser.tcl
2020-12-19 19:46:38 UTC (rev 78030)
@@ -475,7 +475,7 @@
# destroy the framebuffer, if we opened it
if { $_weStartedFbserv } {
puts "cleaning up fbserv"
- set fbfree [file join [bu_brlcad_root "bin"] fbfree]
+ set fbfree [file join [bu_dir bin] fbfree]
if { [ catch { exec $fbfree -F $_fbservPort } error ] } {
puts $error
puts "Unable to properly clean up after our fbserv"
@@ -956,10 +956,10 @@
set device /dev/X
set rgb "255 255 255"
set rtrun ""
- set fbserv [file join [bu_brlcad_root "bin"] fbserv]
- set fbfree [file join [bu_brlcad_root "bin"] fbfree]
- set fbline [file join [bu_brlcad_root "bin"] fbline]
- set fbclear [file join [bu_brlcad_root "bin"] fbclear]
+ set fbserv [file join [bu_dir bin] fbserv]
+ set fbfree [file join [bu_dir bin] fbfree]
+ set fbline [file join [bu_dir bin] fbline]
+ set fbclear [file join [bu_dir bin] fbclear]
# see if we can try to use the mged graphics window instead of firing up
our own framebuffer
set useMgedWindow 0
@@ -1111,7 +1111,7 @@
# simply fires off rtwizard
#
body GeometryBrowser::raytraceWizard {} {
- set rtwizard [file join [bu_brlcad_root "bin"] rtwizard]
+ set rtwizard [file join [bu_dir bin] rtwizard]
puts "exec $rtwizard &"
return [ exec $rtwizard & ]
}
Modified: brlcad/branches/extbuild/src/tclscripts/igraph/GraphEditor.tcl
===================================================================
--- brlcad/branches/extbuild/src/tclscripts/igraph/GraphEditor.tcl
2020-12-19 19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/tclscripts/igraph/GraphEditor.tcl
2020-12-19 19:46:38 UTC (rev 78030)
@@ -281,7 +281,7 @@
# destroy the framebuffer, if we opened it
if { $_weStartedFbserv } {
puts "cleaning up fbserv"
- set fbfree [file join [bu_brlcad_root "bin"] fbfree]
+ set fbfree [file join [bu_dir bin] fbfree]
if { [ catch { exec $fbfree -F $_fbservPort } error ] } {
puts $error
puts "Unable to properly clean up after our fbserv"
@@ -380,10 +380,10 @@
set device /dev/X
set rgb "255 255 255"
set rtrun ""
- set fbserv [file join [bu_brlcad_root "bin"] fbserv]
- set fbfree [file join [bu_brlcad_root "bin"] fbfree]
- set fbline [file join [bu_brlcad_root "bin"] fbline]
- set fbclear [file join [bu_brlcad_root "bin"] fbclear]
+ set fbserv [file join [bu_dir bin] fbserv]
+ set fbfree [file join [bu_dir bin] fbfree]
+ set fbline [file join [bu_dir bin] fbline]
+ set fbclear [file join [bu_dir bin] fbclear]
# see if we can try to use the mged graphics window instead of firing up
our own framebuffer
set useMgedWindow 0
Modified: brlcad/branches/extbuild/src/tclscripts/lib/Ged.tcl
===================================================================
--- brlcad/branches/extbuild/src/tclscripts/lib/Ged.tcl 2020-12-19 19:40:31 UTC
(rev 78029)
+++ brlcad/branches/extbuild/src/tclscripts/lib/Ged.tcl 2020-12-19 19:46:38 UTC
(rev 78030)
@@ -163,8 +163,6 @@
method bounds_all {args}
method brep {args}
method bu_units_conversion {args}
- method bu_brlcad_dir {args}
- method bu_brlcad_root {args}
method bu_prmem {args}
method bu_get_value_by_keyword {args}
method bu_rgb_to_hsv {args}
@@ -1388,14 +1386,6 @@
uplevel \#0 bu_units_conversion $args
}
-::itcl::body cadwidgets::Ged::bu_brlcad_dir {args} {
- uplevel \#0 bu_brlcad_dir $args
-}
-
-::itcl::body cadwidgets::Ged::bu_brlcad_root {args} {
- uplevel \#0 bu_brlcad_root $args
-}
-
::itcl::body cadwidgets::Ged::bu_prmem {args} {
uplevel \#0 bu_prmem $args
}
@@ -1894,7 +1884,7 @@
incr mLastPort
set port $mLastPort
- set binpath [bu_brlcad_root "bin"]
+ set binpath [bu_dir bin]
# This doesn't work (i.e. the "&" causes exec to always succeed, even when
the command fails)
while {[catch {exec [file join $binpath fbserv] -w $_w -n $_n $port
$_fbtype &} pid]} {
@@ -2137,7 +2127,7 @@
make_image $fbs_port $w $n $viewsize $orientation $eye_pt $perspective \
$_bgcolor $_ecolor $_necolor $_occmode $_gamma $_color_objects
$_ghost_objects $_edge_objects
- set binpath [bu_brlcad_root "bin"]
+ set binpath [bu_dir bin]
catch {exec [file join $binpath fb-fb] $fbs_port $port &}
if {$::tcl_platform(platform) == "windows"} {
@@ -6229,8 +6219,6 @@
[brepname] - convert the non-BREP object to BREP form
[suffix] - convert non-BREP comb to unevaluated BREP form}}
$help add bu_units_conversion {{units} {}}
- $help add bu_brlcad_dir {{dirkey} {}}
- $help add bu_brlcad_root {{subdir} {}}
$help add bu_prmem {{title} {}}
$help add bu_get_value_by_keyword {{iwant list} {}}
$help add bu_rgb_to_hsv {{rgb} {}}
Modified: brlcad/branches/extbuild/src/tclscripts/lib/GeometryIO.tcl
===================================================================
--- brlcad/branches/extbuild/src/tclscripts/lib/GeometryIO.tcl 2020-12-19
19:40:31 UTC (rev 78029)
+++ brlcad/branches/extbuild/src/tclscripts/lib/GeometryIO.tcl 2020-12-19
19:46:38 UTC (rev 78030)
@@ -32,14 +32,14 @@
}
proc ::run_conversion_config {input_file log_file} {
- set gui_cmd [list [bu_brlcad_root [file join [bu_brlcad_dir bin]
bwish$::exe_ext]] \
- [bu_brlcad_root "share/tclscripts/lib/gui_conversion.tcl"] "$input_file"
"$log_file"]
+ set gui_cmd [list [file join [bu_dir bin] bwish$::exe_ext] \
+ [file join [bu_dir data] tclscripts lib gui_conversion.tcl] "$input_file"
"$log_file"]
catch {eval exec $gui_cmd} _conv_log
}
proc geom_load {input_file gui_feedback} {
- set binpath [bu_brlcad_root [bu_brlcad_dir "bin"] ]
+ set binpath [bu_dir bin]
set input_ext [file extension $input_file]
set input_root [file rootname [file tail $input_file]]
@@ -60,12 +60,13 @@
if {[string compare $gui_feedback "1"] == 0} {
::run_conversion_config $input_file $log_file
} else {
- set cmd [list [bu_brlcad_root [file join [bu_brlcad_dir bin]
3dm-g$::exe_ext]] \
+ set cmd [list [file join [bu_dir bin] 3dm-g$::exe_ext] \
-r \
-c \
-o $output_file \
$input_file]
- catch {eval exec $cmd} _conv_log
+ #catch {eval exec $cmd} _conv_log
+ eval exec $cmd
}
}
".asc" {
@@ -72,7 +73,7 @@
if {[string compare $gui_feedback "1"] == 0} {
::run_conversion_config $input_file $log_file
} else {
- set cmd [list [bu_brlcad_root [file join [bu_brlcad_dir bin]
asc2g$::exe_ext]] \
+ set cmd [list [file join [bu_dir bin] asc2g$::exe_ext] \
$input_file \
$output_file]
catch {eval exec $cmd} _conv_log
@@ -82,7 +83,7 @@
if {[string compare $gui_feedback "1"] == 0} {
::run_conversion_config $input_file $log_file
} else {
- set cmd [list [bu_brlcad_root [file join [bu_brlcad_dir bin]
fast4-g$::exe_ext]] \
+ set cmd [list [file join [bu_dir bin] fast4-g$::exe_ext] \
-d \
$input_file \
$output_file]
@@ -93,7 +94,7 @@
if {[string compare $gui_feedback "1"] == 0} {
::run_conversion_config $input_file $log_file
} else {
- set cmd [list [bu_brlcad_root [file join [bu_brlcad_dir bin]
fast4-g$::exe_ext]] \
+ set cmd [list [file join [bu_dir bin] fast4-g$::exe_ext] \
-d \
$input_file \
$output_file]
@@ -104,7 +105,7 @@
if {[string compare $gui_feedback "1"] == 0} {
::run_conversion_config $input_file $log_file
} else {
- set cmd [list [bu_brlcad_root [file join [bu_brlcad_dir bin]
fast4-g$::exe_ext]] \
+ set cmd [list [file join [bu_dir bin] fast4-g$::exe_ext] \
-d \
$input_file \
$output_file]
@@ -115,7 +116,7 @@
if {[string compare $gui_feedback "1"] == 0} {
::run_conversion_config $input_file $log_file
} else {
- set cmd [list [bu_brlcad_root [file join [bu_brlcad_dir bin]
fast4-g$::exe_ext]] \
@@ Diff output truncated at 100000 characters. @@
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits