From: [EMAIL PROTECTED] Operating system: Solaris 2.7 PHP version: 4CVS-2003-02-02 (stable) PHP Bug Type: Compile Failure Bug description: php_scandir.c will not compile
The HAVE_DIRENT_H and PHP_WIN32 define blocks are reversed in php_scandir.h, included below. As shown, GCC compilation will fail at line 15, blocking the compilation of php_scandir.c. This is because HAVE_DIRENT_H is not defined at the shown line 3, therefore dirent.h does not include. It is the php_config.h include which contains the HAVE_DIRENT_H define. #include <sys/types.h> #ifdef HAVE_DIRENT_H #include <dirent.h> #endif #ifdef PHP_WIN32 #include "config.w32.h" #include "win32/readdir.h" #else #include "php_config.h" #endif #ifndef HAVE_ALPHASORT int alphasort(const struct dirent **a, const struct dirent **b); #endif #ifndef HAVE_SCANDIR int scandir(const char *dirname, struct dirent **namelist[], int (*selector)(const struct dirent *entry), int (*compare)(const struct dirent **a,const struct dirent **b) ); #endif -- Edit bug report at http://bugs.php.net/?id=22021&edit=1 -- Try a CVS snapshot: http://bugs.php.net/fix.php?id=22021&r=trysnapshot Fixed in CVS: http://bugs.php.net/fix.php?id=22021&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=22021&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=22021&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=22021&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=22021&r=support Expected behavior: http://bugs.php.net/fix.php?id=22021&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=22021&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=22021&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=22021&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=22021&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=22021&r=dst IIS Stability: http://bugs.php.net/fix.php?id=22021&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=22021&r=gnused