Menu

#13 Fail to build against fpc:3.2.0

0.4
closed
MBit
None
2020-09-01
2020-07-02
No

There're some errors when building agaist Free Pascal Compiler=3.2.0 (fpc:3.0.4 works fine)

Free Pascal Compiler version 3.2.0 [2020/06/22] for x86_64
Copyright (c) 1993-2020 by Florian Klaempfl and others
(1002) Target OS: Linux for x86-64
(3104) Compiling ddrescueview.lpr
(3104) Compiling Shared.pas
/build/ddrescueview/src/source/Shared.pas(326,18) Hint: (5091) Local variable "intsA" of a managed type does not seem to be initialized
/build/ddrescueview/src/source/Shared.pas(327,18) Hint: (5091) Local variable "intsB" of a managed type does not seem to be initialized
(3104) Compiling Parser.pas
/build/ddrescueview/src/source/Parser.pas(78,56) Error: (5098) Record or object type expected
/build/ddrescueview/src/source/Parser.pas(79,46) Error: (5098) Record or object type expected
/build/ddrescueview/src/source/Parser.pas(80,50) Error: (5098) Record or object type expected
/build/ddrescueview/src/source/Parser.pas(81,50) Error: (5098) Record or object type expected
/build/ddrescueview/src/source/Parser.pas(85,1) Fatal: (10026) There were 4 errors compiling module, stopping
Fatal: (1018) Compilation aborted
Error: /usr/bin/ppcx64 returned an error exitcode
Error: (lazarus) Compile Project, Mode: Common Debug (huge executable), Target: ddrescueview: stopped with exit code 1
Error: (lazbuild) failed compiling of project /build/ddrescueview/src/source/ddrescueview.lpi

Discussion

  • peter green

    peter green - 2020-08-11

    Googling the error message took me to https://wiki.freepascal.org/User_Changes_Trunk
    which has an entry "Property field access lists no longer allows classes" that
    seems to describe the problem. Poking around in svn it seems that this change
    was backported to 3.2 but they forgot to move the description of it from the
    "user changes trunk" to the "user changes 3.2" page.

    The solution is to use a getter rather than direct access for the
    property. I have attatched a patch that does that, I have tested that it builds
    (with fpc 3.2 in Debian sid) I have not tested it beyond that.

     
    • MBit

      MBit - 2020-08-21

      Good find. I'll use your patch in the next release if you don't mind.
      Greetings, MBit

       
  • MBit

    MBit - 2020-08-24
    • status: open --> accepted
    • assigned_to: MBit
     
  • Sebastian

    Sebastian - 2020-08-29

    The builds did fail also on openSUSE (Tumbleweed) and suceed again using this patch. Thank you for your work!

     
  • MBit

    MBit - 2020-09-01

    This issue has been fixed in v0.4 alpha 4, thanks to the patch supplied by Peter Green.
    Closed.

     
  • MBit

    MBit - 2020-09-01
    • status: accepted --> closed
     

Log in to post a comment.