mdl-sdk provides CMake targets:

  find_package(mdl CONFIG REQUIRED)
  target_link_libraries(main PRIVATE $<COMPILE_ONLY:mdl::mdl_sdk> ${CMAKE_DL_LIBS})

  # Or if you want to use only the MDL Core library:
  find_package(mdl CONFIG REQUIRED)
  target_link_libraries(main PRIVATE $<COMPILE_ONLY:mdl::mdl_core> ${CMAKE_DL_LIBS})
