set (EXENAME custom_tao)

FILE (GLOB SRC_FILES "*.f90")

SET (LINK_FLAGS ${READLINE_LINK_FLAGS})

SET (LINK_LIBS
  tao 
  bmad
  sim_utils
  ${PLOT_LINK_LIBS}
  ${ACC_BMAD_LINK_LIBS}
)

IF (${CMAKE_SYSTEM_NAME} MATCHES "Darwin" AND $ENV{ACC_USE_MACPORTS} MATCHES "Y")
  link_directories(/opt/local/lib)
ENDIF ()

# If this is a conda build we must expand the library search
# with the lib folder
IF ($ENV{ACC_CONDA_BUILD})
  link_directories($ENV{ACC_CONDA_PATH}/lib)
ENDIF ()

IF ($ENV{ACC_PLOT_PACKAGE} MATCHES "plplot")
  IF (NOT ${MSYS})
  SET (SHARED_LINK_LIBS
    pangocairo-1.0
    cairo
    pango-1.0
    gobject-2.0
  )
  ENDIF ()
ENDIF ()
