Page 1 of 1

Writing custom PHP extensions

Posted: Wed Jul 02, 2003 3:15 am
by Tech-X
I'm trying to compile my own PHP extension, but I'm running into an error:

I'm using MS VC++ 6.0 on Windows 98SE with PHP4.3.2. The only error I'm having is that strings.h doesn't exist:
Deleting intermediate files and output files for project 'ext_attempt - Win32 Release_TS'.
--------------------Configuration: ext_attempt - Win32 Release_TS--------------------
Compiling...
main.c
..\..\main\php_config.h(3) : warning C4005: 'ZEND_API' : macro redefinition
..\..\Zend\zend_config.w32.h(72) : see previous definition of 'ZEND_API'
..\..\main\php_config.h(4) : warning C4005: 'ZEND_DLEXPORT' : macro redefinition
..\..\Zend\zend_config.w32.h(75) : see previous definition of 'ZEND_DLEXPORT'
..\..\main\php_config.h(2502) : fatal error C1083: Cannot open include file: 'strings.h': No such file or directory
Error executing cl.exe.

ext_attempt.dll - 1 error(s), 2 warning(s)


Any help?

Posted: Wed Jul 02, 2003 4:01 am
by []InTeR[]
Do you have the include dir's right?

Posted: Wed Jul 02, 2003 11:21 am
by Tech-X
Yeah, and I got to looking, and I don't actually DONT have strings.h anywhere on my system.. is this s PHP specific header file? I thought it was supposed to be with all C compilers?

Posted: Thu Jul 03, 2003 5:36 am
by m3mn0n

Posted: Thu Jul 03, 2003 9:06 pm
by Tech-X
Sami wrote:hmmm....
Awesome! I would have never thought about searching 1 billion+ web pages for the source file! :wink:
Aside from the obvious risks of downloading some random code out there, most of the header files I tried to get wouldn't work at all.

So, I just got rid of Windows and switched over to a real OS, RedHat. Fixed every problem heh.