Build fails on Solaris 10 (pkgsrc) with missing libproc.h
Building on Solaris 10, using gcc-9.3.0, fails with the following:
depbase=`echo AvailableColumnsPanel.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; gcc -DHAVE_CONFIG_H -I. -DNDEBUG -I/usr/pkg/include/ncurses -I/usr/pkg/include -std=c99 -pedantic -Wall -Wcast-align -Wcast-qual -Wextra -Wfloat-equal -Wformat=2 -Winit-self -Wmissing-format-attribute -Wmissing-noreturn -Wmissing-prototypes -Wpointer-arith -Wshadow -Wstrict-prototypes -Wundef -Wunused -Wwrite-strings -Wnull-dereference -D_XOPEN_SOURCE_EXTENDED -DSYSCONFDIR="\"/usr/pkg/etc\"" -I"./solaris" -O2 -I/usr/pkg/include/ncurses -I/usr/pkg/include -MT AvailableColumnsPanel.o -MD -MP -MF $depbase.Tpo -c -o AvailableColumnsPanel.o AvailableColumnsPanel.c && mv -f $depbase.Tpo $depbase.Po
In file included from AvailableColumnsPanel.c:23:
./solaris/Platform.h:18:10: fatal error: libproc.h: No such file or directory
18 | #include <libproc.h>
| ^~~~~~~~~~~
compilation terminated.
*** Error code 1
Stop.
bmake[1]: stopped making "all-am" in /export/home/ajacocks/src/pkgsrc/sysutils/htop/work/htop-3.3.0
*** Error code 1
Stop.
bmake: stopped making "all" in /export/home/ajacocks/src/pkgsrc/sysutils/htop/work/htop-3.3.0
*** Error code 1
Stop.
bmake[1]: stopped making "install" in /export/home/ajacocks/src/pkgsrc/sysutils/htop
*** Error code 1
Stop.
bmake: stopped making "install" in /export/home/ajacocks/src/pkgsrc/sysutils/htop
I searched for libproc.h, but I found a bunch of references to libproc.h being a private header on Solaris.
I've attached the entire build log, below:
Seems to be a pkgsrc issue.
Building the git tip with ./autogen.sh && ./configure --enable-debug && make -j 8 works.
Interesting. I’ll dig deeper into it and see what I can find.
@ajacocks Any updates on this? Were you able to find something?
Not yet.
I just ran into this issue on my Sun Blade 100. I've tried to search a bit and it seems, that libproc.h was a private header and it is not part of the distro: https://github.com/nodejs/node-v0.x-archive/issues/6439#issuecomment-122389758
I've found the file in the source of dtrace4linux (https://github.com/dtrace4linux/linux/blob/master/libproc/common/libproc.h) and there is even a warning about linking to this header file is not recommended, because it is not a public interface.
Node.js solved it by adding the --without-mdb flag: https://github.com/nodejs/node-v0.x-archive/commit/8b81f98c41158856c09b57afc4cf879e9b65efe9
Perhaps this could be done in htop as well?