use Inline Config => INC => '-I/my/path', LIBS => '-L/your/path -lyourlib'; use Inline CPP => <<'END'; /* your C++ code */ END # your perl code