delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1992/06/22/02:09:41

Date: Mon, 22 Jun 1992 00:56:08 -0500
From: Stuart M Lichtenthal <smlg1015 AT uxa DOT cso DOT uiuc DOT edu>
To: djgpp AT sun DOT soe DOT clarkson DOT edu
Subject: .c files using <math.h>

When I try to compile the file work.c which requires the math library, I
get the error 

work.o: Undefined symbol _log referenced  from text segment.

However, the autoexec.bat contains the lines:
set C_INCLUDE_PATH=c:/djgpp/include
set CPLUS_INCLUDE_PATH=c:/djgpp/cplusinc;c:/djgpp/include
set OBJC_INCLUDE_PATH=c:/djgpp/include
set OBJCPLUS_INCLUDE_PATH=c:/djgpp/include
set LIBRARY_PATH=c:/djgpp/lib

I get the above error statement using:
	gcc -O -lm work.c -o work

I am sure that #include <math.h> is in the file work.c.

Stuart Lichtenthal smlg1015 AT uxa DOT cso DOT uiuc DOT edu


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019