History log of /sdk/find_java/
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
4cab9f439720ff9fd914f8bfcbf6b72b04a50d6b 12-Feb-2015 Xavier Ducrohet <xav@google.com> Revert "Add targetPlatform for executable binaries"

This reverts commit 7f3cb91779907c12d02e8e5c5f4a6a7c510d210e.
uild.gradle
7f3cb91779907c12d02e8e5c5f4a6a7c510d210e 06-Feb-2015 Raymond Chiu <chiur@google.com> Add targetPlatform for executable binaries

Make dsl changes due to gradle update.

Change-Id: I65729783f5c8f985ed31a231e7dd9a0b9e50f7b3
uild.gradle
f8796b4dce9202306dcd49afbdc9272f26845329 10-Dec-2014 David Herman <davidherman@google.com> find_java.bat now uses env var instead of find

The officially recommended way to query an OS for its 32-bit/64-bit
architecture can be found in this KB article:
http://support.microsoft.com/kb/556009

Unfortunately, this fails for some subset of users for at least two
reasons:

1) Many users install Unix tools on their Windows box, overwriting
"find" with the Unix variant that doesn't support the \i parameter
2) Some machines are simply missing reg.exe. I've seen one claim in
the wild that this was due to an agressive anti-virus scanner
removing malware from their machine.

Therefore, we now use absolute paths to the utilities we want to
target. Additionally, we now have fallback handling if reg.exe is
missing, where we, instead, rely on the %PROCESSOR_ARCHITECTURE%
environment variable.

Related issues:
https://code.google.com/p/android/issues/detail?id=82099
https://code.google.com/p/android/issues/detail?id=82388

Change-Id: Icee0882fa6e1f5359c086498eb2679197cdf6f8e
ind_java.bat
6c1c55e0da303b2fca8c230e0959275d31cf66e2 10-Dec-2014 David Herman <davidherman@google.com> Fixed find_java syntax error on 32-bit machines

Related issue:
https://code.google.com/p/android/issues/detail?id=82099

Change-Id: I8241eb58d45ceca4b5ada4f5550f79376c716ed6
ind_java.bat
f7dd3d94c134d29ad37299bdb865b0a48430dfb3 25-Nov-2014 David Herman <davidherman@google.com> find_java now locates openjdk as well

Related issue:
https://code.google.com/p/android/issues/detail?id=77218

Change-Id: I08523830c813d9cdcd303780f15f49bd5edc5ac3
rc/source/find_java_lib.cpp
633339d82e0da9cafa9b2ccea46b9375ad64d668 24-Nov-2014 David Herman <davidherman@google.com> Fixed find_java JAVA_HOME minimum version bug

If a minimum version is specified, Find Java should reject any
java whose version is not at least that high. However, faulty
logic ignored this contract when reading an old Java path out of
the JAVA_HOME environment variable.

Related to issue:
https://code.google.com/p/android/issues/detail?id=80419

Change-Id: Iad935694e5b143f53074d28b8c8d7f087f9690e4
rc/source/find_java_lib.cpp
7e91a740cb092a020c1bb6e99982e162741ffd61 14-Nov-2014 Xavier Ducrohet <xav@google.com> Merge "Build and package 32/64bit find_java." into studio-1.0-dev
b5298b16a14cc23b3072401bde45e9bf8720f00f 23-Oct-2014 David Herman <davidherman@google.com> Modifed find_java.bat and build settings

Find Java now statically links in all MFC / Windows dependencies,
as well as it builds to find_java32.exe and find_java64.exe.
find_java.bat has been updated to take advantage of these new
names.

Change-Id: Iaa50d461074235dd9db750201d6e033058a2e695
ind_java.bat
ind_java_exe.vcxproj
8e66edff331244d3a1ad3847e774f98cd342485d 07-Nov-2014 Xavier Ducrohet <xav@google.com> Build and package 32/64bit find_java.

Change-Id: I93a2e42fb0a81d1495bb12b657b6bd6a597a128e
uild.gradle
ea29cd16b2ae3f04294165ba0b5e4d839dfc8406 20-Oct-2014 David Herman <davidherman@google.com> New -path arg for find_java

Previously, the only way to specify a custom java.exe location for
find_java was through JAVA_HOME, but now we have one more hook.
If you pass in a custom path, and it is found, the rest of
find_java will be skipped, and that path will be used.

This has a few advantages:
1) Passing in an explicit custom path is really intuitive.

2) JAVA_HOME may be used by other applications, and asking users
to override it for us could cause compatibility issues.

3) This makes life much easier for our installer, which does not
want to blindly overwrite the user's JAVA_HOME environment
variable.

4) If we ever change where we store a java path (new registry, in
a file somewhere), we don't have to recompile find_java.exe to
account for it. All we have to do is update find_java.bat.

5) This gives us a really easy way to tell users who run into
find_java bugs a way to fix them.

Change-Id: I1d7bd95c9225f34c22d987005f32af256f81d908
rc/source/find_java.h
rc/source/find_java_exe.cpp
rc/source/find_java_lib.cpp
171072b90ed953304b1bbfa96022ab71b82d9969 18-Oct-2014 David Herman <davidherman@google.com> New -error arg for find_java

We want our installer to show a (potentially) helpful error
message when find_java can't, well, find java. (Before, find_java
would print nothing).

After this CL is in, then if you pass -e(rror) in as an argument,
find_java will either print the found java.exe path and return 0,
or it will print an error message and return 1.

Change-Id: I5c411ea75a8eecdb0c60aa84350a2a762a30c6d1
rc/source/find_java_exe.cpp
8ebbf9d423fe3fdbbf57d972dd3a88160ccee823 18-Oct-2014 David Herman <davidherman@google.com> Added new -minv (version) option to find_java

find_java historically checks for v1.6, which is defined by a
constant in find_java.h, and simply bumping the value up may
cause problems with existing tools. Therefore, I've added an
argument that takes an input minimum version to look for.

Change-Id: I901dbf3621a262b3e8ee5a42ce9e46ce49126363
rc/source/find_java.h
rc/source/find_java_exe.cpp
rc/source/find_java_lib.cpp
1b9e6f635463f50548ef24e83ba73c8efd6b6fb3 17-Oct-2014 David Herman <davidherman@google.com> New -jdk option for find_java

find_java traditionally searched for any java.exe it could find,
but recent requirements ask us to find versions of java.exe
that are bundled in a JDK. This can now be done using the -jdk
flag.

Change-Id: I3aaba9c74271f0529d7fa16ff822b999059d578c
rc/source/find_java.h
rc/source/find_java_exe.cpp
rc/source/find_java_lib.cpp
127af49b6548e0a20cb02fa8ce86c90d1da7f875 15-Oct-2014 David Herman <davidherman@google.com> find_java now supports 64-bit builds

Change-Id: I46f2462f396c7c2f40238b7da438189b9de02a15
ind_java.sln
ind_java_exe.vcxproj
ind_java_lib.vcxproj
rc/source/find_java_exe.cpp
rc/source/find_java_lib.cpp
rc/source/utils.h
81f21b205762b11189ba53267bac4c9c1e83181a 10-Oct-2014 David Herman <davidherman@google.com> find_java: new method to search in a custom path

Change-Id: I081871bbff9c6e714eda3e47ee16e8b486e2355b
rc/source/find_java.h
rc/source/find_java_lib.cpp
4a7b893a4da91b4d83095c32e88bcaf939010e4c 10-Oct-2014 David Herman <davidherman@google.com> find_java.sln (and related project files) updated

- Paths needed to be updated from find_java to find_java/src/source
- Some projects weren't compiling and needed to include references
to various .cpp files

Change-Id: I495905ef37a693d25cf34410dc395c9ae074b1da
gitignore
ind_java.sln
ind_java_exe.vcproj
ind_java_exe.vcxproj
ind_java_exe.vcxproj.filters
ind_java_lib.vcproj
ind_java_lib.vcxproj
ind_java_lib.vcxproj.filters
f94d89c0a13dad5a4ad148f2906c0ef67c19f81e 18-Jun-2014 Xavier Ducrohet <xav@google.com> Fix find_java.

Change-Id: Ib2395bd47f4a751b449a618563b438e72f76633f
uild.gradle
53a6029a83a3b070f57dd5323f37f6fd18ca4633 12-Jun-2014 Xavier Ducrohet <xav@google.com> Compile find_java with Gradle.

Change-Id: I90ff236c35a857ebde82c3d63479709474aad204
uild.gradle
ind_java.h
ind_java_exe.cpp
ind_java_lib.cpp
rc/source/find_java.h
rc/source/find_java_exe.cpp
rc/source/find_java_lib.cpp
rc/source/utils.cpp
rc/source/utils.h
tils.cpp
tils.h
7405017e91c15bbc58aa31cbd946091949d44490 16-Aug-2013 Scott Barta <sbarta@google.com> Support for installing SDK in C:\Program Files

Properly handles spaces in installation pathname on Windows.

Change-Id: I8bcfd18fddbe6d5ad70a8563e8696af2876c1d1b
ind_java.bat
69d33c68eab8a49867c2cd9618f0d3d380ab2857 26-Nov-2012 Raphael Moll <ralf@android.com> Merge "SDK Launcher support sdk\tools\android.bat"
d5d08c0ab6c4a0228544f6839e33045cf9b43723 20-Nov-2012 Raphael Moll <ralf@android.com> SDK Launcher support sdk\tools\android.bat

The SDK Launcher is the "SDK Manager.exe" redirector
that is copied at the root of an installed SDK. This
change the path where it looks for android.bat so that
it can also work when placed at the root of an ADT
bundle.

SDK Bug: 39686

Change-Id: I6222e45be5a3aca62d3557e2f8763c21c07f4f5d
ind_java.sln
a7576b7328e7cb64af11e4f9242d55ab56586b70 19-Nov-2012 Raphael Moll <ralf@android.com> find_java.exe: SDK tools require Java 1.6

find_java.exe is used to locate the Path to the JVM on Windows
and it checks the Java version. SDK tools require Java 1.6 now.

Also update the find_java error message to mention the
JAVA_HOME environment variable.

SDK Bug: 39876

Change-Id: I355998b10014471ccbe14ca9e977d07126b072c1
ind_java.bat
ind_java.h
26a423a5de4b715a980a0c0f0a16ec50bf39aef2 17-Aug-2012 Raphael Moll <ralf@android.com> find_java: wrap toShortPath in disableWow64FSRedirection.

Change-Id: I4e3135927616eb6ad3e0da46496bb97b3029ccd9
ind_java_exe.cpp
f84b9feb3e21022f449812dfa10d1d1a1339683f 17-Aug-2012 Raphael Moll <ralf@android.com> VS8 projects for find_java/find_lock (exe & dll).

Change-Id: I73d08808cbf0dd7032fc481aa81ad37181930d05
gitignore
ind_java.sln
ind_java_exe.vcproj
ind_java_lib.vcproj
6123b532fc0e57e33a09dc429f8ec708a88aedcc 30-Jan-2012 Raphael <raphael@google.com> Win SDK: find max version of java.exe

When we find a java.exe file, run java -version and
parse its version number. Only accept java 1.5 or
better.

There's a moderate effort to find the highest
version available in each category: for starter
scripts, it doesn't matter if we actually have
the highest. However within a given category
(env path, program files, registry), picking
up the highest available make sense. In normal
cases users won't have many concurrent versions.

Change-Id: I4f2504642a1712b62aa303562578572066d82d3b
ind_java.h
ind_java_exe.cpp
ind_java_lib.cpp
42a9cedd9d2aa55a9ed71e50cb4a7199a926a4e9 27-Jan-2012 Raphael <raphael@google.com> SDK: update find_java lib

Change-Id: I6a139630a325f3537961cc5be2726816a060bb65
tils.cpp
tils.h
a418de56908e413187e1144b7d1d430bbfc459d5 27-Jan-2012 Raphael <raphael@google.com> SDK: use new find_java.exe in SDK bat files

Change-Id: I9f3fc572c3af6d8457a75cebae1aa6a850511afc
ind_java.bat
ind_java_exe.cpp
692d2b58196af2a73343b476af6e33df876c45a5 26-Jan-2012 Raphael <raphael@google.com> SDK find_java, fix mingw build.

Change-Id: Ic2bfe71de73ee27d44b6004dd66893374e140bba
ind_java_lib.cpp
d7cebf62058bdcc50ada02ac8ecb038830e58af6 25-Jan-2012 Raphael <raphael@google.com> SDK: fix makefile for find_java

Change-Id: I7a7cdd38edfd6cc0d4272faad3df4c1c34b724cd
ndroid.mk
d2d6999d779fffe976c55db04bf523907a8743ed 25-Jan-2012 Raphael <raphael@google.com> Windows: "find_java" exe and lib for android.bat

This adds a "find_java.exe" that will be packages
in SDK/tools/lib. It will be used by android.bat
and the other launchers to locate the best version
of java to use for our tools (currently we have
a find_java.bat that uses DOS commands to achieve
something similar but more limited).

In addition this creates a static "findjavalib"
that is used by the NSIS installer to locate
java and get its version (to complain in case we
only find a Java 1.4 or lesser). The goal is for
the installer to use the same logic as the tools
will use to locate the java binary.

Change-Id: Ic2efb388135087bab9687c3332882047fd041b1c
gitignore
ndroid.mk
OTICE
ind_java.exe.manifest
ind_java.h
ind_java_exe.cpp
ind_java_lib.cpp
mages/android_icon.ico
mages/android_icon.rc
tils.cpp
tils.h