Re: Also from Algorithm genius
On Fri, Apr 26, 2002 at 01:21:21AM -0700, ben wrote:
> On Friday 26 April 2002 12:35 am, DSC Siltec wrote:
> > Okay... I'm not a genius, but this is going to be
> > a no-brainer for some of you, I can't figure it out.
> >
> > I have a simple program that uses log.
> >
> > I have "include <math.h>" in my program.
> >
> > When I compile on gcc, I get "unknown identifier: log."
> >
> > gcc mylogprog.c -o mylogprog.exe
> >
> > I'm guessing that I need to specify libraries, but I don't
> > know what libraries to specify, and I don't know how to find
> > out such things, or how to specify them.
> >
> > I tried doing it on K-Develop, and I compile fine, but "MAKE"
> > fails in the same way.
> >
> > Anyone have a combination of specific and general information
> > that will help?
> >
>
> do your own homework. alternatively, piss off to a list that is more
> sympathetic to enabling lazy-ass cs majors a way through their studies.
This doesn't really have anything to do with homework and everything to
do with the non-obvious fact that while most standard C functions don't
require any special magic, for hysterical raisons, *nix's make you
specify "-lm" to get the *standard* math functions.
--
Eric G. Miller <egm2@jps.net>
--
To UNSUBSCRIBE, email to debian-user-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Reply to: