2a26dcdfcd5d18a73cc0e7325f135b1899eba384
[ipc/ipcdev.git] / linux / src / tests / Makefile.am
1 ##
2 ##  Copyright (c) 2013, Texas Instruments Incorporated
3 ##
4 ##  Redistribution and use in source and binary forms, with or without
5 ##  modification, are permitted provided that the following conditions
6 ##  are met:
7 ##
8 ##  *  Redistributions of source code must retain the above copyright
9 ##     notice, this list of conditions and the following disclaimer.
10 ##
11 ##  *  Redistributions in binary form must reproduce the above copyright
12 ##     notice, this list of conditions and the following disclaimer in the
13 ##     documentation and/or other materials provided with the distribution.
14 ##
15 ##  *  Neither the name of Texas Instruments Incorporated nor the names of
16 ##     its contributors may be used to endorse or promote products derived
17 ##     from this software without specific prior written permission.
18 ##
19 ##  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
20 ##  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
21 ##  THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
22 ##  PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
23 ##  CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
24 ##  EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
25 ##  PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
26 ##  OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
27 ##  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
28 ##  OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
29 ##  EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30 ##
31 ## ======== src/test/Makefile.am ========
32 ##
34 # additional include paths necessary to compile the program
35 AM_CFLAGS = -I$(top_srcdir)/linux/include -I$(top_srcdir)/packages  \
36         -I$(CMEM_INSTALL_DIR)/packages -D_GNU_SOURCE -Wall @AM_CFLAGS@
38 ###############################################################################
39 # THE PROGRAMS TO BUILD
40 ###############################################################################
42 # the program to build (the names of the final binaries)
43 bin_PROGRAMS = ping_rpmsg mmrpc_test
45 if OMAP4430
46   bin_PROGRAMS += MessageQApp_omap4430 MessageQBench_omap4430 \
47                 MessageQMulti_omap4430 NameServerApp_omap4430
48 else
49 if OMAPL138
50   bin_PROGRAMS += MessageQApp_omapl138 MessageQBench_omapl138 \
51                 MessageQMulti_omapl138 NameServerApp_omapl138
52 if CMEM
53   bin_PROGRAMS += nano_test_omapl138
54 endif
55 else
56 if TCI6614
57   bin_PROGRAMS += MessageQApp_tci6614 MessageQBench_tci6614 \
58                 MessageQMulti_tci6614 NameServerApp_tci6614
59 else
60 if TCI6638
61   bin_PROGRAMS += MessageQApp_tci6638 MessageQBench_tci6638 \
62                 MessageQMulti_tci6638 NameServerApp_tci6638
63 else
64   bin_PROGRAMS += MessageQApp_omap4430 MessageQBench_omap4430 \
65                 MessageQMulti_omap4430 NameServerApp_omap4430 \
66                 MessageQApp_omapl138 MessageQBench_omapl138 \
67                 MessageQMulti_omapl138 NameServerApp_omapl138 \
68                 MessageQApp_tci6614 MessageQBench_tci6614 \
69                 MessageQMulti_tci6614 NameServerApp_tci6614 \
70                 MessageQApp_tci6638 MessageQBench_tci6638 \
71                 MessageQMulti_tci6638 NameServerApp_tci6638
72 if CMEM
73   bin_PROGRAMS += nano_test_omapl138
74 endif
75 endif
76 endif
77 endif
78 endif
80 common_sources = \
81                 $(top_srcdir)/linux/include/Std.h \
82                 $(top_srcdir)/packages/ti/ipc/Ipc.h \
83                 $(top_srcdir)/packages/ti/ipc/MessageQ.h
85 nameServer_common_sources = \
86                 $(top_srcdir)/linux/include/Std.h\
87                 $(top_srcdir)/linux/include/ladclient.h \
88                 $(top_srcdir)/linux/include/_NameServer.h \
89                 $(top_srcdir)/packages/ti/ipc/NameServer.h \
90                 NameServerApp.c
92 # list of sources for the 'ping_rpmsg' binary
93 ping_rpmsg_SOURCES = ping_rpmsg.c
95 # list of sources for the 'mmrpc_test' binary
96 mmrpc_test_SOURCES = mmrpc_test.c
98 # list of sources for the 'MessageQApp' binary
99 MessageQApp_omap4430_SOURCES = $(common_sources) MessageQApp.c
100 MessageQApp_omapl138_SOURCES = $(common_sources) MessageQApp.c
101 MessageQApp_tci6614_SOURCES = $(common_sources) MessageQApp.c
102 MessageQApp_tci6638_SOURCES = $(common_sources) MessageQApp.c
104 # list of sources for the 'MessageQBench' binary
105 MessageQBench_omap4430_SOURCES = $(common_sources) MessageQBench.c
106 MessageQBench_omapl138_SOURCES = $(common_sources) MessageQBench.c
107 MessageQBench_tci6614_SOURCES  = $(common_sources) MessageQBench.c
108 MessageQBench_tci6638_SOURCES  = $(common_sources) MessageQBench.c
110 # list of sources for the 'MessageQMulti' binary
111 MessageQMulti_omap4430_SOURCES = $(common_sources) MessageQMulti.c
112 MessageQMulti_omapl138_SOURCES = $(common_sources) MessageQMulti.c
113 MessageQMulti_tci6614_SOURCES  = $(common_sources) MessageQMulti.c
114 MessageQMulti_tci6638_SOURCES  = $(common_sources) MessageQMulti.c
116 # list of sources for the 'NameServerApp' binary
117 NameServerApp_omap4430_SOURCES = $(nameServer_common_sources)
118 NameServerApp_omapl138_SOURCES = $(nameServer_common_sources)
119 NameServerApp_tci6614_SOURCES  = $(nameServer_common_sources)
120 NameServerApp_tci6638_SOURCES  = $(nameServer_common_sources)
122 # list of sources for the 'nano_test' binary
123 nano_test_omapl138_SOURCES = $(common_sources) nano_test.c
125 common_libraries = -lpthread $(top_builddir)/linux/src/api/libtiipc.la \
126                 $(top_builddir)/linux/src/utils/libtiipcutils.la
128 # the additional libraries to link ping_rpmsg
129 ping_rpmsg_LDADD = -lrt
131 # the additional libraries to link mmrpc_test
132 mmrpc_test_LDADD = $(top_builddir)/linux/src/mm/libmmrpc.la
134 # the additional libraries needed to link MessageQApp
135 MessageQApp_omap4430_LDADD = $(common_libraries) \
136                 $(top_builddir)/linux/src/family/libtiipccfg_omap4430.la \
137                 $(AM_LDFLAGS)
138 MessageQApp_omapl138_LDADD = $(common_libraries) \
139                 $(top_builddir)/linux/src/family/libtiipccfg_omapl138.la \
140                 $(AM_LDFLAGS)
141 MessageQApp_tci6614_LDADD = $(common_libraries) \
142                 $(top_builddir)/linux/src/family/libtiipccfg_tci6614.la \
143                 $(AM_LDFLAGS)
144 MessageQApp_tci6638_LDADD = $(common_libraries) \
145                 $(top_builddir)/linux/src/family/libtiipccfg_tci6638.la \
146                 $(AM_LDFLAGS)
148 # the additional libraries needed to link MessageQBench
149 MessageQBench_omap4430_LDADD = $(common_libraries) \
150                 $(top_builddir)/linux/src/family/libtiipccfg_omap4430.la -lrt \
151                 $(AM_LDFLAGS)
152 MessageQBench_omapl138_LDADD = $(common_libraries) \
153                 $(top_builddir)/linux/src/family/libtiipccfg_omapl138.la -lrt \
154                 $(AM_LDFLAGS)
155 MessageQBench_tci6614_LDADD = $(common_libraries) \
156                 $(top_builddir)/linux/src/family/libtiipccfg_tci6614.la -lrt \
157                 $(AM_LDFLAGS)
158 MessageQBench_tci6638_LDADD = $(common_libraries) \
159                 $(top_builddir)/linux/src/family/libtiipccfg_tci6638.la -lrt \
160                 $(AM_LDFLAGS)
162 # the additional libraries needed to link MessageQMulti
163 MessageQMulti_omap4430_LDADD = $(common_libraries) \
164                 $(top_builddir)/linux/src/family/libtiipccfg_omap4430.la \
165                 $(AM_LDFLAGS)
166 MessageQMulti_omapl138_LDADD = $(common_libraries) \
167                 $(top_builddir)/linux/src/family/libtiipccfg_omapl138.la \
168                 $(AM_LDFLAGS)
169 MessageQMulti_tci6614_LDADD = $(common_libraries) \
170                 $(top_builddir)/linux/src/family/libtiipccfg_tci6614.la \
171                 $(AM_LDFLAGS)
172 MessageQMulti_tci6638_LDADD = $(common_libraries) \
173                 $(top_builddir)/linux/src/family/libtiipccfg_tci6638.la \
174                 $(AM_LDFLAGS)
176 # the additional libraries needed to link NameServerApp
177 NameServerApp_omap4430_LDADD = $(common_libraries) \
178                 $(top_builddir)/linux/src/family/libtiipccfg_omap4430.la \
179                 $(AM_LDFLAGS)
180 NameServerApp_omapl138_LDADD = $(common_libraries) \
181                 $(top_builddir)/linux/src/family/libtiipccfg_omapl138.la \
182                 $(AM_LDFLAGS)
183 NameServerApp_tci6614_LDADD = $(common_libraries) \
184                 $(top_builddir)/linux/src/family/libtiipccfg_tci6614.la \
185                 $(AM_LDFLAGS)
186 NameServerApp_tci6638_LDADD = $(common_libraries) \
187                 $(top_builddir)/linux/src/family/libtiipccfg_tci6638.la \
188                 $(AM_LDFLAGS)
190 # the additional libraries needed to link nano_test
191 nano_test_omapl138_LDADD = $(common_libraries) \
192                 $(top_builddir)/linux/src/family/libtiipccfg_omapl138.la \
193                 $(CMEM_INSTALL_DIR)/packages/ti/sdo/linuxutils/cmem/lib/cmem.a470MV \
194                 $(AM_LDFLAGS)
196 ###############################################################################