Russ Whitaker wrote:
> >... may be something about this should be added to FAQ ?
>
> Good idea. Perhaps the following:
>
>
> Why shouldn't I just grab and install a binary?
> =================================
Perhaps mention that this mostly applies to Linux/Unix. (Unix
systems other than Linux are often administered by a trained
administrator who will want to install from the sources, anyway.)
For Dos (DJGPP) and MS-Windows systems, it's usually much easier to
…
[View More]grab and install a binary.
Frank
--
Frank Heckenbach, frank(a)g-n-u.de, http://fjf.gnu.de/
GPC To-Do list, latest features, fixed bugs:
http://agnes.dida.physik.uni-essen.de/~gnu-pascal/todo.html
[View Less]
Hi
>... may be something about this should be added to FAQ ?
Good idea. Perhaps the following:
Why shouldn't I just grab and install a binary?
=================================
Linux may be Linux, but many details are left up to the implementor. If
that isn't enough updating a seemingly unrelated piece of software can
cause compatibility problems. Witness this exchange from the mailing
list:
>>I'm not an expert on this, but I remember that I installed on my
Linux
&…
[View More]gt;>(RedHat 6.1) two RPM packages:
>>
>> gpc-19990118-1.i386.rpm
>> gpc-extras-19990118-1.i386.rpm
> I have install all but it doesn't run anyway!
> My Linux is mandrake 7.0, it is maybe the problem?...
Mandrake is NOT compatible with RedHat despite claims - you need less
manual tweaks then in case with SuSE or Debian but ONLY RedHat is
compatible with RedHat (even in this case only if you are lucky enough
- see below). ESPECIALLY for GPC: Mandrake traditionally using very
"advanced" (read: barely working) versions of gcc and gpc relies
HEAVILY on gcc.
If you DO NOT have RPM for EXACTLY your distribution then better
(=easier) to recompile GPC from sources. And when I'm saying EXACTLY
I mean exactly: RPM for RedHat 5.0 WILL NOT work in RedHat 5.2, RPM
for RedHat 6.0 WILL NOT work in RedHat 6.2, etc. In some cases even
"RedHat x.y" can be incompatible with "RedHat x.y with updates" :-((
Usually it can be easily tracked down and fixed by knowledgeable person
(almost any package for any distribution can be forced to work in
almost any other distribution) but just "rpm -Uvh" quite often will
not work. When you are compiling program from sources autoconf usually
can find and compensate most differences automagically but rpm/dpkg/apt
is NOT sophisticated enough. That's why we recommend to start from
sources when binaries do not work for you.
Russ <russwhit(a)mind.net>
[View Less]
Hi
Nathalie Jarosz wrote>
> Today, I manage to install patch so I go on a little with the
installation
> but the step 2 (configuration) is not ok :
>
> 2. Configuring and building GNU CC GNU Pascal is automatically
> configured with GNU CC. Configuration of GNU CC is treated in
> depth in *Note the GCC installation instructions:
> (gcc)Installation.
> Chdir to the GCC object directory. (This can be a directory of
> your choice, …
[View More]including the GCC source directory.) From there, run
> the `configure' script in the GCC source directory. If both
> directories are the same, the command
> % ./configure
> is sufficient to configure GCC in most cases
>
> When I do this, the following message appears :
> " creating cache./config.cache
> checking host system type ... configure : error : can not guess host type
;
> you must specify one"
Let's back up for a moment:
1. Do you have a working C compiler?
try
cc -v
and you should get version info. The version is not important,
the response is, as cc is used for the first of the three passes
to build GPC.
2. Did you install a package of "include" files? These are a bunch
of files ending in .h and found in a directory or sub directory
called include. In the Slackware distribution the package is
called linuxinc.tgz and they consider it important enough to
provide two copies - one in the D series and the other in the K
series. In a simplistic sense these files tell the C compiler
how to use the library.
Now try make, again
Russ
<russwhit(a)mind.net>
[View Less]
Hello! My name is Janet Casey and I'm working for the Free Software
Foundation assembling a database of free software world wide, which is
why I'm writing to you.
We have this address listed as the maintainer for 'gpc'. Can you take a
quick look through the information I've assembled to see if everything
is correct and if there's anything I should add? I'd appreciate it
greatly.
FYI- a short explanation of some of the fields.
Programs- any additional programs that come included with this …
[View More]one.
Interface- Command line, interactive, X windows, console
Support- listed only if it's something other than mailing list support
Repository- Any CVS repositories where the program is listed
Related- any GNU packages that might be of interest to users of this package
Use Requirements- Required for using the executable
Build Prereq.- Required for building this package
Weak Prereq.- Useful (but not mandatory) to install before building this one
Source Prereq.-
Packages whose source code must be present in order to build this package.
Please bear in mind that not all packages will have all the fields
filled in (in fact, I don't think we've run across any yet that have
all the fields filled in).
If there's anything you think should be added (particularly
individuals who have contributed) please e-mail me.
Thank you very much for your help!
%%name: gpc
%%short-description: GNU Pascal compiler
%%full-description: A 32/64 bit compiler without the 64kB or 640 kB
limit found on certain operating systems (even if run on those
systems). It runs on all operating systems supported by GNU C and can
act as a native or as a cross compiler between all supported
systems. There are a number of GNU extensions that help make the
program portable.
%%category: development
%%license: GPL
%%maintainer: <gpc-request(a)hut.fi>
%%interface: Command line
%%updated: 11 May 2000
%%keywords: Compiler, C, 32 bit, 64 bit
%%GNU: yes
%%web-page: http://agnes.dida.physik.uni-essen.de/~gnu-pascal/
%%support:
%%doc: User reference manual available at
http://agnes.dida.physik.uni-essen.de/~gnu-pascal/gpc-doc.html
%%developers: Jukka Virtanen, Peter Gerwinski, Jan-Jaap van der Heijden
%%contributors: Alexey Volokhov, Bill Currie, Frank Heckenbach,
Matthias Klose, Nick Burrett
%%sponsors:
%%source: ftp://agnes.dida.physik.uni-essen.de/gnu-pascal/
%%debian: http://www.debian.org/packages/stable/devel/gpc.html
%%redhat: ftp://sunsite.doc.ic.ac.uk/gnu/pascal/gpc-2.0.tar.gz
%%repository:
%%related:
%%source-language: C
%%supported-languages: Pascal
%%use-requirements: gcc, binutils
%%build-prerequisites:
%%weak-prerequisites:
%%source-prerequisites:
%%version: 2.0 released; gpc-19990118 beta on 5 Jun 1999
%%announce-list: gpc-announce(a)gnu.org
%%announce-news:
%%help-list:
%%help-news: comp.lang.pascal.misc
%%dev-list: gpc(a)gnu.de
%%dev-news:
v
%%bug-list: bug-gpc(a)gnu.org
Janet Casey
Free Software Foundation
www.gnu.org
jcasey(a)gnu.org
[View Less]
-----Message d'origine-----
De : Tomasz Kowaltowski <tomasz(a)dcc.unicamp.br>
à : Nathalie Jarosz <njarosz(a)fr.packardbell.org>
Date : vendredi 12 mai 2000 13:28
Objet : Re: help!
>I'm not an expert on this, but I remember that I installed on my Linux
>(RedHat 6.1) two RPM packages:
>
> gpc-19990118-1.i386.rpm
> gpc-extras-19990118-1.i386.rpm
I have install all but it doesn't run anyway!
My Linux is mandrake 7.0, it is maybe the problem?..…
[View More].
-----Message d'origine-----
De : Peter Gerwinski <peter(a)gerwinski.de>
à : Nathalie Jarosz <njarosz(a)fr.packardbell.org>
Cc : gpc(a)gnu.de <gpc(a)gnu.de>
Date : vendredi 12 mai 2000 11:18
Objet : Re: help!
>Please install the C compiler for your system from a file of the
>type gcc-something-XrhY_i386(1).rpm. This package will either
>contain the needed libraries or have a dependency that will tell
>you what else has to be installed. (The same dependency should
>then be added to gpc-19990118-2rh6_i386(1).rpm.)
there is no gcc-something-XrhY_i386(1).rpm.
But I think it is not the problem bacause I have had to install some gcc
thnigs to run gpc...
Is anybody have already had the same problem or something similar?...
Nathalie
[View Less]
Hi
Is someone can help me?!!!
I really need to use a pascal compiler and I can't run it correctly.
I manage to install a pascal compiler with "gpc-19990118-2rh6_i386(1).rpm...
But, at
first, when I did the command:
$gpc -o test test.p, it says
ld : cannot open crt1.o : no file or directory of this type.
So, I tried to locate this file, and the only solution I find to go on was
to copy it where I want to compile. It was the same for 'begincrt.o' and
'crti.o'.
After this, the message was :
ld : …
[View More]cannot find -lm.
So, I create a variable called LFLAGS to export the libraries:
$ export LFLAGs="-L /usr/i586-glibc20-linux/lib"
and with the line:
$ gpc -o test $LFLAGS test.p
'test' is created but when I run it, the following message appear:
'segmentation fault'
What does it mean?
thanks a lot in advance for your help,
I guess some people use this so explain how you do to run it correctly, it's
really important for me.
Nathalie
[View Less]
Ryan K C Wong wrote:
> I cannot get GPC working: it always reports missing files.
>
> I use DJGPP 2.02 and GPC20BB for DOS with GO32V2 support
> (please see manifest below)
>
> Thank you.
>
>
> Description
> ***************************************
> The first file it says missing is the DJGPP.DJL
> the path of the file is C:\DJGPP\LIB\DJGP.DJL
>
> after I copied this file to the same directory of my
> program's source file, it continues to …
[View More]report that
> every unit 'CRT0', .... is missing.
>
> I suspect that the configuration file is corrupted.
> I included the DJGPP.ENV here. See below.
>
> *******************************************
> ***** djgpp.env ****************************
> *******************************************
There's no gpc section there. Try adding:
[gpc]
COMPILER_PATH=%/>;COMPILER_PATH%%DJDIR%/bin
LIBRARY_PATH=%/>;LIBRARY_PATH%%DJDIR%/lib
Frank
--
Frank Heckenbach, frank(a)g-n-u.de, http://fjf.gnu.de/
GPC To-Do list, latest features, fixed bugs:
http://agnes.dida.physik.uni-essen.de/~gnu-pascal/todo.html
[View Less]
Wren Lee wrote:
> DEC-Pascal has the ability to initialise a boolean or an enumerated type
> from a text file.The text is case insensitive and is read just as any
> other variable. Is there a way to do this with GPC?
No. For Booleans, it would not be too difficult to implement, but
for enum types, it would require that they're values (which are
program identifiers otherwise) be kept in the executable which is
not provided for currently (besides debug info).
> If not, are there
&…
[View More]gt; any good ways to emulate this behaviour?
Something like the following. It also illustrates the limitations...
program ReadBooleanEnumDemo;
uses GPC;
procedure ReadWord (var f : Text; var s : String);
const WordChars = ['A' .. 'Z', 'a' .. 'z', '_', '0' .. '9'];
begin
s := '';
while f^ in SpaceCharacters do
if EOLn (f) then
Readln (f)
else
Get (f);
while not EOF (f) and not EOLn (f) and (f^ in WordChars) do
begin
s := s + f^;
Get (f)
end
end;
function ReadBoolean (var f : Text) : Boolean;
var s : TString;
begin
ReadWord (f, s);
LoCaseString (s);
if s = 'false' then
ReadBoolean := False
else if s = 'true' then
ReadBoolean := True
else
begin
IOErrorCString (464, FileName (f)); { error when reading from % }
ReadBoolean := False
end
end;
function ReadEnum (var f : Text; const IDs : array of PString) : Integer;
var
s : TString;
i : Integer;
begin
ReadWord (f, s);
LoCaseString (s);
i := Low (IDs);
while (i <= High (IDs)) and (LoCaseStr (IDs [i]^) <> s) do Inc (i);
if i <= High (IDs) then
ReadEnum := i
else
begin
IOErrorCString (464, FileName (f)); { error when reading from % }
ReadEnum := 0
end
end;
procedure WriteEnum (var f : Text; EnumVal : Integer; const IDs : array [m .. n : Integer] of PString);
begin
Write (f, IDs [EnumVal]^)
end;
type
TFruit = (Apple, Orange, Banana);
const
FruitIDs : array [TFruit] of PString = (@'Apple', @'Orange', @'Banana');
var
BoolVar : Boolean;
FruitVar : TFruit;
begin
Write ('Enter a boolean and a fruit: ');
BoolVar := ReadBoolean (Input);
FruitVar := TFruit (ReadEnum (Input, FruitIDs)); { we have to cast the result to the enum type }
Writeln ('You entered:');
Writeln (BoolVar);
WriteEnum (Output, Ord (FruitVar), FruitIDs)
end.
Frank
--
Frank Heckenbach, frank(a)g-n-u.de, http://fjf.gnu.de/
GPC To-Do list, latest features, fixed bugs:
http://agnes.dida.physik.uni-essen.de/~gnu-pascal/todo.html
[View Less]
DEC-Pascal has the ability to initialise a boolean or an enumerated type
from a text file.The text is case insensitive and is read just as any
other variable. Is there a way to do this with GPC? If not, are there
any good ways to emulate this behaviour?
I am currently using GPC v.19991030 based on 2.95.2 19991024 on a LINUX
PC.
The following program shows the functionallity that I am trying to
emulate.
Thanks in advance,
Lee.
---
PROGRAM Read_Enum(input, output);
TYPE
colour = (red, …
[View More]green, blue);
VAR
flag : boolean; { Test boolean }
mycol : colour; { Test enumerated type }
ip_file : TEXT; { input data file }
filename : String(80);
i : integer;
BEGIN
filename := "enum.dat";
open(ip_file, filename, history:=old);
reset(ip_file);
FOR i := 1 to 3 DO
BEGIN
readln(ip_file, flag);
IF (flag) then
writeln("Flag is true")
ELSE
writeln('Flag is false');
END;
FOR i := 1 to 3 DO
BEGIN
readln(ip_file, mycol);
CASE mycol OF
red : writeln("Your colour is red");
green : writeln("Your colour is green");
blue : writeln("Your colour is blue");
END;
END;
close(ip_file);
END.
enum.dat:
========
true
False
TrUE
Red
green
BLUE
output:
======
Flag is true
Flag is false
Flag is true
Your colour is red
Your colour is green
Your colour is blue
--
The Information contained in this E-Mail and any subsequent correspondence
is private and is intended solely for the intended recipient(s).
For those other than the recipient any disclosure, copying, distribution,
or any action taken or omitted to be taken in reliance on such information is
prohibited and may be unlawful.
[View Less]