axis-c-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nandika Jayawardana" <jayaw...@gmail.com>
Subject Re: dll description has invalid state
Date Tue, 06 Mar 2007 09:13:12 GMT
Hi Zoli,

AXIS2_EXTERN means whether the function is exported or not from the dll and
AXIS2_CALL is the calling convention of the function. On windows AXIS2_CALL
is expanded as __stdcall and AXIS2_EXTERN as __declspec(dllexport).You can
find more on this by looking at the header file axis2_utils_defines.h.
   When there is AXIS2_CALL in the function, LoadLibrary() function, which
is used to load the dll fails.

Regards,
Nandika




On 3/6/07, Milinda Pathirage <milinda.pathirage@gmail.com> wrote:
>
> hi,
> Please try to compile the source after replacing
>
> AXIS2_EXTERN int AXIS2_CALL
>     axis2_get_instance(struct axis2_svc_skeleton **inst,
>                             const axis2_env_t *env)
>     {
>           ...
>     }
>
> AXIS2_EXTERN int AXIS2_CALL
>     axis2_remove_instance(axis2_svc_skeleton_t *inst,
>                             const axis2_env_t *env)
>     {
>       ...
>     }
>
> to
>
> AXIS2_EXTERN int
> axis2_get_instance(axis2_svc_skeleton_t **inst,
>         const axis2_env_t *env) {
> ...
> }
>
>
> AXIS2_EXTERN int
> axis2_remove_instance(axis2_svc_skeleton_t *inst,
>         const axis2_env_t *env) {
> ...
> }
>
> Also it's better if you can use the current Axis2/C trunk.
>
> Thnaks
> Milinda
>
>
>
>
> On 3/6/07, Zoltán Altfatter <altfatterz@gmail.com> wrote:
>
> > Hi Milinda,
> >
> > Yes, you're right about that functions, there is something wrong with
> > them.
> >
> > I found out something. In Microsoft Visual Studio I build the project
> > like Win32 application, and building this way the sample echo service from
> > Axis2/C and dll created is ok, meaning that I can connect to that with a
> > Java client using Axis2/Java.
> >
> > I tried also this with my generated SayHelloService service.
> > But unfortunately has compile errors which I don't understand:
> >
> > error C2491: 'axis2_get_instance' : definition of dllimport function not
> > allowed
> > error C2491: 'axis2_remove_instance' : definition of dllimport function
> > not allowed
> >
> > The generated axis2_get_instance and axis2_remove_instance functions
> > look like the following:
> >
> > AXIS2_EXTERN int AXIS2_CALL
> >     axis2_get_instance(struct axis2_svc_skeleton **inst,
> >                             const axis2_env_t *env)
> >     {
> >           ...
> >     }
> >
> > AXIS2_EXTERN int AXIS2_CALL
> >     axis2_remove_instance(axis2_svc_skeleton_t *inst,
> >                             const axis2_env_t *env)
> >     {
> >       ...
> >     }
> >
> > I don't understand the AXIS2_EXTERN and AXIS2_CALL what are those...
> >
> > The axis2_get_instance and axis2_remove_instance functions from sample
> > echo service from AXIS2/C look different:
> >
> > AXIS2_EXPORT int
> > axis2_get_instance(axis2_svc_skeleton_t **inst,
> >         const axis2_env_t *env) {
> > ...
> > }
> >
> >
> > AXIS2_EXPORT int
> > axis2_remove_instance(axis2_svc_skeleton_t *inst,
> >         const axis2_env_t *env) {
> > ...
> > }
> >
> > I've attached the generated files to this mail.
> >
> > Could you check them?
> > Thank you.
> >
> > Zoli
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: axis-c-user-unsubscribe@ws.apache.org
> > For additional commands, e-mail: axis-c-user-help@ws.apache.org
> >
> >
>
>
> --
> milinda@wso2.com
> WSO2, Inc: http://www.wso2.com "Oxygenating the Web Service Platform"
> http://www.milindalakmal.wordpress.com
>



-- 
nandika@wso2.com
WSO2 INC www.wso2.com

Mime
View raw message