Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2012-01

FP IDE: Error: Illegal parameter: -Cp386

3 messages · 2 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Bart

I recently updated to fpc 2.6.0
Now I cannot compile anything in the FP IDE (Version 1.0.12 2011/12/25).

Program test;
{$mode objfpc}
{$h+}
begin
end.

I try to build/make:
Error: Illegal parameter: -Cp386

This is the auto-generated fp.cfg file:

# Automatically created file, don't edit.
#IFDEF NORMAL
-TWin32
-Mfpc
-Sg
-Ci
-O1
-Cp80386
-OpPENTIUM3
-Ratt
-FuC:\devel\fpc\units\i386-Win32
-FuC:\devel\fpc\units\i386-Win32\*
-FuC:\devel\fpc\units\i386-Win32\rtl
-XS
-g-
-p-
-b-

-Cp386 <<<<----------------------
#ENDIF
[snip]

Should probably be -Cp80386?

Bart

Reply by email

Pierre Free Pascal
to Bart

Did you try to "manually" (meaning with some other text editor, or sed script)
remove the offending line -Cp386 from fp.cfg?

The problem might come from a fp.cfg that was created by an earlier version
of Free Pascal for which -Cp386 was allowed.
To complicate things further, once you tried to compile with those wrong options, the compiler exits with fp.cfg file open, which leads to an opening failure on a second compilation try...

I still need to figure out how to correctly fix these possible open files...

Pierre Muller
Free Pascal core team member

Show quoted text 51 lines
-----Message d'origine----- De : [mailto:fpc-pascal- De la part de Bart Envoyé : mardi 3 janvier 2012 19:10 À : FPC-Pascal users discussions Objet : [fpc-pascal] FP IDE: Error: Illegal parameter: -Cp386 I recently updated to fpc 2.6.0 Now I cannot compile anything in the FP IDE (Version 1.0.12 2011/12/25). Program test; {$mode objfpc} {$h+} begin end. I try to build/make: Error: Illegal parameter: -Cp386 This is the auto-generated fp.cfg file: # Automatically created file, don't edit. #IFDEF NORMAL -TWin32 -Mfpc -Sg -Ci -O1 -Cp80386 -OpPENTIUM3 -Ratt -FuC:\devel\fpc\units\i386-Win32 -FuC:\devel\fpc\units\i386-Win32\* -FuC:\devel\fpc\units\i386-Win32\rtl -XS -g- -p- -b- -Cp386 <<<<---------------------- #ENDIF [snip] Should probably be -Cp80386? Bart _______________________________________________ fpc-pascal maillist - http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply by email

Bart
to Pierre Free Pascal
Pierre Free Pascal wrote
Did you try to "manually" (meaning with some other text editor, or sed script) remove the offending line -Cp386 from fp.cfg?

Yes, and that works.

The problem might come from a fp.cfg that was created by an earlier version of Free Pascal for which -Cp386 was allowed.

That might be true, I had fp from 2.4.4 earlier and possibly the config file was already there.
I deleted all config file and let fp recreate them from scratch (not using a previous it found elsewhere) and all seems to work.

So, it probably was all my fault to begin with.

A remark.
Why doesn't fp use only one (per user that is) fp.cgf/fp.ini file stored in the default location for users (like Lazarus does), and possibly configurable by commandline option
(--pcp=/path/to/my-fp-config) or environmentvariable?

Bart

Reply by email