Reply to topic

Compile error with lsbg++ compiler

linello
Registered Member
Posts
56
Karma
0
OS

Compile error with lsbg++ compiler

Thu Mar 29, 2012 1:39 pm
Hi, I'm trying to compile my code which uses last Eigen 3.05 version.

It compiles smoothly under g++-4.5, clang and MSVC2008, but with lsbg++ (a compiler that I need to build an executable which works on every linux distro) I get this error, and can't go forward:


TriangularSolverMatrix.h:215: error: there are no arguments to ‘alloca’ that depend on a template parameter, so a declaration of ‘alloca’ must be available

(I've posted the code on pastebin http://pastebin.com/eshCyfbf )

Adding -fpermissive doesn't help.
User avatar ggael
Moderator
Posts
2206
Karma
15
OS
that mean alloca is not supported by lsbg++. Is there a way to detect this compiler from a predefined preprocessor token?

In the meantime you can compile with:

-DEIGEN_ALLOCA=aligned_malloc

(I did not try, but this should work)
User avatar ggael
Moderator
Posts
2206
Karma
15
OS
btw what lsbg++ is? a strict variant of g++ ? I cannot find any meaningful information on it.
linello
Registered Member
Posts
56
Karma
0
OS
I'm compiling my project using Qt and CMake and I want to create an executables that runs on a variety of linux distros.

I've read on some sites that lsbc++ should be a compiler based on g++ which incorporates the standard linux libraries.

For references:
http://labs.qt.nokia.com/2009/06/02/dep ... -gnulinux/
http://lists.trolltech.com/qt-interest/ ... 925-0.html

P.S.
Unfortunately that definitions doesn't work :(
User avatar ggael
Moderator
Posts
2206
Karma
15
OS
using

-DEIGEN_ALLOCA=aligned_malloc

works for me.

What's the effect of -DEIGEN_ALLOCA=aligned_malloc for you ?

 
Reply to topic

Bookmarks



Who is online

Registered users: AElfwine, alake, anditosan, Artmessiah, Baidu [Spider], Bing [Bot], edmael, Exabot [Bot], garthecho, geaplanet, Google [Bot], google01103, Horus, inksi, Joif, ken300, La Ninje, lazyit, pedrorodriguez, pvonz, thalesgava, tienhung, VP1986, Yahoo [Bot]