emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] /srv/bzr/emacs/trunk r109476: Guard against potential conf


From: Glenn Morris
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r109476: Guard against potential configure bug wrt HAVE_GETWD
Date: Mon, 06 Aug 2012 16:29:45 -0400
User-agent: Bazaar (2.5.0)

------------------------------------------------------------
revno: 109476
committer: Glenn Morris <address@hidden>
branch nick: trunk
timestamp: Mon 2012-08-06 16:29:45 -0400
message:
  Guard against potential configure bug wrt HAVE_GETWD
  
  * configure.ac (BROKEN_GETWD) [unixware]: New define.
  
  * src/sysdep.c: Respect BROKEN_GETWD.
modified:
  ChangeLog
  configure.ac
  src/ChangeLog
  src/sysdep.c
=== modified file 'ChangeLog'
--- a/ChangeLog 2012-08-06 20:22:22 +0000
+++ b/ChangeLog 2012-08-06 20:29:45 +0000
@@ -1,5 +1,7 @@
 2012-08-06  Glenn Morris  <address@hidden>
 
+       * configure.ac (BROKEN_GETWD) [unixware]: New define.
+
        * configure.ac (GNU_LIBRARY_PENDING_OUTPUT_COUNT): Remove.
        (PENDING_OUTPUT_COUNT): Absorb GNU_LIBRARY_PENDING_OUTPUT_COUNT.
        (DISPNEW_NEEDS_STDIO_EXT): New define.

=== modified file 'configure.ac'
--- a/configure.ac      2012-08-06 20:22:22 +0000
+++ b/configure.ac      2012-08-06 20:29:45 +0000
@@ -2724,10 +2724,11 @@
 touchlock \
 cfmakeraw cfsetspeed copysign __executable_start)
 
-dnl FIXME Fragile: something else may test for getwd as a dependency.
-dnl Change to defining BROKEN_xxx ?
 dnl getwd appears to be buggy on SVR4.2, so we don't use it.
-if test $opsys != unixware; then
+if test $opsys = unixware; then
+  dnl In case some other test ends up checking for getwd.
+  AC_DEFINE(BROKEN_GETWD, 1, [Define if getwd should not be used.])
+else
   AC_CHECK_FUNCS(getwd)
 fi
 

=== modified file 'src/ChangeLog'
--- a/src/ChangeLog     2012-08-06 20:22:22 +0000
+++ b/src/ChangeLog     2012-08-06 20:29:45 +0000
@@ -1,5 +1,7 @@
 2012-08-06  Glenn Morris  <address@hidden>
 
+       * sysdep.c: Respect BROKEN_GETWD.
+
        * dispnew.c (GNU_LIBRARY_PENDING_OUTPUT_COUNT, PENDING_OUTPUT_COUNT):
        Let configure handle it.
        (stdio_ext.h) [DISPNEW_NEEDS_STDIO_EXT]: Include it.

=== modified file 'src/sysdep.c'
--- a/src/sysdep.c      2012-08-06 11:16:07 +0000
+++ b/src/sysdep.c      2012-08-06 20:29:45 +0000
@@ -1971,7 +1971,7 @@
  *     under error conditions.
  */
 
-#ifndef HAVE_GETWD
+#if !defined (HAVE_GETWD) || defined (BROKEN_GETWD)
 
 #ifndef MAXPATHLEN
 /* In 4.1, param.h fails to define this.  */
@@ -2001,7 +2001,7 @@
   return pathname;
 }
 
-#endif /* HAVE_GETWD */
+#endif /* !defined (HAVE_GETWD) || defined (BROKEN_GETWD) */
 
 /*
  *     This function will go away as soon as all the stubs fixed. (fnf)


reply via email to

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