Fixed the issue that phony module was broken.

Phony module was broken since it reached the code line to try to
invoke some specific arch functions which caused the runtime panic
error.

Bug: 36739664
Test: mm -j32 -k
phony {
     name: "shell_and_utilities",
     required: [
         "grep",
         "gzip",
         "mkshrc",
         "reboot",
         "sh",
         "toolbox",
         "toybox",
     ],
}
in system/core/shell_and_utilities/Android.bp

Change-Id: Idf7da17d431aae5f0c56b08f5e5eef14ae4eef50
diff --git a/android/androidmk.go b/android/androidmk.go
index d55cdca..f606522 100644
--- a/android/androidmk.go
+++ b/android/androidmk.go
@@ -175,19 +175,21 @@
 
 	if data.Custom != nil {
 		prefix := ""
-		switch amod.Os().Class {
-		case Host:
-			prefix = "HOST_"
-		case HostCross:
-			prefix = "HOST_CROSS_"
-		case Device:
-			prefix = "TARGET_"
+		if amod.ArchSpecific() {
+			switch amod.Os().Class {
+			case Host:
+				prefix = "HOST_"
+			case HostCross:
+				prefix = "HOST_CROSS_"
+			case Device:
+				prefix = "TARGET_"
 
-		}
+			}
 
-		config := ctx.Config().(Config)
-		if amod.Arch().ArchType != config.Targets[amod.Os().Class][0].Arch.ArchType {
-			prefix = "2ND_" + prefix
+			config := ctx.Config().(Config)
+			if amod.Arch().ArchType != config.Targets[amod.Os().Class][0].Arch.ArchType {
+				prefix = "2ND_" + prefix
+			}
 		}
 
 		return data.Custom(w, name, prefix, filepath.Dir(ctx.BlueprintFile(mod)))