enable JAVA build if allowed

- previously disabled in PDK build

Change-Id: Ic7c87d839e8feac940e8f1dfa0a5899868df776c
diff --git a/apps/SampleEmailPolicy/Android.mk b/apps/SampleEmailPolicy/Android.mk
index 9ae9308..9217018 100644
--- a/apps/SampleEmailPolicy/Android.mk
+++ b/apps/SampleEmailPolicy/Android.mk
@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-ifneq ($(TARGET_BUILD_PDK),true)
+ifneq ($(TARGET_BUILD_JAVA_SUPPORT_LEVEL),)
 
 # This is the makefile for the Email Policy package contained elsewhere in this sample.
 # When deploying to an actual device, you must change LOCAL_PACKAGE_NAME to the name desired for
@@ -34,4 +34,4 @@
 
 include $(BUILD_PACKAGE)
 
-endif # !PDK
\ No newline at end of file
+endif # JAVA_SUPPORT
diff --git a/apps/client/Android.mk b/apps/client/Android.mk
index 2318fe3..dfb6357 100644
--- a/apps/client/Android.mk
+++ b/apps/client/Android.mk
@@ -14,7 +14,7 @@
 # limitations under the License.
 #
 
-ifneq ($(TARGET_BUILD_PDK),true)
+ifneq ($(TARGET_BUILD_JAVA_SUPPORT_LEVEL),)
 
 # This makefile is an example of writing an application that will link against
 # a custom shared library included with an Android system.
@@ -40,4 +40,4 @@
 
 include $(BUILD_PACKAGE)
 
-endif # !PDK
\ No newline at end of file
+endif # JAVA_SUPPORT
diff --git a/apps/upgrade/Android.mk b/apps/upgrade/Android.mk
index 4cba7e4..01ec440 100644
--- a/apps/upgrade/Android.mk
+++ b/apps/upgrade/Android.mk
@@ -14,7 +14,7 @@
 # limitations under the License.
 #
 
-ifneq ($(TARGET_BUILD_PDK),true)
+ifneq ($(TARGET_BUILD_JAVA_SUPPORT_LEVEL),)
 
 LOCAL_PATH:= $(call my-dir)
 include $(CLEAR_VARS)
@@ -34,4 +34,4 @@
 
 include $(BUILD_PACKAGE)
 
-endif # !PDK
\ No newline at end of file
+endif # JAVA_SUPPORT