# sources which should be compiled into the library
SET( SRCS auv_slam_estimate.cpp  
          auv_slam_models.cpp
          auv_sparse_matrix.cpp
          auv_sparse_solver.cpp
          auv_ekf_slam.cpp
          auv_eif_slam.cpp  
          auv_seabed_slam.cpp
          auv_seabed_slam_models.cpp
          auv_seabed_ekf_slam.cpp  
          auv_seabed_eif_slam.cpp 
          recovery_cache.cpp
          auv_ekf_imu_slam.cpp
		  auv_seabed_ekf_imu_slam.cpp
          )

# Build the library on 'make'
ADD_LIBRARY( flounder SHARED ${SRCS} )

TARGET_LINK_LIBRARIES( flounder ${LAPACK_LIBRARY}
                                ${CHOLMOD_LIB}
                                libplankton::plankton )
TARGET_INCLUDE_DIRECTORIES(flounder INTERFACE $<INSTALL_INTERFACE:include/libflounder>)

# this should be kept in sync with the binary package name
# and be updated when the ABI (not just API) changes
SET_PROPERTY(TARGET flounder PROPERTY VERSION ${LIBFLOUNDER_VERSION})
SET_PROPERTY(TARGET flounder PROPERTY SOVERSION 1)
# Install the library on 'make install'
INSTALL(TARGETS flounder EXPORT LibFlounderTargets LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}")

