share/hedgewars/Data/Fonts/CMakeLists.txt
changeset 9994 8455993a7a1b
parent 8443 2debc9b9f917
equal deleted inserted replaced
9993:76ad55807c24 9994:8455993a7a1b
     1 install(FILES
     1 set(FONTFILES
     2     DejaVuSans-Bold.ttf
     2     DejaVuSans-Bold.ttf
     3     wqy-zenhei.ttc
     3     wqy-zenhei.ttc)
     4     DESTINATION ${SHAREPATH}Data/Fonts)
     4 
       
     5 if (FONTS_DIRS)
       
     6     foreach(fontfile ${FONTFILES})
       
     7         set(missing 1)
       
     8         foreach(fontdir ${FONTS_DIRS})
       
     9             if (EXISTS "${fontdir}/${fontfile}")
       
    10                 message(STATUS "Fonts: Found ${fontfile} in ${fontdir}")
       
    11                 set(missing 0)
       
    12                 break()
       
    13             endif()
       
    14         endforeach(fontdir)
       
    15         if(missing)
       
    16             set(MISSINGFONTFILES ${MISSINGFONTFILES} ${fontfile})
       
    17             message(STATUS "Fonts: Could not find ${fontfile}, it will be installed")
       
    18         endif()
       
    19     endforeach(fontfile)
       
    20 else()
       
    21     set(MISSINGFONTFILES ${FONTFILES})
       
    22 endif()
       
    23 
       
    24 if (MISSINGFONTFILES)
       
    25     install(FILES ${MISSINGFONTFILES} DESTINATION ${SHAREPATH}Data/Fonts)
       
    26 endif()