Bug 58043 - truncated files left over?
Summary: truncated files left over?
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
3.6.4.3 release
Hardware: All Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-12-09 12:59 UTC by Lionel Elie Mamane
Modified: 2024-12-13 05:56 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Lionel Elie Mamane 2012-12-09 12:59:45 UTC
In my libreoffice-3-6 tree, after a "make" aborted because not enough space on hard disk, a subsequent "make" (after freeing enough space on the disk) fails with errors such as:


terminate called after throwing an instance of 'CppUnit::DynamicLibraryManagerException'
  what():  Failed to load dynamic library: /home/master/src/libreoffice/workdirs/libreoffice-3.6/workdir/unxlngx6/LinkTarget/CppunitTest/libtest_filter_tiff_test.so


terminate called after throwing an instance of 'CppUnit::DynamicLibraryManagerException'
  what():  Failed to load dynamic library: /home/master/src/libreoffice/workdirs/libreoffice-3.6/workdir/unxlngx6/LinkTarget/CppunitTest/libtest_filter_tga_test.so


terminate called after throwing an instance of 'CppUnit::DynamicLibraryManagerException'
  what():  Failed to load dynamic library: /home/master/src/libreoffice/workdirs/libreoffice-3.6/workdir/unxlngx6/LinkTarget/CppunitTest/libtest_hwpfilter_test_hwpfilter.so


My presumption is that these files (or a .o file contained in them) were created, but left truncated after the "ENOSPC" error. When the build ofa file fails after it has been partially written to disk, it should be deleted, else make will never try to remake it.

Ideally the compiler / linker / ... should do that, but if it does not, we can wrap each call to a compiler / linker / ... in something like

 set -e; $(CC) "$<" || ( RET=$?; rm -f "$<"; exit $? )
Comment 1 Joel Madero 2013-07-02 05:41:15 UTC
@Lionel - marking as NEW as it's you, if this problem does not persist or you want independent confirmation please let us know and someone from QA will attempt to reproduce
Comment 2 QA Administrators 2015-04-01 14:41:44 UTC Comment hidden (obsolete)
Comment 3 tommy27 2016-04-16 07:28:01 UTC Comment hidden (obsolete)
Comment 4 QA Administrators 2017-05-22 13:25:33 UTC Comment hidden (obsolete)
Comment 5 Jean-Baptiste Faure 2017-08-15 17:07:29 UTC
Hi Lionel,

Does "make distclean" fix the problem?

Best regards. JBF
Comment 6 Lionel Elie Mamane 2017-08-16 08:05:55 UTC
(In reply to Lionel Elie Mamane from comment #0)
>  set -e; $(CC) "$<" || ( RET=$?; rm -f "$<"; exit $? )

That should be:

set -e; $(CC) "$<" || ( RET=$?; rm -f "$<"; exit $RET )

(In reply to Jean-Baptiste Faure from comment #5)
> Does "make distclean" fix the problem?

Four and a half years later, I don't have a copy of the corrupted build tree to test. However, since the problem is truncated output files, my prediction is that yes, even "make clean" is enough.

I still stand on my solution, as corrected above.
Comment 7 QA Administrators 2018-08-17 02:37:57 UTC Comment hidden (obsolete)
Comment 8 QA Administrators 2020-08-17 04:23:18 UTC Comment hidden (obsolete)
Comment 9 QA Administrators 2022-08-18 03:41:19 UTC Comment hidden (obsolete)
Comment 10 QA Administrators 2024-08-18 03:16:10 UTC Comment hidden (obsolete)
Comment 11 BogdanB 2024-12-13 05:56:32 UTC
I think we can close this after all these years, if not reproduced anymore.