pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkg/57272: devel/cmake: incorrect ps(1) command selected on sparc



>Number:         57272
>Category:       pkg
>Synopsis:       devel/cmake: incorrect ps(1) command selected on sparc
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Mar 15 22:00:01 +0000 2023
>Originator:     Valery Ushakov
>Release:        pkgsrc-2022Q4
>Organization:
>Environment:
NetBSD aurinko 10.99.2 NetBSD 10.99.2 (GENERIC) #0: Tue Mar 14 02:29:01 MSK 2023  uwe@sampo:/home/uwe/work/netbsd/cvs/src/sys/arch/sparc/compile/GENERIC sparc

>Description:
cmake built on NetBSD/sparc picks up wrong ps(1) invocation.

Trying to run cmake on self (the language) I get:

...
-- Preparing for NetBSD on sparc
ps: unknown option -- f
usage:  ps [-AaCcdehjlmrSsTuvwx] [-G group] [-k key] [-M core] [-N system]
           [-O fmt] [-o fmt] [-p pid] [-t tty] [-U user] [-W swap]
        ps -L

The problem is in Source/kwsys/ProcessUNIX.c:2485 where
KWSYSPE_PS_COMMAND macro is defined.

There is no case that handles NetBSD, so a case further down the #if
tree is picked up (b/c of __sparc).

>How-To-Repeat:
Build cmake on sparc.  I don't know anything about cmake.
Get a copy of https://github.com/nbuwe/self/tree/feature/netbsd-macppc
and do e.g.

  $ cmake -B build -DCMAKE_BUILD_TYPE=Debug .

>Fix:
Explicitly handle NetBSD in that #if



Home | Main Index | Thread Index | Old Index