Menu

#24 Compiling with XE4

1.0
open
nobody
None
2022-05-06
2022-04-26
Edwin Yip
No

@angusj,

I was using 3.2 which is compile-able with XE4. Today I wanted to upgrade to the latest release pulled from the repository.

The first compiler issue I encountered was [dcc32 Fatal Error] Img32.Clipper.pas(16): F2092 Program or unit 'Img32.Clipper' recursively uses itself, and I solved it by renaming Clipper.pas as Clipper.Main.pas.

The second issue is [dcc32 Fatal Error] Img32.Clipper.pas(16): F2092 Program or unit 'Img32.Clipper' recursively uses itself, which is related to the following line:
double((path[j].Y + path[i].Y)) * (path[j].X - path[i].X) (you can also check the attached screenshot of my Delphi). How to fix it? Thanks.

And I'm also worried what the next issue will be ;)

1 Attachments

Discussion

  • Angus Johnson

    Angus Johnson - 2022-05-04

    Hi Edwin.
    Yes, Clipper has recently undergone massive change and I'm now in the process of rechecking its integration into Img32.

     
  • Angus Johnson

    Angus Johnson - 2022-05-05

    I'm confident I've found and fixed the problem you were encountering.
    A couple of the Clipper library source files had acquired unicode byte marks which I've now removed. I've also rechecked pretty much everything including the samples and it compiles without issues for me in both Delphi 7 and Delphi 10.4

     
  • Edwin Yip

    Edwin Yip - 2022-05-05

    @angusj, thanks for the new version!
    My XE4 is still getting:
    [dcc32 Fatal Error] Img32.Clipper.pas(16): F2092 Program or unit 'Img32.Clipper' recursively uses itself

     
  • Angus Johnson

    Angus Johnson - 2022-05-05

    OK, I've once again amended Img32.Clipper.
    Hopefully it'll compile for you this time. 🤞

     
  • Edwin Yip

    Edwin Yip - 2022-05-06

    Hi Angus,

    Now I'm getting "[dcc32 Fatal Error] Img32.Clipper.pas(50): F2092 Program or unit 'Img32.Clipper' recursively uses itself", because in the implementation 'Clipper' is still in the use list.

    If I remove it, I'll be getting "[dcc32 Error] Img32.Clipper.pas(88): E2242 'InflatePaths' is not the name of a unit" error.

    I guess the solution might be what I suggested above - rename '\Clipper\Clipper.pas' as something like 'Clipper.Common.pas'?

     
  • Angus Johnson

    Angus Johnson - 2022-05-06

    Evidently XE4 mis-handles the file naming namespaces which is surprising as both older and newer compilersdon't have this problem. I'm not keen on renaming Clipper.pas so I'll probably rename Img32.Clipper.pas to Img32.Clipper2.pas.

     
    😄
    1