-
Notifications
You must be signed in to change notification settings - Fork 9
/
Makefile
138 lines (105 loc) · 3.98 KB
/
Makefile
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
OBJDIR = obj
BINDIR = bin
INCLUDES = headers
CXXFLAGS =$(CFLAGS)
CC = g++
CFLAGS = -Wall -I$(INCLUDES) -lm -g #-O3
export CPATH=$CPATH:$(INCLUDES)
$(OBJDIR)/%.o: %.cpp
@mkdir -p $(@D)
$(CC) $(CFLAGS) -c -o $@ $<
$(OBJDIR):
@mkdir -p $@
$(BINDIR):
@mkdir -p $@
OUTPUT = $(BINDIR)/convertft
FILES = $(FILESDB) circuitmatrix.cpp numberandcoordinate.cpp geometry.cpp circuitgeometry.cpp \
$(wildcard fileformats/*.cpp) \
$(wildcard scheduling/*.cpp) \
$(wildcard astar/*.cpp) \
$(wildcard pins/*.cpp) \
$(wildcard recycling/*.cpp) \
$(wildcard utils/*.cpp) \
oldconvertft.cpp \
gatenumbers.cpp cnotcounter.cpp cuccaro.cpp gidney.cpp\
circconvert.cpp\
computeadditional.cpp plumbingpieces.cpp\
boxworld2.cpp faildistillations.cpp \
connectpins.cpp heuristicparameters.cpp \
convertcoordinate.cpp\
connectionspool.cpp connectionmanager.cpp
# fileformats/psfilewriter.cpp fileformats/qcircfilewriter.cpp \
fileformats/geomfilewriter.cpp fileformats/adamfilewriter.cpp fileformats/chpfilewriter.cpp \
fileformats/iofilewriter.cpp fileformats/boundingboxfilewriter.cpp \
fileformats/infilereader.cpp
#fileformats/toconnectfilewriter.cpp fileformats/boxcoordfilewriter.cpp \
fileformats/iofilereader.cpp \
# causaltogeom.cpp \
OFILES = $(patsubst %.cpp, $(OBJDIR)/%.o, $(FILES))
OUTPUTDB = $(BINDIR)/dbread
FILESDB = decomposition.cpp databasereader.cpp
OFILESDB = $(patsubst %.cpp, $(OBJDIR)/%.o, $(FILESDB))
OUTPUTB = $(BINDIR)/boxworld
FILESB = fileformats/toconnectfilewriter.cpp fileformats/boxcoordfilewriter.cpp \
fileformats/iofilereader.cpp fileformats/iofilewriter.cpp schedulerspace.cpp \
boxworld2.cpp computeadditional.cpp numberandcoordinate.cpp faildistillations.cpp \
fileformats/geomfilewriter.cpp connectpins.cpp geometry.cpp\
boxworld2_main.cpp astaralg.cpp astarpoint.cpp
OFILESB = $(patsubst %.cpp, $(OBJDIR)/%.o, $(FILESB))
OUTPUTF = $(BINDIR)/faildistillations
FILESF = fileformats/toconnectfilewriter.cpp fileformats/iofilereader.cpp \
faildistillations.cpp numberandcoordinate.cpp faildistillations_main.cpp
OFILESF = $(patsubst %.cpp, $(OBJDIR)/%.o, $(FILESF))
OUTPUTP = $(BINDIR)/processraw
FILESP = $(FILESDB) cnotcounter.cpp processraw.cpp fileformats/rawfilereader.cpp \
fileformats/infilewriter.cpp processraw_main.cpp
OFILESP = $(patsubst %.cpp, $(OBJDIR)/%.o, $(FILESP))
OUTPUTA = $(BINDIR)/additional
FILESA = additional.cpp computeadditional.cpp
OFILESA = $(patsubst %.cpp, $(OBJDIR)/%.o, $(FILESA))
OUTPUTC = $(BINDIR)/chp
FILESC = chp.c
OFILESC = $(patsubst %.cpp, $(OBJDIR)/%.o, $(FILESC))
OUTPUTCONN = $(BINDIR)/connectpins
FILESCONN = fileformats/geomfilewriter.cpp fileformats/iofilereader.cpp \
faildistillations.cpp numberandcoordinate.cpp geometry.cpp \
connectpins.cpp connectpinsmain.cpp astaralg.cpp astarpoint.cpp
OFILESCONN = $(patsubst %.cpp, $(OBJDIR)/%.o, $(FILESCONN))
#all:: process convert boxworld additional faild connectpins chp
all:: convert
test::
make -C geomtest
additional:: $(OFILESA) $(BINDIR)
$(CC) $(CFLAGS) $(OFILESA) -o $(OUTPUTA)
dbread:: $(OFILESDB) $(BINDIR)
$(CC) $(CFLAGS) $(OFILESDB) -o $(OUTPUTDB)
boxworld:: $(OFILESB) $(BINDIR)
$(CC) $(CFLAGS) $(OFILESB) -o $(OUTPUTB)
faild:: $(OFILESF) $(BINDIR)
$(CC) $(CFLAGS) $(OFILESF) -o $(OUTPUTF)
convert:: $(OFILES) $(BINDIR)
$(CC) $(CFLAGS) $(OFILES) -o $(OUTPUT)
process:: $(OFILESP) $(BINDIR)
$(CC) $(CFLAGS) $(OFILESP) -o $(OUTPUTP)
chp:: $(OFILESC) $(BINDIR)
$(CS) $(OFILESC) -o $(OUTPUTC)
connectpins:: $(OFILESCONN) $(BINDIR)
$(CC) $(CFLAGS) $(OFILESCONN) -o $(OUTPUTCONN)
#clean::
# rm -f $(OUTPUT) $(FILES)
# rm -f $(OUTPUTP) $(FILESP)
# rm -f $(OUTPUTA) $(FILESA)
# rm -f $(OUTPUTC) $(FILESC)
# rm -f $(OUTPUTB) $(FILESB)
# rm -f $(OUTPUTDB) $(FILESDB)
# rm -f $(OUTPUTF) $(FILESF)
# rm -f $(OUTPUTCONN) $(FILESCONN)
CPFILES = headers/gatenumbers.h seeds.txt \
database template.ps templatec.ps \
templateh.ps adist.raw.in.geom \
circuit.raw.in
cpbin::
cp $(CPFILES) $(BINDIR)
ps::
cat templateh.ps test.ps templatec.ps > circ.ps
epstopdf circ.ps