On Fri, May 30, 2003 at 09:16:54 -0500, [EMAIL PROTECTED] wrote:
>    I have a local C library that I interfaced with XS.  The library
>    has an open function that looks for arguments that are sent in to
>    the function.  If the arguments are Null, the function will check
>    env variables for the values.  When calling this function from
>    perl, the env variables are never set.   

So set the environment variables before calling the function from
perl: 

  $ENV{ENV_VAR} = 'value';

or supply the arguments needed to the function.  

>    The function uses this macro,
> 
>    #define GETENV(var, env) ( (var) == NULL ? getenv((env)) : (var) )
> 
>    , this is used to fill a structure that holds the values.  If I
>    send in non-null arguments the values are set correctly.  I
>    cannot get the env variables to populate the C structure.  I can
>    easily interface the env through %ENV, but this is needed
>    internally by the C function.  

Huh?  getenv(3) returns the strings in %ENV.  

>    Any ideas or suggestions?

-- 
Garry Williams, Zvolve Systems, Inc., +1 770 551-4504

Reply via email to