Sign in Join

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

Mailing lists / fpc-pascal / 2007-06

Question about some units

3 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

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

Test

Hi,

I have a source file (test.pp) that uses some units. Where can I get those units? If you didn't notice, I am a newbie :) I tried to compile but it obviously drops an error.

Example:

uses
cgiapp, unix, unixutils, classes, inifiles

Thanks for helping!

Francisco Reyes
to Test
Test wrote 6 lines
I have a source file (test.pp) that uses some units. Where can I get those units? If you didn't notice, I am a newbie :) I tried to compile but it obviously drops an error. uses cgiapp, unix, unixutils, classes, inifiles

Does the program compile?
If it does it means the compiler is finding the units.. and you can see where the compiler is looking by calling it:
fpc -va test.pp

That is a whole lot of output though..
If you are in a unix machine you could try "locate cgiapp". Another thing you can try if you are in unix: locate fpc.cfg

The fpc.cfg

I am a freepascal newbie myself.. so there may be better ways. The above are just two possible ways to look for the units.

L
Test wrote 6 lines
I have a source file (test.pp) that uses some units. Where can I get those units? If you didn't notice, I am a newbie :) I tried to compile but it obviously drops an error. uses cgiapp, unix, unixutils, classes, inifiles

FPC compiler comes with compiled .a/.ppu/.o files that should be on your computer system inside a directory such as /i386-linux/units/

You could run the program called "updatedb" then run "locate file.ppu". The files such as cgiapp.ppu and unixutils.ppu should be found. If they are not on your system you may have to download or install FPC again and install more items like FCL (it is optional). If your hard drive is big, you may not want to run "updatedb" as it may take ages, use another find program or gui file manager to find the files.

Usually the sources to these units are located in the FCL/RTL directories of your FPC compiler in subdirectories.. but you should not compile from the sources unless neccessary.

Lars