On Tue, 3 Jan 2012 15:55:58 +0100 David Unric <dunric...@gmail.com> wrote:
> Thx Vincent, > > by supplying -P switch to fpc, I can finally produce x86_64 executables. > I'm surprised this switch is not mentioned in interactive help (fpc -? or > -h). Indeed. Please create a bug report. > Why compiler fails when supplied with documented -T<target os> option ? > >fpc -Twin64 consoleapp.dpr > Error: Illegal parameter: -Twin64 > Error: c:\Lazarus\fpc\2.7.1\bin\i386-win32\ppc386.exe returned an error > exitcode > (normal if you did not specify a source file to be compiled) ppc386.exe does not know about the target 'win64'. > Lazarus 0.9.31 seems to do not use -P option as it still produces i386 code > even if target CPU family is set to x86_64 in Project options and exe is > rebuilt from scratch (console app). It does use the -P and -T switch. But it passes them only if they differ from the default. > I'd like to ask somebody to shed some light on this subjects: > 1) why supplying target OS option (-T) fails ? If I'd like to build win64 > exe on win32 system have I pass CPU Target and fpc "automagically" selects > appropriate OS Target ? > 2) How to tweak Lazarus so I can simply switch between win32/win64 targets ? 1. Fix your installation, so that setting "Target OS" and "Target CPU" in the IDE compiler options works. 2. Add another build mode. http://wiki.lazarus.freepascal.org/IDE_Window:_Compiler_Options#Build_modes Mattias -- _______________________________________________ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus