nvi-20-glibc_has_grantpt.patch (884B)
1 #! /bin/sh /usr/share/dpatch/dpatch-run 2 ## 20glibc_has_grantpt.dpatch by <hesso@pool.math.tu-berlin.de> 3 ## 4 ## DP: glibc has grantpt(), so only hceck for HAVE_SYS5_PTY 5 ## DP: on non-glibc installations. 6 7 @DPATCH@ 8 diff -Naur nvi-1.81.6.orig/ex/ex_script.c nvi-1.81.6/ex/ex_script.c 9 --- nvi-1.81.6.orig/ex/ex_script.c 2007-11-18 17:41:42.000000000 +0100 10 +++ nvi-1.81.6/ex/ex_script.c 2008-05-01 18:24:06.000000000 +0200 11 @@ -23,7 +23,8 @@ 12 #include <sys/select.h> 13 #endif 14 #include <sys/stat.h> 15 -#ifdef HAVE_SYS5_PTY 16 +/* glibc2.1 defines grantpt but there is no stropts.h */ 17 +#if defined(HAVE_SYS5_PTY) && !defined(__GLIBC__) 18 #include <sys/stropts.h> 19 #endif 20 #include <sys/time.h> 21 @@ -664,7 +665,7 @@ 22 F_CLR(gp, G_SCRWIN); 23 } 24 25 -#ifdef HAVE_SYS5_PTY 26 +#if defined(HAVE_SYS5_PTY) && !defined(__GLIBC__) 27 static int ptys_open __P((int, char *)); 28 static int ptym_open __P((char *)); 29