You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
111 lines
2.2 KiB
111 lines
2.2 KiB
# Makefile for cln/benchmarks
|
|
|
|
#### Start of system configuration section. ####
|
|
|
|
# Directories used by "make":
|
|
srcdir = @srcdir@
|
|
top_srcdir = @top_srcdir@
|
|
|
|
# Programs used by "make":
|
|
# C compiler
|
|
CC = @CC@
|
|
CFLAGS = @CFLAGS@
|
|
CPP = @CPP@
|
|
# C++ compiler
|
|
CXX = @CXX@
|
|
CXXFLAGS = @CXXFLAGS@
|
|
CXXCPP = @CXXCPP@
|
|
INCLUDES = -I../include -I$(top_srcdir)/include -I$(top_srcdir)/src -I$(srcdir)
|
|
CPPFLAGS += $(INCLUDES)
|
|
LIBTOOL = @LIBTOOL@
|
|
LIBTOOL_LINK = $(LIBTOOL) --mode=link
|
|
MV = mv
|
|
LN = ln
|
|
RM = rm -f
|
|
@SET_MAKE@
|
|
|
|
#### End of system configuration section. ####
|
|
|
|
SHELL = /bin/sh
|
|
|
|
# Needed by $(LIBTOOL).
|
|
top_builddir = ..
|
|
|
|
VPATH = $(srcdir)
|
|
|
|
FILES_CC := $(notdir $(wildcard $(srcdir)/*.cc))
|
|
FILES_CC := $(filter-out %.i.cc, $(FILES_CC))
|
|
|
|
FILES_I_CC := $(patsubst %.cc,%.i.cc,$(FILES_CC))
|
|
|
|
FILES_S := $(patsubst %.cc,%.s,$(FILES_CC))
|
|
|
|
FILES_O := $(patsubst %.cc,%.o,$(FILES_CC))
|
|
|
|
OBJECTS = $(FILES_O)
|
|
|
|
LIBS = ../src/libcln.la -lm
|
|
LIBDEPS = ../src/libcln.la
|
|
|
|
PROGRAMS = timebench1 timebench2a timebench2ap timebench2b
|
|
MODULES_timebench1 = timebench1
|
|
MODULES_timebench2a = timebench2a
|
|
MODULES_timebench2ap = timebench2ap
|
|
MODULES_timebench2b = timebench2b
|
|
|
|
all : timebench2a timebench2ap timebench2b
|
|
|
|
%.s : %.c
|
|
$(CC) $(CFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -S $< -o $@
|
|
|
|
%.s : %.cc
|
|
$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -S $< -o $@
|
|
|
|
ifdef notyet
|
|
|
|
%.o : %.c
|
|
$(CC) $(CFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -c $< -o $@
|
|
|
|
%.o : %.cc
|
|
$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -c $< -o $@
|
|
|
|
else
|
|
|
|
$(FILES_O) : %.o : %.s
|
|
$(CC) $(CFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -c $< -o $@
|
|
|
|
endif
|
|
|
|
%.i : %.c
|
|
$(CPP) $(CFLAGS) $(CPPFLAGS) $(TARGET_ARCH) $< > $@
|
|
|
|
%.i.cc : %.cc
|
|
$(CXXCPP) $(CXXFLAGS) $(CPPFLAGS) $(TARGET_ARCH) $< > $@
|
|
|
|
timebench1 : $(patsubst %,%.o,$(MODULES_timebench1))
|
|
timebench2a : $(patsubst %,%.o,$(MODULES_timebench2a))
|
|
timebench2ap : $(patsubst %,%.o,$(MODULES_timebench2ap))
|
|
timebench2b : $(patsubst %,%.o,$(MODULES_timebench2b))
|
|
$(PROGRAMS) : % : $(LIBDEPS)
|
|
$(LIBTOOL_LINK) $(CXX) $(CXXFLAGS) $(TARGET_ARCH) $(patsubst %,%.o,$(MODULES_$(*F))) $(LIBS) -o $@
|
|
|
|
|
|
install : all
|
|
|
|
installdirs :
|
|
|
|
uninstall :
|
|
|
|
check : all
|
|
|
|
mostlyclean : clean
|
|
|
|
clean : force
|
|
$(RM) *.s *.o *.a $(PROGRAMS) a.out core
|
|
|
|
distclean : clean
|
|
$(RM) config.status config.log config.cache Makefile
|
|
|
|
maintainer-clean : distclean
|
|
|
|
force :
|