Yes, I have. And now I have solved this problem, I use mmm tools/fuzzers/fuzz_me_fuzzer/,it will succeed. The absolute path I used before,like mmm ~/home/XXX/Android/source-8.0.0/tools/fuzzers/fuzz_me_fuzzer/,it failed. So,My description may not be accurate, because I didn't know the reason for the path at the time. finally, mmm tools/fuzzers/fuzz_me_fuzzer/, use internal path is real worked.
thanks for your reply! 在 2018年8月4日星期六 UTC+8上午4:18:14,Colin Cross写道: > > You must have LOCAL_PATH := $(call my-dir) at the top of each Android.mk > > On Fri, Aug 3, 2018, 8:51 AM <[email protected] <javascript:>> wrote: > >> Hello, I have the same problem. I tried to build this on Android O : 8.0 >> I wrote a libfuzzer demo under tools/fuzzers/fuzz_me_fuzzer follow the >> steps of https://source.android.com/devices/tech/debug/libfuzzer,like >> this: >> >> extern "C" int LLVMFuzzerTestOneInput(const uint8_t *buf, size_t len) { >> FuzzMe(buf, len); >> return 0; >> } >> >> and Android.mk: >> >> OCAL_PATH:= $(call my-dir) >> >> include $(CLEAR_VARS) >> >> LOCAL_SRC_FILES := fuzz_me_fuzzer.cpp >> LOCAL_CFLAGS += -Wno-multichar -g -O0 >> LOCAL_MODULE_TAGS := optional >> LOCAL_CLANG := true >> LOCAL_MODULE:= fuzz_me_fuzzer >> >> Include $(BUILD_FUZZ_TEST) >> >> Use command: >> >> make -j$(nproc) fuzz_me_fuzzer SANITIZE_TARGET="address coverage" >> >> get error: >> >> ninja: error: '/src/fuzz_me_fuzzer.cpp', needed by >> 'out/target/product/generic/obj_asan/EXECUTABLES/fuzz_me_fuzzer_intermediates/src/fuzz_me_fuzzer.o', >> >> missing and no known rule to make it >> 20:25:06 ninja failed with: exit status 1 >> >> so ,I think I should make it first.Use command: >> >> mmm tools/fuzzers/fuzz_me_fuzzer/ >> >> get error: C_INCLUDES must be under the source or output directories, >> >> where should I put the files? If I want to write some simple Android >> native code, where should I put the files? Should I use ‘mmm’ or other >> commands? >> >> -Wang >> >> 在 2018年7月18日星期三 UTC+8上午11:56:05,Dan Willemsen写道: >>> >>> So we don't support using files during the build from outside of the >>> source or output directories. That's what this check is intended to check >>> for, so if you're trying that, put all of your source into the source >>> directory. >>> >>> There are a couple of other things that can trigger this check -- I've >>> seen both of these in practice: >>> >>> 1. Using $(VAR)/include in your LOCAL_C_INCLUDES, but when VAR isn't >>> set. The build system then gets "/include", and before this check would >>> attempt to look at the filesystem in that location. If that happened to be >>> present on a machine, it could end up using that inappropriately. >>> >>> 2. Using an absolute path to a directory within the source path. This >>> happens when someone overzealously uses $(abspath) or similar. Instead, >>> make sure that all of your paths are relative paths from the top of the >>> source tree. During a build, the working directory is always at the top of >>> the source tree. >>> >>> - Dan >>> >>> On Tue, Jul 17, 2018 at 11:56 AM RMApps Solution <[email protected]> >>> wrote: >>> >>>> Hello, >>>> I have problem to build in vendor/folder/subfolder. When try to do mm >>>> in that path, i got this errror: >>>> >>>> build/core/binary.mk:1485: error: vendor/folder/subfolder/Android.mk: >>>> libXXX: C_INCLUDES must be under the source or output directories . >>>> >>>> I tried to build this on Android O : 8.0 >>>> >>>> Anyone had this problem ? >>>> >>>> -- >>>> -- >>>> You received this message because you are subscribed to the "Android >>>> Building" mailing list. >>>> To post to this group, send email to [email protected] >>>> To unsubscribe from this group, send email to >>>> [email protected] >>>> For more options, visit this group at >>>> http://groups.google.com/group/android-building?hl=en >>>> >>>> --- >>>> You received this message because you are subscribed to the Google >>>> Groups "Android Building" group. >>>> To unsubscribe from this group and stop receiving emails from it, send >>>> an email to [email protected]. >>>> For more options, visit https://groups.google.com/d/optout. >>>> >>> -- >> -- >> You received this message because you are subscribed to the "Android >> Building" mailing list. >> To post to this group, send email to [email protected] >> <javascript:> >> To unsubscribe from this group, send email to >> [email protected] <javascript:> >> For more options, visit this group at >> http://groups.google.com/group/android-building?hl=en >> >> --- >> You received this message because you are subscribed to the Google Groups >> "Android Building" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> For more options, visit https://groups.google.com/d/optout. >> > -- -- You received this message because you are subscribed to the "Android Building" mailing list. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-building?hl=en --- You received this message because you are subscribed to the Google Groups "Android Building" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
