Re: [fpc-pascal] streaming file from zip into my app

2007-11-30 Thread Marc Santhoff
Am Freitag, den 30.11.2007, 23:09 +0200 schrieb Graeme Geldenhuys:
 On 30/11/2007, Marc Santhoff [EMAIL PROTECTED] wrote:
 
  But I still have questions about the code. Do I understand correctly
  that Graeme contributed the de-/compression code but it still has to get
  integrated and used by the component?
 
 We used the zlib (de)compression units from the tiOPF project. We
 simply removed the references to other tiOPF units - it was pretty
 stand-alone already so was easy.  So yes, what's left is to integrate
 that code into the TZipFile component and do some tests. The
 (de)compression code has already been well unit tested in tiOPF, so we
 know that part works perfectly.  As I stated earlier, I have also
 found a Object Pascal implementation of 7zip which I would like to add
 to both TZipFile and tiOPF - I still need to double check the
 licensing though.

I'm remembering slowly, zlib is for handling gzip format, pkzip format
is still missing. And 7zip, does it have it's own format or is this used
for the common .zip-files?

If I would want to complete the component, I'd try to use and maybe add
something to the unit I've already found in packages/extra/unzip. At
least the compression routines should do.

Marc


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Help getting started with FPC

2007-11-30 Thread Edward Kearns
Because of all the help I got, especially from Jonas Maebe, I  
successfully opened and ran successfully in LIghtweight IDE the  
Pascal program I had developed over several years in Think Pascal.  
NOW I can modify it, as I had desired.


Ed
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] streaming file from zip into my app

2007-11-30 Thread Graeme Geldenhuys
On 30/11/2007, Marc Santhoff [EMAIL PROTECTED] wrote:

 But I still have questions about the code. Do I understand correctly
 that Graeme contributed the de-/compression code but it still has to get
 integrated and used by the component?

We used the zlib (de)compression units from the tiOPF project. We
simply removed the references to other tiOPF units - it was pretty
stand-alone already so was easy.  So yes, what's left is to integrate
that code into the TZipFile component and do some tests. The
(de)compression code has already been well unit tested in tiOPF, so we
know that part works perfectly.  As I stated earlier, I have also
found a Object Pascal implementation of 7zip which I would like to add
to both TZipFile and tiOPF - I still need to double check the
licensing though.


Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] streaming file from zip into my app

2007-11-30 Thread Marc Santhoff
Am Freitag, den 30.11.2007, 16:21 +0100 schrieb
[EMAIL PROTECTED]:
  What de- and encoding is it, are you talking of character sets or
  encryption?
 
 I was referring to compression. It should be trivial to implement, but I
 never got around it. So if you have interest and want to patch it please
 do, I will apply it.

I'd like to, but that would clearly be far too much work for the small
time frame I've got, sorry. But this time I'm lucky, the description
file meta.xml in the root dir of OO.o docs is only stored (in opposite
to deflated).

But I still have questions about the code. Do I understand correctly
that Graeme contributed the de-/compression code but it still has to get
integrated and used by the component?

Thank you,
Marc


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Help getting started with FPC

2007-11-30 Thread Chris Kirkpatrick

I suggest you look at the FPC/Lazarus Wiki
http://wiki.freepascal.org/
for ideas to get you started.

It may be easier to start programmng using either the FPC IDE which 
comes with the FPC package, or the Lazarus IDE which can be used either 
to produce Windowed GUI applications or simple Pascal console-mode programs.


The FPC manuals at
http://www.freepascal.org/docs.html
contain a lot of information to get you going

You will find the FreePascal/Lazarus community very supportive, eg in 
this mailing list. I have very rarely seen the comment 'RTFM', though 
people very often offer links to suitable places to get information.


Hope this helps
Regards - Chris


Edward Kearns wrote:
I am new to FPC, and can't get started. I have used Think Pascal, and 
I seem to have quite a hurdle here. Someone else told me that I need 
to start XCode first. I did that, then I chose a template (FPC Carbon 
Application 2.2.0). Then I didn't know how to enter code, so I opened 
start.pas, entered some code, tried to do build and run, compile, 
and none of these ran my simple code. what am I missing?


Ed
___
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Help getting started with FPC

2007-11-30 Thread Jonas Maebe


On 30 Nov 2007, at 23:20, Edward Kearns wrote:


Program HelloWorld;
begin

print hello

end.


Note that the above is not a valid Pascal program. This is the  
correct version:


Program HelloWorld;
begin

  writeln('hello');

end.


and I'm told

No main program found. Can not build.

What extension do I need on it?


.p, .pas or .pp


Jonas
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Help getting started with FPC

2007-11-30 Thread Jonas Maebe


On 30 Nov 2007, at 19:49, Edward Kearns wrote:

I am new to FPC, and can't get started. I have used Think Pascal,  
and I seem to have quite a hurdle here. Someone else told me that I  
need to start XCode first. I did that, then I chose a  template  
(FPC Carbon Application 2.2.0). Then I didn't know how to enter  
code, so I opened start.pas, entered some code, tried to do build  
and run, compile, and none of these ran my simple code. what am  
I missing?


Xcode /is/ a quite complex environment, and there is no quick do  
this and you can do everything you want with Xcode document, only  
the slower experiment and read its documentation way.


If you want something more akin to Think Pascal, you may want to try  
LWP, which is available here:

http://sourceforge.net/projects/lightweight-ide


Jonas
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] streaming file from zip into my app

2007-11-30 Thread dhkblaszyk
 What de- and encoding is it, are you talking of character sets or
 encryption?

I was referring to compression. It should be trivial to implement, but I
never got around it. So if you have interest and want to patch it please
do, I will apply it.

Darius

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Libc and 2.2.0

2007-11-30 Thread Luca Olivetti

En/na [EMAIL PROTECTED] ha escrit:

Hi,
after I upgraded fpc 2.0.4 - 2.2.0, I can't find unit Libc = can't use
Synaser and RS232.
I use Kubuntu 6.10 and I'm not a programmer (I am electronics).
Any advise?


Try synasnap, it includes synaser and supposedly doesn't use libc (I say 
supposedly just because right now I'm under windows and cannot check).


Bye
--
Luca

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Capture HeadTrace output to file?

2007-11-30 Thread Graeme Geldenhuys
On 30/11/2007, Marc Santhoff [EMAIL PROTECTED] wrote:
 For sh and maybe bash getting stdout and stderr in the file

 ./something 21 out.log

 should do. I didnt test, but getting stderr only may work like this:


I use bash and the above doesn't work...  Henry's example of
./something  log.txt 21 works though.



Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Capture HeadTrace output to file?

2007-11-30 Thread Graeme Geldenhuys
On 30/11/2007, Henry Vermaak [EMAIL PROTECTED] wrote:

 ./something.sh  log.txt 21 will redirect both stdout and stderr to
 log.txt.  a useful trick...


Thanks Henry, this also works.


Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] streaming file from zip into my app

2007-11-30 Thread Marc Santhoff
Am Freitag, den 30.11.2007, 09:04 +0100 schrieb
[EMAIL PROTECTED]:
  Hi,
 
  I'd like to unzip one file from a zip archive and use it directly as
  input for something else (sax or self written parser).
 
  Since the unzip package form the extra dir only writes to disc files:
 
  Is there any alternative source for writing from zip to a stream instead
  of a file?
 
  Or even better: is any fpc source for extracting the document info from
  Openoffice.org files already written? ;)
 
 Hi Marc,
 
 You can have a look at TZipFile
 (http://wiki.lazarus.freepascal.org/ZipFile). The only problem still with
 it is that it does not support decoding / encoding. But the basis is there
 already.

What de- and encoding is it, are you talking of character sets or
encryption?

The target documents are unencrypted for sure, but they are written in
different languages.

 You can access a zipfile as if it's a filesystem.

That would be the right view, I'll have a look.

Thanks Darius,
Marc


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Capture HeadTrace output to file?

2007-11-30 Thread Marc Santhoff
Am Freitag, den 30.11.2007, 15:00 +0100 schrieb Marc Santhoff:
 Am Freitag, den 30.11.2007, 13:45 +0200 schrieb Graeme Geldenhuys:
  On 30/11/2007, Marco van de Voort [EMAIL PROTECTED] wrote:
  
 ./something   out.log
  
  
  That didn't work...
 
 Maybe you use another shell than Marco (that's [t]csh), you could look
 at the man page for your in the part output redirection or similar.
 
 For sh and maybe bash getting stdout and stderr in the file
 
 ./something 21 out.log

That doesn't work, it would only for piping:

./stdfile 21 | cat  out.log

But the rest was okay. Henry got it right however ...

Marc


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] Heaptrc unit is awesome

2007-11-30 Thread Graeme Geldenhuys
Hi,

I had a suspicion that fpGUI was leaking some memory.  After
activating Heaptrc I got a bit of a shocker. I needed to log the
output to file because it was *very* long.   [Yeah I know, nothing to
be proud of].

I had 522 memory leaks!!  [hiding in shame]   But after enabling
Heaptrc and 1 hour later, fpGUI is now totally memory leak free!  :-)

And the best of all - all these cool tools are included with FPC.
Great job guys!


Feature Request:

A minor Feature Request for Heaptrc.  Using the log=filename in the
environment variable works wonders.  I fortunately didn't know that it
doesn't clear the file on every run (I'm used to tiOPF log behaviour).
 So for the first 30 minutes I was constantly staring at the 522
memory leak count (first few lines of the log file) and couldn't
figure out why I ain't getting that value any lower!
After 30 minutes I was growing frustrated and by pure luck I looked at
the log file size between runs and noticed it was growing.  Heaptrc
keeps _appending_ to the log and I was staring at the result of my
first run (over and over).  :-)

A quick:   $ rm ./out.log;  ./test
fixed the issue. Removing the log before each run.  Damn, I wasted a
lot of time on that.

Could we add extra option in the environment variable setting that
clears the log file on each run?


Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Capture HeadTrace output to file?

2007-11-30 Thread Marc Santhoff
Am Freitag, den 30.11.2007, 13:45 +0200 schrieb Graeme Geldenhuys:
 On 30/11/2007, Marco van de Voort [EMAIL PROTECTED] wrote:
 
./something   out.log
 
 
 That didn't work...

Maybe you use another shell than Marco (that's [t]csh), you could look
at the man page for your in the part output redirection or similar.

For sh and maybe bash getting stdout and stderr in the file

./something 21 out.log

should do. I didnt test, but getting stderr only may work like this:

./something 2 out.log


HTH,
Marc


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Capture HeadTrace output to file?

2007-11-30 Thread Henry Vermaak
On 30/11/2007, Graeme Geldenhuys [EMAIL PROTECTED] wrote:
 On 30/11/2007, Marco van de Voort [EMAIL PROTECTED] wrote:
 
./something   out.log
 

 That didn't work...

./something.sh  log.txt 21 will redirect both stdout and stderr to
log.txt.  a useful trick...



 Regards,
   - Graeme -


henry
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Capture HeadTrace output to file?

2007-11-30 Thread Graeme Geldenhuys
On 30/11/2007, Vincent Snijders [EMAIL PROTECTED] wrote:

 RTFM for the log=... use
 http://www.freepascal.org/docs-html/rtl/heaptrc/environment.html


Thanks Darius and Vincent.  I'm new to heaptrc and just tried it out.
For some reason I didn't even think to look for docs...  My bad.


Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Capture HeadTrace output to file?

2007-11-30 Thread Graeme Geldenhuys
On 30/11/2007, Marco van de Voort [EMAIL PROTECTED] wrote:

   ./something   out.log


That didn't work...


Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Capture HeadTrace output to file?

2007-11-30 Thread dhkblaszyk
 [ Charset ISO-8859-1 unsupported, converting... ]
 Hi,

 If I compile a project the -gh (Heaptrc unit), how to I capture the
 output generated when I quite the application to a file?


 I tried the normal:   $./text  out.log

 But that doesn't work... the out.log is empty.

   ./something   out.log

 however units like crt might make this not possible. The exact solution
 for
 that differs with application.

You can also set an environment variable.

http://www.freepascal.org/docs-html/rtl/heaptrc/environment.html

Darius



___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Capture HeadTrace output to file?

2007-11-30 Thread Marco van de Voort
[ Charset ISO-8859-1 unsupported, converting... ]
 Hi,
 
 If I compile a project the -gh (Heaptrc unit), how to I capture the
 output generated when I quite the application to a file?
 
 
 I tried the normal:   $./text  out.log
 
 But that doesn't work... the out.log is empty.

  ./something   out.log

however units like crt might make this not possible. The exact solution for
that differs with application.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Capture HeadTrace output to file?

2007-11-30 Thread Vincent Snijders

Graeme Geldenhuys schreef:

Hi,

If I compile a project the -gh (Heaptrc unit), how to I capture the
output generated when I quite the application to a file?


I tried the normal:   $./text  out.log

But that doesn't work... the out.log is empty.


RTFM for the log=... use
http://www.freepascal.org/docs-html/rtl/heaptrc/environment.html

if no filename is given, it outputs to stderr and not stdout.

Vincent
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] Libc and 2.2.0

2007-11-30 Thread lebduska
Hi,
after I upgraded fpc 2.0.4 - 2.2.0, I can't find unit Libc = can't use
Synaser and RS232.
I use Kubuntu 6.10 and I'm not a programmer (I am electronics).
Any advise?
Peter Lebduska
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Libc and 2.2.0

2007-11-30 Thread Marco van de Voort
 after I upgraded fpc 2.0.4 - 2.2.0, I can't find unit Libc

As Ido already said, unit libc is linux/x86 only, since it is a Kylix
compability unit (and Kylix only runs on linux/x86). So no other
architectures on Linux, no FreeBSD, no OS X.

See also sections 2.3 and 6 in http://www.stack.nl/~marcov/porting.pdf

 = can't use Synaser and RS232.
 I use Kubuntu 6.10 and I'm not a programmer (I am electronics).

Ask for FPC ready components, or try to port them. It seems you are trying
to compile Kylix components.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] Capture HeadTrace output to file?

2007-11-30 Thread Graeme Geldenhuys
Hi,

If I compile a project the -gh (Heaptrc unit), how to I capture the
output generated when I quite the application to a file?


I tried the normal:   $./text  out.log

But that doesn't work... the out.log is empty.


Regards,
  - Graeme -
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] PROCESS_ATTACH on Linux?

2007-11-30 Thread be
Hi,

I am trying to convert a Windows DLL to a lib file for (Debian) Linux. 
The DLL uses PROCESS_ATTACH and PROCESS_DETACH (DllProc). Is there an 
equivalent feature in FreePascal on the Linux platform?

Thanks
Bernd___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] streaming file from zip into my app

2007-11-30 Thread Graeme Geldenhuys
On 30/11/2007, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:

 You can have a look at TZipFile
 (http://wiki.lazarus.freepascal.org/ZipFile). The only problem still with
 it is that it does not support decoding / encoding. But the basis is there
 already. You can access a zipfile as if it's a filesystem.


Hi Darius,

I haven't forgotten about that component either... :-)  We simply
haven't reached that stage in our project yet.  We will be using
TZipFile for a custom compressed help format (something like OOo help)
and for storing our teaching modules (a maths tutoring system).

I would also like to incorporate 7zip compression support with the
existing ZLib compression.  I found a Object Pascal implementation of
7zip the other day.

Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] Help getting started with FPC

2007-11-30 Thread Edward Kearns
I am new to FPC, and can't get started. I have used Think Pascal, and  
I seem to have quite a hurdle here. Someone else told me that I need  
to start XCode first. I did that, then I chose a  template (FPC  
Carbon Application 2.2.0). Then I didn't know how to enter code, so I  
opened start.pas, entered some code, tried to do build and run,  
compile, and none of these ran my simple code. what am I missing?


Ed
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] streaming file from zip into my app

2007-11-30 Thread dhkblaszyk
 Hi,

 I'd like to unzip one file from a zip archive and use it directly as
 input for something else (sax or self written parser).

 Since the unzip package form the extra dir only writes to disc files:

 Is there any alternative source for writing from zip to a stream instead
 of a file?

 Or even better: is any fpc source for extracting the document info from
 Openoffice.org files already written? ;)

Hi Marc,

You can have a look at TZipFile
(http://wiki.lazarus.freepascal.org/ZipFile). The only problem still with
it is that it does not support decoding / encoding. But the basis is there
already.
You can access a zipfile as if it's a filesystem.

Darius


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] INCLUDE directive syntax

2007-11-30 Thread Mark Morgan Lloyd
Running 2.2.0 on Win-32 and Linux is it possible to have an absolute 
(fully-qualified) path as the parameter of a $INCLUDE directive? I've been 
trying to include a file from elsewhere on the /usr/local tree and find I can 
only do that using ../../.. (and so on) which gets somewhat tedious and hard 
to manage.


--
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] streaming file from zip into my app

2007-11-30 Thread dhkblaszyk
 Hi,

 I'd like to unzip one file from a zip archive and use it directly as
 input for something else (sax or self written parser).

 Since the unzip package form the extra dir only writes to disc files:

 Is there any alternative source for writing from zip to a stream instead
 of a file?

 Or even better: is any fpc source for extracting the document info from
 Openoffice.org files already written? ;)

Hi Marc,

You can have a look at TZipFile
(http://wiki.lazarus.freepascal.org/ZipFile). The only problem still with
it is that it does not support decoding / encoding. But the basis is there
already.
You can access a zipfile as if it's a filesystem.

Darius


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Libc and 2.2.0

2007-11-30 Thread ik
The libc unit does not arrive with FPC 64bit...

On Nov 30, 2007 12:29 PM,  [EMAIL PROTECTED] wrote:
 Hi,
 after I upgraded fpc 2.0.4 - 2.2.0, I can't find unit Libc = can't use
 Synaser and RS232.
 I use Kubuntu 6.10 and I'm not a programmer (I am electronics).
 Any advise?
 Peter Lebduska


Ido
-- 
http://ik.homelinux.org/
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Help getting started with FPC

2007-11-30 Thread Jonas Maebe


On 30 Nov 2007, at 22:46, Edward Kearns wrote:

If you want something more akin to Think Pascal, you may want to  
try LWP, which is available here:

http://sourceforge.net/projects/lightweight-ide



I did try LWP, and when I opened New Skel, and Compiled, and Ran,  
all I got were error message.


Which error message?


Where do I go to create my main file in LWP?


Anywhere you want. Just make sure it starts with a program header  
(such as program helloworld;).



Jonas
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Help getting started with FPC

2007-11-30 Thread Ingemar Ragnemalm

Jonas Maebe wrote:
If you want something more akin to Think Pascal, you may want to try  
LWP, which is available here:

http://sourceforge.net/projects/lightweight-ide
  


Thanks, Jonas! I think that is what Edward needs. BTW, the latest 
version is at


http://www.ragnemalm.se/lightweight

It is much harder to upload to SourceForge, so I can't always do that.

Edward Kearns [EMAIL PROTECTED] wrote:

I did try LWP, and when I opened New Skel, and Compiled, and Ran, all  
I got were error message.
  


Then I must guess that you either have problems with the paths (strange 
characters that mess up the command lines) or something is not installed 
properly. What does the about box look like? It should tell what 
compilers are installed.




Here's what I wrote:


Program HelloWorld;
begin

print hello

end.

and I'm told

No main program found. Can not build.
  


I took that code, created a new document in LWP, saved as HW.pas, 
fixed the print line

to WriteLn('hello');, hit cmd-R. It runs just fine.


What extension do I need on it?
  


.p, .pas, .P, .PAS, .dpr should all work in recent versions.

Let me ask:

- Is Free Pascal installed? For the target you use? (If you use an Intel 
Mac, you need to change target to Intel unless the PPC compiler is 
installed.)
- Is GCC installed? (Comes with Xcode, I don't know if you can download 
it separately somewhere. AFAIK FPC needs GCC for linking.)


I am sure this can be solved pretty easily. In all my tests, LWP runs 
nicely as long as FPC is installed. I will gladly fix any beginner traps 
you find.



/Ingemar

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal