Auto-generate java libraries for compatible packages.

Change-Id: I753f8bc5ab8ca6b5293c75b548897bbdec16aa65
Bug: 31221188
diff --git a/Interface.cpp b/Interface.cpp
index fc7e48d..52d960e 100644
--- a/Interface.cpp
+++ b/Interface.cpp
@@ -261,6 +261,11 @@
         return true;
     }
 
+    if (mSuperType != nullptr && !mSuperType->isJavaCompatible()) {
+        mIsJavaCompatibleInProgress = false;
+        return false;
+    }
+
     mIsJavaCompatibleInProgress = true;
 
     if (!Scope::isJavaCompatible()) {