]> granicus.if.org Git - procps-ng/log
procps-ng
3 years agomisc: needed adaptations for the changes in <pids> api
Jim Warner [Tue, 9 Mar 2021 06:00:00 +0000 (00:00 -0600)]
misc: needed adaptations for the changes in <pids> api

That snowball, which began as a simple removal of some
brackets, now ends with this third patch restoring the
ability to build our project. It was made necessary by
the renaming (and rearranging) of several enumerators.

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agolibrary: fix a few source/origin notations, <pids> api
Jim Warner [Tue, 9 Mar 2021 06:00:00 +0000 (00:00 -0600)]
library: fix a few source/origin notations, <pids> api

After removing brackets from those 'derived' notations
I was surprised to discover that several origin/source
comments were wrong. So this patch fixes those errors.

[ along the way a couple enumerators were renamed to ]
[ better (i hope) reflect what they're representing. ]

[ that, in turn, also required a little rearranging. ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agolibrary: clean 'derived' origins in header, <pids> api
Jim Warner [Tue, 9 Mar 2021 06:00:00 +0000 (00:00 -0600)]
library: clean 'derived' origins in header, <pids> api

None of the other four new api headers use brackets on
derived items. With this patch we normalize the fifth.

[ it makes for a cleaner, less confusing, appearance ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agotop: enabled arbitrarily large numbers in 'scale' guys
Jim Warner [Mon, 8 Mar 2021 12:08:21 +0000 (06:08 -0600)]
top: enabled arbitrarily large numbers in 'scale' guys

While experimenting with a new feature, wherein select
fields display the total upon request, the capacity of
the 'num' passed to some 'scale' guys became an issue.

So this commit will, with the compiler's help, put the
responsibility for converting the integer into a float
within the calling code (instead of the called logic).

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agops: Add OOM and OOMADJ fields
Craig Small [Fri, 5 Mar 2021 06:22:29 +0000 (17:22 +1100)]
ps: Add OOM and OOMADJ fields

top has had the OOMs and OOMa fields since 2011. Ten years its
probably time that ps had these fields added too.

ps output options have oom and oomadj for OOM Score and OOM Adjustment
respectively.

References:
 procps-ng/procps#198
 commit 367fd902dab64b51ba49709004b5011440e3105a
 https://www.freelists.org/post/procps/PATCH-12-Add-missed-oom-support-to-libproc

3 years agolibrary: tweaked key used in hash table, <meminfo> api
Jim Warner [Tue, 23 Feb 2021 06:00:00 +0000 (00:00 -0600)]
library: tweaked key used in hash table, <meminfo> api

This small change was a result of some experimentation
trading our current 'hsearch' hash scheme for 'gperf'.

I discovered that when the ':' character was a part of
each 'gperf' key, that generated search logic was more
complicated and thus slower. But without a ':', it was
a little cleaner/leaner and therefore slightly faster.

Assuming that the same trailing ':' *might* affect the
current 'hsearch' logic, to be safe we will remove it.

[ while the 'gperf' version will slightly outperform ]
[ an 'hsearch', too many ugly implementation details ]
[ were exposed which complicates future maintenance. ]

[ thus, we'll retain our current 'hsearch' approach. ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agolibrary: normalized the 'read_failed' guys across APIs
Jim Warner [Mon, 22 Feb 2021 06:00:00 +0000 (00:00 -0600)]
library: normalized the 'read_failed' guys across APIs

This patch will condense some logic in those functions
associated with the file input operations. The changes
will not, for the most part, alter any generated code.

More significantly (though not very) was the change to
two 'strtoul' calls. Since the returned 'endptr' value
isn't exploited, when that parm is set to NULL, we can
save one instruction on each side of such calls (wow).

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agobuild-sys: Fix the uninstall-man target
Craig Small [Wed, 24 Feb 2021 09:58:28 +0000 (20:58 +1100)]
build-sys: Fix the uninstall-man target

If automake doesn't see a dist_man_MANS then there is no
uninstall-man target. This fix uses the main Makefile
targets.

Signed-off-by: Craig Small <csmall@dropbear.xyz>
3 years agotests: Fix paths for testsuite
Craig Small [Wed, 24 Feb 2021 09:41:38 +0000 (20:41 +1100)]
tests: Fix paths for testsuite

make distcheck gets confused what is in srcdir and what is in
topdir

Signed-off-by: Craig Small <csmall@dropbear.xyz>
3 years agodocs: tweak two man pages due to renaming of libproc-2
Jim Warner [Sat, 20 Feb 2021 17:11:11 +0000 (11:11 -0600)]
docs: tweak two man pages due to renaming of libproc-2

Reference(s):
commit 9aa09d8862c00a8dc85910d0365332c8c99b59ce

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agolibrary: eliminate a useless conditional in readproc.h
Jim Warner [Thu, 18 Feb 2021 06:00:00 +0000 (00:00 -0600)]
library: eliminate a useless conditional in readproc.h

When #define QUICK_THREADS was introduced, for copying
some task data for a child thread, one proc_t pad byte
was used to mark, then later identify, those children.

Later the QUICK_THREADS was recycled as FALSE_THREADS,
and used for a different purpose, but a conditional in
the header file erroneously remained. Now, it is gone!

Reference(s):
. Jul, 2016 - QUICK_THREADS become FALSE_THREADS
commit c546d9dd4409ee11cd466c99a820a3b5dadfe3f4
. Aug, 2011 - QUICK_THREADS intruduced
commit bb4f08ba297a67a043f7547670aa8623b54c2e67

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agolibrary: Rename to libproc-2
Craig Small [Sat, 20 Feb 2021 11:30:31 +0000 (22:30 +1100)]
library: Rename to libproc-2

What to call the new library?

Keep using libprocps wouldn't do, its a very different library from
the programs' point of view. It would also mean we could have some
clashes around the packages (two package names, same library name).

The ancient procps used libproc or libproc-a.b.c where a.b.c was the
package version. Kept the revision numbers down (it was always 0.0.0)
but the name of the library changed.

So if we use libproc-2 is there a clash with an ancient procps?
procps v 2.0.0 was around in 1999 so it was 22 years ago, also the
name of the library would have been libproc-2.0.0.so not libproc-2.so
so we're fine with that.

libproc-2 seems to fit, our second major re-work of the procps
library.

Signed-off-by: Craig Small <csmall@dropbear.xyz>
3 years agodocs: adjust revision date for our three new man pages
Jim Warner [Tue, 16 Feb 2021 06:00:00 +0000 (00:00 -0600)]
docs: adjust revision date for our three new man pages

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agodocs: expand 2 man pages 'Usage' to include VAL macros
Jim Warner [Mon, 15 Feb 2021 06:00:00 +0000 (00:00 -0600)]
docs: expand 2 man pages 'Usage' to include VAL macros

Maybe, the biggest obstacle to successfully exploiting
this new library is after those `stacks' are returned.

Unless a user requests all available `items', there is
always a need to translate an actual enumerator into a
relative position within returned stack(s) of results.

So, this patch attempts to bridge that gap by adding a
brief explanation to the existing discussion in Usage.

[ along the way, 'Usage' & 'Caveats' were refactored ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agolibrary: tweak logic for /proc not mounted, <pids> api
Jim Warner [Sun, 14 Feb 2021 06:00:00 +0000 (00:00 -0600)]
library: tweak logic for /proc not mounted, <pids> api

Since 'procps_uptime' will access the /proc filesystem
the <pids> 'new' guy should should protect against the
possibility /proc isn't mounted when 'boot_seconds' is
established. A zero is better than the negative value.

[ the only distortion would be to PIDS_TIME_ELAPSED. ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agolibrary: normalized 'extents_free_all' use across APIs
Jim Warner [Sat, 13 Feb 2021 06:00:00 +0000 (00:00 -0600)]
library: normalized 'extents_free_all' use across APIs

With the way those 'extents_free_all' guys were coded,
there's no real need to check for a NULL this->extents
before calling 'em. That's how <stat> already does it.

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agonls: Update man translations for pidwait
Craig Small [Tue, 16 Feb 2021 10:05:05 +0000 (21:05 +1100)]
nls: Update man translations for pidwait

3 years agopidwait: Add missing name change line
Craig Small [Mon, 15 Feb 2021 19:48:51 +0000 (06:48 +1100)]
pidwait: Add missing name change line

Missed one of the lines that changes from pwait to pidwait
in referenced commit.

References:
 commit 9c1a62b6373abe1a88d8cb51a67090950c5097e6

3 years agopidwait: Rename from pwait
Craig Small [Mon, 15 Feb 2021 10:10:06 +0000 (21:10 +1100)]
pidwait: Rename from pwait

pwait is already in at least Debian in a different package

References:
 https://bugs.debian.org/982391

3 years agobuild-sys: Ignore temp directory for POTFILES.in
Craig Small [Thu, 28 Jan 2021 11:35:33 +0000 (22:35 +1100)]
build-sys: Ignore temp directory for POTFILES.in

Sometimes the testing sequence would leave a source tree
under procps-ng-(version) which, if update-potfiles was
run, would include these temporary files in the list, causing issues
later.

The script now explicitly ignores those temporary files.

3 years agonls: Update the man po files
Craig Small [Mon, 15 Feb 2021 10:46:53 +0000 (21:46 +1100)]
nls: Update the man po files

Takes into account the procps*.3 manpages and updates them to the
corrected latest versions.

3 years agonls: Update translation files
Craig Small [Mon, 15 Feb 2021 10:37:56 +0000 (21:37 +1100)]
nls: Update translation files

3 years agobuild-sys: Update building of translations
Craig Small [Mon, 15 Feb 2021 10:36:57 +0000 (21:36 +1100)]
build-sys: Update building of translations

newlib was lagging behind oldlib in how the build system created
the translation files.

3 years agolibrary: update those source files for copyright dates
Jim Warner [Fri, 5 Feb 2021 06:00:00 +0000 (00:00 -0600)]
library: update those source files for copyright dates

In addition to copyright date, the initial descriptive
line was changed from a generic statement to one which
reflects the specific portion of the proc/ filesystem.

[ such descriptions alternate between 'declarations' ]
[ (h files) & corresponding 'definitions' (c files). ]

Also, a few missing copyright attributions were added.

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agotop: update the man page & source file copyright dates
Jim Warner [Thu, 4 Feb 2021 06:00:00 +0000 (00:00 -0600)]
top: update the man page & source file copyright dates

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agodocs: bring 2 man pages into agreement regarding sorts
Jim Warner [Wed, 3 Feb 2021 06:00:00 +0000 (00:00 -0600)]
docs: bring 2 man pages into agreement regarding sorts

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agolibrary: tweak 'other' user/group names for efficiency
Jim Warner [Tue, 2 Feb 2021 06:00:00 +0000 (00:00 -0600)]
library: tweak 'other' user/group names for efficiency

This commit just ensures that the relatively expensive
ID to name conversions aren't performed unless they're
explicitly requested. It also internalizes those flags
that required the PROC_FILLSTATUS flag to also be set.

[ requiring a caller, in our case pids.c, to provide ]
[ two flags when a single field was the objective is ]
[ wrong & represents a future potential toe-stubber. ]

[ moreover, what's worse is that those two flags are ]
[ seemingly unrelated. but, without both, a SEGV can ]
[ can be expected when a result.str pointer is NULL. ]

[ by contrast, in the master branch those fields are ]
[ arrays which, when set to zeroes, produce an empty ]
[ string. So, there is no abend (but no name either) ]
[ when one of those two required flags were omitted. ]

[ and worth noting, in that branch it's not just one ]
[ caller required to observe a two flag requirement. ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agodocs: vmstat.8 - swap is not virtual memory
Craig Small [Thu, 21 Jan 2021 06:58:48 +0000 (17:58 +1100)]
docs: vmstat.8 - swap is not virtual memory

Chanson Shen rightly pointed out that vmstat swpd stat is
swap memory used not virtual memory used.

Signed-off-by: Craig Small <csmall@dropbear.xyz>
3 years agomisc: Update Craig's email
Craig Small [Thu, 21 Jan 2021 06:37:48 +0000 (17:37 +1100)]
misc: Update Craig's email

3 years agodocs: adapt procps_misc.3 for new 'misc.h' header file
Jim Warner [Wed, 20 Jan 2021 06:00:00 +0000 (00:00 -0600)]
docs: adapt procps_misc.3 for new 'misc.h' header file

This commit adapts our man page for a new consolidated
'misc.h' header file. Along the way, some descriptions
were shortened, others lengthened and whitespace added
in an effort to (hopefully) improve readability a bit.

[ the #include subdirectory was also corrected while ]
[ rearranging & grouping functions into 3 categories ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agoall: make buildable again for new 'misc.h' header file
Jim Warner [Tue, 19 Jan 2021 06:00:00 +0000 (00:00 -0600)]
all: make buildable again for new 'misc.h' header file

With the 4 header files removed in the previous patch,
this commit just changes all those obsolete references
to that new consolidated 'misc.h' header file instead.

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agolibrary: combine 4 files into new 'misc.h' header file
Jim Warner [Mon, 18 Jan 2021 06:00:00 +0000 (00:00 -0600)]
library: combine 4 files into new 'misc.h' header file

Prior to this patch, we had four separate header files
dealing with miscellaneous functions. Those four files
were documented in the single man page: procps_misc.3.

Now, we will have just a single header file documented
in a single man page (that is what's called symmetry).

[ and while we're at it, we will shorten that overly ]
[ long struct 'procps_namespaces' name to agree with ]
[ the function naming conventions, e.g. 'procps_ns'. ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agodocs: update copyright, revision plus name for 2 pages
Jim Warner [Thu, 14 Jan 2021 06:00:00 +0000 (00:00 -0600)]
docs: update copyright, revision plus name for 2 pages

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agolibrary: reduce overhead for another 'escape' function
Jim Warner [Wed, 13 Jan 2021 06:00:00 +0000 (00:00 -0600)]
library: reduce overhead for another 'escape' function

The preceding commit made that 'esc_all' function more
efficient by using direct pointer manipulation instead
of an indexed string reference approach within a loop.

This commit applies the same approach to the 'esc_ctl'
function. Now we'll save 12 more iterated instructions
while decreasing the function's code size by 43 bytes.

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agolibrary: improve performance for one 'escape' function
Jim Warner [Tue, 12 Jan 2021 06:00:00 +0000 (00:00 -0600)]
library: improve performance for one 'escape' function

While this patch has some cosmetic whitespace changes,
more importantly it makes that 'esc_all' function more
efficient. By abandoning the indexed loop approach for
a direct pointer manipulation, we will save 9 iterated
machine instructions, for a total of 33 bytes of code.

Signed-off-by: Jim Warner <james.warner@comcast.net>
3 years agotop: a silly change forcing right margin justification
Jim Warner [Mon, 11 Jan 2021 06:00:00 +0000 (00:00 -0600)]
top: a silly change forcing right margin justification

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agotop: allow setting variable width col scroll (1 vs. 8)
Jim Warner [Wed, 30 Dec 2020 06:00:00 +0000 (00:00 -0600)]
top: allow setting variable width col scroll (1 vs. 8)

The Inspection feature already offered an INSP_SLIDE_1
provision. This patch now offers similar extensions to
variable width column scrolling (assuming SCROLLVAR_NO
isn't defined). Such a provision was useful during the
development of some recent library UTF-8 enhancements.

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agotop: relocate the 'fatal_proc_unmounted' function call
Jim Warner [Tue, 29 Dec 2020 06:00:00 +0000 (00:00 -0600)]
top: relocate the 'fatal_proc_unmounted' function call

With the restoration of corrupt utf8 multibyte editing
to the library, it's important to establish the proper
locale before calling that 'fatal_proc_unmounted' guy.

He calls the original 'look_up_our_self' who, in turn,
will invoke 'stat2proc' which then calls 'escape_str'.
Once there, it's too late to effect changes to locale.

[ the result would be lots and lots of '?' displayed ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agolibrary: refactor 'escape' logic for newlib (2nd time)
Jim Warner [Mon, 28 Dec 2020 06:00:00 +0000 (00:00 -0600)]
library: refactor 'escape' logic for newlib (2nd time)

Much of what was represented in the commit message for
the reference shown below was revisited in this patch.
It also means that the assertion in the last paragraph
of that message will only now be true with LANG unset.

[ and forget all the bullshit about not altering any ]
[ kernel supplied data. sometimes we must to avoid a ]
[ corrupt display due to a string we can not decode. ]

And while this commit still avoids the overhead of the
'mbrtowc', 'wcwidth' 'isprint, & 'iswprint' functions,
we achieve all the benefits with simple table lookups.
Plus such benefits are extended to additional strings.

For example, both PIDS_EXE and PIDS_CMD fields are now
also subject to being 'escaped'. If a program name did
contain multibyte characters, potential truncation may
corrupt it when it's squeezed into a 15/63 byte array.

Now, all future users of this new library only need to
deal with the disparities between string and printable
lengths. Such strings themselves are always printable.

[ the ps program now contains some unnecessary costs ]
[ with the duplicated former 'escape' functions. But ]
[ we retain that copied escape.c code for posterity. ]
[ besides, in a one-shot guy it's of little concern. ]

Note: Proper display of some multibyte strings was not
possible at the linux console. It would seem a concept
of zero length chars (like a 'combining acute accent')
is not recognized. Thus the display becomes corrupted.
But if utf8 decoding is disabled (via LANG=), then all
callers will now see '?', restoring correct alignment.

Reference(s):
. Dec 2020, newlib 'escape' logic refactored
commit a221b9084ae979e6fd073a83e7fbc46c44551f35

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agolibrary: refactor 'escape' logic for newlib essentials
Jim Warner [Thu, 24 Dec 2020 06:00:00 +0000 (00:00 -0600)]
library: refactor 'escape' logic for newlib essentials

This new library provides callers with pure strings or
string vectors. It is up to those callers to deal with
potential utf8 multibyte characters and any difference
between strlen and the corresponding printable widths.

So, it makes no sense for the library to go to all the
trouble of invoking those rather expensive 'mbrtowc' &
'wcwidth' functions to ultimately yield total 'cells'.

Thus, this patch will eliminate all the code and parms
that are involved with such possible multibyte issues.

[ Along the way we'll lose the ability to substitute ]
[ '?' for an invalid/unprintable multibyte sequence. ]
[ We will, however, replace ctrl chars with the '?'. ]

[ This presents no problem for that ps program since ]
[ it now duplicates all of the original escape code. ]
[ And, we'll no longer be executing that code twice! ]

[ As for the top program, it takes the position that ]
[ it is wrong to alter kernel supplied data. So with ]
[ potential invalid/unprintable stuff, he'll rely on ]
[ terminal emulators to properly handle such issues! ]

[ Besides, even using a proper multibyte string, not ]
[ all terminals generate the proper printable width. ]
[ This is especially true when it comes to an emoji. ]

[ And should callers chose not to be portable to all ]
[ locales by calling setlocale(LC_ALL, ""), they can ]
[ expect to see lots of "?", regardless of what this ]
[ library fixes in a faulty multibyte string anyway. ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agotop: added utf8 multibyte support to additional fields
Jim Warner [Wed, 23 Dec 2020 06:00:00 +0000 (00:00 -0600)]
top: added utf8 multibyte support to additional fields

When any process' command line contains multibyte utf8
characters, two separate display problems could arise.

1. If that COMMAND column is not displayed as the very
last field, then field(s) to the right are misaligned.

2. Even when last, should utf8 string length (not that
display length) exceed allowable screen width, it will
nonetheless suffer from improper premature truncation.

Number 1 is less of a concern since the cmdline column
is likely to always be the last field to be displayed,
if only to enable right and left scrolling provisions.

Number 2 is much more likely to occur, especially with
additional fields which might be shown before COMMAND.
Or, forest view child tasks can yield the same effect.

So, this commit will permit the correct utf8 multibyte
display regardless of field position or string length.

And, we'll bring top into line with the ps program for
additional fields potentially subject to utf8 display.

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agops: extend utf8 multibyte support to additional fields
Jim Warner [Wed, 23 Dec 2020 06:00:00 +0000 (00:00 -0600)]
ps: extend utf8 multibyte support to additional fields

Form its inception (back in May of 2011), escaped_copy
has always been a flawed function. It does not operate
on 'escaped' strings but instead treats all input as a
regular string incapable of containing utf8 sequences.

As such, it should only be used for strings guaranteed
to NOT embody multibyte characters (like SUPGIDS). For
all other strings, which could contain utf8 stuff, the
correct function should have been that escape_str guy.

So this commit changes nearly every escaped_copy call.

Reference(s):
. May 2011, original escaped_copy (cmdline, cgroup)
commit 7b0fc19e9d28380dc9790615b93bc3653d6d686e

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agolibrary: fix a potential error relating to 'exe' logic
Jim Warner [Tue, 22 Dec 2020 06:00:00 +0000 (00:00 -0600)]
library: fix a potential error relating to 'exe' logic

After 'errno' management was standardized, a couple of
fields were added to the <pids> api. Only 1 (PIDS_EXE)
involved dynamic memory and, unfortunately, it did not
conform to that expected normalized ENOMEM convention.

Reference(s):
. Jun 2018, added 'exe' to library
commit ad4269f1189d5a7d68765e291bcfa981b6731c25
. Nov 2017, standardized 'errno' management
commit 06be33b43e5ff3f2658e77ef79441ac2e970cfd7

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agolibrary: extend ITEMTABLE_DEBUG just a tad, <PIDS> api
Jim Warner [Mon, 21 Dec 2020 06:00:00 +0000 (00:00 -0600)]
library: extend ITEMTABLE_DEBUG just a tad, <PIDS> api

Under the above #define this commit now also addresses
2 additional possible toe stubbers involving 'select'.

If some readproc.h constants were uncoupled from their
pids.h enumerators a 'make check-lib' will now detect.

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agotop: add pids_item enumerator as comments to task_show
Jim Warner [Sun, 20 Dec 2020 06:00:00 +0000 (00:00 -0600)]
top: add pids_item enumerator as comments to task_show

The Fieldstab uses the full pids_item enumerator names
but also shows top's cryptic relative enumerator names
as comments. So, this commit will mirror that approach
in task_show, adding full pids_item names as comments.

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agomisc: just a couple cosmetic changes for comments only
Jim Warner [Sat, 19 Dec 2020 06:00:00 +0000 (00:00 -0600)]
misc: just a couple cosmetic changes for comments only

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agops: Stop crash if using test fields
Craig Small [Tue, 22 Dec 2020 06:50:17 +0000 (17:50 +1100)]
ps: Stop crash if using test fields

I'm not sure if anyone actually uses these things, but if you
selected test fields on the command line ps would crash.

$ ps/pscommand -o _left
Signal 11 (SEGV) caught by pscommand (3.3.11.877-0488).
/home/csmall/Projects/procps/procps/ps/.libs/pscommand:ps/display.c:66: please report this bug
Segmentation fault

Anyway, it doesn't now:
$ ps/pscommand -o pid,_left,_left2,_right,_unlimited 1
    PID LLLLLLLL L2L2L2L2 RRRRRRRRRRR U
      1 tty7     3270/tty4      59:59 [123456789-12345] <defunct>

4 years agopgrep: Remove memory leak
Craig Small [Tue, 22 Dec 2020 05:14:56 +0000 (16:14 +1100)]
pgrep: Remove memory leak

This is part of !118 where @tt.rantala found a memory leak.
The other part of !118 may come later if the performance change
is significant.

References:
 procps-ng/procps!118

4 years agoIf you use echo -e $(put sgr0)"text" - reset color attributes, it turns out the artif...
Alexandr Miasnikov [Fri, 27 Apr 2018 13:27:17 +0000 (13:27 +0000)]
If you use echo -e $(put sgr0)"text" - reset color attributes, it turns out the artifact (Btext

4 years agobuild-sys: Make pwait test dependent on pwait built
Craig Small [Tue, 22 Dec 2020 04:20:30 +0000 (15:20 +1100)]
build-sys: Make pwait test dependent on pwait built

As pwait building is conditional, testsuite should
only run pwait tests if there is a pwait binary.

4 years agomisc: Add pwait to news
Craig Small [Tue, 22 Dec 2020 04:17:58 +0000 (15:17 +1100)]
misc: Add pwait to news

New command, pwait! Waits for another process to finish just like
pgrep finds or pkill kills another process.

References:
 procps-ng/procps!97

4 years agobuild-sys: Change pwait dependency
Craig Small [Tue, 22 Dec 2020 04:16:01 +0000 (15:16 +1100)]
build-sys: Change pwait dependency

master branch uses lib/nsutils, newlib uses lib/signals

References:
 commit c8384e682c1cfb3b2dc797e0f8a3cbaaccf7a3da

4 years agoMerge branch 'awilfox/procps-utmpx-support'
Craig Small [Tue, 22 Dec 2020 03:59:47 +0000 (14:59 +1100)]
Merge branch 'awilfox/procps-utmpx-support'

References:
 procps-ng/procps!67

4 years agoMerge branch 'teknoraver/procps-master'
Craig Small [Tue, 22 Dec 2020 03:32:26 +0000 (14:32 +1100)]
Merge branch 'teknoraver/procps-master'

References:
 procps-ng/procps!83

4 years agopgrep: fix missed change
Craig Small [Tue, 22 Dec 2020 03:25:56 +0000 (14:25 +1100)]
pgrep: fix missed change

I missed one change from the commit in the master branch meaning
pgrep would not compile.

References:
 commit c8384e682c1cfb3b2dc797e0f8a3cbaaccf7a3da

4 years agomisc: Add watch extra colours to NEWS
Craig Small [Tue, 22 Dec 2020 03:13:45 +0000 (14:13 +1100)]
misc: Add watch extra colours to NEWS

4 years agoSupporting bright colors with ncurses
Nipunn Koorapati [Mon, 13 Jul 2020 02:08:26 +0000 (02:08 +0000)]
Supporting bright colors with ncurses

4 years agoAdd comments and limit to standard colors
Nipunn Koorapati [Mon, 13 Jul 2020 00:59:29 +0000 (00:59 +0000)]
Add comments and limit to standard colors

4 years agobugfix - increment endpointer when parsing color_escape_sequence
Nipunn Koorapati [Thu, 2 Jul 2020 07:45:29 +0000 (07:45 +0000)]
bugfix - increment endpointer when parsing color_escape_sequence

4 years agotestsuite: Add pwait tests
Craig Small [Tue, 22 Dec 2020 01:25:44 +0000 (12:25 +1100)]
testsuite: Add pwait tests

They're pretty simple tests but its something.

References:
  commit 09327c2b772fd7bc2762c557855e6a78b6352eb5

4 years agopgrep: add pwait
Alex Xu (Hello71) [Mon, 24 Feb 2020 03:02:59 +0000 (22:02 -0500)]
pgrep: add pwait

4 years agowatch: Support wide char ncurses on mac with enable-watch8bit
Nipunn Koorapati [Mon, 13 Jul 2020 05:08:24 +0000 (22:08 -0700)]
watch: Support wide char ncurses on mac with enable-watch8bit

Fixes #47

4 years agomisc: fix typos in manual pages
Samanta Navarro [Sat, 3 Oct 2020 11:26:22 +0000 (11:26 +0000)]
misc: fix typos in manual pages

Signed-off-by: Samanta Navarro <ferivoz@riseup.net>
4 years agopkill manpage to document '-e' option
Jan Rybar [Fri, 6 Nov 2020 14:45:56 +0000 (14:45 +0000)]
pkill manpage to document '-e' option

4 years agobuild-sys: Remove refs to old manpage
Craig Small [Tue, 22 Dec 2020 00:27:17 +0000 (11:27 +1100)]
build-sys: Remove refs to old manpage

I removed the old man pages but didn't remove their references in
the Makefile

References:
 commit a978f68c06eb1764d401fa0ffce9fb30cd55f2e4
 commit 770505ded42566b70fd0ee2cade98a317d18ac38
 commit 7246249b8c2683c13515147ff4f9dbb85ba211ae

4 years agopidof: new option to show cmdline-less PIDs (kernel workers), empty input fixed
Jan Rybar [Tue, 22 Dec 2020 00:14:41 +0000 (00:14 +0000)]
pidof: new option to show cmdline-less PIDs (kernel workers), empty input fixed

4 years agoSet TZ to avoid repeated stat("/etc/localtime")
Stephen Brennan [Fri, 20 Nov 2020 00:03:58 +0000 (16:03 -0800)]
Set TZ to avoid repeated stat("/etc/localtime")

With glibc, each time the strftime() function is used (twice per process
in a typical ps -fe run), a stat("/etc/localtime") system call is used
to determine the timezone. Not only does this add extra system call
overhead, but when multiple ps processes are trying to access this
file (or multiple glibc programs using strftime) in parallel, this can
trigger significant lock contention within the OS kernel.

Since ps is not intended to run for long periods of time as a
daemon (during which the system timezone could be altered and PS might
reasonably be expected to adapt its output), there is no benefit to
repeatedly doing this stat(). To stop this behavior, explicitly set the
TZ variable to its default value (:/etc/localtime) whenever it is unset.
glibc will then cache the stat() result.

4 years agodocs: Consistent style across watch.1
ivan tkachenko [Sun, 6 Dec 2020 11:17:23 +0000 (14:17 +0300)]
docs: Consistent style across watch.1

4 years agomisc: Document sysctl change bug
Craig Small [Mon, 21 Dec 2020 23:55:18 +0000 (10:55 +1100)]
misc: Document sysctl change bug

While sysctl did change the order of /run and /etc to match
systemd in the referenced commit, the Debian bug report that
brought it to light was not documented.

References:
 commit 24a1574f0acbe636c98ab13b439c93f7b91de697
 https://bugs.debian.org/950788

4 years agodocs: Merge procps_uptime_* into procps_misc.3
Craig Small [Mon, 21 Dec 2020 01:48:06 +0000 (12:48 +1100)]
docs: Merge procps_uptime_* into procps_misc.3

4 years agodoc: fix typo in procps_misc
Craig Small [Mon, 21 Dec 2020 01:43:00 +0000 (12:43 +1100)]
doc: fix typo in procps_misc

4 years agodocs: Merge procps_ns_* into misc
Craig Small [Mon, 21 Dec 2020 01:41:10 +0000 (12:41 +1100)]
docs: Merge procps_ns_* into misc

4 years agodocs: Merge procps_linux_version into misc
Craig Small [Mon, 21 Dec 2020 01:32:57 +0000 (12:32 +1100)]
docs: Merge procps_linux_version into misc

4 years agomisc: Add test_nsutils to gitignore
Craig Small [Thu, 17 Dec 2020 10:43:10 +0000 (21:43 +1100)]
misc: Add test_nsutils to gitignore

4 years agobuild-sys: a small tweak to the new 'check-lib' target
Jim Warner [Wed, 21 Oct 2020 05:00:00 +0000 (00:00 -0500)]
build-sys: a small tweak to the new 'check-lib' target

So as to not obscure the results from this new target,
we'll redirect that final 'make clean' output to null.

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agolibrary: a tweak to the UNREF_RPTHASH code, <pids> api
Jim Warner [Mon, 19 Oct 2020 05:00:00 +0000 (00:00 -0500)]
library: a tweak to the UNREF_RPTHASH code, <pids> api

If a hash results report is output (via UNREF_RPTHASH)
a portion is devoted to occupied table entries ordered
by depth. There is a possibility that some depths will
not be found among existing occupied table entries and
to avoid any confusion probably should not be printed.

[ to illustrate the potential for confusion prior to ]
[ this patch, force a very small table size (like 8) ]
[ & then trigger the procps_pids_unref() eoj report. ]

So this patch ensures only 'in use' entries are shown.

[ admittedly, all of the remaining logic in the loop ]
[ could/should be subordinate to this new 'if' test, ]
[ but we will keep the change to a minimum. besides, ]
[ there's no harm subtracting/adding a zero numdepth ]
[ especially since the chance of a zero is very low. ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agodocs: Add procps_misc.3 manpage
Craig Small [Sat, 24 Oct 2020 07:25:48 +0000 (18:25 +1100)]
docs: Add procps_misc.3 manpage

The last (I think) of the newlib man pages for the new API.

4 years agofree,slabtop,uptime: complain about extra ops
Craig Small [Mon, 19 Oct 2020 11:36:06 +0000 (22:36 +1100)]
free,slabtop,uptime: complain about extra ops

free, slabtop and uptime would happily take extra command line
arguments and doing nothing about them. The programs now check
optind after option processing and will give you usage screen
if there is anything extra.

References:
 procps-ng/procps#181

4 years agowatch: Add no linewrap option
Craig Small [Mon, 19 Oct 2020 11:03:44 +0000 (22:03 +1100)]
watch: Add no linewrap option

For long lines from a process, watch would wrap them around to the
next. While this default option has it uses, sometimes you want to
just cut those long lines down.

watch has a -w flag which will truncate the lines to the number
of columns. A few simple lines to do this new trick.

I think I caught all the ANSI state correctly but there might be
a chance it bleeds to the next row.

References:
 procps-ng/procps#182

4 years agobuild-sys: Build check programs only on make check
Craig Small [Mon, 19 Oct 2020 09:05:41 +0000 (20:05 +1100)]
build-sys: Build check programs only on make check

noinst_PROGRAMS are built with "make" even though we had the
test programs in there and only needed them for "make check".

In theory the check target should depend on check_PROGRAMS as
check-am target does and the document states it should, but for
reasons understood by the automake whisperers only, it doesn't
build them.

check only depends on BUILT_SOURCES for some reason.

check-am: all-am
        $(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS)
        $(MAKE) $(AM_MAKEFLAGS) check-TESTS
check: $(BUILT_SOURCES)
        $(MAKE) $(AM_MAKEFLAGS) check-recursive

References:
 https://www.gnu.org/software/automake/manual/html_node/Scripts_002dbased-Testsuites.html

4 years agobuild-sys: Add check-lib target
Craig Small [Mon, 19 Oct 2020 08:25:33 +0000 (19:25 +1100)]
build-sys: Add check-lib target

The referenced commits created the library infrastructure and test
program to validate that the structures and macros line up with
each other.

The library needs to be (re)built with -DITEMTABLE_DEBUG and then
the test program ran.  We clean before and after so we are not
testing a non-debug library or having a debug library hanging around
to cause future problems.

Due to test_Itemtables depending on the library, we don't need to
explicitly build the library.

To validate the library structure/header corrospondence run:
make check-lib

References:
 commit e616409aa497b5dc656dc7a5bd0a21adf0ee4d36
 commit 92d0297e1e4d5946c5b098e37c91c7e524a0eca0
 https://www.freelists.org/post/procps/keep-on-patchin,19

4 years agolibrary: tweak that history hash algorithm, <pids> api
Jim Warner [Thu, 1 Oct 2020 05:00:00 +0000 (00:00 -0500)]
library: tweak that history hash algorithm, <pids> api

This patch just raises the size of the hash table used
to calculate elapsed task stuff. The net result should
be less need for 'chaining' under pid hash collisions.

[ the hash scheme is intentionally kept as primitive ]
[ and, therefore, as fast as possible. it employs an ]
[ 'and' approach versus a 'mod' operation since both ]
[ yield similar distribution but the former approach ]
[ was 4 fewer cpu instructions in terms of overhead. ]

[ additionally, for hash collisions, 'chaining' uses ]
[ an array index rather than the usual pointer since ]
[ the HST_t guys may move when they are reallocated. ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agolibrary: tweak the memory allocation logic, <pids> api
Jim Warner [Wed, 30 Sep 2020 05:00:00 +0000 (00:00 -0500)]
library: tweak the memory allocation logic, <pids> api

This patch separates the memory allocations into those
used initially from those used in later reallocations.
Thus, we can reduce that iterative realloc() overhead.

Additionally, we'll correct a long standing oops where
multiple history_info structures were created at 'new'
time when only one should have been allocated (jeeze).

[ originally the allocation was strangely based upon ]
[ number of 'items' (???) & later a #define constant ]

Reference(s):
. May, 2016 - subsequent bad history_info logic
commit 9ebadc1438a6665a98a9f0782523b0f9a2a6248f
. Aug, 2015 - original faulty history_info code
commit 7e6a371d8a36b250a2edddff9f5d059640b8132e

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agops: Match on truncated 16 char for -C
Craig Small [Thu, 24 Sep 2020 12:19:11 +0000 (22:19 +1000)]
ps: Match on truncated 16 char for -C

The referenced commit the comm length was increased from 16 to 64
characters to handle the larger command names for things like kernel
threads.

However most user processes are limited to 15 characters which means
if you try something like ps -C myprogramisbiggerthansixteen this would
fail to match because /proc/<PID>/comm would only be myprogramisbigg

ps now checks the comm length and if it is 15 and if the given match
is 15 or more, it will only match the first 15 characters.

This is also how killall has worked for about a year.

Thanks to Jean Delvare <jdelvare@suse.de> for the note.

Copy of commit from master.

References:
 commit 14005a371e5c14289e96a4927ffd1a827d3c9d85
 commit psmisc/psmisc@1188315cd037d73bf946a0003b70c6423cc330d2
 commit 3e1c00d051ae4a8319df7714d0545b4b7aa81557

Signed-off-by: Craig Small <csmall@dropbear.xyz>
4 years agotop: fix additional SEGVs if no tasks were displayable
Jim Warner [Sun, 13 Sep 2020 05:00:00 +0000 (00:00 -0500)]
top: fix additional SEGVs if no tasks were displayable

This patch is an outgrowth of that commit shown below.

Many additional potential segmentation faults might be
encountered if interactive commands are opened up to a
user when a '-p' switch has a single non-existent pid.

[ always the 'k', 'L', 'r', 'Y' keys & maybe 'v' too ]

So, this patch will restrict such a loser (oops, user)
to a reduced subset of normal commands until he/she/it
quits then restarts top with something to be displayed
or issues the '=' command overriding that '-p' switch.

Reference(s):
commit d3203d99dd7f4508447ea3b4b056a9d134229d10

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agovmstat: Null the diskstats pointer
Craig Small [Sun, 13 Sep 2020 00:25:19 +0000 (10:25 +1000)]
vmstat: Null the diskstats pointer

I'm not sure why, but the make check will now fail for vmstat

Running ./vmstat.test/vmstat.exp ...
FAIL: vmstat disk information (-d option)

With the _new function returning the error.
In vmstat all other structures are set to NULL before calling _new
except the diskstat ones. This has been corrected.

4 years agotop: fix potential SEGV when no tasks were displayable
Jim Warner [Wed, 9 Sep 2020 05:00:00 +0000 (00:00 -0500)]
top: fix potential SEGV when no tasks were displayable

This patch fixes a nearly decade old bug discovered by
Frederik Deweerdt. His merge request shown below would
be an adequate solution except for iterative overhead.

This alternate patch will represent substantially less
overhead for an admittedly extremely rare possibility.

Reference(s):
https://gitlab.com/procps-ng/procps/-/merge_requests/114

And-thanks-to: Frederik Deweerdt <fdeweerdt@fastly.com>
Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agotop: update user/system cpu % graph content (man page)
Jim Warner [Tue, 8 Sep 2020 05:00:00 +0000 (00:00 -0500)]
top: update user/system cpu % graph content (man page)

What had been stated as the contents of the cpu graphs
was never really inclusive enough. Those recent newlib
tweaks highlighted the need for these man doc changes.

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agolibrary: tweak those system cpu statistics, <stat> api
Jim Warner [Tue, 8 Sep 2020 05:00:00 +0000 (00:00 -0500)]
library: tweak those system cpu statistics, <stat> api

This patch may be a little misleading in terms of size
since most of the changes just reorder a little logic.
The most significant changes involve two GUEST values.

My original implementation excluded such tics from the
TOTAL calculation and, therefore, the BUSY figure too.

That decision was erroneously based on some code found
in ./kernel/sched/cputime.c which in hindsight applies
only to processes, not those system level cpu figures.

[ another likely oops classified STOLEN tics as IDLE ]

So, this patch attempts to bring those SUM values into
better agreement with the calculations performed for a
root cgroup (see ./kernel/cgroup/rstat.c source file).

[ we differ from those above in that we also include ]
[ the IDLE plus IOWAIT tics in our TOTAL calculation ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agolibrary: eliminate unused 'FUNCTION' in private header
Jim Warner [Tue, 1 Sep 2020 05:00:00 +0000 (00:00 -0500)]
library: eliminate unused 'FUNCTION' in private header

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agobuild-sys: updated autoscan for that configure.ac file
Jim Warner [Sun, 30 Aug 2020 05:00:00 +0000 (00:00 -0500)]
build-sys: updated autoscan for that configure.ac file

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agolibrary: eliminate one potential source of human error
Jim Warner [Sat, 22 Aug 2020 05:00:00 +0000 (00:00 -0500)]
library: eliminate one potential source of human error

There's a huge toe-stubber awaiting future maintenance
as reflected in that commit below which deals with the
addition of new enumerators to the Item_table. Namely,
whenever the table is grown, one must remember to also
change that existing 'logical_end' enumerator's value.

Well, not anymore! Since that MAXTABLE macro was added
to the procps-private.h header we can now also exploit
it so a 'logical_end' automatically tracks table size.

This change also renders some code associated with the
ITEMTABLE_DEBUG #define unnecessary. So it's gone too.

Reference(s):
. 08/2016, add new enumerators
commit 09e1886c9e731f8b8c89a55d11f72f53f030b2de
. 08/2020, added MAXTABLE macro
commit c865b06c304e645c05eae0f5e06a1f49ea105285
. 08/2020, introduced ITEMTABLE_DEBUG
commit 92d0297e1e4d5946c5b098e37c91c7e524a0eca0

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agotop: even more useless cosemetic stuff (only comments)
Jim Warner [Fri, 21 Aug 2020 05:00:00 +0000 (00:00 -0500)]
top: even more useless cosemetic stuff (only comments)

[ this is what happens when i've run out of bugs and ]
[ issues and am now left with way too much free time ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agotop: more useless cosemetic changes (chiefly comments)
Jim Warner [Thu, 20 Aug 2020 05:00:00 +0000 (00:00 -0500)]
top: more useless cosemetic changes (chiefly comments)

All of these changes are self-explanatory, so I'll not
provide any more comments thus avoiding further shame.

[ everything's perfectly justified and right margins ]
[ are filled entirely, but of course it must be luck ]

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agolibrary: fix a flaw in one 'new' function, <diskstats>
Jim Warner [Wed, 19 Aug 2020 05:00:00 +0000 (00:00 -0500)]
library: fix a flaw in one 'new' function, <diskstats>

At 'new' time, the major API modules each ensure their
'info' parameter isn't NULL but what it pointed to was
except this single straggler, for some unknown reason.

So, this patch brings him into line with those others.

[ And, without going into the ugly details, this was ]
[ the reason I never experienced an abend originally ]
[ but Craig did. And, though related to stacks mgmt, ]
[ zero initialization was not a factor. Anyway, with ]
[ this patch, everybody would have experienced abend ]
[ under the original (faulty) test_Itemtables logic! ]

Reference(s):
https://www.freelists.org/post/procps/keep-on-patchin,13

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agobuild-sys: proper fix for the 'test_Itemtables' module
Jim Warner [Mon, 17 Aug 2020 17:12:12 +0000 (12:12 -0500)]
build-sys: proper fix for the 'test_Itemtables' module

Me thinks Craig had the right idea but perhaps not the
most correct solution. As currently structured, all of
the tests now go way too far by checking every 'unref'
and 'new' call when what we're trying for is survival.

In the final analysis, it doesn't matter who issues an
EXIT_FAILURE - that run_tests guy or an early Exit out
of a procps_new() function. They both will produce the
same end result of the desired "FAIL" test diagnostic.

[ and this patch once again allows the slabinfo test ]

Reference(s):
commit 4eeed6dcff8b3bf3930eb1998738b5c6d458f0c1

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agobuild-sys: Check return values and NULL ctx
Craig Small [Mon, 17 Aug 2020 12:47:39 +0000 (22:47 +1000)]
build-sys: Check return values and NULL ctx

The referenced commit introduced a test program for the API
but it would often fail due to:
  The given pointer for _new() not being NULL
  The return value for _new not checked, so the subsequent _unref()
  would free() random memory
  slabinfo checks failing due to permission denied errors.

The first two are fixed, as well as returning a fail to the test
if they don't return correctly, with slabinfo waiting to see if there
is a way of initialising the structure without reading the slabinfo.

References:
 commit e616409aa497b5dc656dc7a5bd0a21adf0ee4d36

Signed-off-by: Craig Small <csmall@dropbear.xyz>
4 years agobuild-sys: added a 'test_Itemtables' to testing scheme
Jim Warner [Sat, 15 Aug 2020 17:12:12 +0000 (12:12 -0500)]
build-sys: added a 'test_Itemtables' to testing scheme

This change sets the stage for exploiting the recently
added ITEMTABLE_DEBUG #define. All tests are performed
in a single module (after trying 6 separate programs).

The chances of each test detecting errors is extremely
remote (at least while I'm maintaining these modules).
However, this single program approach has one flaw and
it relates to the response whenever an error is found.

Each of those six new API modules calls Exit() if they
detect an error. Otherwise, incorrect results would be
produced at the least or an abend encountered at most.

This means that multiple 'make check' invocations will
be needed if more than 1 module actually was in error.

All in all, it is a small price for a large assurance.

Reference(s):
https://www.freelists.org/post/procps/keep-on-patchin,7

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agobuild-sys: fix some important 'tests.h' related issues
Jim Warner [Sat, 15 Aug 2020 16:11:11 +0000 (11:11 -0500)]
build-sys: fix some important 'tests.h' related issues

Exploiting a header file shouldn't also force users to
code their own '#include <stdio.h>'. More importantly,
unless this header is mentioned in dist_noinst_HEADERS
we'd fail 'make distcheck' with the error shown below.

[ the same error will apply to all 'noinst_PROGRAMS' ]
[ that happen to use this header. but please, do not ]
[ ask me to explain exactly why or how my fix works! ]

Reference(s):
../../proc/test_pids.c:24:10: fatal error: tests.h: No such file or directory
   24 | #include "tests.h"
      |          ^~~~~~~~~

Signed-off-by: Jim Warner <james.warner@comcast.net>
4 years agobuild-sys: tweak make & activate some overlooked tests
Jim Warner [Sat, 15 Aug 2020 15:10:10 +0000 (10:10 -0500)]
build-sys: tweak make & activate some overlooked tests

This commit is just preparing for adding an Itemtables
verification test by reorganizing stuff and activating
a few previously inactive (overlooked?) test programs.

Signed-off-by: Jim Warner <james.warner@comcast.net>