blob: d8058c16fc22117a0fd61174312ccb81460bef52 [file] [log] [blame]
Doug Zongker37bee622009-06-08 17:35:39 -07001# Copyright 2009 The Android Open Source Project
Tao Baod770d2e2016-10-03 15:26:06 -07002#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
Doug Zongker37bee622009-06-08 17:35:39 -070014
15LOCAL_PATH := $(call my-dir)
16
17edify_src_files := \
Tao Baod770d2e2016-10-03 15:26:06 -070018 lexer.ll \
19 parser.yy \
20 expr.cpp
Doug Zongker37bee622009-06-08 17:35:39 -070021
22#
Tao Baod770d2e2016-10-03 15:26:06 -070023# Build the host-side command line tool (host executable)
Doug Zongker37bee622009-06-08 17:35:39 -070024#
25include $(CLEAR_VARS)
26
27LOCAL_SRC_FILES := \
Tao Baod770d2e2016-10-03 15:26:06 -070028 $(edify_src_files) \
29 edify_parser.cpp
Doug Zongker37bee622009-06-08 17:35:39 -070030
Tianjie Xu7aa88742016-09-28 11:42:17 -070031LOCAL_CFLAGS := -Werror
Tao Bao2a5a49d2015-08-20 12:10:46 -070032LOCAL_CPPFLAGS := -g -O0
Tao Baod770d2e2016-10-03 15:26:06 -070033LOCAL_MODULE := edify_parser
Doug Zongker37bee622009-06-08 17:35:39 -070034LOCAL_YACCFLAGS := -v
Dan Albertb02e90f2015-08-07 17:24:49 -070035LOCAL_CPPFLAGS += -Wno-unused-parameter
Tao Bao2a5a49d2015-08-20 12:10:46 -070036LOCAL_CPPFLAGS += -Wno-deprecated-register
Tao Bao80e46e02015-06-03 10:49:29 -070037LOCAL_CLANG := true
Tianjie Xu16255832016-04-30 11:49:59 -070038LOCAL_C_INCLUDES += $(LOCAL_PATH)/..
39LOCAL_STATIC_LIBRARIES += libbase
Doug Zongker37bee622009-06-08 17:35:39 -070040
41include $(BUILD_HOST_EXECUTABLE)
42
Doug Zongker9931f7f2009-06-10 14:11:53 -070043#
Tao Baod770d2e2016-10-03 15:26:06 -070044# Build the device-side library (static library)
Doug Zongker9931f7f2009-06-10 14:11:53 -070045#
46include $(CLEAR_VARS)
Doug Zongker37bee622009-06-08 17:35:39 -070047
Doug Zongker9931f7f2009-06-10 14:11:53 -070048LOCAL_SRC_FILES := $(edify_src_files)
Doug Zongker37bee622009-06-08 17:35:39 -070049
Tianjie Xu7aa88742016-09-28 11:42:17 -070050LOCAL_CFLAGS := -Werror
Tao Bao2a5a49d2015-08-20 12:10:46 -070051LOCAL_CPPFLAGS := -Wno-unused-parameter
52LOCAL_CPPFLAGS += -Wno-deprecated-register
Doug Zongker9931f7f2009-06-10 14:11:53 -070053LOCAL_MODULE := libedify
Tao Bao80e46e02015-06-03 10:49:29 -070054LOCAL_CLANG := true
Tianjie Xu16255832016-04-30 11:49:59 -070055LOCAL_C_INCLUDES += $(LOCAL_PATH)/..
56LOCAL_STATIC_LIBRARIES += libbase
Doug Zongker37bee622009-06-08 17:35:39 -070057
Doug Zongker9931f7f2009-06-10 14:11:53 -070058include $(BUILD_STATIC_LIBRARY)