bug-texinfo
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

DJGPP specific issues concerning LC_MESSAGES


From: Juan Manuel Guerrero
Subject: DJGPP specific issues concerning LC_MESSAGES
Date: Fri, 30 Apr 2004 22:11:35 +0200

While I was trying to compile Texinfo 4.7 I have found the following issues:
1) The definition of LC_MESSAGES have been completely removed from the
   sources. This was previously defined in system.h. This have been done
   because this definition is now part of libintl.h. Unfortunatly not
   every user has an actual port of GNU gettext installed with that
   header defining LC_MESSAGE.
2) In makeinfo/node.c there is a new function called enumerate_filename.
   In this function the variable: dos_file_names is defined as static
   and initialised with pathconf making the compiler complain.
Please note the small patch fixing the issues. The patch is against stock 
texinfo 4.7

Regards,
Juan M. Guerrero


diff -apruNU3 texinfo-4.7.orig/lib/system.h texinfo-4.7.djgpp/lib/system.h
--- texinfo-4.7.orig/lib/system.h       2004-03-26 18:22:16.000000000 +0000
+++ texinfo-4.7.djgpp/lib/system.h      2004-04-30 15:11:10.000000000 +0000
@@ -198,6 +198,15 @@ extern int strcoll ();
 # ifdef __MSDOS__
 #  include <limits.h>
 #  ifdef __DJGPP__
+   /*
+      Not all DJGPP installations have an actual port
+      port of GNU gettext installed, so do not relay
+      on the fact that LC_MESSAGES will be defined
+      in libintl.h.
+   */
+#   ifndef HAVE_LC_MESSAGES
+#    define LC_MESSAGES (-1)
+#   endif
 #   define HAVE_LONG_FILENAMES(dir)  (pathconf (dir, _PC_NAME_MAX) > 12)
 #   define NULL_DEVICE "/dev/null"
 #   define DEFAULT_INFOPATH "c:/djgpp/info;/usr/local/info;/usr/info;."
diff -apruNU3 texinfo-4.7.orig/makeinfo/node.c texinfo-4.7.djgpp/makeinfo/node.c
--- texinfo-4.7.orig/makeinfo/node.c    2004-03-01 08:20:30.000000000 +0000
+++ texinfo-4.7.djgpp/makeinfo/node.c   2004-04-30 15:47:28.000000000 +0000
@@ -1621,7 +1621,7 @@ static char *
 enumerate_filename (char *pathname, char *basename, int number)
 {
   /* Do we need to generate names of subfiles which don't exceed 8+3 limits? */
-  static const int dos_file_names = !HAVE_LONG_FILENAMES (pathname ? pathname 
: ".");
+  const int dos_file_names = !HAVE_LONG_FILENAMES (pathname ? pathname : ".");
   unsigned name_len = strlen (basename);
   char *filename = xmalloc (10 + strlen (pathname) + name_len);
   char *base_filename = xmalloc (10 + name_len);





reply via email to

[Prev in Thread] Current Thread [Next in Thread]