Whamcloud - gitweb
mke2fs: Print a better error msg when ext2fs_get_device_size() returns EFBIG
[tools/e2fsprogs.git] / configure.in
index d057af5..9a43f99 100644 (file)
@@ -367,26 +367,6 @@ fi
 echo "Disabling testio debugging by default"
 )
 dnl
-dnl handle --enable-swapfs
-dnl
-AC_ARG_ENABLE([swapfs],
-[  --disable-swapfs              disable support of legacy byte-swapped filesystems],
-if test "$enableval" = "no"
-then
-       SWAPFS_CMT=#
-       echo "Disabling swapfs support"
-else
-       SWAPFS_CMT=
-       AC_DEFINE(ENABLE_SWAPFS)
-       echo "Enabling swapfs support"
-fi
-,
-SWAPFS_CMT=
-echo "Enabling swapfs support by default"
-AC_DEFINE(ENABLE_SWAPFS)
-)
-AC_SUBST(SWAPFS_CMT)
-dnl
 dnl handle --enable-debugfs
 dnl
 AC_ARG_ENABLE([debugfs],
@@ -683,14 +663,6 @@ AC_CHECK_DECL(lseek64,[AC_DEFINE(HAVE_LSEEK64_PROTOTYPE)],,
 dnl
 dnl Word sizes...
 dnl
-if test "$cross_compiling" = yes -a "$ac_cv_sizeof_long" = ""; then
-  # if cross-compiling, with no cached values, just assume something common. 
-  ac_cv_sizeof_short=2
-  ac_cv_sizeof_int=4
-  ac_cv_sizeof_long=4
-  ac_cv_sizeof_long_long=8
-  AC_MSG_WARN([Cross-compiling, so cannot check type sizes; assuming short=2, int=4, long=4, long long=8])
-fi
 AC_CHECK_SIZEOF(short)
 AC_CHECK_SIZEOF(int)
 AC_CHECK_SIZEOF(long)
@@ -708,6 +680,25 @@ BUILD_CC="$BUILD_CC" CPP="$CPP" /bin/sh $ac_aux_dir/parse-types.sh
 ASM_TYPES_HEADER=./asm_types.h
 AC_SUBST_FILE(ASM_TYPES_HEADER)
 dnl
+dnl Save the configuration #defines needed for the public ext2fs.h
+dnl header file
+dnl
+echo "/* These defines are needed for the public ext2fs.h header file */" \
+     > public_config.h
+if grep HAVE_SYS_TYPES_H confdefs.h > tmp_config.$$; then
+  uniq tmp_config.$$ >> public_config.h
+else
+  echo "#undef HAVE_SYS_TYPES_H" >> public_config.h
+fi
+if grep WORDS_BIGENDIAN confdefs.h > tmp_config.$$; then
+  uniq tmp_config.$$ >> public_config.h
+else
+  echo "#undef WORDS_BIGENDIAN" >> public_config.h
+fi
+rm -f tmp_config.$$
+PUBLIC_CONFIG_HEADER=./public_config.h
+AC_SUBST_FILE(PUBLIC_CONFIG_HEADER)
+dnl
 dnl See if we have inttypes.h and if intptr_t is defined
 dnl
 AC_CHECK_HEADERS([inttypes.h])