www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1999/05/08/15:00:25

From: khan AT xraylith DOT wisc DOT edu (Mumit Khan)
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Problems with random_shuffle() ? __STL_NO_DRAND48
Date: 8 May 1999 18:28:09 GMT
Organization: Center for X-ray Lithography, UW-Madison
Lines: 39
Message-ID: <7h1vnp$g5i$1@news.doit.wisc.edu>
References: <3733F0A8 DOT 9E09BFF3 AT daidun DOT kaist DOT ac DOT kr>
NNTP-Posting-Host: modi.xraylith.wisc.edu
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

In article <3733F0A8 DOT 9E09BFF3 AT daidun DOT kaist DOT ac DOT kr>,
Ahn Ki-yung  <kyagrd AT daidun DOT kaist DOT ac DOT kr> wrote:
>If i make a list<string> and try to random shuffle these error messages come.
>==============================================================================
>n function `void __random_shuffle<basic_string<char,string_ ....and so on to long :-)
>e:/djgpp/lang/cxx/stl_algo.h(617) Error: `lrand48' undeclared (first use this function)
>e:/djgpp/lang/cxx/stl_algo.h(617) Error: (Each undeclared identifier is reported
>                                                            only once
>e:/djgpp/lang/cxx/stl_algo.h(617) Error: for each function it appears in.)
>There were some errors
>==============================================================================
>
>So i opened stl_algo.h and the code was like this
>

Just patch stl_config.h file to tell it not to use l/drand48 for djgpp
and you're all set.

--- stl_config.h.~1     Sat May  8 13:21:36 1999
+++ stl_config.h        Sat May  8 13:22:12 1999
@@ -138,6 +138,10 @@
 #   define __STL_USE_NAMESPACES
 # endif
 
+# if defined(__DJGPP__)
+#   define __STL_NO_DRAND48
+# endif
+
 # if defined(_MSC_VER)
 #   if _MSC_VER > 1000
 #     include <yvals.h>


The djgpp/egcs (or gcc) maintainers should send this to Matthew Auster at 
SGI (stl AT sgi DOT com) for inclusion. 

Regards,
Mumit

- Raw text -


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