in reply to Re: Require in modules...?
in thread Require in modules...?

Now, it's probably better to use use instead, since use directives are processed earlier, and all you have to do to convert "data_defs.pl" to a useable module is to to rename it to "data_defs.pm" (that name is contrary to conventions but it'll work all the same).

I disagree. Modules can be required or used multiple times, but data_defs.pl cannot. To convert data_defs.pl to a module, you'll also need to add a package declaration, which means you'll also need to import the variables from the module use access them via their qualified names.

If you want the loading to occur earlier, use

BEGIN { do 'data_defs.pl' or die "Can't load data defs: " . ($@||$!); +}