Check that ar_path is defined before use
authorCharles Giessen <charles@lunarg.com>
Tue, 13 Aug 2024 14:00:44 +0000 (09:00 -0500)
committerCharles Giessen <46324611+charles-lunarg@users.noreply.github.com>
Tue, 13 Aug 2024 14:24:09 +0000 (09:24 -0500)
BUILD.gn

index 10c483c547d1da4b985b377fab52690debbb8ff6..a5d768c1ef7308f5e6bbd520ac44bfd6e91a8c48 100644 (file)
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -98,7 +98,7 @@ if (!is_android) {
     library_type = "static_library"
   }
   support_unknown_function_handling = false
-  if (ar_path != "" && !is_win && (current_cpu == "arm64" || current_cpu == "x86_64")) {
+  if (defined(ar_path) && ar_path != "" && !is_win && (current_cpu == "arm64" || current_cpu == "x86_64")) {
     support_unknown_function_handling = true
     static_library("asm_offset") {
       sources = [ "loader/asm_offset.c" ]