[fpc-devel] Purpose of "uses ... in"?
Zaher Dirkey
parmaja at gmail.com
Wed Jul 21 11:04:37 CEST 2010
On Wed, Jul 21, 2010 at 8:37 AM, Mattias Gaertner <nc-gaertnma at netcologne.de
> wrote:
> On Tue, 20 Jul 2010 19:57:39 +0200
> Zaher Dirkey <parmaja at gmail.com> wrote:
>
> > uses
> >
> > > myunit in '..\lib\myunit.pas',
> > >
> > > it is no need to change it even in the search path.
> > >
> > >
> > I meant my project have folders like
> > /proj/bin
> > /proj/src
> > /proj/lib
> > i can move the dir /proj or my component package to any dir without need
> a
> > changes.
>
> So it is with search paths. They don't need to change when you move
> your /proj.
> I don't see your point.
>
>
If i have project use some source of components,not use *.o files,
My proj1 use component lib1.pas but lib1.pas need unit unit1.pas in sub dir
(/mylib/src/sqlite/unit1.pas) of same dir of lib1.pas
/proj1/bin
/proj1/src
/proj1/lib
/proj1/addons
/mylib/src
/mylib/src/sqlite/
/mylib/src/firebird/
in fact i must add all in search path, while if i put in /mylib/src/lib1.pas
in uses
uses
sqlite in './sqlite/sqlite.pas';
now i can move copy to friends, make it from another platform
(linux/windows) and send the examples without worry about the paths, may be
i need to change one path
May be the point got when i build site using PHP :)
Thanks
--
Zaher Dirkey
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-devel/attachments/20100721/9c922400/attachment.html>
More information about the fpc-devel
mailing list