Forum > Windows

Upgraded FPC from 2.6.4 to 3.0.0 and now CRT unit is missing

(1/1)

Rich Pasco:
I recently upgraded FPC from 2.6.4 to 3.0.0 as follows:

1. Download and ran the executable fpc-3.0.0.i386-win32.exe
2. Replaced all references to 2.6.4 in my PATH with 3.0.0

Now, when I try to re-compile my existing programs, I get the error message:
"Fatal: Can't find unit CRT used by Program"

Sure enough

  C:\FPC\2.6.4\units\i386-win32\rtl\crt.o
and
  C:\FPC\2.6.4\units\i386-win32\rtl\crt.ppu

exist but there are no couterparts in

  C:\FPC\3.0.0\units\i386-win32\rtl

Was the CRT unit deliberately deleted from 3.0.0, or what did I do wrong?

molly:
unit crt can be found inside directory rtl-console.

Try to compile your project with -va and see what fpc.cfg file was used (as well as which paths are defined to locate your units). Analyzing -va output usually holds the answer.

Rich Pasco:
Thanks, molly.

I was using a custom FPC.CFG file.  Switching to the installer-generated

   C:\FPC\3.0.0\bin\i386-win32\fpc.cfg

fixed that.

But now I have a new fatal error:

  "Destructors cannot have parameters"

Since when?  The offending source line was

  destructor close(commit: Boolean);

It worked with 2.6.4 but is flagged in 3.0.0.  Why?


UPDATE:  It's because I lost my -So switch.  See item 16 here:
http://www.freepascal.org/docs-html/3.0.0/user/usersu82.html

molly:

--- Quote from: richpasco on December 09, 2016, 05:16:58 am ---UPDATE:  It's because I lost my -So switch.
http://www.freepascal.org/docs-html/3.0.0/user/usersu82.html

--- End quote ---
You was quicker than me , as i just found the reason just like you :)

fwiw: you can still use your custom fpc.cfg but, you simply have to make sure the paths are all correct for your 3.0 installation.

Navigation

[0] Message Index

Go to full version