Re: Re: quantlib-python compile error
Posted by
Luigi Ballabio on
URL: http://quantlib.414.s1.nabble.com/quantlib-python-compile-error-tp4088p4093.html
On 10/05/2005 05:35:03 PM, Brad wrote:
>
> ... I thought about where the "asm" comes from, and
> thought that maybe it is something to do with the preprocessing. So I
> ran the above g++ line, but with -E instead of -c.
>
> It seems that this is the offending bit:
> Volatility volatility() const;
> Real __asm__ __volatile__ ("" : : : "memory") const;
> Real rebate() const;
>
> Unfortunately, I have no idea why the preprocessor inserts that bit
> there. Is "barrier()" a macro somewhere?
Google suggests that it's a macro in the Linux kernel source. Why it
gets included beats me. Why the kernel developers don't know better
than defining macros with such generic names is beyond my wits.
Ranting aside, try modifying the source and adding
#ifdef barrier
#undef barrier
#endif
before the class is parsed.
Later,
Luigi
----------------------------------------
The nice thing about standards is that there are so many of them to
choose from.
-- Andrew S. Tanenbaum