2013-10-04 13:22:00 +01:00
|
|
|
#
|
|
|
|
# default base directory for YAP installation
|
|
|
|
# (EROOT for architecture-dependent files)
|
|
|
|
#
|
|
|
|
prefix = @prefix@
|
|
|
|
exec_prefix = @exec_prefix@
|
|
|
|
ROOTDIR = $(prefix)
|
|
|
|
EROOTDIR = @exec_prefix@
|
|
|
|
abs_top_builddir = @abs_top_builddir@
|
|
|
|
#
|
|
|
|
# where the binary should be
|
|
|
|
#
|
|
|
|
BINDIR = $(EROOTDIR)/bin
|
|
|
|
#
|
|
|
|
# where YAP should look for libraries
|
|
|
|
#
|
|
|
|
LIBDIR=@libdir@
|
|
|
|
SHAREDIR=$(ROOTDIR)/share/Yap
|
|
|
|
YAPLIBDIR=@libdir@/Yap
|
|
|
|
#
|
|
|
|
#
|
|
|
|
CC=@CC@
|
2013-10-07 12:20:00 +01:00
|
|
|
NVCC=@NVCC@
|
2013-10-04 13:22:00 +01:00
|
|
|
CFLAGS= @SHLIB_CFLAGS@ $(YAP_EXTRAS) $(DEFS) -I$(srcdir) -I../.. -I$(srcdir)/../../include @CUDA_CPPFLAGS@
|
2013-10-07 12:20:00 +01:00
|
|
|
NVCCFLAGS=@CUDA_CPPFLAGS@ -I$(srcdir) -I../.. -I$(srcdir)/../../include
|
2013-10-04 13:22:00 +01:00
|
|
|
LDFLAGS=@LDFLAGS@
|
|
|
|
#
|
|
|
|
#
|
|
|
|
# You shouldn't need to change what follows.
|
|
|
|
#
|
|
|
|
INSTALL=@INSTALL@
|
|
|
|
INSTALL_DATA=@INSTALL_DATA@
|
|
|
|
INSTALL_PROGRAM=@INSTALL_PROGRAM@
|
|
|
|
SHELL=/bin/sh
|
|
|
|
RANLIB=@RANLIB@
|
|
|
|
srcdir=@srcdir@
|
|
|
|
SO=@SO@
|
|
|
|
#4.1VPATH=@srcdir@:@srcdir@/OPTYap
|
|
|
|
CWD=$(PWD)
|
|
|
|
#
|
|
|
|
|
|
|
|
BDD_PROLOG= \
|
|
|
|
$(srcdir)/cuda.yap
|
|
|
|
|
2013-10-07 12:20:00 +01:00
|
|
|
OBJS=cuda.o memory.o lista.o
|
2013-10-04 13:22:00 +01:00
|
|
|
SOBJS=cuda.@SO@
|
|
|
|
|
|
|
|
#in some systems we just create a single object, in others we need to
|
|
|
|
# create a libray
|
|
|
|
|
|
|
|
all: $(SOBJS)
|
|
|
|
|
2013-10-07 12:20:00 +01:00
|
|
|
cuda.o: $(srcdir)/cuda.c $(srcdir)/pred.h
|
|
|
|
$(NVCC) -c $(NVCCFLAGS) $(srcdir)/cuda.c -o cuda.o
|
2013-10-04 13:22:00 +01:00
|
|
|
|
2013-10-07 13:48:19 +01:00
|
|
|
lista.o: $(srcdir)/lista.cu $(srcdir)/pred.h $(srcdir)/selectproyect.cu $(srcdir)/treeb.cu $(srcdir)/union2.cu $(srcdir)/bpreds.cu
|
2013-10-07 12:20:00 +01:00
|
|
|
$(NVCC) -c $(NVCCFLAGS) $(srcdir)/lista.cu -o lista.o
|
2013-10-04 13:22:00 +01:00
|
|
|
|
2013-10-07 12:20:00 +01:00
|
|
|
memory.o: $(srcdir)/memory.cu $(srcdir)/pred.h
|
|
|
|
$(NVCC) -c $(NVCCFLAGS) $(srcdir)/memory.cu -o memory.o
|
|
|
|
|
|
|
|
@DO_SECOND_LD@cuda.@SO@: $(OBJS)
|
2013-10-09 14:59:03 +01:00
|
|
|
@DO_SECOND_LD@ @CUDA_SHLIB_LD@ $(CUDA_LDFLAGS) -o cuda.@SO@ $(OBJS)
|
2013-10-04 13:22:00 +01:00
|
|
|
|
2014-02-13 01:58:48 +00:00
|
|
|
install: all install-exampleS
|
2013-10-04 13:22:00 +01:00
|
|
|
mkdir -p $(DESTDIR)$(SHAREDIR)
|
|
|
|
for h in $(BDD_PROLOG); do $(INSTALL_DATA) $$h $(DESTDIR)$(SHAREDIR); done
|
|
|
|
$(INSTALL_PROGRAM) $(SOBJS) $(DESTDIR)$(YAPLIBDIR)
|
|
|
|
|
2014-02-10 23:30:21 +00:00
|
|
|
install-examples:
|
|
|
|
|
2013-10-04 13:22:00 +01:00
|
|
|
clean:
|
2014-02-10 23:30:21 +00:00
|
|
|
rm -f *.o *~ $(OBJS) *.BAK
|
|
|
|
|
2014-02-13 01:58:48 +00:00
|
|
|
distclean: clean
|
2014-02-10 23:30:21 +00:00
|
|
|
rm -f $(SOBJS) Makefile
|
2013-10-04 13:22:00 +01:00
|
|
|
|