Re: Linking and autoloading of dependent extensions
| From: | Johannes Schlüter | Date: | Tue, 27 May 2014 12:32:07 +0000 |
| Subject: | Re: Linking and autoloading of dependent extensions | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-74518@lists.php.net to get a copy of this message | ||
Hi,
On Tue, 2014-05-27 at 14:13 +0200, Michael Wallner wrote:
> I've prepared a tiny POC which enables linking and autoloading of
> dependent extensions:
> https://github.com/m6w6/php-src/compare/module_deps
>
> Anybody else other than me interested in this feature?
This is a problem hurting me for a while and I'm happy you're looking
into it! I'm not sure about the solution here, though. This solution
assumes
* the extension is inside extension_dir and
* a specific naming scheme on the extension's shared library file.
Both assumptions might be wrong and might lead to loading the wrong file
when different ones are around. This will also lead to a misleading
error message ("PHP Warning: Module 'foo' already loaded in Unknown on
line 0") where the users just tries to load it once in wrong order.
I'm not sure this is better than completely offloading it to the user,
as we do now.
johannes
Attachment: [application/pgp-signature] This is a digitally signed message part signature.asc
Attachment: [application/pgp-signature] This is a digitally signed message part signature.asc