cmake_modules/FindSDL2_ttf.cmake
changeset 11657 ae6706411b24
parent 9677 71626318f80e
child 12383 e3d9abcc427a
equal deleted inserted replaced
11656:227718170097 11657:ae6706411b24
    72 endif()
    72 endif()
    73 
    73 
    74 set(SDL2_TTF_LIBRARIES ${SDL2_TTF_LIBRARY})
    74 set(SDL2_TTF_LIBRARIES ${SDL2_TTF_LIBRARY})
    75 set(SDL2_TTF_INCLUDE_DIRS ${SDL2_TTF_INCLUDE_DIR})
    75 set(SDL2_TTF_INCLUDE_DIRS ${SDL2_TTF_INCLUDE_DIR})
    76 
    76 
       
    77 if(BUILD_ENGINE_JS)
       
    78     set(SDL2_TTF_LIBRARY "sdl2_ttf_emscripten_internal")
       
    79     set(SDL2_TTF_LIBRARIES "sdl2_ttf_emscripten_internal")
       
    80     set(SDL2_TTF_INCLUDE_DIRS "${CMAKE_SYSTEM_INCLUDE_PATH}/SDL")
       
    81 endif()
       
    82 
    77 include(FindPackageHandleStandardArgs)
    83 include(FindPackageHandleStandardArgs)
    78 
    84 
    79 FIND_PACKAGE_HANDLE_STANDARD_ARGS(SDL2_ttf
    85 FIND_PACKAGE_HANDLE_STANDARD_ARGS(SDL2_ttf
    80                                   REQUIRED_VARS SDL2_TTF_LIBRARIES SDL2_TTF_INCLUDE_DIRS
    86                                   REQUIRED_VARS SDL2_TTF_LIBRARIES SDL2_TTF_INCLUDE_DIRS
    81                                   VERSION_VAR SDL2_TTF_VERSION_STRING)
    87                                   VERSION_VAR SDL2_TTF_VERSION_STRING)