Jump to page: 1 2
Thread overview
library search path
Sep 21, 2002
Marc Kealy
Sep 21, 2002
Jan Knepper
Sep 21, 2002
Marc Kealy
Sep 21, 2002
Jan Knepper
Sep 21, 2002
Marc Kealy
Sep 21, 2002
Jan Knepper
Sep 21, 2002
Marc Kealy
Sep 21, 2002
Walter
Sep 21, 2002
Mark Evans
Sep 21, 2002
Walter
Sep 21, 2002
Marc Kealy
Sep 22, 2002
bw
Sep 22, 2002
Marc Kealy
Sep 22, 2002
Walter
Sep 22, 2002
Marc Kealy
Sep 22, 2002
Walter
Sep 22, 2002
Marc Kealy
Sep 22, 2002
Walter
September 21, 2002
Hi,

I have a problem with extending the lib search path, ie:-
    -LC:\MyLibs
seems to make sc think that I'm specifying a linker that it can't find.

I'm very new to DM, so I'm assuming that this is a fundamental oversite on my part.

--
Marc.



September 21, 2002
Marc Kealy wrote:

> I have a problem with extending the lib search path, ie:-
>     -LC:\MyLibs
> seems to make sc think that I'm specifying a linker that it can't find.

Yes, that's what you do.
When you start sc.exe or dmc.exe without paramters it will tell you what -L is
for.

Jan


September 21, 2002
In the docs for sc, it says that you can also use '-L' to pass arguments to the linker and gives an example of passing both a switch and a lib search path.

If this is not the prefered method, could anybody tell me what is?

Thanks

--
Marc.

"Jan Knepper" wrote
> Marc Kealy wrote:
>
> > I have a problem with extending the lib search path, ie:-
> >     -LC:\MyLibs
> > seems to make sc think that I'm specifying a linker that it can't find.
>
> Yes, that's what you do.
> When you start sc.exe or dmc.exe without paramters it will tell you
what -L is
> for.
>
> Jan
>
>


September 21, 2002
That's -L/
with -L you specify the linker (most likely an external one)
with -L/ you specify arguments to the linker.



Marc Kealy wrote:

> In the docs for sc, it says that you can also use '-L' to pass arguments to the linker and gives an example of passing both a switch and a lib search path.
>
> If this is not the prefered method, could anybody tell me what is?
>
> Thanks
>
> --
> Marc.
>
> "Jan Knepper" wrote
> > Marc Kealy wrote:
> >
> > > I have a problem with extending the lib search path, ie:-
> > >     -LC:\MyLibs
> > > seems to make sc think that I'm specifying a linker that it can't find.
> >
> > Yes, that's what you do.
> > When you start sc.exe or dmc.exe without paramters it will tell you
> what -L is
> > for.
> >
> > Jan
> >
> >

September 21, 2002
Jan,
I appreciate you taking the time to answer my questions, but please don't
assume that I'm an idiot.  Although I'm new to DM, I'm quite familiar with
the concepts of using compilers (Borland + GCC).

Now, in order to extend the lib search, I can find two options:
1. Use the 'LIB' environment variable.  This is a last resort for me.
2. Use -L???.  This is what the manual says:-

    -L/switch  Pass /switch to linker.
     For example, this command:
         sc test -L/packcode -L\test\prog
     adds the option /packcode and the library search path
     \test\prog to the linker's command line.

You'll notice that the second argument of this example dosn't use the '/' charactor, but goes straight into a relative path.  Now, a relative path is not what I want, I want to use an absolute path.

So, what I'd like to know is:-
    Is there a way to use the '-L' switch to add an absolute path to the lib
search?
    If not;  Are there other options than those above?
    How do you do it?

--
Marc.

"Jan Knepper"  wrote
> That's -L/
> with -L you specify the linker (most likely an external one)
> with -L/ you specify arguments to the linker.
>
>
>
> Marc Kealy wrote:
>
> > In the docs for sc, it says that you can also use '-L' to pass arguments
to
> > the linker and gives an example of passing both a switch and a lib
search
> > path.
> >
> > If this is not the prefered method, could anybody tell me what is?
> >
> > Thanks
> >
> > --
> > Marc.
> >
> > "Jan Knepper" wrote
> > > Marc Kealy wrote:
> > >
> > > > I have a problem with extending the lib search path, ie:-
> > > >     -LC:\MyLibs
> > > > seems to make sc think that I'm specifying a linker that it can't
find.
> > >
> > > Yes, that's what you do.
> > > When you start sc.exe or dmc.exe without paramters it will tell you
> > what -L is
> > > for.
> > >
> > > Jan
> > >
> > >
>


September 21, 2002
> 1. Use the 'LIB' environment variable.  This is a last resort for me.

That would work.

> 2. Use -L???.  This is what the manual says:-
>
>     -L/switch  Pass /switch to linker.
>      For example, this command:
>          sc test -L/packcode -L\test\prog
>      adds the option /packcode and the library search path
>      \test\prog to the linker's command line.

What about -L/-Lc:\test\prog ???

Jan


September 21, 2002
The library search path is controlled by the LIB environment variable:

    www.digitalmars.com/ctg/optlink.html#environment


"Marc Kealy" <marc@kealy.fslife.co.uk> wrote in message news:ami76c$2ld0$1@digitaldaemon.com...
> In the docs for sc, it says that you can also use '-L' to pass arguments
to
> the linker and gives an example of passing both a switch and a lib search path.
>
> If this is not the prefered method, could anybody tell me what is?
>
> Thanks
>
> --
> Marc.
>
> "Jan Knepper" wrote
> > Marc Kealy wrote:
> >
> > > I have a problem with extending the lib search path, ie:-
> > >     -LC:\MyLibs
> > > seems to make sc think that I'm specifying a linker that it can't
find.
> >
> > Yes, that's what you do.
> > When you start sc.exe or dmc.exe without paramters it will tell you
> what -L is
> > for.
> >
> > Jan
> >
> >
>
>


September 21, 2002
"Jan Knepper" <jan@smartsoft.cc> wrote in message news:3D8CB83D.392328AC@smartsoft.cc...
> > 1. Use the 'LIB' environment variable.  This is a last resort for me.
>
> That would work.
>
> > 2. Use -L???.  This is what the manual says:-
> >
> >     -L/switch  Pass /switch to linker.
> >      For example, this command:
> >          sc test -L/packcode -L\test\prog
> >      adds the option /packcode and the library search path
> >      \test\prog to the linker's command line.
>
> What about -L/-Lc:\test\prog ???
>
> Jan
>
>

No.  I've tried a few different things like that.

--
Marc.



September 21, 2002
Walter,

You should promote the use of sc.ini more often.  I like programs that are self-contained and require no registry or environment settings.  Especially when I also have MSVC6 on board, which does!

Sc.ini should be the preferred method IMHO.

Mark


>
>The library search path is controlled by the LIB environment variable:
>
>    www.digitalmars.com/ctg/optlink.html#environment
>


September 21, 2002
Yes, you are right. I wish more programs were self-contained. I had to keep after people to keep this working, the install programmers kept wanting to muck with the system directory and registry settings <g>.

"Mark Evans" <Mark_member@pathlink.com> wrote in message news:amip9g$udg$1@digitaldaemon.com...
> Walter,
>
> You should promote the use of sc.ini more often.  I like programs that are self-contained and require no registry or environment settings.
Especially when
> I also have MSVC6 on board, which does!
>
> Sc.ini should be the preferred method IMHO.
>
> Mark
>
>
> >
> >The library search path is controlled by the LIB environment variable:
> >
> >    www.digitalmars.com/ctg/optlink.html#environment
> >
>
>




« First   ‹ Prev
1 2