delorie.com/archives/browse.cgi | search |
Date: | Mon, 24 May 93 13:53:49 EDT |
From: | DJ Delorie <dj AT ctron DOT com> |
To: | tesla AT lamar DOT colostate DOT edu |
Cc: | djgpp AT sun DOT soe DOT clarkson DOT edu |
Subject: | Re: Using the Complex class |
> complex.o: undefined symbol _sin referenced in text segment... > or something like that. (The compilation line that I use is > gcc XXX.cc -lm -oXXX This is a fun one. You need to do it like this: gcc [.c .o .a] -lgcc -lm The "-lgcc" is where the C++ classes are. The C++ class uses sin(), which is in libm.a.
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |