Skip to content
  • Xavier Leroy's avatar
    Remove temporary .o files after linking (#36) · a674c56d
    Xavier Leroy authored
    When -c is not given, .o files are now generated in /tmp, but they are still not erased.
    
    This commit uses an "at_exit" action to erase those temporary .o files before CompCert exits.
    
    Using at_exit is easier to implement than explicit erasure (like we do for other temporary files), yet should not result in temporary files lingering in /tmp longer than strictly necessary, since the call to the linker is the last thing that CompCert does before exiting, hence temporary .o files are erased just after the linker returns.
    a674c56d