🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gcc.help
Article #41368

linux gcc 2.7.0 pow in math.h broken?

#41368
From: Marc Butler
Date: Mon, 01 Apr 1996 00:00
32 lines
1127 bytes
Hi,

When I try to use pow I get this error:

/tmp/cca092541.o: In function `main':
/tmp/cca092541.o(.text+0x15): undefined reference to `pow'

Platform: Linux 1.2.13 (ELF) [Slackware 3.0]
Version:	GCC 2.7.0
libc:			libc.so.5.2.18

The program this error was  generated by is below. Is it me
or the library?

thanks Marc.

#include <stdio.h>
#include <math.h>

void
main (void)
{
	int test;

	test = pow(2,2);
	printf ("\n%i\n", test);
}
-- 
 A loaded gun won't set you free.  | Marc "My Friends call me friend." Butler
 -So you say.                      | Sydney, Australia
 New Dawn Fades, Moby (HEAT)       | http://www.zip.com.au/~marc/
 ------------------------------- (EOF) --------------------------------------
Technical Details
Message-ID: <4jom7h$eaj@the-fly.zip.com.au>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 11318c,abb689789a4e4272,start
X-Google-Attributes: gid11318c,public
From: marc@zip.com.au (Marc Butler)
Subject: linux gcc 2.7.0 pow in math.h broken?
Date: 1996/04/01
Message-ID: <4jom7h$eaj@the-fly.zip.com.au>
X-Deja-AN: 145390445
organization: I need to put my ORGANIZATION here.
newsgroups: gnu.gcc.help