Dear Users,

I am trying to create a Quantlib 1.8 package in msys2 mingw64.
However, something goes wrong during package creation.


To create the package, I have adapted PKGBUILD and patch file from
MINGW-Packages repo., and I use the following command:

MINGW_INSTALLS=mingw64 makepkg-mingw -sLf


Package creation fails during the build phase when compiling the
'test-suite' component of Quantlib.

The build log (cf. end of email) shows that failure occurs
when generating 'quantlib-test-suite.exe' executable as
the linker cannot find some symbols.
It turns out undefined references are from 'boost_thread' and
'boost_system' libraries.

I am not sure why the build behaves this way, or how to solve it cleanly.

Any help would be appreciated.


Kind Regards,
--
Constantinos



-- Build log excerpt --
libtool: link: x86_64-w64-mingw32-g++ -march=x86-64 -mtune=generic -O2
-pipe -pipe -o .libs/quantlib-test-suite.exe quantlibtestsuite.o
americanoption.o amortizingbond.o array.o asianoptions.o assetswap.o
autocovariances.o barrieroption.o binaryoption.o basketoption.o
batesmodel.o bermudanswaption.o blackdeltacalculator.o blackformula.o
bonds.o brownianbridge.o businessdayconventions.o calendars.o capfloor.o
capflooredcoupon.o cashflows.o catbonds.o cdo.o cdsoption.o chooseroption.o
cliquetoption.o cms.o commodityunitofmeasure.o compoundoption.o
convertiblebonds.o covariance.o creditdefaultswap.o creditriskplus.o
curvestates.o dates.o daycounters.o defaultprobabilitycurves.o
digitalcoupon.o digitaloption.o distributions.o dividendoption.o
doublebarrieroption.o doublebinaryoption.o europeanoption.o everestoption.o
exchangerate.o extendedtrees.o extensibleoptions.o fastfouriertransform.o
fdheston.o fdmlinearop.o forwardoption.o functions.o garch.o
gaussianquadratures.o gjrgarchmodel.o gsr.o hestonmodel.o hestonslvmodel.o
himalayaoption.o hybridhestonhullwhiteprocess.o inflation.o
inflationcapfloor.o inflationcapflooredcoupon.o inflationcpibond.o
inflationcpicapfloor.o inflationcpiswap.o inflationvolatility.o
instruments.o integrals.o interestrates.o interpolations.o jumpdiffusion.o
libormarketmodel.o libormarketmodelprocess.o linearleastsquaresregression.o
lookbackoptions.o lowdiscrepancysequences.o margrabeoption.o marketmodel.o
marketmodel_cms.o marketmodel_smm.o marketmodel_smmcapletalphacalibration.o
marketmodel_smmcapletcalibration.o marketmodel_smmcaplethomocalibration.o
markovfunctional.o matrices.o mclongstaffschwartzengine.o mersennetwister.o
money.o noarbsabr.o nthtodefault.o numericaldifferentiation.o observable.o
ode.o operators.o optimizers.o optionletstripper.o overnightindexedswap.o
pagodaoption.o partialtimebarrieroption.o pathgenerator.o period.o
piecewiseyieldcurve.o piecewisezerospreadedtermstructure.o quantooption.o
quotes.o rangeaccrual.o riskneutraldensitycalculator.o riskstats.o
rngtraits.o rounding.o sampledcurve.o schedule.o shortratemodels.o
solvers.o spreadoption.o stats.o swap.o swapforwardmappings.o swaption.o
swaptionvolatilitycube.o swaptionvolatilitymatrix.o swingoption.o
termstructures.o timeseries.o transformedgrid.o tqreigendecomposition.o
tracing.o twoassetbarrieroption.o twoassetcorrelationoption.o utilities.o
variancegamma.o varianceoption.o varianceswaps.o volatilitymodels.o vpp.o
zabr.o  ./.libs/libUnitMain.a ../ql/.libs/libQuantLib.dll.a
-lboost_unit_test_framework-mt -L/mingw64/lib
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text$_ZN5boost6detail11thread_dataINS_3_bi6bind_tIiPFiRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEENS2_5list1INS2_5valueIS9_EEEEEEED1Ev[_ZN5boost6detail11thread_dataINS_3_bi6bind_tIiPFiRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEENS2_5list1INS2_5valueIS9_EEEEEEED1Ev]+0x33):
undefined reference to
`boost::detail::thread_data_base::~thread_data_base()'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text.startup+0x76a): undefined
reference to `boost::thread::hardware_concurrency()'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text.startup+0x1d77): undefined
reference to `boost::thread::start_thread_noexcept()'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text.startup+0x22f1): undefined
reference to `boost::detail::thread_data_base::~thread_data_base()'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text.startup+0x4295): undefined
reference to `boost::system::generic_category()'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text.startup+0x429a): undefined
reference to `boost::system::generic_category()'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text.startup+0x429f): undefined
reference to `boost::system::system_category()'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text$_ZN5boost6detail11thread_dataINS_3_bi6bind_tIiPFiRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEENS2_5list1INS2_5valueIS9_EEEEEEED0Ev[_ZN5boost6detail11thread_dataINS_3_bi6bind_tIiPFiRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEENS2_5list1INS2_5valueIS9_EEEEEEED0Ev]+0x2e):
undefined reference to
`boost::detail::thread_data_base::~thread_data_base()'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text$_ZN5boost16thread_exceptionC2EiPKc[_ZN5boost16thread_exceptionC2EiPKc]+0x19):
undefined reference to `boost::system::system_category()'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text$_ZN5boost12thread_groupD1Ev[_ZN5boost12thread_groupD1Ev]+0x4d):
undefined reference to `boost::thread::detach()'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text$_ZN5boost7movelib10unique_ptrINS_6threadENS0_14default_deleteIS2_EEED1Ev[_ZN5boost7movelib10unique_ptrINS_6threadENS0_14default_deleteIS2_EEED1Ev]+0x12):
undefined reference to `boost::thread::detach()'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text$_ZN5boost12thread_group8join_allEv[_ZN5boost12thread_group8join_allEv]+0x4ad):
undefined reference to `boost::thread::joinable() const'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text$_ZN5boost12thread_group8join_allEv[_ZN5boost12thread_group8join_allEv]+0x4c2):
undefined reference to `boost::thread::get_id() const'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text$_ZN5boost12thread_group8join_allEv[_ZN5boost12thread_group8join_allEv]+0x4cc):
undefined reference to `boost::this_thread::get_id()'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.text$_ZN5boost12thread_group8join_allEv[_ZN5boost12thread_group8join_allEv]+0x4e5):
undefined reference to `boost::thread::join_noexcept()'
quantlibtestsuite.o:quantlibtestsuite.cpp:(.rdata$.refptr._ZTVN5boost6detail16thread_data_baseE[.refptr._ZTVN5boost6detail16thread_data_baseE]+0x0):
undefined reference to `vtable for boost::detail::thread_data_base'
collect2.exe: error: ld returned 1 exit status
make[1]: *** [Makefile:1066: quantlib-test-suite.exe] Error 1
make[1]: Leaving directory
'/g/mingw-w64-quantlib-1.8.0/src/build-x86_64-w64-mingw32/test-suite'
make: *** [Makefile:594: all-recursive] Error 1
==> ERROR: A failure occurred in build().
    Aborting...
------------------------------------------------------------------------------
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
_______________________________________________
Msys2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/msys2-users

Reply via email to