[fpc-devel] Failing Lazarus Codetools Pas2JS-related tests

Maxim Ganetsky ganmax at narod.ru
Mon Dec 25 15:04:09 CET 2023


25.12.2023 16:51, Maxim Ganetsky via fpc-devel пишет:
> 25.12.2023 13:01, Michael Van Canneyt via fpc-devel пишет:
>>
>>
>> On Sun, 24 Dec 2023, Maxim Ganetsky via fpc-devel wrote:
>>
>>>>>> As far as I know, Mattias is busy with it and has at least fixed 
>>>>>> the tests ?
>>>>>
>>>>> I see the commit by Mattias now, but it does not affect config 
>>>>> file created by `make install`, because the following duplicated 
>>>>> code is used for creating config files when running `make install`:
>>>>>
>>>>>
>>> https://gitlab.com/freepascal.org/fpc/pas2js/-/blob/main/fpmake.pp?ref_type=heads#L20 
>>>
>>>>
>>>> I updated the config file writing. 2 files are written now. My 
>>>> local tests are all OK.
>>>
>>> Please elaborate. I just updated FPC and Pas2Js, nothing changed in 
>>> behavior. Where is the commit?
>>
>> Sorry, forgot to push. fpmake.pp in pas2js repo. 
>
> OK, now config contents have changed, but Codetools tests still fail 
> with the same error (pas2js system unit not found). Config contents:
>
> Contents of /usr/local/bin/pas2js.cfg:
> |
> #
> ||
> # Minimal config file for pas2js compiler
> ||
> #
> ||
> # -d is the same as #DEFINE
> ||
> # -u is the same as #UNDEF
> ||
> #
> ||
> # Write always a nice logo ;)
> ||
> -l
> ||
>
> ||
> # Display Warnings, Notes and Hints
> ||
> -vwnh
> ||
> # If you don't want so much verbosity use
> ||
> #-vw
> ||||
> #IFDEF FPC_SUBTARGET_NAMESPACED
> ||||
> -Fu$CfgDir../lib/fpc/3.3.1/pas2js/*/namespaced
> ||
> -Fi$CfgDir../lib/fpc/3.3.1/pas2js/*/src
> ||
> -Fu$CfgDir../lib/fpc/3.3.1/pas2js/rtl/src
> |

I see that there are missing directory separators after $CfgDir, maybe 
this is the reason?

Also probably it would be worth to consider removing code duplication 
between createconfig.pp and fpmake.pp in regards of config file generation.

> |||
> #else
> ||
> -Fu$CfgDir../lib/fpc/3.3.1/pas2js/*/src
> ||
> #endif
> ||
>
> ||
> #IFDEF nodejs
> ||
> -Jirtl.js
> ||
> #ENDIF
> ||
>
> ||
> # Put all generated JavaScript into one file
> ||
> -Jc
> ||
>
> ||
> # end.
>
> ||
> Contents of /usr/local/bin/pas2js-namespaced.cfg:
> ||-dUNICODERTL|
-- 

Best regards,
  Maxim Ganetskymailto:ganmax at narod.ru
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-devel/attachments/20231225/1db17634/attachment.htm>


More information about the fpc-devel mailing list