[go: up one dir, main page]

Menu

[r130]: / libpetey / datasets / makefile  Maximize  Restore  History

Download this file

148 lines (122 with data), 4.4 kB

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
#
# Copywrite 2004 Peter Mills. All rights reserved.
#
OPT_VER = -g
BASE_PATH=/home/Petey
LIB_DIR = $(BASE_PATH)/lib/
INCLUDE_DIR = $(BASE_PATH)/include/
#CLIB_PATH = /home/Petey/libpetey/
VPATH = $(LIB_DIR):$(INCLUDE_DIR)
CC = g++
CFLAGS = -I$(INCLUDE_DIR) -Wno-deprecated $(OPT_VER)
#all: dataset_lib.a dataset_lib.so
all: libdataset$(OPT_VER).a \
dataset.h \
simple_dataset.h \
simple_temp.h \
dependent_dataset.h \
dependent_temp.h \
dependent_swap.h \
composite_dataset.h
install:
cp libdataset$(OPT_VER).a $(LIB_DIR)
# cp libdataset.so $(LIB_DIR)
cp composite_dataset.h $(INCLUDE_DIR)
cp dependent_intc.h $(INCLUDE_DIR)
cp dataset.h $(INCLUDE_DIR)
cp simple_dataset.h $(INCLUDE_DIR)
cp simple_temp.h $(INCLUDE_DIR)
cp dependent_dataset.h $(INCLUDE_DIR)
cp dependent_temp.h $(INCLUDE_DIR)
cp dependent_swap.h $(INCLUDE_DIR)
# date > date_made_dataset
# make the whole library:
libdataset$(OPT_VER).a: composite_dataset$(OPT_VER).o \
dependent_swap$(OPT_VER).o \
dependent_temp$(OPT_VER).o \
dependent_dataset$(OPT_VER).o \
simple_temp$(OPT_VER).o \
simple_dataset$(OPT_VER).o \
heapsort_ptr$(OPT_VER).o \
dependent_intc$(OPT_VER).o \
dataset$(OPT_VER).o
ar -rs libdataset$(OPT_VER).a \
composite_dataset$(OPT_VER).o \
dependent_intc$(OPT_VER).o \
heapsort_ptr$(OPT_VER).o \
dataset$(OPT_VER).o \
simple_temp$(OPT_VER).o \
simple_dataset$(OPT_VER).o \
dependent_dataset$(OPT_VER).o \
dependent_temp$(OPT_VER).o \
dependent_swap$(OPT_VER).o
# remove all object files:
clean:
rm -f *.o
rm -f libdataset$(OPT_VER).a
rm -f libdataset$(OPT_VER).so
# make -C $(CLIB_PATH) clean
# make a dynamic version of the library (not tested):
#dataset_lib.so: composite_dataset.o \
dependent_swap.o \
dependent_temp.o \
dependent_dataset.o \
simple_temp.o \
simple_dataset.o \
heapsort_ptr.o \
peteys_tmpl_lib.a
# $(CC) $(CFLAGS) -shared -o dataset_lib.so \
$(LIB_DIR)libpetey.so \
heapsort_ptr.o \
simple_temp.o \
simple_dataset.o \
dependent_dataset.o \
dependent_temp.o \
dependent_swap.o \
composite_dataset.o
# template library--contained in another directory:
#libpetey.a:
# make -C $(CLIB_PATH)
#libpetey.so:
# make -C $(CLIB_PATH)
# compile the composite dataset class:
composite_dataset$(OPT_VER).o: simple_temp.h dependent_temp.h dataset.h \
composite_dataset.h composite_dataset.cpp \
string_petey.h peteys_tmpl_lib.h
$(CC) $(CFLAGS) -c composite_dataset.cpp -o composite_dataset$(OPT_VER).o
heapsort_ptr$(OPT_VER).o: heapsort_ptr.cc
$(CC) $(CFLAGS) -c heapsort_ptr.cc -o $@
# compile the dependent dataset template classes:
dependent_swap$(OPT_VER).o: dependent_swap.cpp dependent_swap.h \
dependent_temp.h dataset.h \
time_class.h string_petey.h
$(CC) $(CFLAGS) -c dependent_swap.cpp -o dependent_swap$(OPT_VER).o
# compile the dependent dataset template classes:
dependent_temp$(OPT_VER).o: dependent_temp.cpp dependent_temp.h \
dependent_dataset.h dataset.h \
time_class.h string_petey.h
$(CC) $(CFLAGS) -c dependent_temp.cpp -o dependent_temp$(OPT_VER).o
# don't need as everything has been moved into the header file:
# compile the virtual dependent dataset base class:
dependent_dataset$(OPT_VER).o: dependent_dataset.cpp dependent_dataset.h dataset.h \
time_class.h string_petey.h
$(CC) $(CFLAGS) -c dependent_dataset.cpp -o dependent_dataset$(OPT_VER).o
# compile the simple dataset template classes:
simple_temp$(OPT_VER).o: simple_temp.cpp simple_temp.h simple_dataset.h \
dataset.h dependent_dataset.h \
time_class.h string_petey.h peteys_tmpl_lib.h
$(CC) $(CFLAGS) -c simple_temp.cpp -o simple_temp$(OPT_VER).o
# compile the virtual simple base class:
simple_dataset$(OPT_VER).o: simple_dataset.cpp simple_dataset.h dataset.h \
dependent_dataset.h
$(CC) $(CFLAGS) -c simple_dataset.cpp -o simple_dataset$(OPT_VER).o
dependent_intc$(OPT_VER).o: dependent_intc.cc dependent_intc.h \
dataset.h simple_dataset.h simple_temp.h \
dependent_dataset.h
$(CC) $(CFLAGS) -c dependent_intc.cc -o $@
# all this has now been inlined and so is contained in the header file:
# all the inlined functions have now been "un-inlined..."
dataset$(OPT_VER).o: dataset.cpp dataset.h
$(CC) $(CFLAGS) -c dataset.cpp -o dataset$(OPT_VER).o
#peteys_tmpl_lib.h string_petey.h time_class.h:
# Make -C $(CLIB_PATH)