Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2011-01

error compiling lazarus

12 messages · 4 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Benedikt Schindler

hello,

when i try to compile lazarus i get following error:

Free Pascal Compiler version 2.5.1 [2011/01/02] for x86_64 Copyright (c) 1993-2010 by Florian Klaempfl
Note: Switching assembler to default source writing assembler Target OS: Linux for x86-64
Compiling lazcontrols.pas
Compiling dividerbevel.pas
Assembling dividerbevel
Compiling extendednotebook.pas
Assembling extendednotebook
Assembling lazcontrols
688 lines compiled, 0.3 sec
4 hint(s) issued
1 note(s) issued
/bin/cp -fp Makefile.compiled lib/x86_64-linux/LazControls.compiled make[2]: Leaving directory `/opt/lazarus/components/lazcontrols' make[1]: Leaving directory `/opt/lazarus/components' make -C ide ide
make[1]: Entering directory `/opt/lazarus/ide'
../tools/svn2revisioninc .. revision.inc
An unhandled exception occurred at $00000000004935D1 : EAccessViolation : Access violation
$00000000004935D1 line 2087 of lclproc.pas
$00000000004A0189 line 4724 of lclproc.pas
$000000000043ADB6 line 794 of ../inc/system.inc

make[1]: *** [revisioninc] Error 217
make[1]: Leaving directory `/opt/lazarus/ide'
make: *** [ide] Error 2

i get the same error when i try to start the tool by hand.

linux-t613:/opt/lazarus/tools # ./svn2revisioninc
An unhandled exception occurred at $00000000004935D1 : EAccessViolation : Access violation
$00000000004935D1 line 2087 of lclproc.pas
$00000000004A0189 line 4724 of lclproc.pas
$000000000043ADB6 line 794 of ../inc/system.inc

has anyone an idea what this could be?

greatings
Benedikt

Reply by email

Paul Ishenin
to Benedikt Schindler
Benedikt Schindler wrote 6 lines
hello, when i try to compile lazarus i get following error: [compiler crash] has anyone an idea what this could be?

If the compiler version is from older than today please try to update and rebuild the compiler.

Best regards,
Paul Ishenin

Reply by email

Benedikt Schindler
to Paul Ishenin
Paul Ishenin wrote 13 lines
02.01.2011 22:57, Benedikt Schindler wrote: > hello, > > when i try to compile lazarus i get following error: > [compiler crash] > > has anyone an idea what this could be? If the compiler version is from older than today please try to update and rebuild the compiler. Best regards, Paul Ishenin

i compiled it with the svn version of fpc and of lazarus. still the same error.

best regards,
Benedikt

Reply by email

Mark Morgan Lloyd
to Benedikt Schindler
Benedikt Schindler wrote 17 lines
On 01/02/11 17:09, Paul Ishenin wrote: > 02.01.2011 22:57, Benedikt Schindler wrote: >> hello, >> >> when i try to compile lazarus i get following error: >> [compiler crash] >> >> has anyone an idea what this could be? > If the compiler version is from older than today please try to update > and rebuild the compiler. > > Best regards, > Paul Ishenin > i compiled it with the svn version of fpc and of lazarus. still the same error.

I've been having problems on one particular machine over the last few days which I suspect are down to inadequate RAM+swap- I think I've only got around 512Mb total.

Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues]

Reply by email

Mark Morgan Lloyd
to Mark Morgan Lloyd
Mark Morgan Lloyd wrote 6 lines
> i compiled it with the svn version of fpc and of lazarus. > still the same error. I've been having problems on one particular machine over the last few days which I suspect are down to inadequate RAM+swap- I think I've only got around 512Mb total.

This was on a SPARC/Linux system, it's not the same as the slow Solaris compilation I've been ranting about. A system with around 512Mb RAM+swap is having problems usually during linkage, while one with around 768Mb RAM+swap is OK.

Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues]

Reply by email

Benedikt Schindler
to Mark Morgan Lloyd
Mark Morgan Lloyd wrote 14 lines
Mark Morgan Lloyd wrote: >> i compiled it with the svn version of fpc and of lazarus. >> still the same error. > > I've been having problems on one particular machine over the last few > days which I suspect are down to inadequate RAM+swap- I think I've > only got around 512Mb total. This was on a SPARC/Linux system, it's not the same as the slow Solaris compilation I've been ranting about. A system with around 512Mb RAM+swap is having problems usually during linkage, while one with around 768Mb RAM+swap is OK.

I don't think i have a RAM problem.
I am running this on a

Intel(R) Core(TM)2 Duo CPU T9900 @ 3.06GHz
8GB RAM
ppcx64

i can reproduce the error with this little programm. The programm still prints the "test1" and "test2". And when he tryes to set the var Application it crashed in Line47.

<<<<<<<<<<< test svn2revisioninc.pas >>>>>>>>>>>>>>>

program Svn2RevisionInc;
{$mode objfpc}{$H+}
uses
  Classes, CustApp;
type
  { TSvn2RevisionApplication }
  TSvn2RevisionApplication = class(TCustomApplication)
  private
    test : string;
  public
    constructor Create(TheOwner: TComponent); override;
    destructor Destroy; override;
    procedure Run;
  end;
var
  Application: TSvn2RevisionApplication = nil;
constructor TSvn2RevisionApplication.Create(TheOwner: TComponent);
begin
  inherited Create(TheOwner);
  test := 'test1';
  writeln(test);
  test := 'test2';
  writeln(test);
end;
destructor TSvn2RevisionApplication.Destroy;
begin
  inherited Destroy;
end;
procedure TSvn2RevisionApplication.Run;
begin
  exit;
end;
begin
  Application := TSvn2RevisionApplication.Create(nil);
  Application.Run;
  Application.Free;
end.

Reply by email

Benedikt Schindler
to Benedikt Schindler
Benedikt Schindler wrote 30 lines
On 01/02/11 20:17, Mark Morgan Lloyd wrote: > Mark Morgan Lloyd wrote: > >>> i compiled it with the svn version of fpc and of lazarus. >>> still the same error. >> >> I've been having problems on one particular machine over the last few >> days which I suspect are down to inadequate RAM+swap- I think I've >> only got around 512Mb total. > > This was on a SPARC/Linux system, it's not the same as the slow Solaris > compilation I've been ranting about. A system with around 512Mb RAM+swap > is having problems usually during linkage, while one with around 768Mb > RAM+swap is OK. > I don't think i have a RAM problem. I am running this on a Intel(R) Core(TM)2 Duo CPU T9900 @ 3.06GHz 8GB RAM ppcx64 i can reproduce the error with this little programm. The programm still prints the "test1" and "test2". And when he tryes to set the var Application it crashed in Line47. [programm listing]

today i tested the 32bit version.
same error.

i am using:
OpenSuSe 11.3
latest online updates installed
i tried to compile with fpc-2.4.2-1 32Bit and 64Bit

so far it sounds like i am the only one who experienced this error. i will make some more tests to see if i could get more details on that error.

have a nice day
Benedikt

Reply by email

Benedikt Schindler
to Benedikt Schindler

I was wrong.
It is not the same error with 32Bit.
I didn't make sure that he recompiles the svn2revisioninc. In 32Bit i get a linking problem on crti.o.

But i have the package installed and the 32Bit crti.o is pressent in /usr/lib/.

linux-t613:/# ls /usr/lib/crt* /usr/lib/crt1.o /usr/lib/crti.o /usr/lib/crtn.o

Also the i386 section in "/etc/fpc.conf" is set correctly And "-Fl/usr/lib/" also shows up in the compiler line. But it still didn't get found.

Target OS: Linux for i386
Compiling svn2revisioninc.pas
Assembling svn2revisioninc
Linking ./svn2revisioninc
/usr/bin/ld: warning: ./link.res contains output sections; did you forget -T?
/usr/bin/ld: skipping incompatible /usr/lib64/crti.o when searching for /usr/lib64/crti.o
/usr/bin/ld: cannot find /usr/lib64/crti.o
Error: Error while linking
Fatal: There were 1 errors compiling module, stopping Fatal: Compilation aborted

has someone an idea what i could do to try if the 32bit version would work on my computer?

best regards
Benedikt

Benedikt Schindler wrote 51 lines
On 01/02/11 22:45, Benedikt Schindler wrote: > On 01/02/11 20:17, Mark Morgan Lloyd wrote: >> Mark Morgan Lloyd wrote: >> >>>> i compiled it with the svn version of fpc and of lazarus. >>>> still the same error. >>> >>> I've been having problems on one particular machine over the last few >>> days which I suspect are down to inadequate RAM+swap- I think I've >>> only got around 512Mb total. >> >> This was on a SPARC/Linux system, it's not the same as the slow Solaris >> compilation I've been ranting about. A system with around 512Mb RAM+swap >> is having problems usually during linkage, while one with around 768Mb >> RAM+swap is OK. >> > > > I don't think i have a RAM problem. > I am running this on a > > Intel(R) Core(TM)2 Duo CPU T9900 @ 3.06GHz > 8GB RAM > ppcx64 > > > i can reproduce the error with this little programm. > The programm still prints the "test1" and "test2". > And when he tryes to set the var Application it crashed in Line47. > > [programm listing] today i tested the 32bit version. same error. i am using: OpenSuSe 11.3 latest online updates installed i tried to compile with fpc-2.4.2-1 32Bit and 64Bit so far it sounds like i am the only one who experienced this error. i will make some more tests to see if i could get more details on that error. have a nice day Benedikt _______________________________________________ fpc-pascal maillist - http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply by email

Benedikt Schindler
to Benedikt Schindler

Hello,

here is a upate on my problems with the actual svn version of fpc and lazarus.

In 64Bit my fpc has still the problem to compile svn2revisioninc. It rais an exception on the following line:

Application := TSvn2RevisionApplication.Create(nil);

I think this is a problem with the 64Bit compiler. In 32Bit this problem doesn't exist.
But there is an other interesting behaviour.

If i compile a 32bit programm wih lclproc.pas in the uses class everything looks fine.
If i try to run the compiled programm then it sayed:

execvp: <programm name> : Permission denied.

if i compile the same programm without lclproc.pas in the uses class everthing works fine, and i could run the programm.

Does someone know, what bash command lclproc.pas tryes to use in the initialization ?

thanks & best regards
Benedikt

Reply by email

Jonas Maebe
to Benedikt Schindler
Benedikt Schindler wrote
I think this is a problem with the 64Bit compiler. In 32Bit this problem doesn't exist.

What did you do to fix the linking of 32 bit programs on your system? (since in the previous message you showed that this did not work)

Show quoted text 11 lines
If i compile a 32bit programm wih lclproc.pas in the uses class everything looks fine. If i try to run the compiled programm then it sayed: > execvp: <programm name> : Permission denied. if i compile the same programm without lclproc.pas in the uses class everthing works fine, and i could run the programm. Does someone know, what bash command lclproc.pas tryes to use in the initialization ?

That error message has nothing to do with bash commands. It usually means that an invalid dynamic linker is used. You can see the specified dynamic linker by looking for the entry containing "ld-linux.so" in the output of "ldd programname" (if you don't use any units, then the program won't be linked dynamically and hence you cannot have this problem).

Make sure the dynamic linker exists and is for the same architecture as the program itself. In case you solved the 32 bit compilation problem by changing some symlinks or copying some files, then that is probably the reason for this problem.

Jonas

Reply by email

Benedikt Schindler
to Jonas Maebe
Jonas Maebe wrote 7 lines
On 09 Jan 2011, at 00:32, Benedikt Schindler wrote: > I think this is a problem with the 64Bit compiler. > In 32Bit this problem doesn't exist. What did you do to fix the linking of 32 bit programs on your system? (since in the previous message you showed that this did not work)

sorry, here is what i have done to solve the linking problems:

i chnaged the positions in: /etc/ld.so.conf

so there is always the lib32 directory before the lib64 directory.

now it looks like this:

/lib
/lib64
/usr/lib
/usr/lib64
[...]

i thought this shouldn't make any differnce ... but it did.

After that i just created a few missing symlinks for gtk and gdk libs. For example: ln -s /usr/lib/libgtk-x11-2.0.so.0.2000.1 /usr/lib/libgtk-x11-2.0.so

or is that not allowed?

Show quoted text 17 lines
> If i compile a 32bit programm wih lclproc.pas in the > uses class everything looks fine. > If i try to run the compiled programm then it sayed: > >> execvp: <programm name> : Permission denied. > > if i compile the same programm without lclproc.pas in the uses class > everthing works fine, and i could run the programm. > > Does someone know, what bash command lclproc.pas tryes to use in the > initialization ? That error message has nothing to do with bash commands. It usually means that an invalid dynamic linker is used. You can see the specified dynamic linker by looking for the entry containing "ld-linux.so" in the output of "ldd programname" (if you don't use any units, then the program won't be linked dynamically and hence you cannot have this problem). Make sure the dynamic linker exists and is for the same architecture as the program itself. In case you solved the 32 bit compilation problem by changing some symlinks or copying some files, then that is probably the reason for this problem.

i have to look into that.
with "ldd ./lazarus" it also sayed Permission denied. i will look if i find something with a wrong dynamic linker.

thanks so far
Benedikt

Reply by email

Jonas Maebe
to Benedikt Schindler
Benedikt Schindler wrote 17 lines
> What did you do to fix the linking of 32 bit programs on your system? (since in the previous message you showed that this did not work) sorry, here is what i have done to solve the linking problems: i chnaged the positions in: /etc/ld.so.conf so there is always the lib32 directory before the lib64 directory. now it looks like this: /lib /lib64 /usr/lib /usr/lib64 [...] i thought this shouldn't make any differnce ... but it did.

It's a very bad idea to mess around with standard settings in that file unless you really know what you are doing (and for the record, I don't know the details about that either).

Show quoted text 5 lines
After that i just created a few missing symlinks for gtk and gdk libs. For example: ln -s /usr/lib/libgtk-x11-2.0.so.0.2000.1 /usr/lib/libgtk-x11-2.0.so or is that not allowed?

It is "allowed", but unless you know the low level details of how your distribution is designed you are very likely to mess things up. If you don't have those symlinks, it's much better to install the "development" variants of the relevant packages. Amongst other things, they will create those syminks.

Jona

Reply by email