GPC compiler error

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
fbelzile
Posts: 18
Joined: Tue Dec 28, 2004 12:00 am

GPC compiler error

Post by fbelzile »

Hi all,

Yes, I have decided to do a basic OS in Pascal. I have been using Bloodshed's Pascal IDE to make my exe's do far, but now making an OS I need to compile stuff to .bin's.

Bloodshed's Pascal IDE came with the command-line GPC compiler, but when I come to use it, it always gives me this error:

Code: Select all

gpc: installation problem, cannot exec `gpcpp': Invalid argument
I get this when I type:

gpc program.pas -o program.bin


**********************************************

Also, when making an OS with Pascal do I write it any differently from making just an ordinary exe.
User avatar
carbonBased
Member
Member
Posts: 382
Joined: Sat Nov 20, 2004 12:00 am
Location: Wellesley, Ontario, Canada
Contact:

Re: GPC compiler error

Post by carbonBased »

I'm guessing gpc is a driver executable, just like gcc, which actually calls other executables to perform whatever task is asked for (be it compiling, linking, etc).

As such, the bloodshed IDE probably ensures that these executables are in the path before executing gpc, and I'd image you have to do the same.

I'd suggest search for this executable
dir gpcpp.exe /s

And add whatever directory it's in, to the path, and then retry.

Cheers,
Jeff
[AlAdDiN]
Member
Member
Posts: 107
Joined: Fri Oct 22, 2004 11:00 pm
Contact:

Re: GPC compiler error

Post by [AlAdDiN] »

fbelzile wrote: ....
Also, when making an OS with Pascal do I write it any differently from making just an ordinary exe.
there is nothing different in coding style, but u must have in mind that you dont have any library, i m not sure about pascal but if it is like C you have to write youre own "write()/writeln()" functions for example.
-----------------------
There are 10 types of people in this world... those that understand binary, and those that don't.
fbelzile
Posts: 18
Joined: Tue Dec 28, 2004 12:00 am

Re: GPC compiler error

Post by fbelzile »

I'm back finally, I lost hope of this subject for a while, but I'm back with the same problem.

Like I siad I get this error:

Code: Select all

c:\dev_gpc\bin\gpc: installation problem, cannot  exec`c:/dev_gpc/bin/gpcpp.exe': Invalid argument
For one thing, I tried running gpcpp.exe and all it did was display a blank console box, and did nothing.

Is this a sign of a corrupt file? If it is, can someone e-mail me the good "gpcpp.exe" file via e-mail:

felixbelzile@sasktel.nneett (remove the extra n,e,t's)


Thanks,
Post Reply