Author Topic: Lazarus for Windows on aarch64 (ARM64) - Native Compiler  (Read 62331 times)

ydd

  • Jr. Member
  • **
  • Posts: 85
Re: Lazarus for Windows on aarch64 (ARM64) - Native Compiler
« Reply #240 on: August 05, 2026, 08:57:20 pm »
You need FPC and Lazarus trunk/main.

now I'm getting such error:

ydd

  • Jr. Member
  • **
  • Posts: 85
Re: Lazarus for Windows on aarch64 (ARM64) - Native Compiler
« Reply #241 on: August 06, 2026, 06:54:30 pm »
I've tried to install Unleashed version, but got such error:


Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 12721
  • Debugger - SynEdit - and more
    • wiki
Re: Lazarus for Windows on aarch64 (ARM64) - Native Compiler
« Reply #242 on: August 07, 2026, 12:39:14 pm »
A test branch for FpDebug. (Hope it survived the rebase). Please test.

https://gitlab.com/martin_frb/lazarus/-/compare/main...dbg%2Fwin-aarch64-fpdebug?from_project_id=28419588

- Should work: Breakpoints, stepping, watches, locals, basic stack (probably threads)
- not stepping into finally blocks (not even without exception / well, might work with F7, since they are a subroutine)
- Notify on raise exception / BUT NOT, stepping to except/finally
- NO assembler
- NO watchpoints
- NO modify variables

Given the speed of my QEMU setup, I have done almost no testing.

----

Aarch64 should not increase the PC when hitting a breakpoint (or so says any research I did).
=> But on my setup, Windows reports an increased PC.

If breakpoints don't work for you (and possible even the target reports errors after silently passing one), then try the branch without the last commit "FpDebug: (Aarch64/Win) Adjust PC"

DonAlfredo

  • Hero Member
  • *****
  • Posts: 1903
Re: Lazarus for Windows on aarch64 (ARM64) - Native Compiler
« Reply #243 on: August 07, 2026, 02:11:22 pm »
Wow. I can debug !! Thanks very much. Quick work also.
I did not do an extensive test, but the basics are working (like breakpoints and inspect).
Very very good work !

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 12721
  • Debugger - SynEdit - and more
    • wiki
Re: Lazarus for Windows on aarch64 (ARM64) - Native Compiler
« Reply #244 on: August 07, 2026, 02:13:35 pm »
Wow. I can debug !! Thanks very much. Quick work also.
I did not do an extensive test, but the basics are working (like breakpoints and inspect).
Very very good work !

That is with the "adjust pc" commit?

DonAlfredo

  • Hero Member
  • *****
  • Posts: 1903
Re: Lazarus for Windows on aarch64 (ARM64) - Native Compiler
« Reply #245 on: August 07, 2026, 05:59:59 pm »
Yes, I tested the latest sources !

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 12721
  • Debugger - SynEdit - and more
    • wiki
Re: Lazarus for Windows on aarch64 (ARM64) - Native Compiler
« Reply #246 on: August 07, 2026, 06:24:02 pm »
Added to main.

Btw, the GDB that is in the fpc/bin/aarch64-win64 dir after installing with FpcUpDeluxe => that doesn't like the fileformat. Seems to be a gdb for x86? However that ended up there.

DonAlfredo

  • Hero Member
  • *****
  • Posts: 1903
Re: Lazarus for Windows on aarch64 (ARM64) - Native Compiler
« Reply #247 on: August 07, 2026, 06:37:44 pm »
Will solve. Thanks again for your work.

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 12721
  • Debugger - SynEdit - and more
    • wiki
Re: Lazarus for Windows on aarch64 (ARM64) - Native Compiler
« Reply #248 on: August 07, 2026, 07:41:36 pm »
Will solve. Thanks again for your work.

Well thanks for yours too. Without FpcUpDeluxe, I might never have gotten to it.  But thanks to your updates, it was one click to get all the infrastructure, all the dependencies, everything.

And, it left me with a git based install, I could just add my local remote, pull in the changes I had on my main PC, and start testing.

msintle

  • Sr. Member
  • ****
  • Posts: 389
Re: Lazarus for Windows on aarch64 (ARM64) - Native Compiler
« Reply #249 on: August 20, 2026, 04:33:31 pm »
We've updated our installer:

https://www.installaware.com/lazarus-arm64.msi

And our blog:

https://www.installaware.com/blog/?p=986

With the latest native ARM64 Lazarus IDE (and debugger).

The installer will now install the 32-bit IDE if you're running on AMD or Intel, with the cross-compilation option as before.

It'll install the native ARM64 IDE if you're running on an ARM64 device, with the awesome new native debugging that wasn't available before.

This makes a convenient one-click option to get going for anyone who needs true ARM64 support.

Delphi STILL can't get the job done :o

A big thank you to everyone on the Lazarus team :)
« Last Edit: August 20, 2026, 04:41:44 pm by msintle »

Igor

  • Sr. Member
  • ****
  • Posts: 387
Re: Lazarus for Windows on aarch64 (ARM64) - Native Compiler
« Reply #250 on: August 26, 2026, 07:11:15 pm »
Thank you very much! Sounds very exciting. I felt the same in 2020 when I compiled for the first time for ARM64 target on Mac Developer Kit.
I plan to try Lazarus and FPC on ARM laptop in the near future.

Thaddy

  • Hero Member
  • *****
  • Posts: 19805
  • Glad to be alive.
Re: Lazarus for Windows on aarch64 (ARM64) - Native Compiler
« Reply #251 on: August 27, 2026, 08:37:34 am »
@msintle
I enjoyed reading your blog on this subject. Haven't got the MS/AARCH64 hardware, though.
Have been using InstallAware in the past (company/bank) so I trust the quality is excellent.
You explained very well that Delphi's  ARM64EC is actually a surrogate option.
The Freepascal community has been profiting from a native AARCH64 compiler for a couple of years now and indeed, that is a great achievement. Thanks for your efforts.
Any "programmer" that knows only one programming language is not a programmer

msintle

  • Sr. Member
  • ****
  • Posts: 389
Re: Lazarus for Windows on aarch64 (ARM64) - Native Compiler
« Reply #252 on: August 27, 2026, 07:16:44 pm »
@msintle
I enjoyed reading your blog on this subject. Haven't got the MS/AARCH64 hardware, though.
Have been using InstallAware in the past (company/bank) so I trust the quality is excellent.
You explained very well that Delphi's  ARM64EC is actually a surrogate option.
The Freepascal community has been profiting from a native AARCH64 compiler for a couple of years now and indeed, that is a great achievement. Thanks for your efforts.

Many thanks, but all the credit is due to the excellent Lazarus team and FPCUPDELUXE!

It was thanks to the encouragement and motivation of don Alfredo of FPCUPDELUXE that we even undertook this initiative at InstallAware.

After a few false starts, the Lazarus community at large delivered!

All we've done is repackage Lazarus - as installed by FPCUPDELUXE - in a single-click install experience, with combined bitness support.

Once again, a massive shout out to the entire Lazarus community and don Alfredo!

And we thank you also for your support of our blog post.

There's a few gotcha's coming from Delphi indeed - which I hope our post helps alleviate :)
« Last Edit: August 27, 2026, 07:19:28 pm by msintle »

 

TinyPortal © 2005-2018