New Ticket     Wiki     Browse Source     Timeline     Roadmap     Ticket Reports     Search

Ticket #14337: man-patches.diff

File man-patches.diff, 12.6 KB (added by jmr@…, 3 years ago)

Add latest Apple patches and turn off color codes

  • files/src__man.conf.in.diff

     
     1--- src/man.conf.in.orig        2005-08-20 16:26:06.000000000 -0700 
     2+++ src/man.conf.in     2007-01-12 16:53:47.000000000 -0800 
     3@@ -36,11 +36,9 @@ 
     4 # 
     5 # Every automatically generated MANPATH includes these fields 
     6 # 
     7-MANPATH        /usr/man 
     8 MANPATH        /usr/share/man 
     9-MANPATH        /usr/local/man 
     10 MANPATH        /usr/local/share/man 
     11-MANPATH        /usr/X11R6/man 
     12+MANPATH        /usr/X11/man 
     13 # 
     14 # Uncomment if you want to include one of these by default 
     15 # 
     16@@ -64,8 +62,8 @@ 
     17 MANPATH_MAP    /usr/sbin               /usr/share/man 
     18 MANPATH_MAP    /usr/local/bin          /usr/local/share/man 
     19 MANPATH_MAP    /usr/local/sbin         /usr/local/share/man 
     20-MANPATH_MAP    /usr/X11R6/bin          /usr/X11R6/man 
     21-MANPATH_MAP    /usr/bin/X11            /usr/X11R6/man 
     22+MANPATH_MAP    /usr/X11/bin            /usr/X11/man 
     23+MANPATH_MAP    /usr/bin/X11            /usr/X11/man 
     24 MANPATH_MAP    /usr/bin/mh             /usr/share/man 
     25 # 
     26 # NOAUTOPATH keeps man from automatically adding directories that look like 
  • files/src__manpath.c.diff

     
     1--- src/manpath.c.orig  Sun Nov 14 15:25:42 2004 
     2+++ src/manpath.c       Sun Nov 14 15:34:32 2004 
     3@@ -137,6 +137,14 @@ 
     4          len += 3; 
     5      } 
     6  
     7+#if defined(__APPLE__) 
     8+     /* Try to use share/man (3545105). */ 
     9+     strcpy (t + len, "/share/man"); 
     10+ 
     11+     if (is_directory (t) == 1) 
     12+         return t; 
     13+#endif 
     14+ 
     15      /* look for the situation with packagedir/bin and packagedir/man */ 
     16      strcpy (t + len, "/man"); 
     17  
  • files/PR3857969.diff

     
     1--- src/man.c.orig      2004-12-01 12:37:16.000000000 -0800 
     2+++ src/man.c   2004-12-01 12:30:59.000000000 -0800 
     3@@ -1228,7 +1228,7 @@ 
     4  
     5 int 
     6 main (int argc, char **argv) { 
     7-     int status = 0; 
     8+     int status = 1; 
     9      char *nextarg; 
     10      char *tmp; 
     11      char *section = 0; 
  • files/configure.diff

     
     1--- configure.orig      Sat Oct 23 06:24:51 2004 
     2+++ configure   Sat Oct 23 06:37:44 2004 
     3@@ -474,17 +474,12 @@ 
     4     troff="troff -mandoc" 
     5     echo "Warning: could not find groff" 
     6   else 
     7-    if test $Fnroff = "missing" 
     8-    then 
     9-      nroff="$Fgroff -Tlatin1 -mandoc" 
     10-    else 
     11-      nroff="$Fnroff -Tlatin1 -mandoc" 
     12-    fi 
     13+    nroff="$Fgroff -P-c -Wall -mtty-char -Tascii -mandoc" 
     14     troff="$Fgroff -Tps -mandoc" 
     15     jnroff="$Fgroff -Tnippon -mandocj" 
     16   fi 
     17   eqn="$Fgeqn -Tps" 
     18-  neqn="$Fgeqn -Tlatin1" 
     19+  neqn="$Fgeqn -Tascii" 
     20   jneqn="$Fgeqn -Tnippon" 
     21   tbl="$Fgtbl" 
     22   col="$Fcol" 
  • files/PR4121764.diff

     
     1--- man/en/whatis.man.orig      2006-06-02 12:25:41.000000000 -0700 
     2+++ man/en/whatis.man   2006-06-02 12:25:59.000000000 -0700 
     3@@ -24,7 +24,7 @@ 
     4 of system commands for keywords and displays the result on the 
     5 standard output.  Only complete word matches are displayed. 
     6  
     7-The whatis database is created using the command @makewhatis@. 
     8+The whatis database is created using the command /usr/libexec/makewhatis. 
     9 .SH AUTHOR 
     10 John W. Eaton was the original author of 
     11 .BR "man" . 
  • files/PR4302566.diff

     
     1--- src/man.c.orig      2006-06-02 12:52:27.000000000 -0700 
     2+++ src/man.c   2006-06-02 15:11:32.000000000 -0700 
     3@@ -335,7 +335,7 @@ 
     4      if (expander && *expander) { 
     5          char *command; 
     6  
     7-         command = my_xsprintf ("%s %S", expander, name); 
     8+         command = my_xsprintf ("%s '%Q'", expander, name); 
     9          fp = my_popen (command, "r"); 
     10          if (fp == NULL) { 
     11               perror("popen"); 
     12@@ -604,10 +604,10 @@ 
     13  
     14      if (expander && *expander) { 
     15          if (converter && *converter) 
     16-            command = my_xsprintf("%s%s '%S' | %s%s", 
     17+            command = my_xsprintf("%s%s '%Q' | %s%s", 
     18                                   bufh, expander, file, converter, buft); 
     19          else 
     20-            command = my_xsprintf("%s%s '%S'%s", 
     21+            command = my_xsprintf("%s%s '%Q'%s", 
     22                                   bufh, expander, file, buft); 
     23      } else if (ll || pl) { 
     24          const char *cat = getval("CAT"); 
     25@@ -615,10 +615,10 @@ 
     26                  cat = "cat"; 
     27  
     28          if (converter && *converter) 
     29-             command = my_xsprintf("%s%s '%S' | %s%s", 
     30+             command = my_xsprintf("%s%s '%Q' | %s%s", 
     31                                    bufh, cat, file, converter, buft); 
     32          else 
     33-             command = my_xsprintf("%s%s '%S'%s", 
     34+             command = my_xsprintf("%s%s '%Q'%s", 
     35                                    bufh, cat, file, buft); 
     36      } 
     37  
     38@@ -641,7 +641,7 @@ 
     39      } 
     40  
     41      if (expander && *expander) { 
     42-         char *cmd = my_xsprintf ("%s %S", expander, file); 
     43+         char *cmd = my_xsprintf ("%s '%Q'", expander, file); 
     44          fp = my_popen (cmd, "r"); 
     45          if (fp == NULL) { 
     46               perror("popen"); 
     47@@ -826,9 +826,9 @@ 
     48      if (roff_command == NULL) 
     49          return 0; 
     50      if (do_troff) 
     51-         command = my_xsprintf ("(cd \"%S\" && %s)", path, roff_command); 
     52+         command = my_xsprintf ("(cd '%Q' && %s)", path, roff_command); 
     53      else 
     54-         command = my_xsprintf ("(cd \"%S\" && %s | (%s || true))", path, 
     55+         command = my_xsprintf ("(cd '%Q' && %s | (%s || true))", path, 
     56                   roff_command, pager); 
     57  
     58      return !do_system_command (command, 0); 
  • files/PR4062483.diff

     
     1--- src/man.c.orig      2006-06-02 12:52:27.000000000 -0700 
     2+++ src/man.c   2006-06-02 13:16:28.000000000 -0700 
     3@@ -407,6 +407,9 @@ 
     4      if (strlen(name) + strlen(beg) + 1 >= BUFSIZ) 
     5          return 0;             /* very long names, ignore */ 
     6  
     7+     if (beg[0] == '/') { 
     8+         strcpy(name, beg); 
     9+     } else 
     10      if (!index(beg, '/')) { 
     11          /* strange.. try same directory as the .so file */ 
     12          strcat(name, "/"); 
  • files/PR4006198.diff

     
     1--- src/man.c.orig      2006-06-02 12:52:27.000000000 -0700 
     2+++ src/man.c   2006-06-12 17:08:25.000000000 -0700 
     3@@ -380,6 +380,9 @@ 
     4          return (NULL); 
     5      } 
     6  
     7+     if (!isascii(buf[0])) 
     8+         return (NULL); 
     9+ 
     10      if (strncmp(buf, ".so", 3)) 
     11          return (my_strdup(name)); 
     12  
  • files/PR4670363.diff

     
     1--- src/apropos.sh.orig 2006-08-07 13:10:29.000000000 -0700 
     2+++ src/apropos.sh      2006-08-07 13:10:36.000000000 -0700 
     3@@ -22,7 +22,7 @@ 
     4 aproposgrepopt1='i' 
     5 aproposgrepopt2='' 
     6 whatisgrepopt1='iw' 
     7-whatisgrepopt2='^' 
     8+whatisgrepopt2='' 
     9 grepopt1=$%apropos_or_whatis%grepopt1 
     10 grepopt2=$%apropos_or_whatis%grepopt2 
     11  
  • files/src__man-getopt.c.diff

     
     1--- src/man-getopt.c.orig       Sat Oct 23 05:38:46 2004 
     2+++ src/man-getopt.c    Sat Oct 23 06:17:04 2004 
     3@@ -39,7 +39,7 @@ 
     4      exit(1); 
     5 } 
     6  
     7-static char short_opts[] = "B:C:H:xM:P:S:acdDfFhkKm:p:s:tvVwW?"; 
     8+static char short_opts[] = "B:C:H:xM:P:S:acdDfFhkKm:p:s:tvVwW?Lq"; 
     9  
     10 #ifndef NOGETOPT 
     11 #undef _GNU_SOURCE 
     12@@ -167,6 +167,11 @@ 
     13                    fatal (INCOMPAT, "-w", "-t"); 
     14               print_where++; 
     15               break; 
     16+         /* Silently ignore manpath -q and -L (3825529). */ 
     17+         case 'L': 
     18+         case 'q': 
     19+              if (!strncmp(progname, "manpath", 7)) 
     20+                   break; 
     21          case 'h': 
     22          case '?': 
     23          default: 
  • files/src__man.c.diff

     
     1--- src/man.c.orig      Sun Aug 22 20:18:06 2004 
     2+++ src/man.c   Sun Nov 14 15:53:53 2004 
     3@@ -150,6 +153,10 @@ 
     4 static char * 
     5 setpl(void) { 
     6      char *pl; 
     7+ 
     8+     /* Short-circuit bogus behavior (3828722). */ 
     9+     return NULL; 
     10+ 
     11      if (do_troff) 
     12          return NULL; 
     13      if (preformat) 
  • files/PR4076593.diff

     
     1--- src/apropos.sh.orig 2006-09-20 15:40:51.000000000 -0700 
     2+++ src/apropos.sh      2006-09-20 15:45:59.000000000 -0700 
     3@@ -83,6 +83,6 @@ 
     4     fi 
     5  
     6     shift 
     7-done 
     8+done | ${PAGER:-more -E} 
     9  
     10 exit 
  • files/PR3845474.diff

     
     1--- src/man.c.orig      2006-06-02 12:52:27.000000000 -0700 
     2+++ src/man.c   2006-06-02 15:15:54.000000000 -0700 
     3@@ -828,7 +828,7 @@ 
     4      if (do_troff) 
     5          command = my_xsprintf ("(cd \"%S\" && %s)", path, roff_command); 
     6      else 
     7-         command = my_xsprintf ("(cd \"%S\" && %s | %s)", path, 
     8+         command = my_xsprintf ("(cd \"%S\" && %s | (%s || true))", path, 
     9                   roff_command, pager); 
     10  
     11      return !do_system_command (command, 0); 
  • files/src__util.c.diff

     
     1--- src/util.c.orig     Sun Nov 14 15:48:13 2004 
     2+++ src/util.c  Sun Nov 14 15:48:22 2004 
     3@@ -273,7 +273,7 @@ 
     4                        case 'S': /* check and turn into 's' */ 
     5                                ss = va_arg(p, char *); 
     6                                if (!is_shell_safe(ss, (s[1] == 'Q'))) 
     7-                                       return NOT_SAFE; 
     8+                                       return my_strdup(NOT_SAFE); 
     9                                len += strlen(ss); 
     10                                s[1] = 's'; 
     11                                break; 
  • files/PR3939085.diff

     
     1--- src/manfile.c.orig  2006-06-01 17:16:00.000000000 -0700 
     2+++ src/manfile.c       2006-06-01 17:37:31.000000000 -0700 
     3@@ -147,10 +147,14 @@ 
     4 static char ** 
     5 glob_for_file (const char *dir, const char *sec, const char *name, int type) { 
     6      char **names; 
     7+     char shortsec[2]; 
     8  
     9      if (debug >= 2) 
     10         gripe(CALLTRACE2, dir, sec, name, type); 
     11  
     12+     shortsec[0] = sec[0]; 
     13+     shortsec[1] = '\0'; 
     14+ 
     15      if (standards & DO_IRIX) { 
     16          /* try first without `sec' extension */ 
     17          /* maybe this should be done only for cat pages? */ 
     18@@ -158,7 +162,7 @@ 
     19      } 
     20  
     21      /* try /usr/X11R6/man/man3x/XSetFont.3x */ 
     22-     names = glob_for_file_ext (dir, sec, name, sec, type); 
     23+     names = glob_for_file_ext (dir, shortsec, name, sec, type); 
     24  
     25      if (!names) 
     26          return 0;             /* out-of-memory or error */ 
  • Portfile

     
    44 
    55name                    man 
    66version                 1.6f 
     7revision                1 
    78categories              sysutils 
    89platforms               darwin 
    910maintainers             mww 
     
    1920                patch-configure-prepath \ 
    2021                                patch-gencat-genlib.c \ 
    2122                                patch-man2html_Makefile.in \ 
    22                                 configure.diff 
    23 patch_sites             http://www.opensource.apple.com/darwinsource/10.4.8.ppc/man-4/patches/ 
     23                                configure.diff \ 
     24                                PR3845474.diff \ 
     25                                PR3857969.diff \ 
     26                                PR3939085.diff \ 
     27                                PR4006198.diff \ 
     28                                PR4062483.diff \ 
     29                                PR4076593.diff \ 
     30                                PR4302566.diff \ 
     31                                PR4670363.diff \ 
     32                                src__man-getopt.c.diff \ 
     33                                src__man.c.diff \ 
     34                                src__manpath.c.diff \ 
     35                                src__util.c.diff \ 
     36                                src__man.conf.in.diff 
    2437 
    25 checksums               ${distfiles} md5 67aaaa6df35215e812fd7d89472c44b6 \ 
    26                                 ${distfiles} sha1 c97012607ed9d75a6eee7e66d257a99a8ed86918 \ 
    27                                 ${distfiles} rmd160 8680bb94bff9b86fb9d061f58d9acb08c934531e \ 
    28                                 \ 
    29                                 configure.diff md5 9b9b0c22f7249391dfafe905ac8837ab \ 
    30                                 configure.diff sha1 1754a380d8b1b1e1a5c5ebb66fbda69adfdb4aae \ 
    31                                 configure.diff rmd160 5a3a5bdc0c5f0653393b5078a9f275bd7df8c59c 
     38checksums               md5 67aaaa6df35215e812fd7d89472c44b6 \ 
     39                                sha1 c97012607ed9d75a6eee7e66d257a99a8ed86918 \ 
     40                                rmd160 8680bb94bff9b86fb9d061f58d9acb08c934531e 
    3241 
    3342configure.args  --mandir=${prefix}/share/man \ 
    3443                                -compatibility_mode_for_colored_groff \ 
     
    4756variant man_all_lang { 
    4857        configure.args-append +lang all 
    4958} 
     59 
     60platform darwin 8 { 
     61    patchfiles-delete   src__man.conf.in.diff 
     62}