diff -urN diffutils-3.11-orig/configure diffutils-3.11/configure
--- diffutils-3.11-orig/configure	2025-02-03 13:49:48 +0900
+++ diffutils-3.11/configure	2025-02-14 16:14:25 +0900
@@ -2960,6 +2960,7 @@
 ac_user_opts='
 enable_option_checking
 enable_silent_rules
+enable_nanosecond_timestamps
 enable_dependency_tracking
 enable_largefile
 enable_threads
@@ -3617,6 +3618,8 @@
   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
   --enable-silent-rules   less verbose build output (undo: "make V=1")
   --disable-silent-rules  verbose build output (undo: "make V=0")
+  --disable-nanosecond-timestamps
+                          disable nanosecond resolution in timestamps
   --enable-dependency-tracking
                           do not reject slow dependency extractors
   --disable-dependency-tracking
@@ -6174,6 +6177,23 @@
 ac_config_headers="$ac_config_headers lib/config.h:lib/config.hin"
 
 
+# Check whether --enable-nanosecond-timestamps was given.
+if test "${enable_nanosecond_timestamps+set}" = set; then :
+  enableval=$enable_nanosecond_timestamps; case $enableval in
+                 yes|no) ;;
+                 *)      as_fn_error $? "bad value $enableval for nanosecond-timestamps option" "$LINENO" 5 ;;
+               esac
+               nsec_timestamps=$enableval
+else
+  nsec_timestamps=yes
+fi
+
+if ! test "no" = "$nsec_timestamps"; then
+
+$as_echo "#define NSEC_TIMESTAMPS 1" >>confdefs.h
+
+fi
+
 for ac_prog in gawk mawk nawk awk
 do
   # Extract the first word of "$ac_prog", so it can be a program name with args.
diff -urN diffutils-3.11-orig/configure.ac diffutils-3.11/configure.ac
--- diffutils-3.11-orig/configure.ac	2025-02-03 04:17:30 +0900
+++ diffutils-3.11/configure.ac	2025-02-14 16:14:25 +0900
@@ -33,6 +33,20 @@
 
 AC_CONFIG_HEADERS([lib/config.h:lib/config.hin])
 
+AC_ARG_ENABLE(nanosecond-timestamps,
+              [AS_HELP_STRING([--disable-nanosecond-timestamps],
+                              [disable nanosecond resolution in timestamps])],
+              [case $enableval in
+                 yes|no) ;;
+                 *)      AC_MSG_ERROR([bad value $enableval for nanosecond-timestamps option]) ;;
+               esac
+               nsec_timestamps=$enableval],
+              [nsec_timestamps=yes])
+if ! test "no" = "$nsec_timestamps"; then
+  AC_DEFINE([NSEC_TIMESTAMPS], [1],
+            [Define to 1 to enable nanosecond resolution in timestamps.])
+fi
+
 AC_PROG_AWK
 AC_PROG_CC
 AM_MISSING_PROG([HELP2MAN], [help2man])
diff -urN diffutils-3.11-orig/lib/config.hin diffutils-3.11/lib/config.hin
--- diffutils-3.11-orig/lib/config.hin	2025-02-03 11:15:09 +0900
+++ diffutils-3.11/lib/config.hin	2025-02-14 16:14:25 +0900
@@ -2160,6 +2160,9 @@
 /* Define to 1 if nl_langinfo is multithread-safe. */
 #undef NL_LANGINFO_MTSAFE
 
+/* Define to 1 to enable nanosecond resolution in timestamps. */
+#undef NSEC_TIMESTAMPS
+
 /* Define to 1 if open() fails to recognize a trailing slash. */
 #undef OPEN_TRAILING_SLASH_BUG
 
diff -urN diffutils-3.11-orig/src/context.c diffutils-3.11/src/context.c
--- diffutils-3.11-orig/src/context.c	2025-01-13 03:27:47 +0900
+++ diffutils-3.11/src/context.c	2025-02-14 16:16:04 +0900
@@ -77,12 +77,20 @@
       else if (TYPE_SIGNED (time_t))
         {
 	  intmax_t sec = inf->stat.st_mtime;
+#ifdef NSEC_TIMESTAMPS
 	  fprintf (outfile, "%s %s\t%"PRIdMAX".%.9d", mark, name, sec, nsec);
+#else
+	  fprintf (outfile, "%s %s\t%"PRIdMAX, mark, name, sec);
+#endif
 	}
       else
 	{
 	  uintmax_t sec = inf->stat.st_mtime;
+#ifdef NSEC_TIMESTAMPS
 	  fprintf (outfile, "%s %s\t%"PRIuMAX".%.9d", mark, name, sec, nsec);
+#else
+	  fprintf (outfile, "%s %s\t%"PRIuMAX, mark, name, sec);
+#endif
 	}
     }
   set_color_context (RESET_CONTEXT);
diff -urN diffutils-3.11-orig/src/diff.c diffutils-3.11/src/diff.c
--- diffutils-3.11-orig/src/diff.c	2025-02-02 10:31:54 +0900
+++ diffutils-3.11/src/diff.c	2025-02-14 16:16:57 +0900
@@ -748,7 +748,8 @@
 
   if (output_style != OUTPUT_CONTEXT || hard_locale (LC_TIME))
     {
-#if defined STAT_TIMESPEC || defined STAT_TIMESPEC_NS
+#if defined NSEC_TIMESTAMPS && \
+    (defined STAT_TIMESPEC || defined STAT_TIMESPEC_NS)
       time_format = "%Y-%m-%d %H:%M:%S.%N %z";
 #else
       time_format = "%Y-%m-%d %H:%M:%S %z";
