shithub: cstory

ref: 4e50046d4b4c57f2b4d7bcf20dedcb913c266020
dir: /DoConfig/fltk/CMake/install-symlinks.cmake.in/

View raw version

# On unix create backward compatibility symlinks
if(NOT EXISTS $ENV{DESTDIR}@PREFIX_INCLUDE@/Fl)
   EXECUTE_PROCESS(COMMAND ln -s FL Fl
      WORKING_DIRECTORY $ENV{DESTDIR}@PREFIX_INCLUDE@
      )
endif(NOT EXISTS $ENV{DESTDIR}@PREFIX_INCLUDE@/Fl)

file(GLOB FLTK_HEADER_FILES $ENV{DESTDIR}@PREFIX_INCLUDE@/FL/*.H)
foreach(file ${FLTK_HEADER_FILES})
   GET_FILENAME_COMPONENT(nameWE ${file} NAME_WE)
   if(NOT EXISTS $ENV{DESTDIR}@PREFIX_INCLUDE@/FL/${nameWE}.h)
      EXECUTE_PROCESS(COMMAND ln -s ${nameWE}.H ${nameWE}.h
         WORKING_DIRECTORY $ENV{DESTDIR}@PREFIX_INCLUDE@/FL
      )
   endif(NOT EXISTS $ENV{DESTDIR}@PREFIX_INCLUDE@/FL/${nameWE}.h)
endforeach(file)