Compiling x64 in 32-bit Lazarus 1.2.6

Instead of drudging through a million documents that cover every end-case under the sun, here’s a simplified, abridged set of instructions on how to compile x64 applications for windows using Lazarus 1.2.6.  It may also work with future, newer versions of Lazarus.

It is recommended to use the 32-bit IDE and cross compile x64 unless you really need some x64 components to run at design time.  Most components will be x86 compiled, so use the x86 IDE.

1) Install Lazarus 1.2.6 (or later)

2) Install the x64 cross compiler, which has traditionally been included in the folder/page along with the Lazarus IDE but as a separate download.  I’d link you, but I’m sure there will be a newer one by the time you read this.

3) In Project->Options->Config and Target Set

  • Target OS to Win64
  • Target CPU family x86_64
  • Target processor ATHLON64

4) Build and Run.  Debugging support should be available, but it is a tad bit flaky in my initial tests.  Have fun!

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.