137bee62aefb5ac10716054edf482fd37078f1427Doug Zongker# Copyright 2009 The Android Open Source Project 237bee62aefb5ac10716054edf482fd37078f1427Doug Zongker 337bee62aefb5ac10716054edf482fd37078f1427Doug ZongkerLOCAL_PATH := $(call my-dir) 437bee62aefb5ac10716054edf482fd37078f1427Doug Zongker 537bee62aefb5ac10716054edf482fd37078f1427Doug Zongkeredify_src_files := \ 637bee62aefb5ac10716054edf482fd37078f1427Doug Zongker lexer.l \ 737bee62aefb5ac10716054edf482fd37078f1427Doug Zongker parser.y \ 837bee62aefb5ac10716054edf482fd37078f1427Doug Zongker expr.c 937bee62aefb5ac10716054edf482fd37078f1427Doug Zongker 1037bee62aefb5ac10716054edf482fd37078f1427Doug Zongker# "-x c" forces the lex/yacc files to be compiled as c; 1137bee62aefb5ac10716054edf482fd37078f1427Doug Zongker# the build system otherwise forces them to be c++. 1237bee62aefb5ac10716054edf482fd37078f1427Doug Zongkeredify_cflags := -x c 1337bee62aefb5ac10716054edf482fd37078f1427Doug Zongker 1437bee62aefb5ac10716054edf482fd37078f1427Doug Zongker# 1537bee62aefb5ac10716054edf482fd37078f1427Doug Zongker# Build the host-side command line tool 1637bee62aefb5ac10716054edf482fd37078f1427Doug Zongker# 1737bee62aefb5ac10716054edf482fd37078f1427Doug Zongkerinclude $(CLEAR_VARS) 1837bee62aefb5ac10716054edf482fd37078f1427Doug Zongker 1937bee62aefb5ac10716054edf482fd37078f1427Doug ZongkerLOCAL_SRC_FILES := \ 2037bee62aefb5ac10716054edf482fd37078f1427Doug Zongker $(edify_src_files) \ 2137bee62aefb5ac10716054edf482fd37078f1427Doug Zongker main.c 2237bee62aefb5ac10716054edf482fd37078f1427Doug Zongker 2337bee62aefb5ac10716054edf482fd37078f1427Doug ZongkerLOCAL_CFLAGS := $(edify_cflags) -g -O0 2437bee62aefb5ac10716054edf482fd37078f1427Doug ZongkerLOCAL_MODULE := edify 2537bee62aefb5ac10716054edf482fd37078f1427Doug ZongkerLOCAL_YACCFLAGS := -v 2637bee62aefb5ac10716054edf482fd37078f1427Doug Zongker 2737bee62aefb5ac10716054edf482fd37078f1427Doug Zongkerinclude $(BUILD_HOST_EXECUTABLE) 2837bee62aefb5ac10716054edf482fd37078f1427Doug Zongker 299931f7f3c1288171319e9ff7d053ebaad07db720Doug Zongker# 309931f7f3c1288171319e9ff7d053ebaad07db720Doug Zongker# Build the device-side library 319931f7f3c1288171319e9ff7d053ebaad07db720Doug Zongker# 329931f7f3c1288171319e9ff7d053ebaad07db720Doug Zongkerinclude $(CLEAR_VARS) 3337bee62aefb5ac10716054edf482fd37078f1427Doug Zongker 349931f7f3c1288171319e9ff7d053ebaad07db720Doug ZongkerLOCAL_SRC_FILES := $(edify_src_files) 3537bee62aefb5ac10716054edf482fd37078f1427Doug Zongker 369931f7f3c1288171319e9ff7d053ebaad07db720Doug ZongkerLOCAL_CFLAGS := $(edify_cflags) 379931f7f3c1288171319e9ff7d053ebaad07db720Doug ZongkerLOCAL_MODULE := libedify 3837bee62aefb5ac10716054edf482fd37078f1427Doug Zongker 399931f7f3c1288171319e9ff7d053ebaad07db720Doug Zongkerinclude $(BUILD_STATIC_LIBRARY) 40