cmd/gomobile: don't ignore -openal if no NDK was found

Updates golang/go#20902

Change-Id: I523c0b7a205e620c143f2ba9c7cdbe30865a9c59
Reviewed-on: https://go-review.googlesource.com/101136
Reviewed-by: Hyang-Ah Hana Kim <hyangah@gmail.com>
diff --git a/cmd/gomobile/init.go b/cmd/gomobile/init.go
index 79d6d88..10e7370 100644
--- a/cmd/gomobile/init.go
+++ b/cmd/gomobile/init.go
@@ -170,9 +170,13 @@
 }
 
 func installOpenAL(gomobilepath string) error {
-	if initNDK == "" || initOpenAL == "" {
+	if initOpenAL == "" {
 		return nil
 	}
+	if !hasNDK() {
+		return errors.New("The Android NDK is needed to build OpenAL but it was not found. Please run gomobile init with the ndk-bundle installed through the Android SDK manager or with the -ndk flag set.")
+	}
+
 	var cmake string
 	if buildN {
 		cmake = "cmake"