package M1; use parent qw(Exporter); our @EXPORT; sub func{print "Hello"} #sub import{print "Imported";@EXPORT=qw(func)} 1;