annotate liboffloadmic/Makefile.am @ 158:494b0b89df80 default tip

...
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Mon, 25 May 2020 18:13:55 +0900
parents 1830386684a0
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 #
kono
parents:
diff changeset
2 # Copyright (c) 2014 Intel Corporation. All Rights Reserved.
kono
parents:
diff changeset
3 #
kono
parents:
diff changeset
4 # Redistribution and use in source and binary forms, with or without
kono
parents:
diff changeset
5 # modification, are permitted provided that the following conditions
kono
parents:
diff changeset
6 # are met:
kono
parents:
diff changeset
7 #
kono
parents:
diff changeset
8 # * Redistributions of source code must retain the above copyright
kono
parents:
diff changeset
9 # notice, this list of conditions and the following disclaimer.
kono
parents:
diff changeset
10 # * Redistributions in binary form must reproduce the above copyright
kono
parents:
diff changeset
11 # notice, this list of conditions and the following disclaimer in the
kono
parents:
diff changeset
12 # documentation and/or other materials provided with the distribution.
kono
parents:
diff changeset
13 # * Neither the name of Intel Corporation nor the names of its
kono
parents:
diff changeset
14 # contributors may be used to endorse or promote products derived
kono
parents:
diff changeset
15 # from this software without specific prior written permission.
kono
parents:
diff changeset
16 #
kono
parents:
diff changeset
17 # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
kono
parents:
diff changeset
18 # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
kono
parents:
diff changeset
19 # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
kono
parents:
diff changeset
20 # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
kono
parents:
diff changeset
21 # HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
kono
parents:
diff changeset
22 # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
kono
parents:
diff changeset
23 # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
kono
parents:
diff changeset
24 # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
kono
parents:
diff changeset
25 # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
kono
parents:
diff changeset
26 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
kono
parents:
diff changeset
27 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
kono
parents:
diff changeset
28 #
kono
parents:
diff changeset
29
kono
parents:
diff changeset
30
kono
parents:
diff changeset
31 AUTOMAKE_OPTIONS = foreign
kono
parents:
diff changeset
32 ACLOCAL_AMFLAGS = -I .. -I ../config
kono
parents:
diff changeset
33
kono
parents:
diff changeset
34 # Build plugin for Intel MIC
kono
parents:
diff changeset
35 SUBDIRS = . plugin
kono
parents:
diff changeset
36
kono
parents:
diff changeset
37 # Directories.
kono
parents:
diff changeset
38 build_dir = $(top_builddir)
kono
parents:
diff changeset
39 coi_inc_dir = $(top_srcdir)/include/coi
kono
parents:
diff changeset
40 libgomp_dir = $(build_dir)/../libgomp
kono
parents:
diff changeset
41 source_dir = $(top_srcdir)/runtime
kono
parents:
diff changeset
42
kono
parents:
diff changeset
43 # May be used by toolexeclibdir.
kono
parents:
diff changeset
44 gcc_version := $(shell @get_gcc_base_ver@ $(top_srcdir)/../gcc/BASE-VER)
kono
parents:
diff changeset
45 libsubincludedir = $(libdir)/gcc/$(target_alias)/$(gcc_version)/include
kono
parents:
diff changeset
46
kono
parents:
diff changeset
47 # Target list.
kono
parents:
diff changeset
48 if LIBOFFLOADMIC_HOST
kono
parents:
diff changeset
49 nodist_toolexeclib_HEADERS = liboffloadmic_host.spec
kono
parents:
diff changeset
50 toolexeclib_LTLIBRARIES = libcoi_host.la liboffloadmic_host.la
kono
parents:
diff changeset
51 nodist_libsubinclude_HEADERS = runtime/compiler_if_host.h
kono
parents:
diff changeset
52 ofld_obj =
kono
parents:
diff changeset
53 else # LIBOFFLOADMIC_TARGET
kono
parents:
diff changeset
54 nodist_toolexeclib_HEADERS = liboffloadmic_target.spec
kono
parents:
diff changeset
55 toolexeclib_LTLIBRARIES = libcoi_device.la liboffloadmic_target.la
kono
parents:
diff changeset
56 nodist_libsubinclude_HEADERS = runtime/compiler_if_target.h
kono
parents:
diff changeset
57 ofld_obj = ofldbegin.o ofldend.o
kono
parents:
diff changeset
58 endif
kono
parents:
diff changeset
59
kono
parents:
diff changeset
60 # Liboffloadmic.
kono
parents:
diff changeset
61 liboffloadmic_sources = runtime/dv_util.cpp \
kono
parents:
diff changeset
62 runtime/liboffload_error.c \
kono
parents:
diff changeset
63 runtime/liboffload_msg.c \
kono
parents:
diff changeset
64 runtime/offload_common.cpp \
kono
parents:
diff changeset
65 runtime/offload_table.cpp \
kono
parents:
diff changeset
66 runtime/offload_trace.cpp \
kono
parents:
diff changeset
67 runtime/offload_util.cpp
kono
parents:
diff changeset
68
kono
parents:
diff changeset
69 liboffloadmic_cppflags = -DLINUX -DCOI_LIBRARY_VERSION=2 -DOFFLOAD_DEBUG=1 -DSEP_SUPPORT -DTIMING_SUPPORT -I$(coi_inc_dir) -I$(source_dir) -I$(libgomp_dir)
kono
parents:
diff changeset
70
kono
parents:
diff changeset
71 liboffloadmic_host_la_SOURCES = $(liboffloadmic_sources) \
kono
parents:
diff changeset
72 runtime/cean_util.cpp \
kono
parents:
diff changeset
73 runtime/coi/coi_client.cpp \
kono
parents:
diff changeset
74 runtime/compiler_if_host.cpp \
kono
parents:
diff changeset
75 runtime/offload_engine.cpp \
kono
parents:
diff changeset
76 runtime/offload_env.cpp \
kono
parents:
diff changeset
77 runtime/offload_host.cpp \
kono
parents:
diff changeset
78 runtime/offload_omp_host.cpp \
kono
parents:
diff changeset
79 runtime/offload_orsl.cpp \
kono
parents:
diff changeset
80 runtime/offload_timer_host.cpp \
kono
parents:
diff changeset
81 runtime/orsl-lite/lib/orsl-lite.c
kono
parents:
diff changeset
82
kono
parents:
diff changeset
83 liboffloadmic_host_la_CPPFLAGS = $(liboffloadmic_cppflags) -DHOST_LIBRARY=1
kono
parents:
diff changeset
84 liboffloadmic_host_la_LDFLAGS = @lt_cv_dlopen_libs@ -version-info 5:0:0
kono
parents:
diff changeset
85
kono
parents:
diff changeset
86 liboffloadmic_target_la_SOURCES = $(liboffloadmic_sources) \
kono
parents:
diff changeset
87 runtime/coi/coi_server.cpp \
kono
parents:
diff changeset
88 runtime/compiler_if_target.cpp \
kono
parents:
diff changeset
89 runtime/offload_omp_target.cpp \
kono
parents:
diff changeset
90 runtime/offload_target.cpp \
kono
parents:
diff changeset
91 runtime/offload_timer_target.cpp
kono
parents:
diff changeset
92
kono
parents:
diff changeset
93 liboffloadmic_target_la_CPPFLAGS = $(liboffloadmic_cppflags) -DHOST_LIBRARY=0
kono
parents:
diff changeset
94 liboffloadmic_target_la_LDFLAGS = @lt_cv_dlopen_libs@ -version-info 5:0:0
kono
parents:
diff changeset
95 liboffloadmic_target_la_LIBADD = libcoi_device.la
kono
parents:
diff changeset
96 liboffloadmic_target_la_DEPENDENCIES = $(liboffloadmic_target_la_LIBADD)
kono
parents:
diff changeset
97
kono
parents:
diff changeset
98 # Emulator.
kono
parents:
diff changeset
99 libcoi_host_la_SOURCES = runtime/emulator/coi_host.cpp
kono
parents:
diff changeset
100 libcoi_device_la_SOURCES = runtime/emulator/coi_device.cpp
kono
parents:
diff changeset
101
kono
parents:
diff changeset
102 libcoi_host_la_DEPENDENCIES = runtime/emulator/coi_version_linker_script.map
kono
parents:
diff changeset
103 libcoi_device_la_DEPENDENCIES = runtime/emulator/coi_version_linker_script.map
kono
parents:
diff changeset
104
kono
parents:
diff changeset
105 libcoi_host_la_CPPFLAGS = -I$(coi_inc_dir)
kono
parents:
diff changeset
106 libcoi_device_la_CPPFLAGS = -I$(coi_inc_dir)
kono
parents:
diff changeset
107
kono
parents:
diff changeset
108 libcoi_host_la_LDFLAGS = -lrt -Wl,--version-script=$(source_dir)/emulator/coi_version_linker_script.map
kono
parents:
diff changeset
109 libcoi_device_la_LDFLAGS = -lrt -Wl,--version-script=$(source_dir)/emulator/coi_version_linker_script.map
kono
parents:
diff changeset
110
kono
parents:
diff changeset
111 # ofldbegin, ofldend
kono
parents:
diff changeset
112 all-local: $(ofld_obj)
kono
parents:
diff changeset
113
kono
parents:
diff changeset
114 ofldbegin.o: runtime/ofldbegin.cpp
kono
parents:
diff changeset
115 $(CXXCOMPILE) $(liboffloadmic_target_la_CPPFLAGS) -c $< -o $@
kono
parents:
diff changeset
116
kono
parents:
diff changeset
117 ofldend.o: runtime/ofldend.cpp
kono
parents:
diff changeset
118 $(CXXCOMPILE) $(liboffloadmic_target_la_CPPFLAGS) -c $< -o $@
kono
parents:
diff changeset
119
kono
parents:
diff changeset
120 # Work around what appears to be a GNU make bug handling MAKEFLAGS
kono
parents:
diff changeset
121 # values defined in terms of make variables, as is the case for CC and
kono
parents:
diff changeset
122 # friends when we are called from the top level Makefile.
kono
parents:
diff changeset
123 AM_MAKEFLAGS = \
kono
parents:
diff changeset
124 "AR_FLAGS=$(AR_FLAGS)" \
kono
parents:
diff changeset
125 "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
kono
parents:
diff changeset
126 "CFLAGS=$(CFLAGS)" \
kono
parents:
diff changeset
127 "CXXFLAGS=$(CXXFLAGS)" \
kono
parents:
diff changeset
128 "CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
kono
parents:
diff changeset
129 "CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
kono
parents:
diff changeset
130 "INSTALL=$(INSTALL)" \
kono
parents:
diff changeset
131 "INSTALL_DATA=$(INSTALL_DATA)" \
kono
parents:
diff changeset
132 "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
kono
parents:
diff changeset
133 "INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \
kono
parents:
diff changeset
134 "JC1FLAGS=$(JC1FLAGS)" \
kono
parents:
diff changeset
135 "LDFLAGS=$(LDFLAGS)" \
kono
parents:
diff changeset
136 "LIBCFLAGS=$(LIBCFLAGS)" \
kono
parents:
diff changeset
137 "LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \
kono
parents:
diff changeset
138 "MAKE=$(MAKE)" \
kono
parents:
diff changeset
139 "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \
kono
parents:
diff changeset
140 "PICFLAG=$(PICFLAG)" \
kono
parents:
diff changeset
141 "PICFLAG_FOR_TARGET=$(PICFLAG_FOR_TARGET)" \
kono
parents:
diff changeset
142 "SHELL=$(SHELL)" \
kono
parents:
diff changeset
143 "RUNTESTFLAGS=$(RUNTESTFLAGS)" \
kono
parents:
diff changeset
144 "exec_prefix=$(exec_prefix)" \
kono
parents:
diff changeset
145 "infodir=$(infodir)" \
kono
parents:
diff changeset
146 "libdir=$(libdir)" \
kono
parents:
diff changeset
147 "prefix=$(prefix)" \
kono
parents:
diff changeset
148 "includedir=$(includedir)" \
kono
parents:
diff changeset
149 "AR=$(AR)" \
kono
parents:
diff changeset
150 "AS=$(AS)" \
kono
parents:
diff changeset
151 "LD=$(LD)" \
kono
parents:
diff changeset
152 "LIBCFLAGS=$(LIBCFLAGS)" \
kono
parents:
diff changeset
153 "NM=$(NM)" \
kono
parents:
diff changeset
154 "PICFLAG=$(PICFLAG)" \
kono
parents:
diff changeset
155 "RANLIB=$(RANLIB)" \
kono
parents:
diff changeset
156 "DESTDIR=$(DESTDIR)"
kono
parents:
diff changeset
157
kono
parents:
diff changeset
158 MAKEOVERRIDES =
kono
parents:
diff changeset
159
145
1830386684a0 gcc-9.2.0
anatofuz
parents: 111
diff changeset
160 include $(top_srcdir)/../multilib.am