package c; use vars qw($AUTOLOAD); use c::stuff; use MDK::Common; sub AUTOLOAD() { $AUTOLOAD =~ /::(.*)/ or return; my $fct = $1; my @l = eval { &{$c::stuff::{$fct}} }; if (my $err = $@) { $err =~ /Undefined subroutine &main::/ ? die("cannot find function $AUTOLOAD\n" . backtrace()) : die("$fct: " . $err); } wantarray() ? @l : $l[0]; } 1; =head1 SYNOPSYS The C module is glue code between the Perl & the C worlds that enable drakx to: =over =item * access various C libraries, mainly libldetect =item * bind some C functions (eg: syslog(), ...) =item * implement in C some helper functions =back It is autogenerated from perl-install/c/stuff.xs.pl. One needs to run "perl Makefile.PL" It's used quite a lot by L. =cut