annotate example/fft/Makefile.gpu @ 1786:ba6ffc679a8f draft

minor fix
author Masataka Kohagura <e085726@ie.u-ryukyu.ac.jp>
date Sat, 30 Nov 2013 21:06:44 +0900
parents 2e8931baef7f
children 9de57d13a386
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1551
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
1 include ./Makefile.def
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
2
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
3 SRCS_TMP = $(wildcard *.cc)
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
4 SRCS_EXCLUDE = # 除外するファイルを書く
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
5 SRCS = $(filter-out $(SRCS_EXCLUDE),$(SRCS_TMP))
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
6 OBJS = $(SRCS:.cc=.o)
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
7
1702
f52904f8f03e fix example.run ANY_ANY
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents: 1551
diff changeset
8 GPU_TASK_DIR = gpu
1730
2e8931baef7f fix fft
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents: 1702
diff changeset
9 #TASK_DIR = ppe
2e8931baef7f fix fft
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents: 1702
diff changeset
10 #TASK_SRCS_TMP = $(wildcard $(TASK_DIR)/*.cc)
1551
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
11 TASK_SRCS_EXCLUDE =
1730
2e8931baef7f fix fft
Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp>
parents: 1702
diff changeset
12 TASK_SRCS = $(filter-out $(GPU_TASK_DIR)/$(TASK_SRCS_EXCLUDE),$(TASK_SRCS_TMP)) $(wildcard $(GPU_TASK_DIR)/*.cc)
1551
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
13 TASK_OBJS = $(TASK_SRCS:.cc=.o)
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
14
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
15 CC += $(ABI)
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
16 CFLAGS += -D__CERIUM_GPU__
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
17
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
18 LIBS = -L${CERIUM}/TaskManager -DUSE_SIMPLE_TASK -lGpuManager -framework opencl `sdl-config --libs`
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
19
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
20 .SUFFIXES: .cc .o
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
21
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
22 .cc.o:
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
23 $(CC) $(CFLAGS) $(INCLUDE) -c $< -o $@
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
24
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
25 all: $(TARGET)
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
26
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
27 $(TARGET): $(OBJS) $(TASK_OBJS)
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
28 $(CC) -o $@ $(OBJS) $(TASK_OBJS) $(LIBS)
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
29
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
30 link:
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
31 $(CC) -o $(TARGET) $(OBJS) $(TASK_OBJS) $(LIBS)
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
32
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
33 debug: $(TARGET)
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
34 sudo gdb ./$(TARGET)
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
35
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
36 clean:
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
37 rm -f $(TARGET) $(OBJS) $(TASK_OBJS)
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
38 rm -f *~ \#*
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
39 rm -f ppe/*~ ppe/\#*
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
40 rm -f spe/*~ spe/\#*
57317332f6ef create fft example
Yuhi TOMARI <yuhi@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
41 rm -f gpu/*~ gpu/\#*