[LLVMdev] Building the CFE I get this error: there areno arguments to `lrand48'

Henrik Bach henrik_bach_llvm at hotmail.com
Sat Jan 22 07:47:40 PST 2005


Hi LLVM'ers,

Today, Anton Korobeynikov gave me the last keys to solve the rand48 problem 
I encountered and the hint just to move on, even if other compiling problems 
arises.

However, it seemed that the way I did it, this error was the last in the 
chain.

The next big question is: does it work? :)


Henrik.


----Original Message Follows----
From: Jeff Cohen <jeffc at jolt-lang.org>
Reply-To: jeffc at jolt-lang.org,        LLVM Developers Mailing List 
<llvmdev at cs.uiuc.edu>
To: LLVM Developers Mailing List <llvmdev at cs.uiuc.edu>
Subject: Re: [LLVMdev] Building the CFE I get this error: there 
areno	arguments to `lrand48'
Date: Fri, 14 Jan 2005 08:00:38 -0800

This sounds suspiciously like the problem I ran into with VC++, whose std 
implementation also includes _Distance. Could mingw have copied VC++ too 
closely? The fix with VC++ was to add a "using std::_Distance" line (or just 
"using namespace std".

Chris Lattner wrote:

>On Fri, 14 Jan 2005, Henrik Bach wrote:
>
>>when building the llvm cfe (3.4 derivative), for the mingw platform, I get 
>>this error: 'error: there are no arguments to `lrand48' that depend on a 
>>template parameter, so a declaration of `lrand48' must be available'.
>
>
>Hi Henrik,
>
>We haven't modified the GCC configure script or build system, so I don't 
>know what could have caused this. It's quite possible that the GCC snapshot 
>we are using isn't happy with mingw. In any case, I think it would be 
>better to ask on the mingw lists to get some idea of what to do about this.
>
>-Chris
>
>>------------------------
>>make[3]: Entering directory 
>>`/C/projects/build/MinGW/llvm-gcc-1-1/i686-pc-mingw32/libstdc++-v3/testsuite'
>>
>>`/C/projects/build/MinGW/llvm-gcc-1-1/i686-pc-mingw32/libstdc++-v3/scripts/testsuite_flags 
>>--build-cxx` -DHAVE_CONFIG_H -I. 
>>-I../../../../../../src/llvm-gcc-1/llvm-gcc/libstdc++-v3/testsuite -I.. 
>>-I/C/projects/build/MinGW/llvm-gcc-1-1/i686-pc-mingw32/libstdc++-v3/include/i686-pc-mingw32 
>>-I/C/projects/build/MinGW/llvm-gcc-1-1/i686-pc-mingw32/libstdc++-v3/include 
>>-I/C/projects/src/llvm-gcc-1/llvm-gcc/libstdc++-v3/libsupc++ -O2 -D__MINGW 
>>-DLLVM_ON_WIN32=1 -O2 -c -o testsuite_hooks.o 
>>../../../../../../src/llvm-gcc-1/llvm-gcc/libstdc++-v3/testsuite/testsuite_hooks.cc
>>
>>In file included from 
>>c:/projects/build/MinGW/llvm-gcc-1-1/i686-pc-mingw32/libstdc++-v3/include/algorithm:69,
>>
>>from 
>>c:/projects/build/MinGW/llvm-gcc-1-1/i686-pc-mingw32/libstdc++-v3/include/string:56,
>>
>>from 
>>c:/projects/build/MinGW/llvm-gcc-1-1/i686-pc-mingw32/libstdc++-v3/include/bits/locale_classes.h:47,
>>
>>from 
>>c:/projects/build/MinGW/llvm-gcc-1-1/i686-pc-mingw32/libstdc++-v3/include/locale:45,
>>
>>from 
>>../../../../../../src/llvm-gcc-1/llvm-gcc/libstdc++-v3/testsuite/testsuite_hooks.h:70,
>>
>>from 
>>../../../../../../src/llvm-gcc-1/llvm-gcc/libstdc++-v3/testsuite/testsuite_hooks.cc:31:
>>
>>c:/projects/build/MinGW/llvm-gcc-1-1/i686-pc-mingw32/libstdc++-v3/include/bits/stl_algo.h: 
>>In function `_Distance std::__random_number(_Distance)':
>>c:/projects/build/MinGW/llvm-gcc-1-1/i686-pc-mingw32/libstdc++-v3/include/bits/stl_algo.h:1616: 
>>error: there are no arguments to `lrand48' that depend on a template 
>>parameter, so a declaration of `lrand48' must be available
>>c:/projects/build/MinGW/llvm-gcc-1-1/i686-pc-mingw32/libstdc++-v3/include/bits/stl_algo.h:1616: 
>>error: (if you use `-fpermissive', G++ will accept your code, but allowing 
>>the use of an undeclared name is deprecated)
>>make[3]: *** [testsuite_hooks.o] Error 1
>>------------------------
>>
>>I use this command to build the cfe: 'make all'
>>
>>If I build the gcc 3.4.0 on the mingw platform I don't see such error. 
>>However the command to build is slightly different.
>>
>>
>>Any suggestions?
>>
>>Henrik.
>>
>>
>>P.S. In some cases when building on mingw I've noticed that libtool? calls 
>>cygpath:
>>
>>-----------------
>>../libtool: cygpath: command not found
>>-----------------
>>
>>
>>=============================================================
>>Henrik Bach
>>LLVM Open Source Developer
>>
>>e-mail: henrik_bach_llvm at hotmail.com
>>=============================================================
>>'Nothing is impossible; The impossible just takes longer time :)'
>>- Inventor of a new energy saver light bulp from Denmark.
>>
>>No software patents - Thank you Poland: 
>>http://www.nosoftwarepatents.com/en/m/intro/app0411.html
>>Got Freedom?
>>Software Freedom Day - 28th of August
>>http://www.softwarefreedomday.org/
>>=============================================================
>>
>>_________________________________________________________________
>>F� alle de nye og sjove ikoner med MSN Messenger 
>>http://messenger.msn.dk/
>>
>>_______________________________________________
>>LLVM Developers mailing list
>>LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu
>>http://mail.cs.uiuc.edu/mailman/listinfo/llvmdev
>>
>
>-Chris
>
>------------------------------------------------------------------------
>
>_______________________________________________
>LLVM Developers mailing list
>LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
>http://mail.cs.uiuc.edu/mailman/listinfo/llvmdev
>
>

_______________________________________________
LLVM Developers mailing list
LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
http://mail.cs.uiuc.edu/mailman/listinfo/llvmdev

_________________________________________________________________
Log på MSN Messenger direkte fra nettet  http://webmessenger.msn.com/




More information about the llvm-dev mailing list