diff --git a/gtsam/geometry/Point2.h b/gtsam/geometry/Point2.h index 74ea16638..31d89a39f 100644 --- a/gtsam/geometry/Point2.h +++ b/gtsam/geometry/Point2.h @@ -190,7 +190,7 @@ public: /// @} /// Streaming - friend std::ostream &operator<<(std::ostream &os, const Point2& p); + GTSAM_EXPORT friend std::ostream &operator<<(std::ostream &os, const Point2& p); private: diff --git a/gtsam/geometry/Point3.h b/gtsam/geometry/Point3.h index cf30bd1ff..510666bb2 100644 --- a/gtsam/geometry/Point3.h +++ b/gtsam/geometry/Point3.h @@ -204,7 +204,7 @@ namespace gtsam { /// @} /// Output stream operator - friend std::ostream &operator<<(std::ostream &os, const Point3& p); + GTSAM_EXPORT friend std::ostream &operator<<(std::ostream &os, const Point3& p); private: diff --git a/gtsam/geometry/Pose3.h b/gtsam/geometry/Pose3.h index 234e2cad6..4556f2200 100644 --- a/gtsam/geometry/Pose3.h +++ b/gtsam/geometry/Pose3.h @@ -291,7 +291,7 @@ namespace gtsam { static std::pair rotationInterval() { return std::make_pair(0, 2); } /// Output stream operator - friend std::ostream &operator<<(std::ostream &os, const Pose3& p); + GTSAM_EXPORT friend std::ostream &operator<<(std::ostream &os, const Pose3& p); private: /** Serialization function */ diff --git a/gtsam/geometry/Rot3.h b/gtsam/geometry/Rot3.h index 6adcd8a1b..9316ab33d 100644 --- a/gtsam/geometry/Rot3.h +++ b/gtsam/geometry/Rot3.h @@ -356,7 +356,7 @@ namespace gtsam { Vector quaternion() const; /// Output stream operator - friend std::ostream &operator<<(std::ostream &os, const Rot3& p); + GTSAM_EXPORT friend std::ostream &operator<<(std::ostream &os, const Rot3& p); private: /** Serialization function */ diff --git a/gtsam_unstable/nonlinear/ConcurrentFilteringAndSmoothing.h b/gtsam_unstable/nonlinear/ConcurrentFilteringAndSmoothing.h index 706ae2b65..71fe45b47 100644 --- a/gtsam_unstable/nonlinear/ConcurrentFilteringAndSmoothing.h +++ b/gtsam_unstable/nonlinear/ConcurrentFilteringAndSmoothing.h @@ -111,7 +111,7 @@ public: protected: - friend void synchronize(ConcurrentFilter& filter, ConcurrentSmoother& smoother); + GTSAM_UNSTABLE_EXPORT friend void synchronize(ConcurrentFilter& filter, ConcurrentSmoother& smoother); /** Default constructor */ ConcurrentSmoother() {}; diff --git a/gtsam_unstable/slam/serialization.h b/gtsam_unstable/slam/serialization.h index 08451fa0c..491299fe1 100644 --- a/gtsam_unstable/slam/serialization.h +++ b/gtsam_unstable/slam/serialization.h @@ -14,25 +14,25 @@ namespace gtsam { // Serialize/Deserialize a NonlinearFactorGraph -std::string serializeGraph(const NonlinearFactorGraph& graph); +GTSAM_EXPORT std::string serializeGraph(const NonlinearFactorGraph& graph); -NonlinearFactorGraph::shared_ptr deserializeGraph(const std::string& serialized_graph); +GTSAM_EXPORT NonlinearFactorGraph::shared_ptr deserializeGraph(const std::string& serialized_graph); -std::string serializeGraphXML(const NonlinearFactorGraph& graph, +GTSAM_EXPORT std::string serializeGraphXML(const NonlinearFactorGraph& graph, const std::string& name = "graph"); -NonlinearFactorGraph::shared_ptr deserializeGraphXML(const std::string& serialized_graph, +GTSAM_EXPORT NonlinearFactorGraph::shared_ptr deserializeGraphXML(const std::string& serialized_graph, const std::string& name = "graph"); // Serialize/Deserialize a Values -std::string serializeValues(const Values& values); +GTSAM_EXPORT std::string serializeValues(const Values& values); -Values::shared_ptr deserializeValues(const std::string& serialized_values); +GTSAM_EXPORT Values::shared_ptr deserializeValues(const std::string& serialized_values); -std::string serializeValuesXML(const Values& values, const std::string& name = "values"); +GTSAM_EXPORT std::string serializeValuesXML(const Values& values, const std::string& name = "values"); -Values::shared_ptr deserializeValuesXML(const std::string& serialized_values, +GTSAM_EXPORT Values::shared_ptr deserializeValuesXML(const std::string& serialized_values, const std::string& name = "values"); // Serialize to/from files @@ -40,21 +40,21 @@ Values::shared_ptr deserializeValuesXML(const std::string& serialized_values, // Filename arguments include path // Serialize -bool serializeGraphToFile(const NonlinearFactorGraph& graph, const std::string& fname); -bool serializeGraphToXMLFile(const NonlinearFactorGraph& graph, +GTSAM_EXPORT bool serializeGraphToFile(const NonlinearFactorGraph& graph, const std::string& fname); +GTSAM_EXPORT bool serializeGraphToXMLFile(const NonlinearFactorGraph& graph, const std::string& fname, const std::string& name = "graph"); -bool serializeValuesToFile(const Values& values, const std::string& fname); -bool serializeValuesToXMLFile(const Values& values, +GTSAM_EXPORT bool serializeValuesToFile(const Values& values, const std::string& fname); +GTSAM_EXPORT bool serializeValuesToXMLFile(const Values& values, const std::string& fname, const std::string& name = "values"); // Deserialize -NonlinearFactorGraph::shared_ptr deserializeGraphFromFile(const std::string& fname); -NonlinearFactorGraph::shared_ptr deserializeGraphFromXMLFile(const std::string& fname, +GTSAM_EXPORT NonlinearFactorGraph::shared_ptr deserializeGraphFromFile(const std::string& fname); +GTSAM_EXPORT NonlinearFactorGraph::shared_ptr deserializeGraphFromXMLFile(const std::string& fname, const std::string& name = "graph"); -Values::shared_ptr deserializeValuesFromFile(const std::string& fname); -Values::shared_ptr deserializeValuesFromXMLFile(const std::string& fname, +GTSAM_EXPORT Values::shared_ptr deserializeValuesFromFile(const std::string& fname); +GTSAM_EXPORT Values::shared_ptr deserializeValuesFromXMLFile(const std::string& fname, const std::string& name = "values"); } // \namespace gtsam