Jump to content
Delpher2600

Cannot compilate ProjectGroup with dynamic library

Recommended Posts

Hello. I made ProjectGroup from host FMX-project and dynamic library-project (.so). I'm using standart code for call export function:

{$IFDEF MSWINDOWS}
  procedure DStart; external 'DLLName.dll';
 {$ENDIF}

 {$IFDEF ANDROID}
  procedure DStart; external 'libDLLName.so';
  {$ENDIF}

And when i tryed compilate it for Android. Delphi fired out with next error:

[DCC Error] E2597 C:\Users\Public\Documents\Embarcadero\Studio\22.0\CatalogRepository\AndroidNDK-21-22.0.48361.3236\android-ndk-r21\toolchains\arm-linux-androideabi-4.9\prebuilt\windows-x86_64\bin\arm-linux-androideabi-ld.exe: error: cannot find -lDllName {DllName is library name}

What is it and how fix it?

Share this post


Link to post
Posted (edited)

Not enough information really...

On 5/17/2024 at 6:11 PM, Delpher2600 said:

cannot find -lDllName {DllName is library name}

but I would guess it is a path issue. Where is your libDLLName.so? Does it exist? How are you deploying it?

 

Here is a post about deploying it.

 

Edited by Jim McKeeth
add quote

Share this post


Link to post
On 5/18/2024 at 2:11 AM, Delpher2600 said:

What is it and how fix it?

Contrary to the Windows platform, the linker for Android/iOS/macOS needs the .so/.dylib, so it must be available when you compile (and link) your project. A quick and easy solution is to put the .so in the $(Platform)\$(Config) folder of your project.

 

There are numerous elaborate explanations out there on why this is the case with the external linkers used for other platforms, but unfortunately I can't locate one right now.

 

But you also need to deploy the .so - that's what Jims post is referring to.

  • Like 1

Share this post


Link to post
12 hours ago, msohn said:

Contrary to the Windows platform, the linker for Android/iOS/macOS needs the .so/.dylib, so it must be available when you compile (and link) your project. A quick and easy solution is to put the .so in the $(Platform)\$(Config) folder of your project.

 

There are numerous elaborate explanations out there on why this is the case with the external linkers used for other platforms, but unfortunately I can't locate one right now.

 

But you also need to deploy the .so - that's what Jims post is referring to.

But i don't know haw compilate so-library. When i just press big green button, it's just processing. and in the end RAD fireing out with error and showing me this page. 

And sub-folder bin in a folder Android>Release is empty.

изображение_2024-05-23_014709365.png

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×