AW: [PHP-WIN] problem linking module
| From: | Bruno Haller | Date: | Tue, 14 Aug 2001 09:26:14 +0000 |
| Subject: | AW: [PHP-WIN] problem linking module | ||
| References: | 1 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-8834@lists.php.net to get a copy of this message | ||
Sorry, my mistake.. didnt use the __decl stuff in the prototype.
Bye
Bruno
> -----Ursprüngliche Nachricht-----
> Von: Bruno Haller [mailto:bruno@hil.net]
> Gesendet: Dienstag, 14. August 2001 10:44
> An: php-windows@lists.php.net
> Betreff: [PHP-WIN] problem linking module
>
> Hello,
>
> I am writing a PHP module like I already told in my last question.
> I am using VC++ 6 on Win2000.
>
> I finally managed to compile a module with the simple example from
> zend.com/apidoc
> But when i want to load the .dll with dl() PHP says it is not a PHP
> library
>
> I guess thats because it doesnt export any functions...
>
> I tried to replace
> ZEND_FUNCTION(first_module)
> with
> __declspec(dllexport) ZEND_FUNCTION(first_module)
> but when i do this i get a linker error (it is a german VC++6, i will
> try my best to translate the error message ;):
>
> error C2375: 'zend_if_first_module' : redefinition; different link
> see declaration of 'zend_if_first_module'
>
> when i use
> __declspec(dllexport) void __cdecl
> firstmodule(INTERNAL_FUNCTION_PARAMETERS)
> it says:
> error LNK2001: unresolve external symbol _zend_if_first_module
>
> What am I doing wrong? I am linking php4ts.lib
> How do i write the function correct? I browsed the example workspaces
> for the modules from the PHP source but somehow I didnt find out how
it
> works... (thats where I did copy the __declspec(dllexport) stuff from
at
> all)
>
> Can someone help me?
>
> Regards
> Bruno
>
>
> --
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-windows-unsubscribe@lists.php.net
> For additional commands, e-mail: php-windows-help@lists.php.net
> To contact the list administrators, e-mail:
php-list-admin@lists.php.net