Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix windows tests #5

Closed
wants to merge 3 commits into from
Closed

Fix windows tests #5

wants to merge 3 commits into from

Conversation

talregev
Copy link
Owner

@talregev talregev commented Jun 30, 2023

Fix windows tests:

  1. compile with ninja
  2. Add fix for compilation in Visual Studio. This seems to be a weird issue with how size_t is interpreted since the multiple symbols defined error comes from additional declarations of std::map<Key, size_t>. This might be a bug in MSVC 16. from Fix Windows Tests borglab/gtsam#1553
  3. GTSAM_EXPORT on functions.
  4. GTSAM_EXPORT on nested structs / classes.

@talregev
Copy link
Owner Author

gtsamDebug.lib(gtsamDebug.dll) : error LNK2005: "public: unsigned __int64 __cdecl std::_Tree<class std::_Tmap_traits<unsigned __int64,unsigned __int64,struct std::less,class std::allocator<struct std::pair<unsigned __int64 const ,unsigned __int64> >,0> >::size(void)const " (?size@?$_Tree@V?$_Tmap_traits@_K_KU?$less@_K@std@@v?$allocator@U?$pair@$$CB_K_K@std@@@2@$0A@@std@@@std@@QEBA_KXZ) already defined in LPInitSolver.cpp.obj

@talregev
Copy link
Owner Author

testBasisFactors.cpp.obj : error LNK2019: unresolved external symbol "class Eigen::Matrix<double,-1,-1,0,-1,-1> __cdecl gtsam::kroneckerProductIdentity(unsigned __int64,class Eigen::Matrix<double,1,-1,1,1,-1> const &)" (?kroneckerProductIdentity@gtsam@@ya?AV?$Matrix@N$0?0$0?0$0A@$0?0$0?0@Eigen@@_KAEBV?$Matrix@N$00$0?0$00$00$0?0@3@@z) referenced in function "protected: void __cdecl gtsam::Basis::VectorDerivativeFunctor::calculateJacobian(void)" (?calculateJacobian@VectorDerivativeFunctor@?$Basis@VChebyshev2@gtsam@@@gtsam@@IEAAXXZ)

@talregev
Copy link
Owner Author

testChebyshev2.cpp.obj : error LNK2019: unresolved external symbol "public: static class gtsam::Pose3 __cdecl gtsam::Pose3::ChartAtOrigin::Retract(class Eigen::Matrix<double,6,1,0,6,1> const &,class gtsam::OptionalJacobian<6,6>)" (?Retract@ChartAtOrigin@Pose3@gtsam@@sa?AV23@AEBV?$Matrix@N$05$00$0A@$05$00@Eigen@@v?$OptionalJacobian@$05$05@3@@z) referenced in function "public: virtual void __cdecl Chebyshev2InterpolatePose3Test::run(class TestResult &)" (?run@Chebyshev2InterpolatePose3Test@@UEAAXAEAVTestResult@@@z)

@talregev
Copy link
Owner Author

testSignatureParser.cpp.obj : error LNK2019: unresolved external symbol "public: static class std::optional<class std::vector<class std::vector<double,class std::allocator >,class std::allocator<class std::vector<double,class std::allocator > > > > __cdecl gtsam::SignatureParser::Parse(class std::basic_string<char,struct std::char_traits,class std::allocator > const &)" (?Parse@SignatureParser@gtsam@@sa?AV?$optional@V?$vector@V?$vector@NV?$allocator@N@std@@@std@@v?$allocator@V?$vector@NV?$allocator@N@std@@@std@@@2@@std@@@std@@aebv?$basic_string@DU?$char_traits@D@std@@v?$allocator@D@2@@4@@z) referenced in function "public: virtual void __cdecl SimpleParserSimpleTest::run(class TestResult &)" (?run@SimpleParserSimpleTest@@UEAAXAEAVTestResult@@@z)

@talregev
Copy link
Owner Author

testOrdering.cpp.obj : error LNK2019: unresolved external symbol "public: class gtsam::Ordering & __cdecl gtsam::Ordering::operator+=(class std::vector<unsigned __int64,class std::allocator > &)" (??YOrdering@gtsam@@QEAAAEAV01@AEAV?$vector@_KV?$allocator@_K@std@@@std@@@z) referenced in function "public: virtual void __cdecl OrderingAppendVectorTest::run(class TestResult &)" (?run@OrderingAppendVectorTest@@UEAAXAEAVTestResult@@@z)

@talregev
Copy link
Owner Author

I don't know yet how to fix:
gtsamDebug.lib(gtsamDebug.dll) : error LNK2005: "public: class Eigen::Matrix<double,-1,1,0,-1,1> __cdecl gtsam::NoiseModelFactorN::evaluateError(class gtsam::Pose3 const &,class Eigen::Matrix<double,-1,-1,0,-1,-1> &)const " (?evaluateError@?$NoiseModelFactorN@VPose3@gtsam@@@gtsam@@qeba?AV?$Matrix@N$0?0$00$0A@$0?0$00@Eigen@@AEBVPose3@2@AEAV?$Matrix@N$0?0$0?0$0A@$0?0$0?0@4@@z) already defined in testImuFactor.cpp.obj

@talregev
Copy link
Owner Author

talregev commented Jun 30, 2023

I don't know yet how to fix:
gtsamDebug.lib(gtsamDebug.dll) : error LNK2005: "public: class Eigen::Matrix<double,-1,1,0,-1,1> __cdecl gtsam::NoiseModelFactorN::evaluateError(class gtsam::Pose3 const &)const " (?evaluateError@?$NoiseModelFactorN@VPose3@gtsam@@@gtsam@@qeba?AV?$Matrix@N$0?0$00$0A@$0?0$00@Eigen@@AEBVPose3@2@@z) already defined in testImuFactor.cpp.obj

@talregev talregev force-pushed the TalR/fix/windows-tests branch 5 times, most recently from b198286 to 51c26ce Compare June 30, 2023 14:55
@talregev
Copy link
Owner Author

gtsamDebug.lib(gtsamDebug.dll) : error LNK2005: "public: __cdecl std::vector<unsigned __int64,class std::allocator >::vector<unsigned __int64,class std::allocator >(class std::initializer_list,class std::allocator const &)" (??0?$vector@_KV?$allocator@_K@std@@@std@@qeaa@V?$initializer_list@_K@1@AEBV?$allocator@_K@1@@z) already defined in testSymbolicConditional.cpp.obj

- GTSAM_EXPORT on functions.
- GTSAM_EXPORT on nested struts / classes.
@talregev talregev closed this Jun 30, 2023
@talregev talregev deleted the TalR/fix/windows-tests branch June 30, 2023 21:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant