|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2009-10-16 10:52 UTC] admin at atilailhankartal dot com dot tr
Description: ------------ Error 1 fatal error C1017: invalid integer constant expression \tsrm\tsrm_config_common.h 5 php_myextension my compiler Visual Studio C++ 2008 (VC9) Reproduce code: --------------- #ifndef TSRM_CONFIG_COMMON_H #define TSRM_CONFIG_COMMON_H #ifndef __CYGWIN__ # if WINNT|WIN32 // Problemed row # define TSRM_WIN32 # endif #endif #ifdef TSRM_WIN32 # include "tsrm_config.w32.h" #else # include <tsrm_config.h> # include <sys/param.h> #endif PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2026 The PHP GroupAll rights reserved. |
Last updated: Tue Jun 23 09:00:01 2026 UTC |
Yeah. ?t is realy; My ext have not a problem but my ext a helloWorld function for test. My Code hello.c #ifdef HAVE_CONFIG_H #include "config.h" #endif #include "php.h" #include "php_hello.h" static function_entry hello_functions[] = { PHP_FE(hello_world, NULL) {NULL, NULL, NULL} }; zend_module_entry hello_module_entry = { #if ZEND_MODULE_API_NO >= 20010901 STANDARD_MODULE_HEADER, #endif PHP_HELLO_WORLD_EXTNAME, hello_functions, NULL, NULL, NULL, NULL, NULL, #if ZEND_MODULE_API_NO >= 20010901 PHP_HELLO_WORLD_VERSION, #endif STANDARD_MODULE_PROPERTIES }; #ifdef COMPILE_DL_HELLO ZEND_GET_MODULE(hello) #endif PHP_FUNCTION(hello_world) { RETURN_STRING("Hello World", 1); } php_hello.h #ifndef PHP_HELLO_H #define PHP_HELLO_H 1 #define PHP_HELLO_WORLD_VERSION "1.0" #define PHP_HELLO_WORLD_EXTNAME "hello" PHP_FUNCTION(hello_world); extern zend_module_entry hello_module_entry; #define phpext_hello_ptr &hello_module_entry #endif My Included Directories "C:\PHPDEV\php-5.3.0"; "C:\PHPDEV\php-5.3.0\Zend"; "C:\PHPDEV\php-5.3.0\win32"; "C:\PHPDEV\php-5.3.0\TSRM"; "C:\PHPDEV\php-5.3.0\main" And My Preprocessor Definitions ZEND_DEBUG=0; COMPILE_DL_MYEXT; ZTS=1; ZEND_WIN32; PHP_WIN32; MYEXT can u analysis this code and parameters. Thanks Atilla ?lhan KARTAL Web Application & Software Architect Turkey Republic