2 # @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
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
8 # http://www.apache.org/licenses/LICENSE-2.0
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.
17 ######### installed shared library(*.so) #############
18 INST_SHLIBS = libcan_hal
20 ######### installed static library(*.a) #############
22 ######### install headers(*.h) #############
23 INST_HEADERS = ../hal_api/can_hal.h
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
29 ######### include paths/files ###################
31 CPPFLAGS += -I../hal_api/
33 ######### compile options #######################
34 CPPFLAGS += -Wall -fPIC
36 ######### link options ##########################
38 LDFLAGS += -Wl,--gc-sections
39 LDFLAGS += -Wl,--no-as-needed
40 LDFLAGS += -Wl,--no-undefined
41 LDFLAGS += -L$(SDKTARGETSYSROOT)/usr/agl/lib
43 RPATH := /usr/lib:/usr/agl/lib
45 ######### linked library ########################
46 LDLIBS += -Wl,-Bdynamic -lstdc++
47 LDLIBS += -Wl,-Bdynamic -lpthread
48 LDLIBS += -Wl,-Bdynamic -lNS_FrameworkUnified
51 AGL_TOPDIR ?= $(DESTDIR)/usr