This forum is deprecated.
I'm having issues with compiling and deploying an app on the Android platform.Every time I try to compile my project, it says:
[ldandroid Fehler] C:\Users\Public\Documents\Embarcadero\Studio\18.0\PlatformSDKs\android-ndk-r9c\toolchains\arm-linux-androideabi-4.8\prebuilt\windows\bin\arm-linux-androideabi-ld.exe: error: cannot find -lFireDACMySQLDriver
I'm using MyDAC for Database communication, so I don't get why the compiler is looking for the FireDAC driver.I've tried the same thing in C++ Builder 10.3, but decided to downgrade to 10.1.2. again because of the terrible Code insight performance an the falsely marked syntactical errors in 10.3
The Project includes the following headers:
#include "DBAccess.hpp"#include "MemDS.hpp"#include "MyAccess.hpp"#include <Data.DB.hpp>#include <FMX.Controls.hpp>#include <FMX.Controls.Presentation.hpp>#include <FMX.Edit.hpp>#include <FMX.Layouts.hpp>#include <FMX.ListBox.hpp>#include <FMX.Media.hpp>#include <FMX.StdCtrls.hpp>#include <FMX.Types.hpp>#include <System.Classes.hpp>
(no FireDAC Components used)
also, I noticed that when i compile even an empty FMX project and deploy it to Android, my VDevice always crashes the App - Does anyone know why this may happen? I'm using the SDK fpr A9 and A10. this has nothing to do with the main problem but i need some advice...
Tanks in advance
is possible you upload one project same that simple for test here!
thanks for your suggestion.
searching for the driver name in the files delivers 0 results.
"other, possibility to find the cause:
this wont solve the problem either, I completely removed RAD studio from my system und reinstalled it (Removing Programdata, Appdata, Public, ProgramFiles, Registry Paths) and i get the same error, so i guess it has something to do with the project itself.
I've tried removing all FireDAC packages in the Project options, didnt help either
from what I understand the compiler looks for something in the NDK files, so I tried using the 10.3 RIO SDK and NDK enviroment while still using C++ builder 10.1.2 Berlin, and here i get a different error:
[bccaarm Fatal Error] sysmac.h(113): 'stdint.h' file not found
I'm starting to think that the IDE may cause the problem...
maybe install mswindows + rad in a VM for tests before hard action
.if still, then, the cause it's your project files setting.
try delete all files created by IDE when compiling, like .dproj .cachexxx and some .res files.
I ended up redoing the whole Projekt, starting with an empty application, building the forms and copying the code method by method - and will you look at that - it compiled. Then I compared the old vs the new souncecode via telemetry... -> absolutely the same for every file. this kinda tells me that RAD Studio linked something that wasnt there to begin with by itself...
this whole process took me 8h. I think this will be the last time I use FMX in general, VCL seems to be fine.
Even though i now can compile my project, it still crashes on every android device i try to deploy it to. Even empty projects do this, and I tested it with 10.3.2, 10.2.3 and 10.1.2 (and different NDKs, SDKs)
I'm starting to get mad... does anybody have a clue
I'm using 10.3.3 and can deploy to Android device just fine to my Pixel 2 XL from Delphi for a Android 64-bit app. Also, just created a simple C++Builder FMX app and deployed to the same device with a 32-bit version (no 64-bit option available for Android in C++Builder 10.3.3). Looks like possibly still a configuration issue somewhere and I can attest to it being really finnicky to get configured properly.
What error are you getting: during deployment, after deployment and while running? Have you tried an empty Delphi project?
That would at least tell you if it's a RAD Studio config issue or if it's specific to C++Builder. I have verified that I can deploy to an Android device in both 32-bit and 64-bit from C++Builder and Delphi for 10.3.3.
I've been using Delphi for a long time and can attest to hiccups, bumps in the road, and other issues with configuration, but it's also nice to be able to target Windows, iOS, macOS, Android, and Linux (server-side apps) from a single codebase.
I totally understand your frustration, but I wouldn't give up on FMX just yet.
I've recorded the whole process here
I've not installed the Delphi Builder option, just C++ builderI'm on 10.2.3 at the moment for the reasons I stated earlier.
You may have to target an older Android SDK/NDK/API and/or Android Emulator. I remember having similar issues with Delphi when Android switched to requiring 64-bit and iOS requiring 64-bit. Almost positive that's what happening with your setup.
I've tried using older SDK/NDK. when I tried to setup the RAD Android SDK enviroment and pick the folders, it always tells me that my NDK/SDK folders ar not valid. and this doesnt happen just on emulated devices, i deployed it and transfered it to my OnePlus 3, the installation quits with "the app was not installed".
I bought a oneplus Nord on launch day yesterday, when it arrives i will test it on this device too.
"You may have to target an older Android SDK/NDK/API" -> should i try compiling on API27 (Android 8.1)?
Yes, try that. The problem is targeting newer versions of Android from an older version of C++Builder.
Maybe set up an emulator that is running Android 8 (maybe 9 - I can't remember when the transition occurred) and try that.