Commit 00a6c491 authored by Darek Stojaczyk's avatar Darek Stojaczyk Committed by Ben Walker
Browse files

configure: try harder to parse nasm version



Nasm doesn't always include the patch version in its
version string and we currently detect 2.14 as older
than 2.13.03. Fix it by checking the major and minor
version numbers separately.

Change-Id: I37d1129775b17d252b84a911ee1c849f4f0e2ec7
Reported-by: default avatarJames Bergsten <jamesx.bergsten@intel.com>
Signed-off-by: default avatarDarek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/452533


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
Reviewed-by: default avatarShuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
parent 7685a48f
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -432,7 +432,8 @@ than or equal to 4.14 will see significantly reduced performance.
fi

if [[ "${CONFIG[ISAL]}" = "y" ]] || [[ "${CONFIG[CRYPTO]}" = "y" ]]; then
	if [[ $(nasm -v | awk '{print $3}' | sed 's/[^0-9]*//g') -lt "21303" ]]; then
	ver=$(nasm -v | awk '{print $3}' | sed 's/[^0-9]*//g')
	if [[ "${ver:0:1}" -le "2" ]] && [[ "${ver:0:3}" -le "213" ]] && [[ "${ver:0:5}" -lt "21303" ]]; then
		echo "Notice: ISA-L, compression & crypto auto-disabled due to nasm dependency."
		echo "These features require NASM version 2.13.03 or newer.  Please install"
		echo "or upgrade then re-run this script."