Move -Wno-null-pointer-arithmetic to external only

Test: m checkbuild
Bug: 72331524
Change-Id: I9c49a8cef547f6c840001fd203a0abecaeef44d5
Merged-In: I9c49a8cef547f6c840001fd203a0abecaeef44d5
(cherry picked from commit 3e88cb03993ac8f1d97951f3ae5cdecb70d91371)
diff --git a/cc/config/clang.go b/cc/config/clang.go
index c070bf2..a0ebd10 100644
--- a/cc/config/clang.go
+++ b/cc/config/clang.go
@@ -167,10 +167,6 @@
 		"-Wno-tautological-unsigned-enum-zero-compare",
 		"-Wno-tautological-unsigned-zero-compare",
 
-		// http://b/72331524 Allow null pointer arithmetic until the instances detected by
-		// this new warning are fixed.
-		"-Wno-null-pointer-arithmetic",
-
 		// http://b/72330874 Disable -Wenum-compare until the instances detected by this new
 		// warning are fixed.
 		"-Wno-enum-compare",
@@ -187,6 +183,10 @@
 	// Extra cflags for projects under external/ directory
 	pctx.StaticVariable("ClangExtraExternalCflags", strings.Join([]string{
 		// TODO(yikong): Move -Wno flags here
+
+		// http://b/72331524 Allow null pointer arithmetic until the instances detected by
+		// this new warning are fixed.
+		"-Wno-null-pointer-arithmetic",
 	}, " "))
 }