scamp 1 Posted November 10, 2023 I have installed D12 using the offline installer (ISO). The installer claimed to have installed Android NDK and SDK. Under Tools / Options / Deployment / SDK Manager the paths for NDK & Java are marked as correct. But for the SDK all paths with the exception of "avdmanager.bat or android.bat location:" have an exclamation mark. And indeed, C:\Users\Public\Documents\Embarcadero\Studio\23.0\CatalogRepository\AndroidSDK-2525-23.0.50491.5718 only contains the cmdline-tools subdirectory, and a couple of files (GetItInstall.dat, png, Eula, commandlinetools-win-9477386.zip). On D11 the SDK directory is 1.4GB in size, and contains subdirectories "build-tools", "emulator", "platforms" etc etc. So clearly the Delphi installer is not correctly/fully installing it. Removing and re-adding it with "Manage Features..." results in the exact same result. No errors reported, but SDK is not fully installed. Any pointers? Share this post Link to post
Dave Nottage 568 Posted November 10, 2023 3 minutes ago, scamp said: So clearly the Delphi installer is not correctly/fully installing it. It's likely because you have an incompatible JDK present on the machine. This is a potential fix: 1. Make sure JAVA_HOME environment variable is set to the Adoptium JDK: JAVA_HOME=C:\Program Files\Eclipse Adoptium\jdk-11.0.15.10-hotspot 2. Add missing build-tools by going to: C:\Users\Public\Documents\Embarcadero\Studio\23.0\CatalogRepository\AndroidSDK-2525-23.0.50491.5718\cmdline-tools\latest\bin In a command prompt and issue these commands: sdkmanager “build-tools;33.0.2” sdkmanager “platforms;android-33” 5 Share this post Link to post
scamp 1 Posted November 10, 2023 Hey Dave, thanks much. I first had to get that Eclipse Adoptium installer. Confused on why the Delphi installer is not installing any JDK when it's needing it... Using the two sdkmanager commands works, and a couple of exclamation marks are gone, but the SDK Manager still is complaining about "SDK base path", "adb.exe location". Do you know what else to install? (Trying to add the Android platform to a project and building it produces the amazingly helpful compiler output "[Error]", so the compiler clearly isn't happy yet, either) 1 Share this post Link to post
qubits 21 Posted November 14, 2023 On 11/9/2023 at 10:52 PM, scamp said: Do you know what else to install? Had same issue.. sdkmanager "platform-tools" "platforms;android-33" this command will install the platform-tools which are also missing.. sdkmanager pretty sure my issue was due to an older version of java during install, sdkmanager fails to run.. make sure java paths are set for both 32 and 64 bits, i forgot one.. no more compile errors anyways.. thanks! ~q 2 Share this post Link to post
Bart Kindt 5 Posted November 28, 2023 (edited) I cannot make this work. The entire directory AndroidSDK-2525-23.0.50371.5667\ does not exist. I then downloaded the 'build-tools' from the android website, created this directory and copied the build-tools into it. The PATH to the C:\Program Files\Eclipse Adoptium\ exists (and it is installed) When I run the command line, I get this error: Error: Could not determine SDK root. Error: Either specify it explicitly with --sdk_root= or move this package into its expected location: <sdk>\cmdline-tools\latest\ When I then try to add the --sdk_root I get the error: Error: Unknown argument "--sdk_root C:\..... What a mess. What must I do to make it work? Edited November 28, 2023 by Bart Kindt To get notified Share this post Link to post
Dave Nottage 568 Posted November 28, 2023 2 minutes ago, Bart Kindt said: The entire directory AndroidSDK-2525-23.0.50371.5667\ does not exist. In the released version of Delphi 12, the folder is: C:\Users\Public\Documents\Embarcadero\Studio\23.0\CatalogRepository\AndroidSDK-2525-23.0.50491.5718 Share this post Link to post
Bart Kindt 5 Posted November 28, 2023 (edited) To be clear: there was NO NDK directory at all after installation. Note I had the Beta version initially installed, but I have not tested the Android side of it then. Now I need to work on my Android App, I only found that while the SDK directories are set up in the Deployment, they where never created and nothing at all was downloaded. Edited November 28, 2023 by Bart Kindt Type Share this post Link to post
Bart Kindt 5 Posted November 28, 2023 (edited) I am now completely uninstalling the whole system. ... I have now re-installed. And now I have lost everything! The Options>Deployment>SDK manager is now completely empty! I did see a flash of a CMD window with something like 'file not found' but was gone to quick. What must I now do to completely delete the entire installation (icluding all registry) and how am I supposed to get Delphi 12 installed properly?? Edited November 28, 2023 by Bart Kindt Share this post Link to post
Bart Kindt 5 Posted November 29, 2023 Final solution: First I uninstalled via Windows. But this did not do the request to clear all registery data, so new installation was worse than the original situation. But when I run the (ISO) installation direct, I could tell the installer to clear everything during un-install. When the system was re-installing I could tell it to install the SDK and related stuff. Now everything finally seems complete. 1 Share this post Link to post
FabDev 8 Posted January 18, 2024 (edited) Hello, I have exactly the same problem here after Delphi 12 installation. This directory has been created : C:\Users\Public\Documents\Embarcadero\Studio\23.0\CatalogRepository\AndroidSDK-2525-23.0.50491.5718 But a lot of files are missing in this directory (platforms, build-tools and platforms-tools subdirectories for example). Maybe because of an existing Delphi 11.3 + Android SDK (AndroidSDK-2525-22.0.47991.2819) always installed ? Edited January 18, 2024 by FabDev Share this post Link to post
mark.m 0 Posted February 6, 2024 Hello, after being stuck on Delphi XE5 for many years I am finally trying to catch up and get the latest. The main goal/motivation is to develop for Android. I tried D11 but installation was crashing because of bad-gateway on "getit" server. So, I registered for D12 Trial and successfully installed but I could not find much of Android platform available (more details below). Perhaps the root of my problems is that I was using Windows 7 SP1. Before I move on to Windows 11, I'd like to ask here if D12 can be installed (with Android dev platform) on Windows 7 machine ? If yes, then 2nd part of my story is below. My installation of D12 (from iso file) completed okay but I found no Android platform available as a target. So I googled, found this thread and uninstalled D12. Next I made sure to have "Eclipse Adoptium" java, JAVA_HOME environment and JAVA_HOME\bin in my system "path". Launched installation of D12 again. Everything seemed to be fine but Android SDK/NDK were non-existent when installation completed. In C:\Users\Public\Documents\Embarcadero\Studio\23.0\CatalogRepository\ I have the following folders: Windows_and_Android_Common_Files-23.0.50491.5718, Delphi_Android_Enterprise_Trial-23.0.50491.5718 and Android_Common_Files_Enterprise_Trial-23.0.50491.5718 but they are nearly-empty. When I open Tools-> Options->Deployment->SDK Manager everything is empty. Same as first time. In the next step I tried to add Android SDK/NDK manually, by following this and this. I used SDK 32 and NDK r26b and advanced well forward. In the end however, the "Create a new Android SDK" window in D12 reported that it cannot find paths/locations of ld.exe, strip.exe and gdbserver. I searched the SDK and NDK folders and only found ld.exe but no strip.exe and gdbserver. No I wonder what's the next step. Any hint will be greatly appreciated - thanks ! Share this post Link to post
Lajos Juhász 298 Posted February 6, 2024 6 hours ago, mark.m said: I'd like to ask here if D12 can be installed (with Android dev platform) on Windows 7 machine ? If yes, then 2nd part of my story is below. Since a long time Windows 10 is reuqired to install the Delphi IDE. You can compile applications for older versions of Windows but the dev. machine should be at least Windows 10. I am not aware if there a possibility to install it on Windows 7. Share this post Link to post
mark.m 0 Posted February 6, 2024 Thanks a lot Lajos - I will proceed with installation on Windows 10 and see if the result is better. Share this post Link to post
mark.m 0 Posted February 7, 2024 I did a fresh installation of D12 Architect on a solid Windows 10 box with all updates, Adoptium JDK, JAVA_HOME, java/bin in system paths and everything else I could imagine as potentially important. The installation went perfectly fine. The final result was identical to what I experienced on Windows 7. Android SDK and other Android components were missing. In particular, the folders AndroidSDK-2525 and AndroidNDK-21 are nowhere to be found. I wonder what is the next move that can help in getting Android development ? Share this post Link to post
Dave Nottage 568 Posted February 7, 2024 2 minutes ago, mark.m said: JAVA_HOME, java/bin in system paths What does JAVA_HOME show as, and do you have C:\Program Files\Eclipse Adoptium\jdk-11.0.14.101-hotspot\bin (or a variation thereof, depending on the hotspot version) in the PATH variable? Do you have anything else in the PATH that points to some other JDK? Share this post Link to post
mark.m 0 Posted February 8, 2024 The JAVA_HOME points to C:\Program Files\Eclipse Adoptium\jdk-21.0.2.13-hotspot System variable "PATH" has C:\Program Files\Eclipse Adoptium\jdk-21.0.2.13-hotspot\bin There is no other Java/JDK instance specified in PATH or otherwise. Share this post Link to post
lefjucabro 0 Posted March 19, 2024 Hello, I have same issue: when installing Delphi 12 with Eclipse Adoptium and Android SDK options checked, I have missing files for deploying an Android application. Then I tried to download missing files with these commands in prompt but it doesn't work, I have errors: cmdline-tools\latest\bin\sdkmanager.bat --update cmdline-tools\latest\bin\sdkmanager.bat --install "platforms;android-33" cmdline-tools\latest\bin\sdkmanager.bat --install "build-tools;33.0.0" Like mark.m, I have these following settings: On 2/8/2024 at 6:34 AM, mark.m said: The JAVA_HOME points to C:\Program Files\Eclipse Adoptium\jdk-21.0.2.13-hotspot System variable "PATH" has C:\Program Files\Eclipse Adoptium\jdk-21.0.2.13-hotspot\bin There is no other Java/JDK instance specified in PATH or otherwise At that point I really don't know how to figure it out and resolve my issue. That's why I also installed Android Studio hoping I could download SDK and NDK with SDK Manager tool. I tought it has resolve my issue because downloaded directories are accepted by Delphi (ie directories are fully complete) but in the configuration page, there are stil warnings: Regards Share this post Link to post
GabrielMoraru 0 Posted Friday at 07:11 PM (edited) I had the same issues on Delphi 11.3. I have no clue why Delphi setup completely failed to install all SDK files/folders for Android. Java path was also not set. And this is a brand new installation (in a brand new computer ) I read the official documentation and tried some commands. In the end it worked. So, I created a script - otherwise, next time when I install Delphi, I forget all the commands. Do a search for "Update_SDK.cmd" in this page. In the script, replace "32" with "33" if you are on Delphi 12! Run the script and grab a beer until it finishes... Edited Friday at 07:14 PM by GabrielMoraru Share this post Link to post
Dave Nottage 568 Posted Friday at 07:29 PM 10 minutes ago, GabrielMoraru said: I have no clue why Delphi setup completely failed to install all SDK files/folders for Android. Java path was also not set. And this is a brand new installation (in a brand new computer ) The original installer is broken. If the PC does not have a compatible JDK already installed, it fails to install the SDK and NDK. This has been fixed somewhere between 11.3 and 12.2. The remedy with the "broken" versions is to install the JDK first, with no SDK/NDK, then use Tools | Manage Features to install the SDK/NDK, or install the compatible JDK even before installing Delphi. Share this post Link to post
GabrielMoraru 0 Posted Friday at 07:32 PM (edited) 1 minute ago, Dave Nottage said: The original installer is broken. I think I have seen a "Java not found" message during setup but I just shrugged my shoulders as Delphi compiled fine for Win. But as I said, now I have a script to fix it all. But... too bad for all those wasted hours... Embarcadero could have been done it properly from the beginning with a bit more testing... _____ Edit: I think Emba knew about it from the beginning because the official documentation says: " The first time you attempt to compile an Android application, RAD Studio prompts you to install the missing components of the Android SDK, Android NDK and Android development tools if some required components have not been installed during RAD Studio installation". This vague language... Do they mean, "by accident" or "the user did not want to install them"? Edited Friday at 07:36 PM by GabrielMoraru Share this post Link to post
GabrielMoraru 0 Posted Friday at 07:56 PM Great! Now "Android SDK Manager" is missing! Share this post Link to post
Dave Nottage 568 Posted Friday at 08:00 PM Just now, GabrielMoraru said: Great! Now "Android SDK Manager" is missing! From the Android SDK? Android have not shipped the SDK Manager UI with the SDK for some time now. If you mean from Delphi, what do you see when you go to Tools | Options, Deployment > SDK Manager? Share this post Link to post
GabrielMoraru 0 Posted Friday at 08:03 PM (edited) 13 minutes ago, Dave Nottage said: If you mean from Delphi, what do you see when you go to Tools | Options, Deployment > SDK Manager? My Android device is not detected (even if connected via USB and switched to developer mode). The official documentation shows this screenshot where I could install the driver for my device: https://docwiki.embarcadero.com/images/RADStudio/Alexandria/e/d/d6/AndSDKMini.png with the following warning: Quote "Caution: Use only the Android SDK Manager that is available in the Android Tools node on the Start menu. Do not use any other Android SDK Manager that might be installed elsewhere on your system. A comm and window opens, and then the Android SDK Manager opens". They say it should be under the Start menu, but I can't find it there. Edited Friday at 08:19 PM by GabrielMoraru Share this post Link to post
Dave Nottage 568 Posted Friday at 10:31 PM 2 hours ago, GabrielMoraru said: My Android device is not detected (even if connected via USB and switched to developer mode). That's a separate issue. What device is it? 2 hours ago, GabrielMoraru said: then the Android SDK Manager opens Sadly, this is out of date. The Android SDK Manager will not "open", as per my earlier message (i.e. the UI no longer ships with the SDK) If you install the SDK/NDK via the Manage Features section of the Delphi IDE, you should not need to use it anyway. There are alternatives to installing platform levels and build tools in the SDK, such as via the command line. Share this post Link to post
GabrielMoraru 0 Posted Saturday at 10:28 AM 11 hours ago, Dave Nottage said: Sadly, this is out of date. Yes. Delphi's documentation was always in a deplorable state. Since I had problems installing the SDK, I wanted to follow their documentation. ----------- I used FMX some years ago and I don't remember having any of this problems. Is FMX getting worse instead of better? (Rhetoric question) Share this post Link to post