By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
464,372 Members | 1,223 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 464,372 IT Pros & Developers. It's quick & easy.

Anybody who making a shared library for PHP in HP and IBM?

P: n/a

I wanna use my dynamic shared library(built with C language) with php
(PHP version is 4.0.6)
So I making a shared library(*.so) in Solaris environment(2.7) and it is
Php script can load my library successfully.

And Now I port my library to HP(HP-UX 11.0) and IBM(AIX 4.1.3) system.
But I can't build my shared library.
I don't know why it can't be compiled.
Following is Error Message:

in HP environment :

ld: Unsatisfied symbols:
_convert_to_string (code)
convert_to_long (code)
zend_get_parameters_ex (code)
_emalloc (code)
alloc_globals (data)
_zval_copy_ctor (code)
wrong_param_count (code)
_estrndup (code)
$global$ (data)
ld: Unsatisfied symbols:
$global$ (data)
*** Error exit code 1


in IBM environment :

ld: 0711-327 WARNING: Entry point not found: __start
ld: 0711-244 ERROR: No csects or exported symbols have been saved.
make: The error code from the last command is 8.
In HP environment, I added libphp4.a for link in my Makefile.
So some error was disappear. But "$global$ (data)" message was seen still.
But I can't added libphp4.a in solaris environment and successfully
What is problem? Did you know this?
Please Help me..

Same as, In IBM enviroment, I can't make a library.
I don't know why above error message occur.
Please help...

Each environment, I added "-r" linker(ld) options.
So it was compiled. But php script can't load my shared library.
Following is error message :

in HP environment :

Unable to load dynamic library
'/usr/local/lib/php/extensions/no-debug-non-zts-20001222/' - Bad
magic number for shared library:
/usr/local/lib/php/extensions/no-debug-non-zts-20001222/ in
in IBM environment :

Unable to load dynamic library
'/usr/local/lib/php/extensions/no-debug-non-zts-20001222/' - Could
not load module
The .loader section does not exist. in <b>a.php</b>
If you know this problem. Please tell me how I fix this problem.

Thank you for reading...

Have a nice day..
Jul 17 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.