Remove JAVA_NOT_REQUIRED
This is no longer required.
Test: cs/JAVA_NOT_REQUIRED
Change-Id: I9f64e153c9f4af7df1c8dee4eaea3c7458be61c0
diff --git a/core/config.mk b/core/config.mk
index 1692f2f..bf567d0 100644
--- a/core/config.mk
+++ b/core/config.mk
@@ -860,22 +860,14 @@
APPS_DEFAULT_VERSION_NAME := $(PLATFORM_VERSION)
endif
-ifeq ($(JAVA_NOT_REQUIRED),true)
-# Remove java and tools from our path so that we make sure nobody uses them.
-unexport ANDROID_JAVA_HOME
-unexport JAVA_HOME
-export ANDROID_BUILD_PATHS:=$(abspath $(BUILD_SYSTEM)/no_java_path):$(ANDROID_BUILD_PATHS)
-export PATH:=$(abspath $(BUILD_SYSTEM)/no_java_path):$(PATH)
-else
- # Put java first on the path
- # TODO(ccross): remove this once tools run during the build no longer depend on
- # finding java in the path
- ifeq (,$(strip $(CALLED_FROM_SETUP)))
- ifneq ($(shell which java),$(abspath $(ANDROID_JAVA_TOOLCHAIN)/java))
- $(warning Found incorrect java $(shell which java) in $$PATH)
- $(warning Adding $(abspath $(ANDROID_JAVA_TOOLCHAIN)) to $$PATH)
- export PATH:=$(abspath $(ANDROID_JAVA_TOOLCHAIN)):$(PATH)
- endif
+# Put java first on the path
+# TODO(ccross): remove this once tools run during the build no longer depend on
+# finding java in the path
+ifeq (,$(strip $(CALLED_FROM_SETUP)))
+ ifneq ($(shell which java),$(abspath $(ANDROID_JAVA_TOOLCHAIN)/java))
+ $(warning Found incorrect java $(shell which java) in $$PATH)
+ $(warning Adding $(abspath $(ANDROID_JAVA_TOOLCHAIN)) to $$PATH)
+ export PATH:=$(abspath $(ANDROID_JAVA_TOOLCHAIN)):$(PATH)
endif
endif
diff --git a/core/no_java_path/jar b/core/no_java_path/jar
deleted file mode 120000
index 8586397..0000000
--- a/core/no_java_path/jar
+++ /dev/null
@@ -1 +0,0 @@
-java
\ No newline at end of file
diff --git a/core/no_java_path/jarsigner b/core/no_java_path/jarsigner
deleted file mode 120000
index 8586397..0000000
--- a/core/no_java_path/jarsigner
+++ /dev/null
@@ -1 +0,0 @@
-java
\ No newline at end of file
diff --git a/core/no_java_path/java b/core/no_java_path/java
deleted file mode 100755
index f3422f3..0000000
--- a/core/no_java_path/java
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/bash
-
-echo "Error: JAVA_NOT_REQUIRED=true, $(basename $0) is unavailable." 1>&2
-exit 1
diff --git a/core/no_java_path/javac b/core/no_java_path/javac
deleted file mode 120000
index 8586397..0000000
--- a/core/no_java_path/javac
+++ /dev/null
@@ -1 +0,0 @@
-java
\ No newline at end of file
diff --git a/core/no_java_path/keytool b/core/no_java_path/keytool
deleted file mode 120000
index 8586397..0000000
--- a/core/no_java_path/keytool
+++ /dev/null
@@ -1 +0,0 @@
-java
\ No newline at end of file