Re-organized sub-directory by category
[staging/basesystem.git] / hal / can_hal / src / Makefile
1 #
2 # @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
3 #
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
7 #
8 #      http://www.apache.org/licenses/LICENSE-2.0
9 #
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
15 #
16
17 ######### installed shared library(*.so) #############
18 INST_SHLIBS = libcan_hal
19
20 ######### installed static library(*.a) #############
21
22 ######### install headers(*.h)  #############
23 INST_HEADERS = ../hal_api/can_hal.h
24
25 ######### compiled sources  #############
26 libcan_hal_SRCS = can_hal_core.cpp can_hal_stm.cpp can_hal_api.cpp
27 libcan_hal_SRCS += driver_can__CWORD31_.c
28
29 ######### include paths/files ###################
30 CPPFLAGS += -I./inc/
31 CPPFLAGS += -I../hal_api/
32
33 ######### compile options #######################
34 CPPFLAGS += -Wall -fPIC
35
36 ######### link options ##########################
37 LDFLAGS += -shared
38 LDFLAGS += -Wl,--gc-sections
39 LDFLAGS += -Wl,--no-as-needed
40 LDFLAGS += -Wl,--no-undefined
41 LDFLAGS += -L$(SDKTARGETSYSROOT)/usr/agl/lib
42
43 RPATH := /usr/lib:/usr/agl/lib
44
45 ######### linked library ########################
46 LDLIBS += -Wl,-Bdynamic -lstdc++
47 LDLIBS += -Wl,-Bdynamic -lpthread
48 LDLIBS += -Wl,-Bdynamic -lNS_FrameworkUnified
49
50 COMPONENT_NAME =
51 AGL_TOPDIR ?= $(DESTDIR)/usr
52 include ../can_hal.mk