File drop_ftime.patch of Package uucp

Index: uucp-1.07/configure
===================================================================
--- uucp-1.07.orig/configure
+++ uucp-1.07/configure
@@ -3837,114 +3837,6 @@ else
 LIBOBJS="$LIBOBJS getlin.o"
 fi
 
-echo $ac_n "checking for ftime""... $ac_c" 1>&6
-echo "configure:3842: checking for ftime" >&5
-if eval "test \"`echo '$''{'ac_cv_func_ftime'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 3847 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char ftime(); below.  */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char ftime();
-
-int main() {
-
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined (__stub_ftime) || defined (__stub___ftime)
-choke me
-#else
-ftime();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:3870: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_ftime=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_ftime=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'ftime`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  echo $ac_n "checking that ftime works correctly""... $ac_c" 1>&6
-echo "configure:3885: checking that ftime works correctly" >&5
-if eval "test \"`echo '$''{'uucp_cv_sys_ftime_ok'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test "$cross_compiling" = yes; then
-  uucp_cv_sys_ftime_ok=runtime
-else
-  cat > conftest.$ac_ext <<EOF
-#line 3893 "configure"
-#include "confdefs.h"
-
-#include <sys/types.h>
-#include <sys/timeb.h>
-main ()
-{
-  struct timeb s, slast;
-  int c = 0;
-  ftime (&slast);
-  while (c < 10)
-    {
-      ftime (&s);
-      if (s.time < slast.time
-	  || (s.time == slast.time && s.millitm < slast.millitm))
-	exit (1);
-      if (s.time != slast.time)
-	++c;
-      slast.time = s.time;
-      slast.millitm = s.millitm;
-    }
-  exit (0);
-}
-
-EOF
-if { (eval echo configure:3918: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-then
-  uucp_cv_sys_ftime_ok=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -fr conftest*
-  uucp_cv_sys_ftime_ok=no
-fi
-rm -fr conftest*
-fi
-
-fi
-
-case $uucp_cv_sys_ftime_ok in
-yes) echo "$ac_t""yes" 1>&6 ;;
-no)  echo "$ac_t""no" 1>&6
-     echo "configure: warning: ftime seems to be buggy" 1>&2 ;;
-runtime) echo "$ac_t""will check at run time" 1>&6 ;;
-esac
-
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-if test $uucp_cv_sys_ftime_ok = yes || test $uucp_cv_sys_ftime_ok = runtime; then
-  cat >> confdefs.h <<\EOF
-#define HAVE_FTIME 1
-EOF
-
-fi
 for ac_func in times
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
Index: uucp-1.07/configure.in
===================================================================
--- uucp-1.07.orig/configure.in
+++ uucp-1.07/configure.in
@@ -371,48 +371,6 @@ AC_CHECK_FUNC(getdelim,
 [AC_LIBOBJ(getlin)])],
 [AC_LIBOBJ(getlin)])
 dnl
-dnl Check for the SCO buggy ftime; the code can cope with the bug,
-dnl though it would prefer not to, so if we're cross-configuring we
-dnl accept that ftime exists.
-AC_CHECK_FUNC(ftime,
-[AC_MSG_CHECKING(that ftime works correctly)
-AC_CACHE_VAL(uucp_cv_sys_ftime_ok,
-[AC_TRY_RUN([
-#include <sys/types.h>
-#include <sys/timeb.h>
-main ()
-{
-  struct timeb s, slast;
-  int c = 0;
-  ftime (&slast);
-  while (c < 10)
-    {
-      ftime (&s);
-      if (s.time < slast.time
-	  || (s.time == slast.time && s.millitm < slast.millitm))
-	exit (1);
-      if (s.time != slast.time)
-	++c;
-      slast.time = s.time;
-      slast.millitm = s.millitm;
-    }
-  exit (0);
-}
-],
-uucp_cv_sys_ftime_ok=yes,
-uucp_cv_sys_ftime_ok=no,
-uucp_cv_sys_ftime_ok=runtime)])
-case $uucp_cv_sys_ftime_ok in
-yes) AC_MSG_RESULT(yes) ;;
-no)  AC_MSG_RESULT(no)
-     AC_MSG_WARN(ftime seems to be buggy) ;;
-runtime) AC_MSG_RESULT(will check at run time) ;;
-esac
-])
-if test $uucp_cv_sys_ftime_ok = yes || test $uucp_cv_sys_ftime_ok = runtime; then
-  AC_DEFINE(HAVE_FTIME, 1, [Whether you have ftime])
-fi
-dnl
 AC_CHECK_FUNCS(times)
 AC_CHECK_FUNCS(napms nap usleep poll select)
 if test $ac_cv_func_napms != yes \
openSUSE Build Service is sponsored by