Sign in Join

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

Mailing lists / fpc-devel / 2024-03

Failing Lazarus Codetools Pas2JS-related tests - again

10 messages · 4 people · –

Reply by email Subscribe to this list Your subscription

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

Maxim Ganetsky

Hello.

After recent update of FPC 3.3.1 (and Pas2JS) in Lazarus CI several Codetools tests related to Pas2JS started failing again:

TTestPas2js.TestPas2js_ReadSettings: pas2js system unit not found TTestPas2js.TestPas2js_FindDeclaration: pas2js system unit not found TTestPas2js.TestPas2js_FindDeclaration_AWait: pas2js system unit not found

They worked fine with FPC 3.3.1 from the end of December.

Contents of Pas2JS configuration files follow:

#7 1429.0 Contents of /usr/local/bin/pas2js.cfg:
|
#7 1429.0 #
||
#7 1429.0 # Minimal config file for pas2js compiler ||
#7 1429.0 #
||
#7 1429.0 # -d is the same as #DEFINE
||
#7 1429.0 # -u is the same as #UNDEF
||
#7 1429.0 #
||
#7 1429.0 # Write always a nice logo ;)
||
#7 1429.0 -l
||
#7 1429.0
||
#7 1429.0 # Display Warnings, Notes and Hints
||
#7 1429.0 -vwnh
||
#7 1429.0 # If you don't want so much verbosity use ||
#7 1429.0 #-vw
||
#7 1429.0
||
#7 1429.0 # Allow C-operators
||
#7 1429.0 -Sc
||
#7 1429.0
||
#7 1429.0 #IFDEF FPC_SUBTARGET_NAMESPACED
||
#7 1429.0 -Fu$CfgDir/../lib/fpc/3.3.1/pas2js/*/*/namespaced ||
#7 1429.0 -Fi$CfgDir/../lib/fpc/3.3.1/pas2js/*/*/src ||
#7 1429.0 #else
||
#7 1429.0 -Fu$CfgDir/../lib/fpc/3.3.1/pas2js/*/*/src ||
#7 1429.0 #endif
||
#7 1429.0
||
#7 1429.0 #IFDEF nodejs
||
#7 1429.0 -Jirtl.js
||
#7 1429.0 #ENDIF
||
#7 1429.0
||
#7 1429.0 # Put all generated JavaScript into one file ||
#7 1429.0 -Jc
||
#7 1429.0
||
#7 1429.0 # end.
||
#7 1429.0 Contents of /usr/local/bin/pas2js-namespaced.cfg: ||#7 1429.0 -dUNICODERTL|

Best regards, Maxim

Reply by email

Mattias Gaertner
to Maxim Ganetsky
Maxim Ganetsky wrote 16 lines
[...] After recent update of FPC 3.3.1 (and Pas2JS) in Lazarus CI several Codetools tests related to Pas2JS started failing again: TTestPas2js.TestPas2js_ReadSettings: pas2js system unit not found TTestPas2js.TestPas2js_FindDeclaration: pas2js system unit not found TTestPas2js.TestPas2js_FindDeclaration_AWait: pas2js system unit not found They worked fine with FPC 3.3.1 from the end of December. Contents of Pas2JS configuration files follow: [...] #7 1429.0 #else || #7 1429.0 -Fu$CfgDir/../lib/fpc/3.3.1/pas2js/*/*/src

This should be enough
-Fu$CfgDir/../lib/fpc/3.3.1/pas2js/packages/*/src

[...]

Can you compile a simple Helloworld?

begin
   writeln('Hi');
end.

?

If this works, you might try removing the
components/codetools/tests/codetools.config, so codetools rebuild the cache.

Mattias

Reply by email

Michael Van Canneyt
to Maxim Ganetsky: Hello. After recent update of FPC 3.3.1 (and Pas2JS) in Lazarus CI several Codetools…
Maxim Ganetsky wrote 55 lines
Hello. After recent update of FPC 3.3.1 (and Pas2JS) in Lazarus CI several Codetools tests related to Pas2JS started failing again: TTestPas2js.TestPas2js_ReadSettings: pas2js system unit not found TTestPas2js.TestPas2js_FindDeclaration: pas2js system unit not found TTestPas2js.TestPas2js_FindDeclaration_AWait: pas2js system unit not found They worked fine with FPC 3.3.1 from the end of December. Contents of Pas2JS configuration files follow: #7 1429.0 Contents of /usr/local/bin/pas2js.cfg: | #7 1429.0 # || #7 1429.0 # Minimal config file for pas2js compiler || #7 1429.0 # || #7 1429.0 # -d is the same as #DEFINE || #7 1429.0 # -u is the same as #UNDEF || #7 1429.0 # || #7 1429.0 # Write always a nice logo ;) || #7 1429.0 -l || #7 1429.0 || #7 1429.0 # Display Warnings, Notes and Hints || #7 1429.0 -vwnh || #7 1429.0 # If you don't want so much verbosity use || #7 1429.0 #-vw || #7 1429.0 || #7 1429.0 # Allow C-operators || #7 1429.0 -Sc || #7 1429.0 || #7 1429.0 #IFDEF FPC_SUBTARGET_NAMESPACED || #7 1429.0 -Fu$CfgDir/../lib/fpc/3.3.1/pas2js/*/*/namespaced || #7 1429.0 -Fi$CfgDir/../lib/fpc/3.3.1/pas2js/*/*/src

This seems wrong to me, but Mattias will need to .

Reply by email

Maxim Ganetsky
to Mattias Gaertner: This should be enough -Fu$CfgDir/../lib/fpc/3.3.1/pas2js/packages/*/src Can you compile a…

18.03.2024 22:15, Mattias Gaertner via fpc-devel пишет:

Show quoted text 30 lines
On 18.03.24 18:43, Maxim Ganetsky via fpc-devel wrote: > [...] > After recent update of FPC 3.3.1 (and Pas2JS) in Lazarus CI several > Codetools tests related to Pas2JS started failing again: > > TTestPas2js.TestPas2js_ReadSettings: pas2js system unit not found > TTestPas2js.TestPas2js_FindDeclaration: pas2js system unit not found > TTestPas2js.TestPas2js_FindDeclaration_AWait: pas2js system unit not > found > > They worked fine with FPC 3.3.1 from the end of December. > > Contents of Pas2JS configuration files follow: > > [...] > #7 1429.0 #else > || > #7 1429.0 -Fu$CfgDir/../lib/fpc/3.3.1/pas2js/*/*/src This should be enough -Fu$CfgDir/../lib/fpc/3.3.1/pas2js/packages/*/src > [...] Can you compile a simple Helloworld? begin   writeln('Hi'); end.

Note that these failures are encountered in our CI system. I didn't test, but guess that compiling Helloworld will fail (because system unit cannot be found).

Show quoted text 5 lines
? If this works, you might try removing the components/codetools/tests/codetools.config, so codetools rebuild the cache.

These failures happen inside CI, so there is always a clean checkout without this file.

Best regards, Maxim Ganetsky

Reply by email

Maxim Ganetsky
to Mattias Gaertner

19.03.2024 12:56, Mattias Gaertner via fpc-devel пишет:

Show quoted text 11 lines
On 18.03.24 20:29, Michael Van Canneyt via fpc-devel wrote: > [...] >> #7 1429.0 -Fu$CfgDir/../lib/fpc/3.3.1/pas2js/*/*/namespaced >> || >> #7 1429.0 -Fi$CfgDir/../lib/fpc/3.3.1/pas2js/*/*/src > > This seems wrong to me, but Mattias will need to look at this. I changed the fpmake.pp. Please test.

Pas2Js cannot be built now:

#7 941.6 Cloning into 'pas2js'...
|
#7 944.6 /usr/lib/fpc/3.3.1/ppcx64 fpmake.pp
||
#7 944.6 Free Pascal Compiler version 3.3.1 [2024/03/19] for x86_64 ||
#7 944.6 Copyright (c) 1993-2024 by Florian Klaempfl and others ||
#7 944.6 Target OS: Linux for x86-64
||
#7 944.6 Compiling fpmake.pp
||
#7 944.7 fpmake.pp(228,5) Error: Identifier not found "T" ||
#7 944.7 fpmake.pp(230,7) Error: Identifier not found "T" ||
#7 944.7 fpmake.pp(363) Fatal: There were 2 errors compiling module, stopping
||
#7 944.7 Fatal: Compilation aborted
||#7 944.7 make: *** [Makefile:1550: fpmake] Error 1|

Best regards, Maxim

Reply by email

Mattias Gaertner
to Maxim Ganetsky
Maxim Ganetsky wrote
[...] #7 944.7 fpmake.pp(228,5) Error: Identifier not found "T"

Ah, you are using fpc 3.3.1 to compile it.

Fixed.

But I get strange linker errors compiling webidl2pas:

(9015) Linking bin/x86_64-linux/webidl2pas
/usr/bin/ld.bfd:
/path/compiler/utils/pas2js/units/x86_64-linux/webidl2pas.o:(.fpc.n_links+0x50): undefined reference to `DEBUGSTART_$CUSTAPP'
/usr/bin/ld.bfd:
/path/compiler/utils/pas2js/units/x86_64-linux/webidl2pas.o:(.fpc.n_links+0x58): undefined reference to `DEBUGEND_$CUSTAPP'

It compiles with the ppu files of fpc 3.3.1 and 3.2.2 tough, but not with the sources ...

Mattias

Reply by email

Martin Frb
to Mattias Gaertner
Mattias Gaertner wrote 22 lines
On 19.03.24 14:58, Maxim Ganetsky via fpc-devel wrote: > [...] > #7 944.7 fpmake.pp(228,5) Error: Identifier not found "T" Ah, you are using fpc 3.3.1 to compile it. Fixed. But I get strange linker errors compiling webidl2pas: (9015) Linking bin/x86_64-linux/webidl2pas /usr/bin/ld.bfd: /path/compiler/utils/pas2js/units/x86_64-linux/webidl2pas.o:(.fpc.n_links+0x50): undefined reference to `DEBUGSTART_$CUSTAPP' /usr/bin/ld.bfd: /path/compiler/utils/pas2js/units/x86_64-linux/webidl2pas.o:(.fpc.n_links+0x58): undefined reference to `DEBUGEND_$CUSTAPP' It compiles with the ppu files of fpc 3.3.1 and 3.2.2 tough, but not with the sources ...

I don't know if it applies.

But I have in some cases seen similar linking issues, if parts of the code were compiled with DWARF-2 and other parts with DWARF-3

Reply by email

Maxim Ganetsky
to Mattias Gaertner: Ah, you are using fpc 3.3.1 to compile it. Fixed. But I get strange linker errors…

19.03.2024 17:41, Mattias Gaertner via fpc-devel пишет:

Show quoted text 22 lines
On 19.03.24 14:58, Maxim Ganetsky via fpc-devel wrote: > [...] > #7 944.7 fpmake.pp(228,5) Error: Identifier not found "T" Ah, you are using fpc 3.3.1 to compile it. Fixed. But I get strange linker errors compiling webidl2pas: (9015) Linking bin/x86_64-linux/webidl2pas /usr/bin/ld.bfd: /path/compiler/utils/pas2js/units/x86_64-linux/webidl2pas.o:(.fpc.n_links+0x50): undefined reference to `DEBUGSTART_$CUSTAPP' /usr/bin/ld.bfd: /path/compiler/utils/pas2js/units/x86_64-linux/webidl2pas.o:(.fpc.n_links+0x58): undefined reference to `DEBUGEND_$CUSTAPP' It compiles with the ppu files of fpc 3.3.1 and 3.2.2 tough, but not with the sources ...

I use binary FPC installers, so don't get these errors, everything is fine in this regard.

Build image is successfully updated and tests work OK now, thanks.

Best regards, Maxim Ganetsky

Reply by email

Michael Van Canneyt
to Martin Frb: I don't know if it applies. But I have in some cases seen similar linking issues, if…
Martin Frb wrote 28 lines
On 19/03/2024 15:41, Mattias Gaertner via fpc-devel wrote: > > > On 19.03.24 14:58, Maxim Ganetsky via fpc-devel wrote: >> [...] >> #7 944.7 fpmake.pp(228,5) Error: Identifier not found "T" > > Ah, you are using fpc 3.3.1 to compile it. > > Fixed. > > But I get strange linker errors compiling webidl2pas: > > (9015) Linking bin/x86_64-linux/webidl2pas > /usr/bin/ld.bfd: > /path/compiler/utils/pas2js/units/x86_64-linux/webidl2pas.o:(.fpc.n_links+0x50): > undefined reference to `DEBUGSTART_$CUSTAPP' > /usr/bin/ld.bfd: > /path/compiler/utils/pas2js/units/x86_64-linux/webidl2pas.o:(.fpc.n_links+0x58): > undefined reference to `DEBUGEND_$CUSTAPP' > > It compiles with the ppu files of fpc 3.3.1 and 3.2.2 tough, but not with > the sources ... I don't know if it applies. But I have in some cases seen similar linking issues, if parts of the code were compiled with DWARF-2 and other parts with DWARF-3

This happens regularly to me since years, usually indeed different debug formats (or sometimes no debug info at all).
Recompiling everything fixes the issue.

Michael.

Reply by email