- INSTALL(CODE "FILE(TIMESTAMP \"${CMAKE_CURRENT_SOURCE_DIR}/${file}\" py_time)")
- INSTALL(CODE "FILE(TIMESTAMP \"${CMAKE_INSTALL_PREFIX}/${path}/${file_we}.pyc\" pyc_time)")
- INSTALL(CODE "FILE(TIMESTAMP \"${CMAKE_INSTALL_PREFIX}/${path}/${file_we}.pyo\" pyo_time)")
+ INSTALL(CODE "FILE(TIMESTAMP \"${CMAKE_INSTALL_PREFIX}/${path}/${file_name}\" py_time)")
+ INSTALL(CODE "IF(EXISTS \"${CMAKE_INSTALL_PREFIX}/${path}/${file_we}.pyc\") \n FILE(TIMESTAMP \"${CMAKE_INSTALL_PREFIX}/${path}/${file_we}.pyc\" pyc_time) \n ELSE()\n SET(pyc_time 0) \n ENDIF() ")
+ INSTALL(CODE "IF(EXISTS \"${CMAKE_INSTALL_PREFIX}/${path}/${file_we}.pyo\") \n FILE(TIMESTAMP \"${CMAKE_INSTALL_PREFIX}/${path}/${file_we}.pyo\" pyo_time) \n ELSE()\n SET(pyo_time 0) \n ENDIF() ")