+ case "${usergroup_phase}" in
+ local run_cmd
+ run_cmd=run_su
+ shift
+ run_su /usr/pkg/bin/bmake all BATCH=1 DEPENDS_TARGET=/nonexistent WRKLOG=/tmp/bulklog/lockf-1/work.log
+ su pbulk -c '"$@"' make /usr/pkg/bin/bmake all BATCH=1 DEPENDS_TARGET=/nonexistent WRKLOG=/tmp/bulklog/lockf-1/work.log
===> Building for lockf-1
cd /home/pbulk/build/sysutils/lockf/work;  echo "cc -o lockf lockf.c";  cc  -pipe -O2     -Wl,-zrelro -Wl,-R/usr/pkg/lib -o lockf lockf.c
cc -o lockf lockf.c
lockf.c: In function ‘acquire_lock’:
lockf.c:167:40: error: ‘O_EXLOCK’ undeclared (first use in this function)
  if ((fd = open(name, O_RDONLY|O_CREAT|O_EXLOCK|flags, 0666)) == -1) {
                                        ^
lockf.c:167:40: note: each undeclared identifier is reported only once for each function it appears in
lockf.c: At top level:
lockf.c:206:17: error: expected ‘;’, ‘,’ or ‘)’ before ‘__unused’
 timeout(int sig __unused)
                 ^
lockf.c: In function ‘wait_for_lock’:
lockf.c:230:32: error: ‘O_EXLOCK’ undeclared (first use in this function)
  if ((fd = open(name, O_RDONLY|O_EXLOCK, 0666)) == -1) {
                                ^
lockf.c: At top level:
lockf.c:43:13: warning: ‘timeout’ used but never defined [enabled by default]
 static void timeout(int sig);
             ^
*** Error code 1

Stop.
bmake[1]: stopped in /data/jenkins/workspace/pkgsrc-el7-trunk-x86_64/sysutils/lockf
*** Error code 1

Stop.
bmake: stopped in /data/jenkins/workspace/pkgsrc-el7-trunk-x86_64/sysutils/lockf