Recent

Author Topic: Lazarus 64bit  (Read 8597 times)

Deepaak

  • Sr. Member
  • ****
  • Posts: 454
Lazarus 64bit
« on: November 20, 2014, 06:47:39 am »
how to configure lazarus for 64bit
Holiday season is online now. :-)

Leledumbo

  • Hero Member
  • *****
  • Posts: 8757
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: Lazarus 64bit
« Reply #1 on: November 20, 2014, 07:22:15 am »
Same as other bit...

Deepaak

  • Sr. Member
  • ****
  • Posts: 454
Re: Lazarus 64bit
« Reply #2 on: November 20, 2014, 08:14:46 am »
Same as other bit...

means, i want to configure lazarus for building 64bit executable for windows platform. I guess i need 64bit fpc.

I have fpc compiler source. How to build fpc compiler for x64
Holiday season is online now. :-)

Leledumbo

  • Hero Member
  • *****
  • Posts: 8757
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: Lazarus 64bit
« Reply #3 on: November 20, 2014, 11:28:54 am »
means, i want to configure lazarus for building 64bit executable for windows platform. I guess i need 64bit fpc.

I have fpc compiler source. How to build fpc compiler for x64
In general:
Code: [Select]
make all install CPU_TARGET=x86_64 OS_TARGET=win64 INSTALL_PREFIX=<your top fpc directory>should work. But it also depends on your fpc.cfg, you have to configure it to be multiple targets friendly.

Deepaak

  • Sr. Member
  • ****
  • Posts: 454
Re: Lazarus 64bit
« Reply #4 on: November 20, 2014, 12:18:31 pm »

In general:
Code: [Select]
make all install CPU_TARGET=x86_64 OS_TARGET=win64 INSTALL_PREFIX=<your top fpc directory>should work. But it also depends on your fpc.cfg, you have to configure it to be multiple targets friendly.

I got following errors

Quote
makefile:197: *** The Makefile doesn't support target x86_64-win64, please run fpcmake first.  Stop.
Holiday season is online now. :-)

snorkel

  • Hero Member
  • *****
  • Posts: 817
Re: Lazarus 64bit
« Reply #5 on: November 20, 2014, 10:40:46 pm »
means, i want to configure lazarus for building 64bit executable for windows platform. I guess i need 64bit fpc.

I have fpc compiler source. How to build fpc compiler for x64
In general:
Code: [Select]
make all install CPU_TARGET=x86_64 OS_TARGET=win64 INSTALL_PREFIX=<your top fpc directory>should work. But it also depends on your fpc.cfg, you have to configure it to be multiple targets friendly.

On windows you can just install the prebuilt cross compiler for 64bit and you don't have to do anything with fpc.cfg.
On linux I have had to mess with fpc.cfg.
***Snorkel***
If I forget, I always use the latest stable 32bit version of Lazarus and FPC. At the time of this signature that is Laz 3.0RC2 and FPC 3.2.2
OS: Windows 10 64 bit

Leledumbo

  • Hero Member
  • *****
  • Posts: 8757
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: Lazarus 64bit
« Reply #6 on: November 21, 2014, 03:13:29 am »
I got following errors

Quote
makefile:197: *** The Makefile doesn't support target x86_64-win64, please run fpcmake first.  Stop.
Do as it says. Run `fpcmake -Tall` in the top level directory

Deepaak

  • Sr. Member
  • ****
  • Posts: 454
Re: Lazarus 64bit
« Reply #7 on: November 21, 2014, 04:35:09 am »
Do as it says. Run `fpcmake -Tall` in the top level directory

Done, Now i have 64bit version of freepascal, I build lazarus64 with it. Every thing gone fairly smooth, but when ever i try to debug after click play button, nothing happens although title bar of lazarus shows debugging. 64bit executable is built, but cannot debug in the ide.  What i am missing i don't know.  :(


Holiday season is online now. :-)

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 9857
  • Debugger - SynEdit - and more
    • wiki
Re: Lazarus 64bit
« Reply #8 on: November 21, 2014, 04:47:21 am »
Do you have a 64 bit version of gdb?

Deepaak

  • Sr. Member
  • ****
  • Posts: 454
Re: Lazarus 64bit
« Reply #9 on: November 21, 2014, 05:06:51 am »
Do you have a 64 bit version of gdb?

No, I replaced 32bit gdb with mingw 64bit gdb. Then also not working, is there any 64bit version of GDB for freepascal
Holiday season is online now. :-)

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 9857
  • Debugger - SynEdit - and more
    • wiki
Re: Lazarus 64bit
« Reply #10 on: November 21, 2014, 05:38:42 am »
the mingw should work.

Try changing debug info: stabs vs dwarf (Though if your app does not load in the debugger, then that is not the likely cause)

What is in view > debug > debug output?

Maybe a logfile: http://wiki.lazarus.freepascal.org/GDB_Debugger_Tips#Log_info_for_debug_session

Deepaak

  • Sr. Member
  • ****
  • Posts: 454
Re: Lazarus 64bit
« Reply #11 on: November 21, 2014, 06:09:23 am »
the mingw should work.

Try changing debug info: stabs vs dwarf (Though if your app does not load in the debugger, then that is not the likely cause)

What is in view > debug > debug output?

Maybe a logfile: http://wiki.lazarus.freepascal.org/GDB_Debugger_Tips#Log_info_for_debug_session

Thank you, In my case stabs worked. Is this ok for debugging, any difference among all this stabs,dwarfs etc stuff.

gdb is 7.1 from mingwx64 edition.

But when tried with gdb 7.6 none of the option worked, messagebox with message ''Oops we are pulling the plug'' came.

Is new version of gdb is not compatable with freepascal.

Is there any other debugger available other than gdb.
Holiday season is online now. :-)

Leledumbo

  • Hero Member
  • *****
  • Posts: 8757
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: Lazarus 64bit
« Reply #12 on: November 22, 2014, 02:50:44 pm »
Is this ok for debugging, any difference among all this stabs,dwarfs etc stuff.
gdb is 7.1 from mingwx64 edition.

But when tried with gdb 7.6 none of the option worked, messagebox with message ''Oops we are pulling the plug'' came.

Is new version of gdb is not compatable with freepascal.
http://wiki.freepascal.org/Debugger_Setup#GDB_Version
Is there any other debugger available other than gdb.
http://lazarus-dev.blogspot.co.uk/2014/05/de-bug-wars-new-hope.html

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 9857
  • Debugger - SynEdit - and more
    • wiki
Re: Lazarus 64bit
« Reply #13 on: November 22, 2014, 03:53:02 pm »
But when tried with gdb 7.6 none of the option worked, messagebox with message ''Oops we are pulling the plug'' came.

GDB 7.5.9 and up are very sensitive, and  easy to crash (internal assert in gdb). Lots of it  (but not all) comes down to:
- smartlinking,
- any optimization -O[123]
- mixing stabs and dwarf

Check all packages, for their debug settings, newer gdb should prefer dwarf, and dwarf ( -gw2 / dwarf 2) is the better format. But one single package left with stabs.... boom.

Having said that, none of it guarantees that gdb will work.

Code: [Select]
type
  TFOo = array[0..maxint] of byte;
  PFoo = ^TFoo;
The above kills any gdb that I know off.

Deepaak

  • Sr. Member
  • ****
  • Posts: 454
Re: Lazarus 64bit
« Reply #14 on: November 23, 2014, 05:07:53 am »
Having said that, none of it guarantees that gdb will work.

Hmm, so is there any other alternative to gdb. Which works out-of-box and is less vulnerable than gdb.
Holiday season is online now. :-)

 

TinyPortal © 2005-2018