From: Amos Jeffries Date: Wed, 29 Jul 2015 03:29:17 +0000 (-0700) Subject: Fix libdiskio build with auto-disabled modules X-Git-Tag: merge-candidate-3-v1~24^2~3 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=fedd516f0e6209bbc33671c7b3f61a0ddaf72fcd;p=thirdparty%2Fsquid.git Fix libdiskio build with auto-disabled modules The squid_disk_module_candidates_* autoconf variable for disabled disk I/O modules needs to be explicitly set to 'no' to perform the disabling. Do this for all modules that were not doing so when module dependencies were broken or absent. Also, convert the IpcIo module from a hard ERROR, to a soft auto-disable when SHM support is not present. --- diff --git a/configure.ac b/configure.ac index 06a7a041cd..53e95dccbe 100644 --- a/configure.ac +++ b/configure.ac @@ -592,6 +592,7 @@ for module in $squid_disk_module_candidates none; do esac else AC_MSG_NOTICE([AIO DiskIO Module disabled. Missing POSIX AIO support.]) + squid_disk_module_candidates_AIO=no fi ;; @@ -606,6 +607,7 @@ for module in $squid_disk_module_candidates none; do case "$squid_host_os" in mingw) AC_MSG_NOTICE(["DiskDaemon not supported on MinGW"]) + squid_disk_module_candidates_DiskDaemon=no ;; *) AC_MSG_NOTICE([Enabling DiskDaemon DiskIO module]) @@ -692,17 +694,20 @@ for module in $squid_disk_module_candidates none; do else AC_MSG_NOTICE([Native pthreads support disabled. DiskThreads module automaticaly disabled.]) SQUID_STATE_ROLLBACK([diskthreads_state]) + squid_disk_module_candidates_DiskThreads=no fi ;; IpcIo) AC_MSG_NOTICE([Enabling IpcIo DiskIO module]) if test "x$ac_cv_search_shm_open" = "xno" ; then - AC_MSG_ERROR([DiskIO IpcIo module requires shared memory support]) + AC_MSG_NOTICE([DiskIO IpcIo module requires shared memory support]) + squid_disk_module_candidates_IpcIo=no + else + DISK_MODULES="$DISK_MODULES IpcIo" + DISK_LINKOBJS="$DISK_LINKOBJS DiskIO/IpcIo/IpcIoDiskIOModule.o" + AC_DEFINE([HAVE_DISKIO_MODULE_IPCIO],1,[IpcIo Disk I/O module is built]) fi - DISK_MODULES="$DISK_MODULES IpcIo" - DISK_LINKOBJS="$DISK_LINKOBJS DiskIO/IpcIo/IpcIoDiskIOModule.o" - AC_DEFINE([HAVE_DISKIO_MODULE_IPCIO],1,[IpcIo Disk I/O module is built]) ;; Mmapped) @@ -710,6 +715,7 @@ for module in $squid_disk_module_candidates none; do dnl OR support windows mmap functions if test "x$squid_host_os" = "xmingw" ; then AC_MSG_NOTICE([Mmapped DiskIO is not available on Mingw]) + squid_disk_module_candidates_Mmapped=no else AC_MSG_NOTICE([Enabling Mmapped DiskIO module]) DISK_MODULES="$DISK_MODULES Mmapped"