package Library; ... sub import { my $calling = (caller())[0]; eval qq{ # Load these on behalf of the calling package. package $calling; use Library::This; use Library::That; use Library::TheOther::Thing; }; die $@ if $@; }