From adba3c0a0aa9ccd6b90a4f0ade79b420a23d0987 Mon Sep 17 00:00:00 2001 From: bralee Date: Wed, 8 Jan 2020 09:10:53 +0800 Subject: [PATCH] AIDEGen:fix module_bp_cc_deps.json content error. Bug: 147324044 Test: 1. export SOONG_COLLECT_CC_DEPS=1 SOONG_GEN_CMAKEFILES=1;m nothing module_bp_cc_deps.json will be generated. In module_bp_cc_deps.json, "libui": { ... "system_include_flags": { "header_search_path": [ "system/core/include", "system/media/audio/include", "hardware/libhardware/include", "hardware/libhardware_legacy/include", "hardware/ril/include", "frameworks/native/include", "frameworks/native/opengl/include", "frameworks/av/include", "libnativehelper/include_jni" ] "system_search_path": [ "bionic/libc/include", "bionic/libc/kernel/uapi", "bionic/libc/kernel/uapi/asm-x86", "bionic/libc/kernel/android/scsi", "bionic/libc/kernel/android/uapi" ] }, ... }, Change-Id: Iabc638ca451f568b2a4c09327f8f3c220f6fc154 --- cc/ccdeps.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cc/ccdeps.go b/cc/ccdeps.go index 9b89110b9..4e23a7bee 100644 --- a/cc/ccdeps.go +++ b/cc/ccdeps.go @@ -142,7 +142,7 @@ func parseCompilerCCParameters(ctx android.SingletonContext, params []string) cc compilerParams.HeaderSearchPath = append(compilerParams.HeaderSearchPath, strings.TrimPrefix(param, "-I")) case systemHeaderSearchPath: - if i < len(params)-1 { + if i < len(cparams)-1 { compilerParams.SystemHeaderSearchPath = append(compilerParams.SystemHeaderSearchPath, cparams[i+1]) } i = i + 1