Go Back   ZeroC Forums > Help Center

Reply
 
LinkBack Thread Tools Rate Thread Display Modes
  #1 (permalink)  
Old 03-15-2004
angela.lu angela.lu is offline
Registered User
 
 
Join Date: Feb 2004
Posts: 8
why I can't use slice in icephp?

I tried to run the IcePHP hello demo using PHP5b4 and Apache 2 on Windows 2000. Here is what I did:


Copied php5ts.dll to C:\WINNT\system32

Copied the Ice DLLs and all third-party dependencies to C:\WINNT\system32

Created C:\icephp

Copied php_ice.dll to C:\icephp

Copied Hello.ice to C:\icephp

Copied php.ini-dist from the PHP source directory to C:\Program Files\Apache Group\Apache2\php.ini

Added the following lines to C:\Program Files\Apache Group\Apache2\php.ini:

extension_dir = "C:/icephp"
extension = "php_ice.dll"
ice.slice = "C:/icephp/Hello.ice"


Copied hello.php to C:\Program Files\Apache Group\Apache2\htdocs

Edited hello.php to remove the SSL endpoint from the proxy

Added the following lines to httpd.conf:

LoadModule php5_module C:/php-5.0.0b4-Win32/php5apache2.dll
AddType application/x-httpd-php .php

Start the Apache Server,and I received the error message:
PHP Startup: Unable to initalize module 'ice'

If I delete the following line to C:\Program Files\Apache Group\Apache2\php.ini:

ice.slice = "C:/icephp/Hello.ice"

the error message not show


Anybody can tell me why? Thanks.

angela.lu
Reply With Quote
  #2 (permalink)  
Old 03-15-2004
angela.lu angela.lu is offline
Registered User
 
 
Join Date: Feb 2004
Posts: 8
I traced the Ice_php.dll. There is an exception in Line 408 of Communicator.cpp. The following codes are exception codes:
static void
handleFreeStorage(zend_object* p TSRMLS_DC)
{
ice_object* obj = (ice_object*)p;
if(obj->ptr)
{
Ice::CommunicatorPtr* _this = static_cast<Ice::CommunicatorPtr*>(obj->ptr);
try
{
(*_this)->destroy();
}
catch(const IceUtil::Exception& ex)
{
ostringstream ostr;
ex.ice_print(ostr);
zend_error(E_ERROR, "unable to destroy communicator:\n%s", ostr.str().c_str());
}
delete _this;
}

zend_objects_free_object_storage(p TSRMLS_CC);
}
----------------------------------------------------------------------------------------------

I have tried it in different machines and got the same results.

Any replies are appreciated.

Angela
Reply With Quote
  #3 (permalink)  
Old 03-15-2004
mes's Avatar
mes mes is offline
ZeroC Staff
 
Name: Mark Spruiell
Organization: ZeroC, Inc.
Project: Ice Developer
 
Join Date: Feb 2003
Location: California
Posts: 971
Hi,

Check the messages in Apache's error.log file. I expect that you will see a message like this:

Quote:
'icecpp.exe' is not recognized as an internal or external command,
operable program or batch file.
This means you need to copy icecpp.exe to C:\WINNT\system32.

Take care,
- Mark
Reply With Quote
  #4 (permalink)  
Old 03-15-2004
fengxb's Avatar
fengxb fengxb is offline
Registered User
 
Name: feng xuebin
Organization: jiexin tech
Project: scientific calculation
 
Join Date: Aug 2003
Location: R.P.China
Posts: 78
hi

My OS is WinXP. IcePHP works fine. The same things as Angela happend when I try to migrate it to Win2K. It's very strange. May the IcePHP not support Win2K?

Regards,

Fengxb
__________________
Fengxb
Reply With Quote
  #5 (permalink)  
Old 03-15-2004
angela.lu angela.lu is offline
Registered User
 
 
Join Date: Feb 2004
Posts: 8
Hi,

I check the messages in Apache's error.log file,but I didn't see the message like you said.


And I copy icecpp.exe to C:\WINNT\system32,but I get the same error message.

I try the Ice-1.3.0-VC70.msi and IcePHP-1.0.2-bin-VC70.zip in WIN2000,and they work fine.

Why I can't use ICE1.3.0 and IcePHP1.0.2 with VC6 in Win2000?

Thanks

angela.lu
Reply With Quote
  #6 (permalink)  
Old 03-24-2004
mes's Avatar
mes mes is offline
ZeroC Staff
 
Name: Mark Spruiell
Organization: ZeroC, Inc.
Project: Ice Developer
 
Join Date: Feb 2003
Location: California
Posts: 971
Hi,

I'm fairly certain this error is caused by the use of _popen in the Slice parser. It works fine when you call this function from a VC6 program running in a console, but fails when running as a service. It must have been fixed in the VC.NET runtime. I'm not sure yet whether we'll be able to include a workaround for this in a future Ice release, so for now you will need to use the VC 7.x libraries when using IcePHP with Apache.

Take care,
- Mark
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
IcePHP cesartovic Help Center 2 09-25-2006 01:05 PM
IcePHP 1.0.3 released mes Announcements 0 03-24-2004 03:03 PM
Ice 1.3.0 and IcePHP 1.0.2 released! mes Announcements 0 03-05-2004 09:20 PM
problem with icephp santi Help Center 2 02-07-2004 07:35 AM


All times are GMT -4. The time now is 08:40 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.0.0
(c) 2008 ZeroC, Inc.