mirror of
https://github.com/klzgrad/naiveproxy.git
synced 2024-12-05 03:36:08 +03:00
43 lines
1.3 KiB
Plaintext
43 lines
1.3 KiB
Plaintext
|
# Copyright (C) 2017 The Android Open Source Project
|
||
|
#
|
||
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||
|
# you may not use this file except in compliance with the License.
|
||
|
# You may obtain a copy of the License at
|
||
|
#
|
||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||
|
#
|
||
|
# Unless required by applicable law or agreed to in writing, software
|
||
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||
|
# See the License for the specific language governing permissions and
|
||
|
# limitations under the License.
|
||
|
|
||
|
declare_args() {
|
||
|
# Address Sanitizer: memory bugs (e.g., UAF).
|
||
|
is_asan = false
|
||
|
|
||
|
# Leak Sanitizer: memory leaks.
|
||
|
is_lsan = false
|
||
|
|
||
|
# Memory Sanitizer: uninitialized reads.
|
||
|
is_msan = false
|
||
|
|
||
|
# Thread Sanitizer: threading bugs.
|
||
|
is_tsan = false
|
||
|
|
||
|
# Undefined Behaviour Sanitizer.
|
||
|
is_ubsan = false
|
||
|
|
||
|
# # Compile for fuzzing with LLVM LibFuzzer.
|
||
|
use_libfuzzer = false
|
||
|
}
|
||
|
|
||
|
declare_args() {
|
||
|
using_sanitizer =
|
||
|
is_asan || is_lsan || is_tsan || is_msan || is_ubsan || use_libfuzzer
|
||
|
}
|
||
|
|
||
|
assert(!using_sanitizer || is_clang, "is_*san requires is_clang=true'")
|
||
|
assert(!is_msan || is_linux, "msan only supported on linux")
|
||
|
assert(!is_tsan || (is_linux || is_mac), "tsan only supported on linux and mac")
|