Hello QuantLib community
I'm building my project on QuantLib1.7.1 QuantLibAddin 1.7 On Windows, everything is fine, my code can be compiled and run. But on Mac, compile passed, on running, there 'Bus error 10', and when I debug, it points to 'libQuantLib.0.dylib','boost::math::lanczos::lanczos17m64' with 'EXEC_BAD_ACCESS' error.
I googled around, it seems it has something to do with CXXFLAGS The thing is my project depends on another library which uses c++11 on Mac and Linux, but not on Windows. So on Mac and Linux, I have to use c++11 flag. What are my options in this situation? Thanks! Regards Jerry ------------------------------------------------------------------------------ Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San Francisco, CA to explore cutting-edge tech and listen to tech luminaries present their vision of the future. This family event has something for everyone, including kids. Get more information and register today. http://sdm.link/attshape _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Hi Jerry,
I think compiling QuantLib with C++11 will solve the boost issue, i.e. configure it with something like ./configure CXXFLAGS="-std=c++11 -g -O2 -Wno-deprecated-declarations" (... your other options, if any ...) The last flag silences a lot of warnings showing up because auto_ptr is deprecated in C++11. Also, here are two links which might be of interest for you in this context. http://quantlib.10058.n7.nabble.com/c-0x-td14280.html https://sourceforge.net/p/quantlib/mailman/message/33394785/ Best Regards Peter On 9 July 2016 at 15:50, Jerry Jin <[hidden email]> wrote: > Hello QuantLib community > > I'm building my project on QuantLib1.7.1 QuantLibAddin 1.7 > > On Windows, everything is fine, my code can be compiled and run. > > But on Mac, compile passed, on running, there 'Bus error 10', and when I > debug, it points to > 'libQuantLib.0.dylib','boost::math::lanczos::lanczos17m64' with > 'EXEC_BAD_ACCESS' error. > > I googled around, it seems it has something to do with CXXFLAGS > > The thing is my project depends on another library which uses c++11 on Mac > and Linux, but not on Windows. So on Mac and Linux, I have to use c++11 > flag. > > What are my options in this situation? > > Thanks! > > Regards > Jerry > > ------------------------------------------------------------------------------ > Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San > Francisco, CA to explore cutting-edge tech and listen to tech luminaries > present their vision of the future. This family event has something for > everyone, including kids. Get more information and register today. > http://sdm.link/attshape > _______________________________________________ > QuantLib-users mailing list > [hidden email] > https://lists.sourceforge.net/lists/listinfo/quantlib-users > ------------------------------------------------------------------------------ Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San Francisco, CA to explore cutting-edge tech and listen to tech luminaries present their vision of the future. This family event has something for everyone, including kids. Get more information and register today. http://sdm.link/attshape _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Thanks a lot Peter! I followed your instructions and re-compiled QuantLib, now I can run my project on Mac with no error. I read some google search result regarding this, and changed CXXFLAGS to -stdlib=libc++ The configure step passed, but there was error at compile Thanks again! Regards Jerry On Sun, Jul 10, 2016 at 8:42 PM, Peter Caspers <[hidden email]> wrote: Hi Jerry, ------------------------------------------------------------------------------ Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San Francisco, CA to explore cutting-edge tech and listen to tech luminaries present their vision of the future. This family event has something for everyone, including kids. Get more information and register today. http://sdm.link/attshape _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
That’s great, Jerry. If you have another minute, please fill the poll about your MSVC version here
Kind Regards Peter
------------------------------------------------------------------------------ Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San Francisco, CA to explore cutting-edge tech and listen to tech luminaries present their vision of the future. This family event has something for everyone, including kids. Get more information and register today. http://sdm.link/attshape _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Hi Peter I already did the other day, I'm using VS2012 for windows project, XCode 5 on Mac, gcc that comes with centos 7 Regards Jerry On Sun, Jul 10, 2016 at 11:48 PM, Peter Caspers <[hidden email]> wrote:
------------------------------------------------------------------------------ Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San Francisco, CA to explore cutting-edge tech and listen to tech luminaries present their vision of the future. This family event has something for everyone, including kids. Get more information and register today. http://sdm.link/attshape _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Free forum by Nabble | Edit this page |