public inbox for glibc-cvs@sourceware.org
help / color / mirror / Atom feed
* [glibc/azanella/y2038] iconv: Use LFS and 64 bit time_t for installed programs
@ 2021-03-04 17:40 Adhemerval Zanella
  0 siblings, 0 replies; 3+ messages in thread
From: Adhemerval Zanella @ 2021-03-04 17:40 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=fe7fa61c45956ee49ee0302501aa60242c29e47f

commit fe7fa61c45956ee49ee0302501aa60242c29e47f
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Tue Mar 2 17:15:03 2021 -0300

    iconv: Use LFS and 64 bit time_t for installed programs
    
    It is enabled for iconv and iconvconfig.

Diff:
---
 iconv/Makefile | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/iconv/Makefile b/iconv/Makefile
index 659857dd8c..b7494efd0c 100644
--- a/iconv/Makefile
+++ b/iconv/Makefile
@@ -94,6 +94,14 @@ $(inst_bindir)/iconv: $(objpfx)iconv_prog $(+force)
 
 $(objpfx)iconv_prog: $(iconv_prog-modules:%=$(objpfx)%.o)
 $(objpfx)iconvconfig: $(iconvconfig-modules:%=$(objpfx)%.o)
+include $(o-iterator)
+define o-iterator-doit
+$(foreach f,$(others:%s=$(objpfx)%.o) $(iconv_prog-modules) \
+	    $(iconvconfig-modules), \
+	    $(objpfx)$(f)$(o)): CFLAGS += -D_TIME_BITS=64 -D_FILE_OFFSET_BITS=64
+endef
+object-suffixes-left := $(all-object-suffixes)
+include $(o-iterator)
 
 $(objpfx)test-iconvconfig.out: /dev/null $(objpfx)iconvconfig
 	(set -e; \


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [glibc/azanella/y2038] iconv: Use LFS and 64 bit time_t for installed programs
@ 2021-03-05 19:22 Adhemerval Zanella
  0 siblings, 0 replies; 3+ messages in thread
From: Adhemerval Zanella @ 2021-03-05 19:22 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=c1285e49f8c88e261e927225dd79f4096590cd53

commit c1285e49f8c88e261e927225dd79f4096590cd53
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Tue Mar 2 17:15:03 2021 -0300

    iconv: Use LFS and 64 bit time_t for installed programs
    
    It is enabled for iconv and iconvconfig.

Diff:
---
 iconv/Makefile | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/iconv/Makefile b/iconv/Makefile
index 659857dd8c..b7494efd0c 100644
--- a/iconv/Makefile
+++ b/iconv/Makefile
@@ -94,6 +94,14 @@ $(inst_bindir)/iconv: $(objpfx)iconv_prog $(+force)
 
 $(objpfx)iconv_prog: $(iconv_prog-modules:%=$(objpfx)%.o)
 $(objpfx)iconvconfig: $(iconvconfig-modules:%=$(objpfx)%.o)
+include $(o-iterator)
+define o-iterator-doit
+$(foreach f,$(others:%s=$(objpfx)%.o) $(iconv_prog-modules) \
+	    $(iconvconfig-modules), \
+	    $(objpfx)$(f)$(o)): CFLAGS += -D_TIME_BITS=64 -D_FILE_OFFSET_BITS=64
+endef
+object-suffixes-left := $(all-object-suffixes)
+include $(o-iterator)
 
 $(objpfx)test-iconvconfig.out: /dev/null $(objpfx)iconvconfig
 	(set -e; \


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [glibc/azanella/y2038] iconv: Use LFS and 64 bit time_t for installed programs
@ 2021-03-04 11:33 Adhemerval Zanella
  0 siblings, 0 replies; 3+ messages in thread
From: Adhemerval Zanella @ 2021-03-04 11:33 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=e813b6f8e9b9ba4aa13a6ec10d1ece4f24def67a

commit e813b6f8e9b9ba4aa13a6ec10d1ece4f24def67a
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Tue Mar 2 17:15:03 2021 -0300

    iconv: Use LFS and 64 bit time_t for installed programs
    
    It is enabled for iconv and iconvconfig.

Diff:
---
 iconv/Makefile        | 8 ++++++++
 iconv/iconv_charmap.c | 4 ++--
 iconv/iconv_prog.c    | 4 ++--
 3 files changed, 12 insertions(+), 4 deletions(-)

diff --git a/iconv/Makefile b/iconv/Makefile
index 659857dd8c..b7494efd0c 100644
--- a/iconv/Makefile
+++ b/iconv/Makefile
@@ -94,6 +94,14 @@ $(inst_bindir)/iconv: $(objpfx)iconv_prog $(+force)
 
 $(objpfx)iconv_prog: $(iconv_prog-modules:%=$(objpfx)%.o)
 $(objpfx)iconvconfig: $(iconvconfig-modules:%=$(objpfx)%.o)
+include $(o-iterator)
+define o-iterator-doit
+$(foreach f,$(others:%s=$(objpfx)%.o) $(iconv_prog-modules) \
+	    $(iconvconfig-modules), \
+	    $(objpfx)$(f)$(o)): CFLAGS += -D_TIME_BITS=64 -D_FILE_OFFSET_BITS=64
+endef
+object-suffixes-left := $(all-object-suffixes)
+include $(o-iterator)
 
 $(objpfx)test-iconvconfig.out: /dev/null $(objpfx)iconvconfig
 	(set -e; \
diff --git a/iconv/iconv_charmap.c b/iconv/iconv_charmap.c
index f76b3ce2b1..f40b0f5119 100644
--- a/iconv/iconv_charmap.c
+++ b/iconv/iconv_charmap.c
@@ -172,11 +172,11 @@ charmap_conversion (const char *from_code, struct charmap_t *from_charmap,
 	  }
 
 #ifdef _POSIX_MAPPED_FILES
-	struct stat64 st;
+	struct stat st;
 	char *addr;
 	/* We have possibilities for reading the input file.  First try
 	   to mmap() it since this will provide the fastest solution.  */
-	if (fstat64 (fd, &st) == 0
+	if (fstat (fd, &st) == 0
 	    && ((addr = mmap (NULL, st.st_size, PROT_READ, MAP_PRIVATE,
 			      fd, 0)) != MAP_FAILED))
 	  {
diff --git a/iconv/iconv_prog.c b/iconv/iconv_prog.c
index c5dbb18519..35c4c3f6d6 100644
--- a/iconv/iconv_prog.c
+++ b/iconv/iconv_prog.c
@@ -255,7 +255,7 @@ conversions from `%s' and to `%s' are not supported"),
 	do
 	  {
 #ifdef _POSIX_MAPPED_FILES
-	    struct stat64 st;
+	    struct stat st;
 	    char *addr;
 #endif
 	    int fd, ret;
@@ -280,7 +280,7 @@ conversions from `%s' and to `%s' are not supported"),
 #ifdef _POSIX_MAPPED_FILES
 	    /* We have possibilities for reading the input file.  First try
 	       to mmap() it since this will provide the fastest solution.  */
-	    if (fstat64 (fd, &st) == 0
+	    if (fstat (fd, &st) == 0
 		&& ((addr = mmap (NULL, st.st_size, PROT_READ, MAP_PRIVATE,
 				  fd, 0)) != MAP_FAILED))
 	      {


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-03-05 19:22 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-04 17:40 [glibc/azanella/y2038] iconv: Use LFS and 64 bit time_t for installed programs Adhemerval Zanella
  -- strict thread matches above, loose matches on Subject: below --
2021-03-05 19:22 Adhemerval Zanella
2021-03-04 11:33 Adhemerval Zanella

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).