Lazarus

Programming => Operating Systems => Android => Topic started by: cpalx on October 09, 2022, 08:18:27 pm

Title: Lawm and AMD CPU
Post by: cpalx on October 09, 2022, 08:18:27 pm
Hello i have an AND Ryzen 7 CPU, and i cannot make load the android emulator (windows and Linux)

I installed by lawm manager

all in the bios is enabled about virutalization


Note: I Installed Android Studio and thh emulator works fine and fast (windows)
Title: Re: Lawm and AMD CPU
Post by: loaded on October 09, 2022, 08:32:12 pm
It's not a direct answer to your question, it can be used as a much faster solution on windows;
LAMW can use android studio's emulator. It is sufficient to run the emulator beforehand. Or you can run it directly yourself.
Title: Re: Lawm and AMD CPU
Post by: cpalx on October 09, 2022, 08:45:24 pm
but how?
Title: Re: Lawm and AMD CPU
Post by: loaded on October 10, 2022, 05:09:51 am
You should set the Jre and Emulator names according to your system.
Code: Pascal  [Select][+][-]
  1. procedure TForm1.Button1Click(Sender: TObject);
  2. var
  3.   jre_path:String='D:\Android Studio\jre\jre\bin';
  4.   emu_path:String='C:\Users\mali.aydin\AppData\Local\Android\Sdk\emulator\emulator.exe';
  5.   emu_name:String='Pixel_3a_API_29';
  6. begin
  7.   ShellExecute(Application.handle, 'open', 'cmd.exe',
  8.       PChar('/c "cd '+jre_path+' &&  '+emu_path+' -netdelay none -netspeed full -avd '+emu_name+'"  ' ), nil, SW_HIDE);
  9. end;
Title: Re: Lawm and AMD CPU
Post by: cpalx on October 10, 2022, 04:17:53 pm
i made as you told me, but i have the error

Panic: adb: failed to install C:\Users\chris\Dev\LAMWProjects\AppLAMWProject3\bin\AppLAMWProject3-debug.apk: Failure [INSTALL_FAILED_NO_MATCHING_ABIS: Failed to extract native libraries, res=-113]

Panic: Performing Streamed Install

Fatal: [Exception] Failed: Cannot install APK!
Title: Re: Lawm and AMD CPU
Post by: loaded on October 10, 2022, 06:07:32 pm
Congratulations, you are on the right track;
All you need is to choose the chipset according to the emulator.
Yours is probably x86_64
Title: Re: Lawm and AMD CPU
Post by: cpalx on October 10, 2022, 06:47:28 pm
thanks

I made it work creating an amulator with ARM v7a (slower, but it works)

i tried to change to x86_64 as you have, but lazarus tell me that it cannot support x86_64-android (any help please)
Title: Re: Lawm and AMD CPU
Post by: loaded on October 10, 2022, 07:27:37 pm
I guess it's a case of the version of FPC and its plugins. I had manually installed Lamw and its requirements myself. I don't update for a long time. There may be changes in your version. There is an installation video of the version I have. You can try it in your free time.
https://youtu.be/_EtHi1GHSLk (https://youtu.be/_EtHi1GHSLk)

Or you can try to install the necessary plugin for fpc here.
https://youtu.be/_EtHi1GHSLk?t=278 (https://youtu.be/_EtHi1GHSLk?t=278)
Title: Re: Lawm and AMD CPU
Post by: cpalx on October 10, 2022, 07:40:58 pm
Thanks, i have all to do it.

Now I will do it in Linux
Title: Re: Lawm and AMD CPU
Post by: cpalx on October 10, 2022, 11:20:10 pm
Works perfectly on Linux

Emulator in i386 ( so fast)

Thanks a lot.
TinyPortal © 2005-2018