Skip to content

Instantly share code, notes, and snippets.

@maxanier
Created September 30, 2018 20:15
Show Gist options
  • Save maxanier/3318bb1d00c73a935933f2272bd53df7 to your computer and use it in GitHub Desktop.
Save maxanier/3318bb1d00c73a935933f2272bd53df7 to your computer and use it in GitHub Desktop.
find_path(AMLOGIC_INCLUDE_DIR
NAMES codec.h
DOC "Amlogic include directory"
PATHS /opt/vero3/include /usr/local/include/amcodec /usr/include/amcodec /usr/include/)
mark_as_advanced(AMLOGIC_INCLUDE_DIR)
find_library(AMAVUTILS_LIBRARY
NAMES libamavutils.so
DOC "Path to Amlogic Audio Video Utils Library"
PATHS /usr/osmc/lib /usr/lib/aml_libs /usr/local/lib /usr/lib)
mark_as_advanced(AMAVUTILS_LIBRARY)
find_library(AMADEC_LIBRARY
NAMES libamadec.so
DOC "Path to Amlogic Audio Decoder Library"
PATHS /usr/osmc/lib /usr/lib/aml_libs /usr/local/lib /usr/lib)
mark_as_advanced(AMADEC_LIBRARY)
find_library(AMCODEC_LIBRARY
NAMES libamcodec.so
DOC "Path to Amlogic Video Codec Library"
PATHS /usr/osmc/lib /usr/lib/aml_libs /usr/local/lib /usr/lib)
mark_as_advanced(AMCODEC_LIBRARY)
include(${CMAKE_ROOT}/Modules/FindPackageHandleStandardArgs.cmake)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Amlogic DEFAULT_MSG AMLOGIC_INCLUDE_DIR AMCODEC_LIBRARY AMADEC_LIBRARY AMAVUTILS_LIBRARY)
set(AMLOGIC_LIBRARIES ${AMCODEC_LIBRARY} ${AMADEC_LIBRARY} ${AMAVUTILS_LIBRARY})
set(AMLOGIC_INCLUDE_DIRS ${AMLOGIC_INCLUDE_DIR})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment