How to source variables and values from a file, like in UNIX sh scripts?

From: Ronnie Laurikkala (ronnie.laurikkala_at_ericsson.com)
Date: 12/18/03


Date: Thu, 18 Dec 2003 11:21:43 +0100

In e.g. a Bourne shell script I can source variables and values;
#!/bin/sh
. ${HOME}/script_common_lib

How can I source variables and values from a file
and use them in Perl-scripts?

Perl-"pseudo code":
     ...
     source("${HOME}/script_common_lib");
     $logfile = $A_LOG_FILE;
     ...
     print "Log file name: ", $logfile;
     ...

And in the file '${HOME}/script_common_lib' contains e.g.:
     ...
     export A_LOG_FILE=/tmp/foo.log
     ...

Best Regards,
Ronnie