From 8cf4e37523a8ec3fc4267c54f5b7c1a83d3227a0 Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Thu, 24 Feb 2022 18:49:00 +0100
Subject: applying patch timezone_data-2021e.patch


diff --git a/zic.c b/zic.c
index b70a606..f506bc8 100644
--- a/zic.c
+++ b/zic.c
@@ -1138,7 +1138,7 @@ dolink(char const *target, char const *linkname, bool staysymlink)
 	    break;
 	  }
 	  link_errno = errno;
-	  if (link_errno == EXDEV || link_errno == ENOTSUP)
+         if (link_errno == EXDEV || link_errno == ENOTSUP || link_errno == B_UNSUPPORTED)
 	    break;
 
 	  if (link_errno == EEXIST) {
@@ -1150,9 +1150,9 @@ dolink(char const *target, char const *linkname, bool staysymlink)
 	    mkdirs(linkname, true);
 	    linkdirs_made = true;
 	  } else {
-	    fprintf(stderr, _("%s: Can't link %s/%s to %s/%s: %s\n"),
+           fprintf(stderr, _("%s: Can't link %s/%s to %s/%s: %s %x\n"),
 		    progname, directory, target, directory, outname,
-		    strerror(link_errno));
+                   strerror(link_errno), link_errno);
 	    exit(EXIT_FAILURE);
 	  }
 	}
@@ -1178,7 +1178,7 @@ dolink(char const *target, char const *linkname, bool staysymlink)
 	  }
 	  free(linkalloc);
 	  if (symlink_errno == 0) {
-	    if (link_errno != ENOTSUP && link_errno != EEXIST)
+           if (link_errno != ENOTSUP && link_errno !=B_UNSUPPORTED && link_errno != EEXIST)
 	      warning(_("symbolic link used because hard link failed: %s"),
 		      strerror(link_errno));
 	  } else {
@@ -1196,7 +1196,7 @@ dolink(char const *target, char const *linkname, bool staysymlink)
 	      putc(c, tp);
 	    close_file(tp, directory, linkname, tempname);
 	    close_file(fp, directory, target, NULL);
-	    if (link_errno != ENOTSUP)
+           if (link_errno != ENOTSUP && link_errno != B_UNSUPPORTED)
 	      warning(_("copy used because hard link failed: %s"),
 		      strerror(link_errno));
 	    else if (symlink_errno != ENOTSUP)
-- 
2.30.2

