From 1e7d4ef233d0508c8754603b1b93df3885753937 Mon Sep 17 00:00:00 2001 From: Summer G Stapleton Date: Thu, 29 Nov 2018 17:07:38 -0700 Subject: [PATCH] Adding remaining requirements to build the eal.cpp --- CMakeLists.txt | 4 +++- include/eal.h | 14 ++++++++++++++ src/eal.cpp | 6 ++++-- 3 files changed, 21 insertions(+), 3 deletions(-) create mode 100644 include/eal.h diff --git a/CMakeLists.txt b/CMakeLists.txt index e22a944..3fd1f58 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -20,12 +20,14 @@ set(CMAKE_CXX_STANDARD 11) # Library setup add_library(usgsephem SHARED src/TestObject.cpp + src/eal.cpp ) set_target_properties(usgsephem PROPERTIES VERSION ${PROJECT_VERSION} SOVERSION 1 ) -set(EPHEM_INCLUDE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/include") +set(EPHEM_INCLUDE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/include/" + "${CMAKE_CURRENT_SOURCE_DIR}/include/json") target_include_directories(usgsephem PUBLIC "${EPHEM_INCLUDE_DIRS}" diff --git a/include/eal.h b/include/eal.h new file mode 100644 index 0000000..72e8ef3 --- /dev/null +++ b/include/eal.h @@ -0,0 +1,14 @@ +#ifndef eal_H +#define eal_H + +#include + +class eal { + +public: + + std::string constructStateFromIsd(const std::string positionRotationData) const; + +}; + +#endif diff --git a/src/eal.cpp b/src/eal.cpp index a8b101a..6f2729f 100644 --- a/src/eal.cpp +++ b/src/eal.cpp @@ -1,11 +1,13 @@ +#include "eal.h" + #include +#include using json = nlohmann::json; -std::string eal::constructStateFromIsd(const std::string positionRotationData) const -{ +std::string eal::constructStateFromIsd(const std::string positionRotationData) const { // Parse the position and rotation data from isd json isd = json::parse(positionRotationData); json state; -- GitLab