use Inline ( C => Config => LIBS => '-lyourlib', AUTO_INCLUDE => '#include "header.h";' ); function1 (NULL);