Mail Archives: djgpp/1999/04/06/03:34:55
On Mon, 5 Apr 1999, Chris Hut wrote:
> This seems like a faq type thing, but I checked and haven't seen this
> problem listed anywhere...
The FAQ only includes FREQUENTLY-asked questions. You should also
search the DJGPP mail archives
(http://www.delorie.com/djgpp/mail-archives/), as the FAQ says. This
isssue popped up a couple of times before.
> when compiling I get this error:
> c:/djgpp/lang/cxx/stl_algo.h: In function 'void __random_shuffle<int *,
> int>(int *, int *, int *)':
> c:/djgpp/lang/cxx/stl_algo.h:617: 'lrand48' undeclared (first use this
> function)
> (stuff about each undeclared identifier only reported once)
This is a bug in libstdcxx: it doesn't define the symbol that tells
the rest of the code DJGPP doesn't have the rand48 family of
functions.
To solve this problem, edit the file lang/cxx/stl_config.h and add the
following snippet to it:
#ifdef __DJGPP__
# define __STL_NO_DRAND48
#endif
After that, your program should compile and link without this problem.
- Raw text -