iliaa           Wed Nov 12 18:43:47 2003 EDT

  Modified files:              
    /php-src    configure.in 
    /php-src/ext/standard       basic_functions.h basic_functions.c 
  Log:
  Added configure check for nanosleep() availability.
  
  
Index: php-src/configure.in
diff -u php-src/configure.in:1.476 php-src/configure.in:1.477
--- php-src/configure.in:1.476  Thu Oct 30 10:14:29 2003
+++ php-src/configure.in        Wed Nov 12 18:43:46 2003
@@ -1,4 +1,4 @@
-dnl ## $Id: configure.in,v 1.476 2003/10/30 15:14:29 sniper Exp $ -*- sh -*-
+dnl ## $Id: configure.in,v 1.477 2003/11/12 23:43:46 iliaa Exp $ -*- sh -*-
 dnl ## Process this file with autoconf to produce a configure script.
 
 divert(1)
@@ -526,6 +526,7 @@
 tzset \
 unsetenv \
 usleep \
+nanosleep \
 utime \
 vsnprintf \
 )
Index: php-src/ext/standard/basic_functions.h
diff -u php-src/ext/standard/basic_functions.h:1.126 
php-src/ext/standard/basic_functions.h:1.127
--- php-src/ext/standard/basic_functions.h:1.126        Wed Nov 12 17:02:37 2003
+++ php-src/ext/standard/basic_functions.h      Wed Nov 12 18:43:46 2003
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: basic_functions.h,v 1.126 2003/11/12 22:02:37 iliaa Exp $ */
+/* $Id: basic_functions.h,v 1.127 2003/11/12 23:43:46 iliaa Exp $ */
 
 #ifndef BASIC_FUNCTIONS_H
 #define BASIC_FUNCTIONS_H
@@ -48,7 +48,9 @@
 PHP_FUNCTION(toggle_short_open_tag);
 PHP_FUNCTION(sleep);
 PHP_FUNCTION(usleep);
+#if HAVE_NANOSLEEP
 PHP_FUNCTION(nanosleep);
+#endif
 PHP_FUNCTION(flush);
 PHP_FUNCTION(ip2long);
 PHP_FUNCTION(long2ip);
Index: php-src/ext/standard/basic_functions.c
diff -u php-src/ext/standard/basic_functions.c:1.639 
php-src/ext/standard/basic_functions.c:1.640
--- php-src/ext/standard/basic_functions.c:1.639        Wed Nov 12 17:02:37 2003
+++ php-src/ext/standard/basic_functions.c      Wed Nov 12 18:43:46 2003
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: basic_functions.c,v 1.639 2003/11/12 22:02:37 iliaa Exp $ */
+/* $Id: basic_functions.c,v 1.640 2003/11/12 23:43:46 iliaa Exp $ */
 
 #include "php.h"
 #include "php_streams.h"
@@ -301,7 +301,9 @@
        PHP_FE(bin2hex,                                                                
                                                 NULL)
        PHP_FE(sleep,                                                                  
                                                 NULL)
        PHP_FE(usleep,                                                                 
                                                 NULL)
+#if HAVE_NANOSLEEP
        PHP_FE(nanosleep,                                                              
                                                 NULL)
+#endif
        PHP_FE(time,                                                                   
                                                 NULL)
        PHP_FE(mktime,                                                                 
                                                 NULL)
        PHP_FE(gmmktime,                                                               
                                                 NULL)
@@ -1691,6 +1693,7 @@
 }
 /* }}} */
 
+#if HAVE_NANOSLEEP
 /* {{{ proto mixed nanosleep(long seconds, long nanoseconds)
    Delay for a number of seconds and nano seconds */
 PHP_FUNCTION(nanosleep)
@@ -1718,6 +1721,7 @@
        RETURN_FALSE;
 }
 /* }}} */
+#endif
 
 /* {{{ proto string get_current_user(void)
    Get the name of the owner of the current PHP script */

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to