prefix = /usr
exec_prefix = /usr
PACKAGE_TARNAME = papi
datadir = /usr/share/${PACKAGE_TARNAME}
testlibdir = $(datadir)/testlib
INCLUDE = -I. -I/usr/include -I$(testlibdir)
LIBDIR  = /usr/lib64
PAPILIB = $(LIBDIR)/libpapi.a
TESTLIB = $(testlibdir)/libtestlib.a
LDFLAGS = -ldl
CC	= gcc
F77	= gfortran
CC_R	= $(CC) -pthread
CFLAGS	= -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mcpu=power8 -mtune=power8 -g -DSTATIC_PAPI_EVENTS_TABLE -DPEINCLUDE=\"/usr/include/perfmon/perf_event.h\" -D_REENTRANT -D_GNU_SOURCE -DUSE_COMPILER_TLS  -Wall 
OMPCFLGS = -fopenmp
UTILOBJS = $(TESTLIB)

tests: $(NAME)_tests

install:
	@echo "$(NAME) tests (DATADIR) being installed in: \"$(DATADIR)\""; 
	-mkdir -p $(DATADIR)/$(NAME)/tests
	-chmod go+rx $(DATADIR)
	-chmod go+rx $(DATADIR)/$(NAME)/tests
	-find . -perm -100 -type f -exec cp {} $(DATADIR)/$(NAME)/tests \;
	-chmod go+rx $(DATADIR)/$(NAME)/*
	-find . -name "*.[ch]" -type f -exec cp {} $(DATADIR)/$(NAME)/tests \;
	-cp Makefile $(DATADIR)/$(NAME)/tests
	-cp ../../Makefile_comp_tests $(DATADIR)


