Chaosforge Forum

  • November 04, 2024, 06:41
  • Welcome, Guest
Please login or register.



Login with username, password and session length
Pages: [1]

Author Topic: Compilation Errors in vstream.pas  (Read 12547 times)

Chris

  • Private FC
  • *
  • Offline Offline
  • Posts: 12
    • View Profile
Compilation Errors in vstream.pas
« on: May 28, 2007, 17:54 »

When attempting to do the sr tutorial I get the following error:

vstream.pas(145,18) Error: function header doesn't match the forward declaration "IOutputStream.Write(const LongInt, Pointer)"

I'm using the 4.0 version of the Valkyrie library, by the way.

I'm doing this on OS X, but I was getting the same error on windows, when I was trying to compile berserk. I'm compiling using the command "fpc sr.pas -S2". I'm new to free pascal, so maybe I'm doing something really simple wrong. Anyway, any help would be great. Thanks.
Logged

Kornel Kisielewicz

  • God Hand
  • Apostle
  • *
  • *
  • Offline Offline
  • Posts: 4576
    • View Profile
    • http://chaosforge.org/
Re: Compilation Errors in vstream.pas
« Reply #1 on: May 28, 2007, 23:32 »

Hmm, there may be many reasons:

1) the sr tutorial is broken beyond repair -- it's very outdated, and I keep promising myself to write a new one :/
2) as for berserk -- it SHOULD work with the newest Valkyrie. Yet I know there are some errors in compilation when using 2.1.4 version of FreePascal (the newest ones) -- these however are relatively easy to fix (if that's the case than post your error log, and I'll tell you what to modify).
3) Berserk! needs 0.4.1 to compile.

I would publish the newest Valkyrie library, but... it breaks compatibility YET AGAIN, and the current berserk release doesn't compile with it :P.
Logged
at your service,
Kornel Kisielewicz

Chris

  • Private FC
  • *
  • Offline Offline
  • Posts: 12
    • View Profile
Re: Compilation Errors in vstream.pas
« Reply #2 on: May 29, 2007, 13:05 »

Using fpc version 2.1.4, on windows, with Valkyrie 4.1, I get these errors\warnings:

vstream.pas(148,18) Error: function header doesn't match the forward declaration "IOutputStream.Write(const LongInt, Pointer)"
vstream.pas(166,20) Warning: An inherited method is hidden by "constructor TFileInputStream.Open(const ShortString)"
vstream.pas(199,20) Warning: An inherited method is hidden by "constructor TMemoryOutputStream.Open(const LongInt)"
vstream.pas(235,20) Warning: An inherited method is hidden by "constructor TTextInputStream.Open(const ShortString)"
vstream.pas(255,17) Warning: An inherited method is hidden by "TTextInputStream.ReadString:ShortString"
vstream.pas(297,20) Warning: An inherited method is hidden by "constructor TSTDOutputStream.Create"
vstream.pas(328,1) Fatal: There were 1 errors compiling module, stopping

One thing to note is that initially it couldn't find a file vtextut.pas, which I couldn't see in the 4.1 library, so I added it from 4.2.

Thanks in advance.
Logged

init13

  • Private
  • *
  • Offline Offline
  • Posts: 1
    • View Profile
Re: Compilation Errors in vstream.pas
« Reply #3 on: November 04, 2007, 10:31 »

Hmm, there may be many reasons:

1) the sr tutorial is broken beyond repair -- it's very outdated, and I keep promising myself to write a new one :/
2) as for berserk -- it SHOULD work with the newest Valkyrie. Yet I know there are some errors in compilation when using 2.1.4 version of FreePascal (the newest ones) -- these however are relatively easy to fix (if that's the case than post your error log, and I'll tell you what to modify).
3) Berserk! needs 0.4.1 to compile.

I would publish the newest Valkyrie library, but... it breaks compatibility YET AGAIN, and the current berserk release doesn't compile with it :P.

Hey!

I have the same problem here. Using 0.4.2 Valkyre lib and FPC 2.2.0.
I can't compile anything due to that error.

Can you make any suggestion, please?

Thank ya, man :)
Logged

Kornel Kisielewicz

  • God Hand
  • Apostle
  • *
  • *
  • Offline Offline
  • Posts: 4576
    • View Profile
    • http://chaosforge.org/
Re: Compilation Errors in vstream.pas
« Reply #4 on: November 05, 2007, 07:00 »

Use the SVN version from sourceforge :)
Logged
at your service,
Kornel Kisielewicz
Pages: [1]