Recent

Author Topic: IBX 2.5.0: can't install to trunk  (Read 610 times)

zoltanleo

  • Sr. Member
  • ****
  • Posts: 486
IBX 2.5.0: can't install to trunk
« on: December 06, 2022, 02:09:27 pm »
Hi tonyw

I tried to install the latest version of iBX on fpc/lazarus trunk but couldn't do it due to installation errors:

1.
Code: Pascal  [Select][+][-]
  1. IBCustomDataSet.pas(1046,5) Error: Expected another 1 array elements

this is fixed quite easily, just add one element like this
Code: Pascal  [Select][+][-]
  1. ...
  2.     nil                 {ftExtended}
  3. {$IFEND}
  4.     , nil //<-- added one more parameter
  5.     );
  6. (*var
  7.   CreateProviderProc: function(DataSet: TIBCustomDataSet): IProvider = nil;*)
  8. ...

2.
another error that needs fixing the code
Code: Pascal  [Select][+][-]
  1. IBDynamicGrid.pas(199,15) Error: Function header doesn''t match the previous declaration "DrawCellText(LongInt;LongInt;TRect;TGridDrawState;AnsiString);"
  2. grids.pas(4740,23) Error: Found declaration: DrawCellText(LongInt;LongInt;TRect;TGridDrawState;const AnsiString);

Please make the correct changes to the code
Win10 LTSC x64/Deb 11 amd64(gtk2/qt5)/Darwin Cocoa (Monterey):
Lazarus x32/x64 2.3(trunk); FPC 3.3.1 (trunk), FireBird 3.0.10; IBX by TonyW

Sorry for my bad English, I'm using translator ;)

tonyw

  • Sr. Member
  • ****
  • Posts: 319
    • MWA Software
Re: IBX 2.5.0: can't install to trunk
« Reply #1 on: December 06, 2022, 11:50:06 pm »
Thanks for pointing these out:

1. This is like playing wack-a-mole. The type keeps changing. I am going to have to move away from an array of TFieldType in order to avoid this problem again.

2. Why did someone think it worth changing a string to a const string?

tonyw

  • Sr. Member
  • ****
  • Posts: 319
    • MWA Software
Re: IBX 2.5.0: can't install to trunk
« Reply #2 on: December 07, 2022, 12:32:08 am »
I have posted an update to https://svn.mwasoftware.co.uk/ibx/trunk. Please check it out.

zoltanleo

  • Sr. Member
  • ****
  • Posts: 486
Re: IBX 2.5.0: can't install to trunk
« Reply #3 on: December 07, 2022, 01:10:06 pm »
I have posted an update to https://svn.mwasoftware.co.uk/ibx/trunk. Please check it out.


Hi tonyw. Thank you for your reply and for your selfless care and support!

There are two errors:
1. (see attach)
Code: Pascal  [Select][+][-]
  1. IBDynamicGrid.pas(463,119) Error: Procedure directive "OVERRIDE" not allowed in implementation section

If you comment out the override, the following error appears

2.
Code: Pascal  [Select][+][-]
  1. IBArrayGrid.pas(152,15) Error: Function header doesn''t match the previous declaration "DrawCellText(LongInt;LongInt;TRect;TGridDrawState;AnsiString);"
  2. grids.pas(4740,23) Error: Found declaration: DrawCellText(LongInt;LongInt;TRect;TGridDrawState;const AnsiString);

If you fix the parameter type to a constant, then the packages are compiled successfully.

==============

I also have a big wish that Lazarus does not check for the presence of a Firebird server with such a warning at startup:
Quote
IBX is unable to locate or otherwise load the Firebird Library - have you remembered to install it? - Object reference is Nil or VMT is damaged

Firstly, this may not be true, because a user can have several servers running at the same time (this is the case for Windows).

Secondly, this control can be easily bypassed if you put fbclient.dll/.so/.dblib of the same bitness next to the Lazarus executable file.

This check has remained since the time of IB, when the server could only be started in a single instance. And this test is an atavism for today.
Win10 LTSC x64/Deb 11 amd64(gtk2/qt5)/Darwin Cocoa (Monterey):
Lazarus x32/x64 2.3(trunk); FPC 3.3.1 (trunk), FireBird 3.0.10; IBX by TonyW

Sorry for my bad English, I'm using translator ;)

 

TinyPortal © 2005-2018