+ if (!defined $AUTOLOAD and defined $::AUTOLOAD) {
+ &DEBUG("AUTOLOAD: hrm.. ::AUTOLOAD defined!");
+ }
+ return unless (defined $AUTOLOAD);
+ return if ($AUTOLOAD =~ /__/); # internal.
+
+ my $str = join(', ', @_);
+ my ($package, $filename, $line) = caller;
+ &ERROR("UNKNOWN FUNCTION CALLED: $AUTOLOAD ($str) $filename line $line");
+
+ $AUTOLOAD =~ s/^(\S+):://g;
+
+ if (exists $myModules{lc $AUTOLOAD}) {
+ # hopefully this will work.
+ &DEBUG("Trying to load module $AUTOLOAD...");
+ &loadMyModule(lc $AUTOLOAD);
+ }
+}
+
+sub getPerlFiles {
+ my($dir) = @_;
+
+ if (!opendir(DIR, $dir)) {
+ &ERROR("Cannot open source directory ($dir): $!");
+ exit 1;