From: Boon van der RJ Newsgroups: comp.os.msdos.djgpp Subject: Re: Link to 3rd Party Libs Date: 2 Oct 1998 12:04:48 GMT Organization: Fac. Wiskunde & Informatica, VU, Amsterdam Lines: 20 Message-ID: <6v2fh0$goh$1@star.cs.vu.nl> References: <6v2ehi$2e9 AT dfw-ixnews10 DOT ix DOT netcom DOT com> NNTP-Posting-Host: sloep04.cs.vu.nl User-Agent: tin/pre-1.4-980730 (UNIX) (SunOS/5.5.1 (sun4u)) Originator: rjvdboon AT sloep04 DOT cs DOT vu DOT nl To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp John \"The Mayor\" Curley wrote: > I would like to link with some 3rd Party class libraries. How would I > specify the path and name of the libraries from the command line? You specify an extra library-dir with: -Lyour/dir/here an extra include-dir with: -Iyour/dir/here and the library name by: -lname (only if the library is named libname.a, else gcc will not find it. You can also add the lib to the link line as if it's an object: gcc -o prog.exe prog.o /your/dir/extlib.a) (It's all in gcc.info, and maybe even in the FAQ) And finally make sure they are compiled with djgpp (but you know this already, right), because you can't mix non-djgpp-libs with djgpp-libs (In general. An exception is rsxntdj, but that creates win-apps) bye now, Robert. -- rjvdboon AT cs DOT vu DOT nl | "En dat is niet waar!" sprak ex-Staatsecretaris- www.cs.vu.nl/~rjvdboon | van-Onderwijs Netelenbos fel.