Browse code

autojunk'd

Mickey Sola authored on 2017/03/31 06:22:49
Showing 22 changed files
... ...
@@ -194,6 +194,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
194 194
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
195 195
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
196 196
 	$(top_srcdir)/m4/reorganization/yara.m4 \
197
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
197 198
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
198 199
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
199 200
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -390,6 +390,9 @@
390 390
 /* systemd is supported */
391 391
 #undef HAVE_SYSTEMD
392 392
 
393
+/* Use private fts() implementation which is LFS safe */
394
+#undef HAVE_SYSTEM_LFS_FTS
395
+
393 396
 /* Define to 1 if you have the <sys/cdefs.h> header file. */
394 397
 #undef HAVE_SYS_CDEFS_H
395 398
 
... ...
@@ -606,9 +609,20 @@
606 606
    `char[]'. */
607 607
 #undef YYTEXT_POINTER
608 608
 
609
+/* Enable large inode numbers on Mac OS X 10.5.  */
610
+#ifndef _DARWIN_USE_64_BIT_INODE
611
+# define _DARWIN_USE_64_BIT_INODE 1
612
+#endif
613
+
614
+/* Number of bits in a file offset, on hosts where this is settable. */
615
+#undef _FILE_OFFSET_BITS
616
+
609 617
 /* Define to 1 to make fseeko visible on some hosts (e.g. glibc 2.2). */
610 618
 #undef _LARGEFILE_SOURCE
611 619
 
620
+/* Define for large files, on AIX-style hosts. */
621
+#undef _LARGE_FILES
622
+
612 623
 /* Define to 1 if on MINIX. */
613 624
 #undef _MINIX
614 625
 
... ...
@@ -169,6 +169,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
169 169
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
170 170
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
171 171
 	$(top_srcdir)/m4/reorganization/yara.m4 \
172
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
172 173
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
173 174
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
174 175
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -150,6 +150,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
150 150
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
151 151
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
152 152
 	$(top_srcdir)/m4/reorganization/yara.m4 \
153
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
153 154
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
154 155
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
155 156
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -168,6 +168,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
168 168
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
169 169
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
170 170
 	$(top_srcdir)/m4/reorganization/yara.m4 \
171
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
171 172
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
172 173
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
173 174
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -99,6 +99,7 @@ build_triplet = @build@
99 99
 host_triplet = @host@
100 100
 target_triplet = @target@
101 101
 @BUILD_CLAMD_TRUE@sbin_PROGRAMS = clamd$(EXEEXT)
102
+@BUILD_CLAMD_TRUE@@SYSTEM_LFS_FTS_FALSE@am__append_1 = fts.c
102 103
 subdir = clamd
103 104
 DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
104 105
 	$(srcdir)/clamav-daemon.service.in \
... ...
@@ -170,6 +171,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
170 170
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
171 171
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
172 172
 	$(top_srcdir)/m4/reorganization/yara.m4 \
173
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
173 174
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
174 175
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
175 176
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -199,7 +201,8 @@ am__clamd_SOURCES_DIST = $(top_srcdir)/shared/output.c \
199 199
 	thrmgr.h server-th.c server.h scanner.c scanner.h others.c \
200 200
 	others.h shared.h onaccess_fan.c onaccess_fan.h onaccess_ddd.c \
201 201
 	onaccess_ddd.h onaccess_hash.c onaccess_hash.h onaccess_scth.c \
202
-	onaccess_scth.h
202
+	onaccess_scth.h priv_fts.h fts.c
203
+@BUILD_CLAMD_TRUE@@SYSTEM_LFS_FTS_FALSE@am__objects_1 = fts.$(OBJEXT)
203 204
 @BUILD_CLAMD_TRUE@am_clamd_OBJECTS = output.$(OBJEXT) \
204 205
 @BUILD_CLAMD_TRUE@	idmef_logging.$(OBJEXT) optparser.$(OBJEXT) \
205 206
 @BUILD_CLAMD_TRUE@	getopt.$(OBJEXT) misc.$(OBJEXT) \
... ...
@@ -210,7 +213,7 @@ am__clamd_SOURCES_DIST = $(top_srcdir)/shared/output.c \
210 210
 @BUILD_CLAMD_TRUE@	onaccess_fan.$(OBJEXT) \
211 211
 @BUILD_CLAMD_TRUE@	onaccess_ddd.$(OBJEXT) \
212 212
 @BUILD_CLAMD_TRUE@	onaccess_hash.$(OBJEXT) \
213
-@BUILD_CLAMD_TRUE@	onaccess_scth.$(OBJEXT)
213
+@BUILD_CLAMD_TRUE@	onaccess_scth.$(OBJEXT) $(am__objects_1)
214 214
 clamd_OBJECTS = $(am_clamd_OBJECTS)
215 215
 clamd_LDADD = $(LDADD)
216 216
 AM_V_lt = $(am__v_lt_@AM_V@)
... ...
@@ -527,42 +530,24 @@ target_vendor = @target_vendor@
527 527
 top_build_prefix = @top_build_prefix@
528 528
 top_builddir = @top_builddir@
529 529
 top_srcdir = @top_srcdir@
530
-@BUILD_CLAMD_TRUE@clamd_SOURCES = \
531
-@BUILD_CLAMD_TRUE@    $(top_srcdir)/shared/output.c \
532
-@BUILD_CLAMD_TRUE@    $(top_srcdir)/shared/output.h \
533
-@BUILD_CLAMD_TRUE@    $(top_srcdir)/shared/idmef_logging.c \
534
-@BUILD_CLAMD_TRUE@    $(top_srcdir)/shared/idmef_logging.h \
535
-@BUILD_CLAMD_TRUE@    $(top_srcdir)/shared/optparser.c \
536
-@BUILD_CLAMD_TRUE@    $(top_srcdir)/shared/optparser.h \
537
-@BUILD_CLAMD_TRUE@    $(top_srcdir)/shared/getopt.c \
538
-@BUILD_CLAMD_TRUE@    $(top_srcdir)/shared/getopt.h \
539
-@BUILD_CLAMD_TRUE@    $(top_srcdir)/shared/misc.c \
540
-@BUILD_CLAMD_TRUE@    $(top_srcdir)/shared/misc.h \
541
-@BUILD_CLAMD_TRUE@    clamd.c \
542
-@BUILD_CLAMD_TRUE@    tcpserver.c \
543
-@BUILD_CLAMD_TRUE@    tcpserver.h \
544
-@BUILD_CLAMD_TRUE@    localserver.c \
545
-@BUILD_CLAMD_TRUE@    localserver.h \
546
-@BUILD_CLAMD_TRUE@    session.c \
547
-@BUILD_CLAMD_TRUE@    session.h \
548
-@BUILD_CLAMD_TRUE@    thrmgr.c \
549
-@BUILD_CLAMD_TRUE@    thrmgr.h \
550
-@BUILD_CLAMD_TRUE@    server-th.c \
551
-@BUILD_CLAMD_TRUE@    server.h \
552
-@BUILD_CLAMD_TRUE@    scanner.c \
553
-@BUILD_CLAMD_TRUE@    scanner.h \
554
-@BUILD_CLAMD_TRUE@    others.c \
555
-@BUILD_CLAMD_TRUE@    others.h \
556
-@BUILD_CLAMD_TRUE@    shared.h \
557
-@BUILD_CLAMD_TRUE@    onaccess_fan.c \
558
-@BUILD_CLAMD_TRUE@    onaccess_fan.h \
559
-@BUILD_CLAMD_TRUE@    onaccess_ddd.c \
560
-@BUILD_CLAMD_TRUE@    onaccess_ddd.h \
561
-@BUILD_CLAMD_TRUE@    onaccess_hash.c \
562
-@BUILD_CLAMD_TRUE@    onaccess_hash.h \
563
-@BUILD_CLAMD_TRUE@    onaccess_scth.c \
564
-@BUILD_CLAMD_TRUE@    onaccess_scth.h
565
-
530
+@BUILD_CLAMD_TRUE@clamd_SOURCES = $(top_srcdir)/shared/output.c \
531
+@BUILD_CLAMD_TRUE@	$(top_srcdir)/shared/output.h \
532
+@BUILD_CLAMD_TRUE@	$(top_srcdir)/shared/idmef_logging.c \
533
+@BUILD_CLAMD_TRUE@	$(top_srcdir)/shared/idmef_logging.h \
534
+@BUILD_CLAMD_TRUE@	$(top_srcdir)/shared/optparser.c \
535
+@BUILD_CLAMD_TRUE@	$(top_srcdir)/shared/optparser.h \
536
+@BUILD_CLAMD_TRUE@	$(top_srcdir)/shared/getopt.c \
537
+@BUILD_CLAMD_TRUE@	$(top_srcdir)/shared/getopt.h \
538
+@BUILD_CLAMD_TRUE@	$(top_srcdir)/shared/misc.c \
539
+@BUILD_CLAMD_TRUE@	$(top_srcdir)/shared/misc.h clamd.c \
540
+@BUILD_CLAMD_TRUE@	tcpserver.c tcpserver.h localserver.c \
541
+@BUILD_CLAMD_TRUE@	localserver.h session.c session.h thrmgr.c \
542
+@BUILD_CLAMD_TRUE@	thrmgr.h server-th.c server.h scanner.c \
543
+@BUILD_CLAMD_TRUE@	scanner.h others.c others.h shared.h \
544
+@BUILD_CLAMD_TRUE@	onaccess_fan.c onaccess_fan.h onaccess_ddd.c \
545
+@BUILD_CLAMD_TRUE@	onaccess_ddd.h onaccess_hash.c \
546
+@BUILD_CLAMD_TRUE@	onaccess_hash.h onaccess_scth.c \
547
+@BUILD_CLAMD_TRUE@	onaccess_scth.h priv_fts.h $(am__append_1)
566 548
 @BUILD_CLAMD_TRUE@AM_CFLAGS = @WERR_CFLAGS@
567 549
 @BUILD_CLAMD_TRUE@@INSTALL_SYSTEMD_UNITS_TRUE@systemdsystemunit_DATA = clamav-daemon.socket clamav-daemon.service
568 550
 AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/shared -I$(top_srcdir)/libclamav @SSL_CPPFLAGS@ @JSON_CPPFLAGS@ @PCRE_CPPFLAGS@
... ...
@@ -686,6 +671,7 @@ distclean-compile:
686 686
 	-rm -f *.tab.c
687 687
 
688 688
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clamd.Po@am__quote@
689
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fts.Po@am__quote@
689 690
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/getopt.Po@am__quote@
690 691
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/idmef_logging.Po@am__quote@
691 692
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/localserver.Po@am__quote@
... ...
@@ -168,6 +168,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
168 168
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
169 169
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
170 170
 	$(top_srcdir)/m4/reorganization/yara.m4 \
171
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
171 172
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
172 173
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
173 174
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -150,6 +150,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
150 150
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
151 151
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
152 152
 	$(top_srcdir)/m4/reorganization/yara.m4 \
153
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
153 154
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
154 155
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
155 156
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -169,6 +169,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
169 169
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
170 170
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
171 171
 	$(top_srcdir)/m4/reorganization/yara.m4 \
172
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
172 173
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
173 174
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
174 175
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -168,6 +168,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
168 168
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
169 169
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
170 170
 	$(top_srcdir)/m4/reorganization/yara.m4 \
171
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
171 172
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
172 173
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
173 174
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -694,6 +694,8 @@ ENABLE_LIBFRESHCLAM_FALSE
694 694
 ENABLE_LIBFRESHCLAM_TRUE
695 695
 ENABLE_CLAMSUBMIT_FALSE
696 696
 ENABLE_CLAMSUBMIT_TRUE
697
+SYSTEM_LFS_FTS_FALSE
698
+SYSTEM_LFS_FTS_TRUE
697 699
 HAVE_YARA
698 700
 subdirs
699 701
 llvmconfig
... ...
@@ -963,6 +965,7 @@ enable_prelude
963 963
 with_libprelude_prefix
964 964
 with_libcurl
965 965
 with_system_libmspack
966
+enable_largefile
966 967
 '
967 968
       ac_precious_vars='build_alias
968 969
 host_alias
... ...
@@ -1655,6 +1658,7 @@ Optional Features:
1655 1655
   --disable-yara          do not include yara support
1656 1656
   --enable-libfreshclam   enable building of libfreshclam
1657 1657
   --enable-prelude        Enable Prelude support for alerts.
1658
+  --disable-largefile     omit support for large files
1658 1659
 
1659 1660
 Optional Packages:
1660 1661
   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
... ...
@@ -21897,7 +21901,7 @@ if test "$enable_stat64" != "no"; then
21897 21897
 
21898 21898
 $as_echo "#define HAVE_STAT64 1" >>confdefs.h
21899 21899
 
21900
-CFLAGS="$CFLAGS -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE"
21900
+CFLAGS="$CFLAGS -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64"
21901 21901
 fi
21902 21902
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_stat64" >&5
21903 21903
 $as_echo "$enable_stat64" >&6; }
... ...
@@ -24208,6 +24212,55 @@ fi
24208 24208
 
24209 24209
 
24210 24210
 
24211
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking LFS safe fts implementation" >&5
24212
+$as_echo_n "checking LFS safe fts implementation... " >&6; }
24213
+if test "$cross_compiling" = yes; then :
24214
+  have_LFS_fts=no
24215
+
24216
+else
24217
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24218
+/* end confdefs.h.  */
24219
+
24220
+#include <fts.h>
24221
+
24222
+int main(void) {
24223
+    fts_open((void *)0, FTS_PHYSICAL, (void *)0);
24224
+
24225
+    return 0;
24226
+}
24227
+
24228
+_ACEOF
24229
+if ac_fn_c_try_run "$LINENO"; then :
24230
+  have_LFS_fts=yes
24231
+else
24232
+  have_LFS_fts=no
24233
+fi
24234
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24235
+  conftest.$ac_objext conftest.beam conftest.$ac_ext
24236
+fi
24237
+
24238
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_LFS_fts" >&5
24239
+$as_echo "$have_LFS_fts" >&6; }
24240
+ if test "x$have_LFS_fts" = "xyes"; then
24241
+  SYSTEM_LFS_FTS_TRUE=
24242
+  SYSTEM_LFS_FTS_FALSE='#'
24243
+else
24244
+  SYSTEM_LFS_FTS_TRUE='#'
24245
+  SYSTEM_LFS_FTS_FALSE=
24246
+fi
24247
+
24248
+if test "x$have_LFS_fts" = "xyes"; then
24249
+
24250
+$as_echo "#define HAVE_SYSTEM_LFS_FTS 1" >>confdefs.h
24251
+
24252
+	lfs_fts_msg="libc"
24253
+else
24254
+
24255
+$as_echo "#define HAVE_SYSTEM_LFS_FTS 0" >>confdefs.h
24256
+
24257
+	lfs_fts_msg="internal, libc's is not LFS compatible"
24258
+fi
24259
+
24211 24260
  if test "$have_curl" = "yes"; then
24212 24261
   ENABLE_CLAMSUBMIT_TRUE=
24213 24262
   ENABLE_CLAMSUBMIT_FALSE='#'
... ...
@@ -24703,6 +24756,7 @@ else
24703 24703
   USE_INTERNAL_MSPACK_FALSE=
24704 24704
 fi
24705 24705
 
24706
+    CLFAGS="$CFLAGS -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64"
24706 24707
 else
24707 24708
 
24708 24709
 pkg_failed=no
... ...
@@ -24790,6 +24844,206 @@ if test "x$use_internal_mspack" = "xyes"; then
24790 24790
     mspack_msg="Internal"
24791 24791
     subdirs="$subdirs libclamav/libmspack-0.5alpha"
24792 24792
 
24793
+    # Check whether --enable-largefile was given.
24794
+if test "${enable_largefile+set}" = set; then :
24795
+  enableval=$enable_largefile;
24796
+fi
24797
+
24798
+if test "$enable_largefile" != no; then
24799
+
24800
+  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
24801
+$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
24802
+if ${ac_cv_sys_largefile_CC+:} false; then :
24803
+  $as_echo_n "(cached) " >&6
24804
+else
24805
+  ac_cv_sys_largefile_CC=no
24806
+     if test "$GCC" != yes; then
24807
+       ac_save_CC=$CC
24808
+       while :; do
24809
+	 # IRIX 6.2 and later do not support large files by default,
24810
+	 # so use the C compiler's -n32 option if that helps.
24811
+	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24812
+/* end confdefs.h.  */
24813
+#include <sys/types.h>
24814
+ /* Check that off_t can represent 2**63 - 1 correctly.
24815
+    We can't simply define LARGE_OFF_T to be 9223372036854775807,
24816
+    since some C++ compilers masquerading as C compilers
24817
+    incorrectly reject 9223372036854775807.  */
24818
+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24819
+  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
24820
+		       && LARGE_OFF_T % 2147483647 == 1)
24821
+		      ? 1 : -1];
24822
+int
24823
+main ()
24824
+{
24825
+
24826
+  ;
24827
+  return 0;
24828
+}
24829
+_ACEOF
24830
+	 if ac_fn_c_try_compile "$LINENO"; then :
24831
+  break
24832
+fi
24833
+rm -f core conftest.err conftest.$ac_objext
24834
+	 CC="$CC -n32"
24835
+	 if ac_fn_c_try_compile "$LINENO"; then :
24836
+  ac_cv_sys_largefile_CC=' -n32'; break
24837
+fi
24838
+rm -f core conftest.err conftest.$ac_objext
24839
+	 break
24840
+       done
24841
+       CC=$ac_save_CC
24842
+       rm -f conftest.$ac_ext
24843
+    fi
24844
+fi
24845
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
24846
+$as_echo "$ac_cv_sys_largefile_CC" >&6; }
24847
+  if test "$ac_cv_sys_largefile_CC" != no; then
24848
+    CC=$CC$ac_cv_sys_largefile_CC
24849
+  fi
24850
+
24851
+  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
24852
+$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
24853
+if ${ac_cv_sys_file_offset_bits+:} false; then :
24854
+  $as_echo_n "(cached) " >&6
24855
+else
24856
+  while :; do
24857
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24858
+/* end confdefs.h.  */
24859
+#include <sys/types.h>
24860
+ /* Check that off_t can represent 2**63 - 1 correctly.
24861
+    We can't simply define LARGE_OFF_T to be 9223372036854775807,
24862
+    since some C++ compilers masquerading as C compilers
24863
+    incorrectly reject 9223372036854775807.  */
24864
+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24865
+  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
24866
+		       && LARGE_OFF_T % 2147483647 == 1)
24867
+		      ? 1 : -1];
24868
+int
24869
+main ()
24870
+{
24871
+
24872
+  ;
24873
+  return 0;
24874
+}
24875
+_ACEOF
24876
+if ac_fn_c_try_compile "$LINENO"; then :
24877
+  ac_cv_sys_file_offset_bits=no; break
24878
+fi
24879
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24880
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24881
+/* end confdefs.h.  */
24882
+#define _FILE_OFFSET_BITS 64
24883
+#include <sys/types.h>
24884
+ /* Check that off_t can represent 2**63 - 1 correctly.
24885
+    We can't simply define LARGE_OFF_T to be 9223372036854775807,
24886
+    since some C++ compilers masquerading as C compilers
24887
+    incorrectly reject 9223372036854775807.  */
24888
+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24889
+  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
24890
+		       && LARGE_OFF_T % 2147483647 == 1)
24891
+		      ? 1 : -1];
24892
+int
24893
+main ()
24894
+{
24895
+
24896
+  ;
24897
+  return 0;
24898
+}
24899
+_ACEOF
24900
+if ac_fn_c_try_compile "$LINENO"; then :
24901
+  ac_cv_sys_file_offset_bits=64; break
24902
+fi
24903
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24904
+  ac_cv_sys_file_offset_bits=unknown
24905
+  break
24906
+done
24907
+fi
24908
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
24909
+$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
24910
+case $ac_cv_sys_file_offset_bits in #(
24911
+  no | unknown) ;;
24912
+  *)
24913
+cat >>confdefs.h <<_ACEOF
24914
+#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
24915
+_ACEOF
24916
+;;
24917
+esac
24918
+rm -rf conftest*
24919
+  if test $ac_cv_sys_file_offset_bits = unknown; then
24920
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
24921
+$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
24922
+if ${ac_cv_sys_large_files+:} false; then :
24923
+  $as_echo_n "(cached) " >&6
24924
+else
24925
+  while :; do
24926
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24927
+/* end confdefs.h.  */
24928
+#include <sys/types.h>
24929
+ /* Check that off_t can represent 2**63 - 1 correctly.
24930
+    We can't simply define LARGE_OFF_T to be 9223372036854775807,
24931
+    since some C++ compilers masquerading as C compilers
24932
+    incorrectly reject 9223372036854775807.  */
24933
+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24934
+  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
24935
+		       && LARGE_OFF_T % 2147483647 == 1)
24936
+		      ? 1 : -1];
24937
+int
24938
+main ()
24939
+{
24940
+
24941
+  ;
24942
+  return 0;
24943
+}
24944
+_ACEOF
24945
+if ac_fn_c_try_compile "$LINENO"; then :
24946
+  ac_cv_sys_large_files=no; break
24947
+fi
24948
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24949
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24950
+/* end confdefs.h.  */
24951
+#define _LARGE_FILES 1
24952
+#include <sys/types.h>
24953
+ /* Check that off_t can represent 2**63 - 1 correctly.
24954
+    We can't simply define LARGE_OFF_T to be 9223372036854775807,
24955
+    since some C++ compilers masquerading as C compilers
24956
+    incorrectly reject 9223372036854775807.  */
24957
+#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24958
+  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
24959
+		       && LARGE_OFF_T % 2147483647 == 1)
24960
+		      ? 1 : -1];
24961
+int
24962
+main ()
24963
+{
24964
+
24965
+  ;
24966
+  return 0;
24967
+}
24968
+_ACEOF
24969
+if ac_fn_c_try_compile "$LINENO"; then :
24970
+  ac_cv_sys_large_files=1; break
24971
+fi
24972
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24973
+  ac_cv_sys_large_files=unknown
24974
+  break
24975
+done
24976
+fi
24977
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
24978
+$as_echo "$ac_cv_sys_large_files" >&6; }
24979
+case $ac_cv_sys_large_files in #(
24980
+  no | unknown) ;;
24981
+  *)
24982
+cat >>confdefs.h <<_ACEOF
24983
+#define _LARGE_FILES $ac_cv_sys_large_files
24984
+_ACEOF
24985
+;;
24986
+esac
24987
+rm -rf conftest*
24988
+  fi
24989
+
24990
+
24991
+fi
24992
+
24793 24993
 else
24794 24994
     mspack_msg="External, $LIBMSPACK_CFLAGS $LIBMSPACK_LIBS"
24795 24995
 fi
... ...
@@ -25005,6 +25259,10 @@ if test -z "${HAVE_CURSES_TRUE}" && test -z "${HAVE_CURSES_FALSE}"; then
25005 25005
   as_fn_error $? "conditional \"HAVE_CURSES\" was never defined.
25006 25006
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25007 25007
 fi
25008
+if test -z "${SYSTEM_LFS_FTS_TRUE}" && test -z "${SYSTEM_LFS_FTS_FALSE}"; then
25009
+  as_fn_error $? "conditional \"SYSTEM_LFS_FTS\" was never defined.
25010
+Usually this means the macro was only invoked conditionally." "$LINENO" 5
25011
+fi
25008 25012
 if test -z "${ENABLE_CLAMSUBMIT_TRUE}" && test -z "${ENABLE_CLAMSUBMIT_FALSE}"; then
25009 25013
   as_fn_error $? "conditional \"ENABLE_CLAMSUBMIT\" was never defined.
25010 25014
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
... ...
@@ -27598,6 +27856,10 @@ if test -z "${HAVE_CURSES_TRUE}" && test -z "${HAVE_CURSES_FALSE}"; then
27598 27598
   as_fn_error $? "conditional \"HAVE_CURSES\" was never defined.
27599 27599
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
27600 27600
 fi
27601
+if test -z "${SYSTEM_LFS_FTS_TRUE}" && test -z "${SYSTEM_LFS_FTS_FALSE}"; then
27602
+  as_fn_error $? "conditional \"SYSTEM_LFS_FTS\" was never defined.
27603
+Usually this means the macro was only invoked conditionally." "$LINENO" 5
27604
+fi
27601 27605
 if test -z "${ENABLE_CLAMSUBMIT_TRUE}" && test -z "${ENABLE_CLAMSUBMIT_FALSE}"; then
27602 27606
   as_fn_error $? "conditional \"ENABLE_CLAMSUBMIT\" was never defined.
27603 27607
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
... ...
@@ -30355,6 +30617,20 @@ else
30355 30355
 fi
30356 30356
 
30357 30357
 
30358
+
30359
+   $as_echo_n "              fts         : "
30360
+   if test "x$lfs_fts_msg" = "xno"; then :
30361
+  $as_echo "yes (disabled)"
30362
+elif test "x$lfs_fts_msg" = "xyes"; then :
30363
+  $as_echo "yes"
30364
+elif test "x$lfs_fts_msg" = "x"; then :
30365
+  $as_echo "yes"
30366
+else
30367
+  $as_echo "yes ($lfs_fts_msg)"
30368
+fi
30369
+
30370
+
30371
+
30358 30372
 # Yep, downgrading the compiler avoids the bug too:
30359 30373
 # 4.0.x, and 4.1.0 are the known buggy versions
30360 30374
 # 3.4 doesn't have the bug
... ...
@@ -166,6 +166,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
166 166
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
167 167
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
168 168
 	$(top_srcdir)/m4/reorganization/yara.m4 \
169
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
169 170
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
170 171
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
171 172
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -166,6 +166,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
166 166
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
167 167
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
168 168
 	$(top_srcdir)/m4/reorganization/yara.m4 \
169
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
169 170
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
170 171
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
171 172
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -167,6 +167,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
167 167
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
168 168
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
169 169
 	$(top_srcdir)/m4/reorganization/yara.m4 \
170
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
170 171
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
171 172
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
172 173
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -171,6 +171,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
171 171
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
172 172
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
173 173
 	$(top_srcdir)/m4/reorganization/yara.m4 \
174
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
174 175
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
175 176
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
176 177
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -228,6 +228,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
228 228
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
229 229
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
230 230
 	$(top_srcdir)/m4/reorganization/yara.m4 \
231
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
231 232
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
232 233
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
233 234
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -5277,12 +5277,13 @@ save_LDFLAGS="$LDFLAGS"
5277 5277
 save_CFLAGS="$CFLAGS"
5278 5278
 save_LIBS="$LIBS"
5279 5279
 
5280
-SSL_LIBS="-lssl -lcrypto -lz"
5280
+SSL_LIBS="$LIBS -lssl -lcrypto -lz"
5281
+LIBS="$LIBS $SSL_LIBS"
5281 5282
 
5282 5283
 if test "$LIBSSL_HOME" != "/usr"; then
5283 5284
     SSL_LDFLAGS="-L$LIBSSL_HOME/lib"
5284 5285
     SSL_CPPFLAGS="-I$LIBSSL_HOME/include"
5285
-    LDFLAGS="-L$LIBSSL_HOME/lib $SSL_LIBS"
5286
+    LDFLAGS="-L$LIBSSL_HOME/lib"
5286 5287
     CFLAGS="$SSL_CPPFLAGS"
5287 5288
 else
5288 5289
     SSL_LDFLAGS=""
... ...
@@ -5292,47 +5293,24 @@ fi
5292 5292
 have_ssl="no"
5293 5293
 have_crypto="no"
5294 5294
 
5295
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_library_init in -lssl" >&5
5296
-$as_echo_n "checking for SSL_library_init in -lssl... " >&6; }
5297
-if ${ac_cv_lib_ssl_SSL_library_init+:} false; then :
5298
-  $as_echo_n "(cached) " >&6
5299
-else
5300
-  ac_check_lib_save_LIBS=$LIBS
5301
-LIBS="-lssl -lcrypto -lz $LIBS"
5302 5295
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5303 5296
 /* end confdefs.h.  */
5304
-
5305
-/* Override any GCC internal prototype to avoid an error.
5306
-   Use char because int might match the return type of a GCC
5307
-   builtin and then its argument prototype would still apply.  */
5308
-#ifdef __cplusplus
5309
-extern "C"
5310
-#endif
5311
-char SSL_library_init ();
5297
+#include <openssl/ssl.h>
5312 5298
 int
5313 5299
 main ()
5314 5300
 {
5315
-return SSL_library_init ();
5301
+SSL_library_init();
5316 5302
   ;
5317 5303
   return 0;
5318 5304
 }
5319 5305
 _ACEOF
5320 5306
 if ac_fn_c_try_link "$LINENO"; then :
5321
-  ac_cv_lib_ssl_SSL_library_init=yes
5307
+  have_ssl="yes";
5322 5308
 else
5323
-  ac_cv_lib_ssl_SSL_library_init=no
5309
+  as_fn_error $? "Your OpenSSL installation is misconfigured or missing" "$LINENO" 5
5324 5310
 fi
5325 5311
 rm -f core conftest.err conftest.$ac_objext \
5326 5312
     conftest$ac_exeext conftest.$ac_ext
5327
-LIBS=$ac_check_lib_save_LIBS
5328
-fi
5329
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_SSL_library_init" >&5
5330
-$as_echo "$ac_cv_lib_ssl_SSL_library_init" >&6; }
5331
-if test "x$ac_cv_lib_ssl_SSL_library_init" = xyes; then :
5332
-  have_ssl="yes"
5333
-else
5334
-  as_fn_error $? "Your OpenSSL installation is misconfigured or missing" "$LINENO" 5
5335
-fi
5336 5313
 
5337 5314
 
5338 5315
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EVP_EncryptInit in -lcrypto" >&5
... ...
@@ -167,6 +167,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
167 167
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
168 168
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
169 169
 	$(top_srcdir)/m4/reorganization/yara.m4 \
170
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
170 171
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
171 172
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
172 173
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -156,6 +156,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
156 156
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
157 157
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
158 158
 	$(top_srcdir)/m4/reorganization/yara.m4 \
159
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
159 160
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
160 161
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
161 162
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -168,6 +168,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
168 168
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
169 169
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
170 170
 	$(top_srcdir)/m4/reorganization/yara.m4 \
171
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
171 172
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
172 173
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
173 174
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -149,6 +149,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
149 149
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
150 150
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
151 151
 	$(top_srcdir)/m4/reorganization/yara.m4 \
152
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
152 153
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
153 154
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
154 155
 	$(top_srcdir)/m4/reorganization/bsd.m4 \
... ...
@@ -151,6 +151,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/acinclude.m4 \
151 151
 	$(top_srcdir)/libclamav/c++/m4/llvm-opts.m4 \
152 152
 	$(top_srcdir)/m4/reorganization/sha_collect.m4 \
153 153
 	$(top_srcdir)/m4/reorganization/yara.m4 \
154
+	$(top_srcdir)/m4/reorganization/code_checks/fts.m4 \
154 155
 	$(top_srcdir)/m4/reorganization/libfreshclam.m4 \
155 156
 	$(top_srcdir)/m4/reorganization/prelude.m4 \
156 157
 	$(top_srcdir)/m4/reorganization/bsd.m4 \