+ case "${usergroup_phase}" in
+ local run_cmd
+ run_cmd=run_su
+ shift
+ run_su /opt/pkg/bin/bmake configure BATCH=1 DEPENDS_TARGET=/nonexistent WRKLOG=/tmp/bulklog/openocd-0.12.0/work.log
+ su pbulk -c '"$@"' make /opt/pkg/bin/bmake configure BATCH=1 DEPENDS_TARGET=/nonexistent WRKLOG=/tmp/bulklog/openocd-0.12.0/work.log
=> Bootstrap dependency digest>=20211023: found digest-20220214
=> Checksum BLAKE2s OK for openocd-0.12.0.tar.bz2
=> Checksum SHA512 OK for openocd-0.12.0.tar.bz2
===> Installing dependencies for openocd-0.12.0
==========================================================================
The supported build options for openocd are:

	capstone libftdi1 libhidapi libusb libusb1

The currently selected options are:

	capstone libftdi1 libhidapi libusb libusb1

You can select which build options to use by setting PKG_DEFAULT_OPTIONS
or the following variable.  Its current value is shown:

	PKG_OPTIONS.openocd (not defined)

==========================================================================
==========================================================================
The following variables will affect the build process of this package,
openocd-0.12.0.  Their current value is shown below:

        * LIBUSB_TYPE = compat

You may want to abort the process now with CTRL-C and change the value
of variables in the first group before continuing.  Be sure to run
`/opt/pkg/bin/bmake clean' after the changes.
==========================================================================
=> Tool dependency libtool-base>=2.4.2nb9: found libtool-base-2.4.7nb1
=> Tool dependency mktools-[0-9]*: found mktools-20220614
=> Tool dependency gmake>=3.81: found gmake-4.4.1
=> Tool dependency pkgconf-[0-9]*: found pkgconf-2.2.0
=> Tool dependency cwrappers>=20150314: found cwrappers-20220403
=> Tool dependency checkperms>=1.1: found checkperms-1.12
=> Full dependency pkg_install-info-[0-9]*: found pkg_install-info-4.5nb3
=> Full dependency libhidapi>=0.13.1: found libhidapi-0.14.0
=> Full dependency libusb1>=1.0.9: found libusb1-1.0.27
=> Full dependency libusb-compat>=0.1.6rc2: found libusb-compat-0.1.8
=> Full dependency libftdi1>=1.5nb7: found libftdi1-1.5nb8
=> Full dependency capstone>=3.0: found capstone-5.0.1
=> Full dependency jimtcl>=0.80nb1: found jimtcl-0.82nb3
===> Overriding tools for openocd-0.12.0
===> Extracting for openocd-0.12.0
===> Patching for openocd-0.12.0
=> Applying pkgsrc patches for openocd-0.12.0
=> Verifying /data/jenkins/workspace/pkgsrc-upstream-bulktest/devel/openocd/patches/patch-Makefile.in
=> Applying pkgsrc patch /data/jenkins/workspace/pkgsrc-upstream-bulktest/devel/openocd/patches/patch-Makefile.in
Hmm...  Looks like a unified diff to me...
The text leading up to this was:
--------------------------
|$NetBSD: patch-Makefile.in,v 1.1 2021/05/06 15:31:13 tnn Exp $
|
|use pkg-config to find libjim.so
|
|--- Makefile.in.orig	2021-03-07 11:02:20.000000000 +0000
|+++ Makefile.in
--------------------------
Patching file Makefile.in using Plan A...
Hunk #1 succeeded at 143 (offset 46 lines).
done
=> Verifying /data/jenkins/workspace/pkgsrc-upstream-bulktest/devel/openocd/patches/patch-configure
=> Applying pkgsrc patch /data/jenkins/workspace/pkgsrc-upstream-bulktest/devel/openocd/patches/patch-configure
Hmm...  Looks like a unified diff to me...
The text leading up to this was:
--------------------------
|$NetBSD: patch-configure,v 1.2 2023/05/17 15:29:13 nikita Exp $
|
|Fix build on Linux.
|CONFIG_SHELL should ensure that "echo -e" works but for some reason this part
|of the script gets executed with the wrong shell.
|
|--- configure.orig	2023-01-14 21:32:26.000000000 +0100
|+++ configure	2023-05-17 17:19:52.560370134 +0200
--------------------------
Patching file configure using Plan A...
Hunk #1 succeeded at 14787.
Hunk #2 succeeded at 15045.
Hunk #3 succeeded at 16515.
Hunk #4 succeeded at 17819.
done
=> Verifying /data/jenkins/workspace/pkgsrc-upstream-bulktest/devel/openocd/patches/patch-src_flash_nor_fm4.c
=> Applying pkgsrc patch /data/jenkins/workspace/pkgsrc-upstream-bulktest/devel/openocd/patches/patch-src_flash_nor_fm4.c
Hmm...  Looks like a unified diff to me...
The text leading up to this was:
--------------------------
|$NetBSD: patch-src_flash_nor_fm4.c,v 1.1 2018/03/13 03:01:15 dholland Exp $
|
|Fix ctype.h misuse.
|
|--- src/flash/nor/fm4.c~	2016-12-25 14:12:54.000000000 +0000
|+++ src/flash/nor/fm4.c
--------------------------
Patching file src/flash/nor/fm4.c using Plan A...
Hunk #1 succeeded at 605 (offset -4 lines).
done
===> Creating toolchain wrappers for openocd-0.12.0
===> Configuring for openocd-0.12.0
=> Modifying GNU configure scripts to avoid --recheck
=> Replacing config-guess with pkgsrc versions
=> Replacing config-sub with pkgsrc versions
=> Replacing install-sh with pkgsrc version
=> Checking for portability problems in extracted files
checking for makeinfo... /home/pbulk/build/devel/openocd/work/.tools/bin/makeinfo
checking for a BSD-compatible install... /opt/pkg/bin/bsdinstall -c -o pbulk -g pbulk
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... build-aux/install-sh -c -d
checking for gawk... /usr/bin/nawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for x86_64-sun-solaris2.11-gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether gcc understands -c and -o together... yes
checking whether make supports the include directive... yes (GNU style)
checking dependency style of gcc... gcc3
checking for gcc option to accept ISO C99... none needed
checking for x86_64-sun-solaris2.11-ranlib... no
checking for ranlib... ranlib
checking pkg-config is at least version 0.23... yes
checking build system type... x86_64-sun-solaris2.11
checking host system type... x86_64-sun-solaris2.11
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... (cached) /usr/xpg4/bin/grep
checking for egrep... (cached) /usr/xpg4/bin/grep -E
checking for fgrep... /usr/xpg4/bin/grep -F
checking for ld used by gcc... /bin/ld
checking if the linker (/bin/ld) is GNU ld... no
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -p
checking the name lister (/usr/bin/nm -p) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 786240
checking how to convert x86_64-sun-solaris2.11 file names to x86_64-sun-solaris2.11 format... func_convert_file_noop
checking how to convert x86_64-sun-solaris2.11 file names to toolchain format... func_convert_file_noop
checking for /bin/ld option to reload object files... -r
checking for x86_64-sun-solaris2.11-objdump... no
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for x86_64-sun-solaris2.11-dlltool... no
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for x86_64-sun-solaris2.11-ar... no
checking for ar... ar
checking for archiver @FILE support... no
checking for x86_64-sun-solaris2.11-strip... no
checking for strip... strip
checking for x86_64-sun-solaris2.11-ranlib... ranlib
checking command to parse /usr/bin/nm -p output from gcc object... ok
checking for sysroot... no
checking for a working dd... /usr/bin/dd
checking how to truncate binary pipes... /usr/bin/dd bs=4096 count=1
checking for x86_64-sun-solaris2.11-mt... no
checking for mt... mt
checking if mt is a manifest tool... no
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... no
checking if gcc supports -c -o file.o... rm: conftest*: No such file or directory
yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/bin/ld -64) supports shared libraries... yes
checking dynamic linker characteristics... solaris2.11 ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... no
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... no
checking whether to build static libraries... yes
checking for an ANSI C-conforming const... yes
checking for unsigned long long int... yes
checking for long long int... yes
checking for library containing ioperm... no
checking for library containing dlopen... none required
checking for library containing openpty... no
checking sys/socket.h usability... yes
checking sys/socket.h presence... yes
checking for sys/socket.h... yes
checking elf.h usability... yes
checking elf.h presence... yes
checking for elf.h... yes
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking malloc.h usability... yes
checking malloc.h presence... yes
checking for malloc.h... yes
checking netdb.h usability... yes
checking netdb.h presence... yes
checking for netdb.h... yes
checking poll.h usability... yes
checking poll.h presence... yes
checking for poll.h... yes
checking for strings.h... (cached) yes
checking sys/ioctl.h usability... yes
checking sys/ioctl.h presence... yes
checking for sys/ioctl.h... yes
checking sys/param.h usability... yes
checking sys/param.h presence... yes
checking for sys/param.h... yes
checking sys/select.h usability... yes
checking sys/select.h presence... yes
checking for sys/select.h... yes
checking for sys/stat.h... (cached) yes
checking sys/sysctl.h usability... no
checking sys/sysctl.h presence... no
checking for sys/sysctl.h... no
checking sys/time.h usability... yes
checking sys/time.h presence... yes
checking for sys/time.h... yes
checking for sys/types.h... (cached) yes
checking for unistd.h... (cached) yes
checking for arpa/inet.h... yes
checking for netinet/in.h... yes
checking for netinet/tcp.h... yes
checking whether to enable assertions... yes
checking for stdbool.h that conforms to C99... yes
checking for _Bool... yes
checking whether byte ordering is bigendian... no
checking for strndup... yes
checking for strnlen... yes
checking for gettimeofday... yes
checking for usleep... yes
checking for realpath... yes
checking whether to build a release... yes
checking whether to build Doxygen as HTML... yes
checking whether to build Doxygen as PDF... no
checking whether to enable verbose USB I/O messages... no
checking whether to enable verbose USB communication messages... no
checking whether to enable malloc free space logging... no
checking for libusb-1.0... yes
configure: libusb-1.0 header bug workaround: LIBUSB1_CFLAGS changed to "-isystem /opt/pkg/include/libusb-1.0"
checking for capstone... yes
checking for hidapi... no
checking for hidapi-hidraw... no
checking for hidapi-libusb... yes
checking for libftdi1... yes
checking for libgpiod... no
checking for libjaylink >= 0.2... no
checking for environ in unistd.h and stdlib.h... no
checking for extern environ... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing libtool commands
rm: libtoolT: No such file or directory
=== configuring in src/jtag/drivers/libjaylink (/home/pbulk/build/devel/openocd/work/openocd-0.12.0/src/jtag/drivers/libjaylink)
configure: running /usr/bin/bash ./configure.gnu --disable-option-checking '--prefix=/opt/pkg'  '--disable-internal-jimtcl' '--build=x86_64-sun-solaris2.11' '--host=x86_64-sun-solaris2.11' '--infodir=/opt/pkg/info' '--mandir=/opt/pkg/share/man' '--enable-option-checking=yes' 'build_alias=x86_64-sun-solaris2.11' 'host_alias=x86_64-sun-solaris2.11' 'CC=gcc' 'CFLAGS=-pipe -O2 -msave-args -fno-aggressive-loop-optimizations -I/opt/pkg/include -I/usr/include' 'LDFLAGS=-L/opt/pkg/lib -Wl,-R/opt/pkg/lib -L/usr/lib/amd64 -Wl,-R/usr/lib/amd64' 'LIBS=' 'CPPFLAGS=-I/opt/pkg/include -I/usr/include' 'PKG_CONFIG=/home/pbulk/build/devel/openocd/work/.tools/bin/pkg-config' 'PKG_CONFIG_PATH=' 'PKG_CONFIG_LIBDIR=/home/pbulk/build/devel/openocd/work/.buildlink/lib/amd64/pkgconfig:/home/pbulk/build/devel/openocd/work/.buildlink/lib/pkgconfig:/home/pbulk/build/devel/openocd/work/.buildlink/share/pkgconfig' --cache-file=/dev/null --srcdir=.
configure: WARNING: unrecognized options: --disable-internal-jimtcl
checking build system type... x86_64-sun-solaris2.11
checking host system type... x86_64-sun-solaris2.11
checking for a BSD-compatible install... /opt/pkg/bin/bsdinstall -c -o pbulk -g pbulk
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... build-aux/install-sh -c -d
checking for gawk... /usr/bin/nawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for x86_64-sun-solaris2.11-gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether gcc understands -c and -o together... yes
checking whether make supports the include directive... yes (GNU style)
checking dependency style of gcc... gcc3
checking for gcc option to accept ISO C99... none needed
checking for x86_64-sun-solaris2.11-ar... no
checking for x86_64-sun-solaris2.11-lib... no
checking for x86_64-sun-solaris2.11-link... no
checking for ar... ar
checking the archiver (ar) interface... ar
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... (cached) /usr/xpg4/bin/grep
checking for egrep... (cached) /usr/xpg4/bin/grep -E
checking for fgrep... /usr/xpg4/bin/grep -F
checking for ld used by gcc... /bin/ld
checking if the linker (/bin/ld) is GNU ld... no
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -p
checking the name lister (/usr/bin/nm -p) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 786240
checking how to convert x86_64-sun-solaris2.11 file names to x86_64-sun-solaris2.11 format... func_convert_file_noop
checking how to convert x86_64-sun-solaris2.11 file names to toolchain format... func_convert_file_noop
checking for /bin/ld option to reload object files... -r
checking for x86_64-sun-solaris2.11-objdump... no
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for x86_64-sun-solaris2.11-dlltool... no
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for x86_64-sun-solaris2.11-ar... ar
checking for archiver @FILE support... no
checking for x86_64-sun-solaris2.11-strip... no
checking for strip... strip
checking for x86_64-sun-solaris2.11-ranlib... no
checking for ranlib... ranlib
checking command to parse /usr/bin/nm -p output from gcc object... ok
checking for sysroot... no
checking for a working dd... /usr/bin/dd
checking how to truncate binary pipes... /usr/bin/dd bs=4096 count=1
checking for x86_64-sun-solaris2.11-mt... no
checking for mt... mt
checking if mt is a manifest tool... no
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... no
checking if gcc supports -c -o file.o... rm: conftest*: No such file or directory
yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/bin/ld -64) supports shared libraries... yes
checking whether -lc should be explicitly linked in... rm: conftest*: No such file or directory
no
checking dynamic linker characteristics... solaris2.11 ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... no
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking pkg-config is at least version 0.9.0... yes
checking for libusb-1.0 >= 1.0.16... yes
checking whether byte ordering is bigendian... no
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating libjaylink/Makefile
config.status: creating libjaylink/version.h
config.status: creating libjaylink.pc
config.status: creating Doxyfile
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing libtool commands
rm: libtoolT: No such file or directory
configure: WARNING: unrecognized options: --disable-internal-jimtcl

libjaylink configuration summary:
 - Package version ................ 0.3.1
 - Library version ................ 2:0:2
 - Installation prefix ............ /opt/pkg
 - Building on .................... x86_64-sun-solaris2.11
 - Building for ................... x86_64-sun-solaris2.11

Enabled transports:
 - USB ............................ yes
 - TCP ............................ yes



OpenOCD configuration summary
--------------------------------------------------
MPSSE mode of FTDI based devices        yes (auto)
ST-Link Programmer                      yes (auto)
TI ICDI JTAG Programmer                 yes (auto)
Keil ULINK JTAG Programmer              yes (auto)
Altera USB-Blaster II Compatible        yes (auto)
Bitbang mode of FT232R based devices    yes (auto)
Versaloon-Link JTAG Programmer          yes (auto)
TI XDS110 Debug Probe                   yes (auto)
CMSIS-DAP v2 Compliant Debugger         yes (auto)
OSBDM (JTAG only) Programmer            yes (auto)
eStick/opendous JTAG Programmer         yes (auto)
Olimex ARM-JTAG-EW Programmer           yes (auto)
Raisonance RLink JTAG Programmer        yes (auto)
USBProg JTAG Programmer                 yes (auto)
Espressif JTAG Programmer               yes (auto)
Andes JTAG Programmer (deprecated)      no
CMSIS-DAP Compliant Debugger            yes (auto)
Nu-Link Programmer                      yes (auto)
Cypress KitProg Programmer              yes (auto)
Altera USB-Blaster Compatible           yes (auto)
ASIX Presto Adapter                     yes (auto)
OpenJTAG Adapter                        yes (auto)
Linux GPIO bitbang through libgpiod     no
SEGGER J-Link Programmer                yes (auto)
Bus Pirate                              yes (auto)
Use Capstone disassembly framework      yes (auto)

=> Modifying libtool scripts to use pkgsrc libtool
=> Modifying libtool scripts to use pkgsrc depcomp