From cc3fb685ac370a368cb84480117be13d109eebf0 Mon Sep 17 00:00:00 2001 From: Simon Josefsson Date: Thu, 31 Oct 2024 13:10:34 +0100 Subject: [PATCH] crc: make it a maintainer setting rather than a user setting. * m4/crc.m4 (gl_CRC_SLICE_BY_8): Drop AC_ARG_ENABLE. --- ChangeLog | 5 +++++ m4/crc.m4 | 23 +++++++++++++---------- 2 files changed, 18 insertions(+), 10 deletions(-) diff --git a/ChangeLog b/ChangeLog index 42367f8135..b0719c23bf 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2024-10-31 Simon Josefsson + + crc: make it a maintainer setting rather than a user setting. + * m4/crc.m4 (gl_CRC_SLICE_BY_8): Drop AC_ARG_ENABLE. + 2024-10-27 Sam Russell crc: New optimised slice-by-8 implementation diff --git a/m4/crc.m4 b/m4/crc.m4 index 0007b7274e..f62987e78e 100644 --- a/m4/crc.m4 +++ b/m4/crc.m4 @@ -1,22 +1,25 @@ # crc.m4 -# serial 3 -dnl Copyright (C) 2024-2024 Free Software Foundation, Inc. +# serial 4 +dnl Copyright (C) 2024 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. dnl This file is offered as-is, without any warranty. +# For use by maintainer's after gl_EARLY in configure.ac. +AC_DEFUN([gl_DISABLE_CRC_SLICE_BY_8], +[ + gl_crc_slice_by_8=no +]) + AC_DEFUN([gl_CRC_SLICE_BY_8], [ AC_MSG_CHECKING([whether to enable CRC slice-by-8 algorithm]) - AC_ARG_ENABLE([crc-slice-by-8], - [AS_HELP_STRING([[--disable-crc-slice-by-8]], - [disable CRC slice-by-8 algorithm])], - [enable_crc_slice_by_8=$enableval], - [enable_crc_slice_by_8=yes]) - - if test $enable_crc_slice_by_8 = yes; then + if test x"$gl_crc_slice_by_8" != x"no"; then + AC_MSG_RESULT([yes]) AC_DEFINE([GL_CRC_SLICE_BY_8], [1], - [Define to get faster but larger CRC32 operation.]) + [Define to get faster but larger CRC32 operation.]) + else + AC_MSG_RESULT([no]) fi ]) -- 2.39.5