lint: Make lint work on Darwin
Darwin's getopt does not support the same parameters as the util-linux version and so it is not possible to commit any changes because lint fails. Change-Id: Ife26083d2de080af9ed3d509945720051ca14bd7 Signed-off-by: Stefan Reinauer <stefan.reinauer@coreboot.org> Reviewed-on: https://review.coreboot.org/c/coreboot/+/80436 Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
committed by
Felix Singer
parent
343ef6fc3f
commit
98ecb1612c
@@ -29,7 +29,14 @@ junit_write () {
|
||||
fi
|
||||
}
|
||||
|
||||
if ! cmd_args="$(getopt -l help,junit,invert -o hIJ -- "$@")"; then
|
||||
# Look if we have getopt. If not, build it.
|
||||
if [ $(uname) == Darwin ]; then
|
||||
GETOPT="getopt hIJ"
|
||||
else
|
||||
GETOPT="getopt -l help,junit,invert -o hIJ"
|
||||
fi
|
||||
|
||||
if ! cmd_args="$($GETOPT -- "$@")"; then
|
||||
usage
|
||||
exit 0
|
||||
fi
|
||||
|
Reference in New Issue
Block a user