Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 1 May 2004 14:28:19 +0100
From:      Richard Bradley <rtb27@cam.ac.uk>
To:        freebsd-hackers@freebsd.org
Subject:   linking questions (how to use linux version of libc)
Message-ID:  <200405011428.19287.rtb27@cam.ac.uk>

next in thread | raw e-mail | index | archive | help
Hi,

I am trying to compile a program that uses "initstate_r" from random(3) in 
libc.

However this function only seems to exist in the linux version of libc.

Compare `man 3 random` on a linux box [1] which has "initstate_r" and 
"initstate", whereas `man 3 random` on a FreeBSD box [2] has only 
"initstate".

I have the linux compat stuff on my system.

The header called in the file is "#include <stdlib.h>"

When I try to compile, it comes up with "undeclared identifier" errors.

What can I do?

Any help is much appreciated.


Rich


[1] -- man 3 random on linux -- http://h30097.www3.hp.com/docs/base_doc/
DOCUMENTATION/V51B_HTML/MAN/MAN3/2370____.HTM 

[2] -- man 3 random on FreeBSD -- http://www.FreeBSD.org/cgi/
man.cgi?query=random&apropos=0&sektion=0&manpath=FreeBSD+5.2-RELEASE+and
+Ports&format=html



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200405011428.19287.rtb27>