Portable mktemp calls in the tests

Timur I. Bakeyev timur at freebsd.org
Fri Dec 22 01:49:48 UTC 2017


Here is another piece of puzzle of making samba autobuild work out of the
box on FreeBSD.

There are plenty of places in the tests where 'mktemp` is called with
'--tempdir' or '-p' parameter, which are not recognized on FreeBSD(and,
possibly other Unix-like platforms).

This call can be safely replaced with the sequence:

$(TMPDIR="$TEST_VAR_DIR" mktemp -d)

Also, 'sha1sum' on FreeBSD is called just 'sha1', as well as there are
'md5' and 'sha256' commands instead of *sum variants.

So, second patch allows to set environment variable that would override
the name of the sha1sum command.

With regards,
Timur Bakeyev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Made-calls-to-mktemp-compatiable-with-FreeBSD.patch
Type: application/octet-stream
Size: 11295 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20171222/1516662a/0001-Made-calls-to-mktemp-compatiable-with-FreeBSD.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-Allow-to-set-sha1sum-command-name-through-the-enviro.patch
Type: application/octet-stream
Size: 1091 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20171222/1516662a/0002-Allow-to-set-sha1sum-command-name-through-the-enviro.obj>


More information about the samba-technical mailing list