If file is not executable then continue to the next file. Do not go any further with this file. Not a big deal here. However it seems this simple test does not behave as it should on Solaris 10 :if [ ! -x "$file" ];thencontinue;fi;
[root@zone2 pkg]$ echo $SHELL/usr/bin/bash[root@zone2 pkg]$ ls -lh /root/whatever-rw-r--r-- 1 root root 0 Mar 22 20:42 /root/whatever[root@zone2 pkg]$ if test -x /root/whatever;then echo file is executable; else echo file is not executable; fifile is executable
# echo $SHELL/usr/bin/ksh# ls -lh /root/whatever-rw-r--r-- 1 root root 0 Mar 22 20:42 /root/whatever# if test -x /root/whatever;then echo file is executable; else echo file is not executable; fifile is not executable
TOOLS_PLATFORM.sh?= /opt/csw/bin/bashTOOLS_PLATFORM.bash?= /opt/csw/bin/bash
Hi,actually there is no empty files... there is simply no files at all :[root@zone2 perl5]$ ls -lh /var/tmp/pkgbuild/lang/perl5/work/.errortotal 0[root@zone2 perl5]$ ls -lh /var/tmp/pkgbuild/lang/perl5/work/.warningtotal 0However there is something there :I'll try to take a look to mk/bsd.pkg.mk.[root@zone2 perl5]$ cat /var/tmp/pkgbuild/lang/perl5/work/.error-done/_check-interpreter[check-interpreter.mk] The interpreter "perl" of "/var/tmp/pkgbuild/lang/perl5/work/.destdir/usr/pkg/lib/perl5/5.28.0/Math/BigFloat/Trace.pm" does not exist.[check-interpreter.mk] The interpreter "perl" of "/var/tmp/pkgbuild/lang/perl5/work/.destdir/usr/pkg/lib/perl5/5.28.0/Math/BigInt/Trace.pm" does not exist.[root@zone2 perl5]$ head -1 "/var/tmp/pkgbuild/lang/perl5/work/.destdir/usr/pkg/lib/perl5/5.28.0/Math/BigInt/Trace.pm"#!perl[root@zone2 perl5]$ head -1 "/var/tmp/pkgbuild/lang/perl5/work/.destdir/usr/pkg/lib/perl5/5.28.0/Math/BigFloat/Trace.pm"#!perlOn Thu, Feb 28, 2019 at 3:20 PM Roland Illig <roland.illig%gmx.de@localhost> wrote:
Am 25.02.2019 um 18:15 schrieb Julien Savard:
> cd /var/tmp/pkgbuild/lang/perl5/work/.error;
> for file in ./*; do
> test "$file" != "./*" || exit 0;
> break; done;
> /usr/bin/cat * |
> /usr/pkg/bin/nbsed -e "s|^|ERROR: |" 1>&2;
> if /usr/pkg/bin/nawk 'END { exit (NR > 0) ? 0 : 1; }'
> ./*; then /usr/bin/mv -f ./*
> /var/tmp/pkgbuild/lang/perl5/work/.error-done;
> exit 1; fi
> *** Error code 1
Please have a look at the files in
/var/tmp/pkgbuild/lang/perl5/work/.error and
/var/tmp/pkgbuild/lang/perl5/work/.warning. I suspect that there is an
empty file there.
These files are created by ${ERROR_MSG}, ${FAIL_MSG} and ${WARNING_MSG}.
These commands are defined in mk/bsd.pkg.mk. To further analyze this,
you may override these with a custom command that pauses until you press
Enter. Then you will see exactly at which point these files are written.
The actual cause might be an error message that has a shell redirection
in it, such as:
${ERROR_MSG} Cannot continue -> stopping.
This would interpret the ">" as a shell redirection. That's my first
guess, it may also be something entirely different.
Best,
Roland