#! /usr/bin/perl -w
#/*@@
#  @file      ConfigureWithPAPI.pl
#  @date      18 May 2005
#  @author    Thomas Radke
#  @desc
#             Finds an external PAPI installation
#  @enddesc
#  @version   $Header$
#@@*/

# PAPI_DIR must be given be the user
my $papi_dir = $ENV{'PAPI_DIR'};
if (! $papi_dir)
{
  print "BEGIN ERROR\n";
  print "PAPIClocks requires an external PAPI installation. Please specify " .
        "PAPI_DIR to point to this installation or remove thorn PAPIClocks " .
        "from your ThornList !\n";
  print "END ERROR\n";
  exit (-1);
}

print <<EOF;
INCLUDE_DIRECTORY $papi_dir/include
LIBRARY_DIRECTORY $papi_dir/lib
LIBRARY           papi perfctr
EOF

exit (0);
