]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Remaining build issues in HEAD tests.
authorAmos Jeffries <squid3@treenet.co.nz>
Thu, 4 Dec 2008 23:55:38 +0000 (12:55 +1300)
committerAmos Jeffries <squid3@treenet.co.nz>
Thu, 4 Dec 2008 23:55:38 +0000 (12:55 +1300)
Several missing symbols added to CommIO stub and extra smart storeio
checks to prevent duplicate object linkages when both async-io and
storeio are enabled.

configure.in
src/Makefile.am
src/tests/stub_CommIO.cc

index 405f9911a3565184b158d05703081049c973c2da..c0eae384ef7afa874b1cb414f8076f68c9ed524c 100644 (file)
@@ -468,18 +468,22 @@ AC_ARG_ENABLE(storeio,
   fi
 ])
 if test -n "$STORE_MODULES"; then
-    for module in $STORE_MODULES; do
-       if test -d $srcdir/src/fs/$module; then
-           :
+    dnl ensure that all modules a) exist and b) only include once.
+    STORE_MODULES_FULL=$STORE_MODULES
+    STORE_MODULES=
+    STORE_LINKOBJS=
+    for module in $STORE_MODULES_FULL; do
+        have_mod=`echo "$STORE_MODULES" | grep "$module"`
+        if test "$have_mod" != ""; then
+           echo "Removing duplicate $module from storeio"
+       elif test -d $srcdir/src/fs/$module; then
+           STORE_MODULES="$STORE_MODULES $module"
+           STORE_LINKOBJS="$STORE_LINKOBJS fs/${module}/StoreFS${module}.o"
        else
            AC_MSG_ERROR(storeio $module does not exist)
        fi
     done
     echo "Store modules built: $STORE_MODULES"
-    STORE_LINKOBJS=
-    for module in $STORE_MODULES; do
-        STORE_LINKOBJS="$STORE_LINKOBJS fs/${module}/StoreFS${module}.o"
-    done
 fi
 dnl remove all but diskd - its the only module that needs to recurse
 dnl into the sub directory
index 5c2308f4f9e93d6b596be9717b49e52d6b836107..3435437454ba05474d60ad3d0f5f07c8f74fb88d 100644 (file)
@@ -1477,8 +1477,7 @@ tests_testDiskIO_SOURCES= \
        tests/testDiskIO.cc \
        tests/testDiskIO.h \
        tests/testMain.cc \
-       tests/stub_cache_manager.cc \
-       tests/stub_CommIO.cc
+       tests/stub_cache_manager.cc
 
 tests_testDiskIO_LDADD= \
        @DISK_LIBS@ \
@@ -2210,8 +2209,9 @@ tests_testString_DEPENDENCIES = $(top_builddir)/lib/libmiscutil.a \
        @SQUID_CPPUNIT_LA@
 
 SWAP_TEST_SOURCES = \
-       tests/stub_store_rebuild.cc \
        tests/stub_internal.cc \
+       tests/stub_CommIO.cc \
+       tests/stub_store_rebuild.cc \
        fd.cc \
        disk.cc \
        filemap.cc \
index 4eacf7e09774b1ac0b082edf97d03cde32e94e79..dfb38ec9543341cc5e6b6a3bb281bfcf925fa49b 100644 (file)
@@ -1,6 +1,11 @@
 #include "squid.h"
 #include "CommIO.h"
 
+bool CommIO::Initialised = false;
+bool CommIO::DoneSignalled = false;
+int CommIO::DoneFD = -1;
+int CommIO::DoneReadFD = -1;
+
 void
 CommIO::ResetNotifications()
 {