After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 750334 - gnome-documents-3.16.2: failure to build parallel
gnome-documents-3.16.2: failure to build parallel
Status: RESOLVED OBSOLETE
Product: gnome-documents
Classification: Core
Component: general
3.16.x
Other Linux
: Normal normal
: ---
Assigned To: GNOME documents maintainer(s)
GNOME documents maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2015-06-03 11:37 UTC by kobboi
Modified: 2015-09-18 17:02 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
proposed patch (736 bytes, patch)
2015-06-13 18:26 UTC, Alexandre Rostovtsev
reviewed Details | Review

Description kobboi 2015-06-03 11:37:18 UTC
/usr/bin/install: cannot create regular file ‘/var/tmp/portage/gnome-extra/gnome-documents-3.16.2/image//usr/share/gnome-documents/js/path.js’: File exists
Makefile:899: recipe for target 'install-nodist_jsDATA' failed

- Occurs with varying probability when building with -j4
- Has not yet occurred when building with -j1
Comment 1 Pacho Ramos 2015-06-13 16:29:25 UTC
The full build.log is at:
https://549570.bugs.gentoo.org/attachment.cgi?id=403338
Comment 2 Alexandre Rostovtsev 2015-06-13 18:08:07 UTC
So looking at the output:

 /usr/lib/portage/python2.7/ebuild-helpers/xattr/install -c -m 644 application.js changeMonitor.js documents.js edit.js embed.js errorBox.js main.js mainBooks.js mainToolbar.js mainWindow.js manager.js miners.js notifications.js password.js places.js presentation.js preview.js properties.js query.js search.js searchbar.js selections.js sharing.js shellSearchProvider.js trackerController.js trackerUtils.js utils.js view.js windowMode.js path.js '/var/tmp/portage/gnome-extra/gnome-documents-3.16.2/image//usr/share/gnome-documents/js/'
 /usr/lib/portage/python2.7/ebuild-helpers/xattr/install -c -m 644 GdPrivate-1.0.gir '/var/tmp/portage/gnome-extra/gnome-documents-3.16.2/image//usr/share/gnome-documents/gir-1.0'
 /bin/mkdir -p '/var/tmp/portage/gnome-extra/gnome-documents-3.16.2/image//usr/share/gnome-documents/js/'
 /usr/lib/portage/python2.7/ebuild-helpers/xattr/install -c -m 644 path.js config.js '/var/tmp/portage/gnome-extra/gnome-documents-3.16.2/image//usr/share/gnome-documents/js/'
 /bin/mkdir -p '/var/tmp/portage/gnome-extra/gnome-documents-3.16.2/image//usr/share/gnome-documents'
/usr/bin/install: cannot create regular file ‘/var/tmp/portage/gnome-extra/gnome-documents-3.16.2/image//usr/share/gnome-documents/js/path.js’: File exists

It seems we are installing path.js two times. And in GNU install I believe there is a race condition, where the destination path is first stat-ed to see if it exists, and it it doesn't exist, it's opened in O_EXCL mode.

So we have the following scenario:

* install #1 stats $DESTDIR//usr/share/gnome-documents/js/path.js
* install #2 stats $DESTDIR//usr/share/gnome-documents/js/path.js
* install #1 opens $DESTDIR//usr/share/gnome-documents/js/path.js in O_EXCL mode
* install #2 opens $DESTDIR//usr/share/gnome-documents/js/path.js in O_EXCL mode → error


Reproducing this reliably probably requires either a slow file system (nfs) or slow storage (not ssd).
Comment 3 Alexandre Rostovtsev 2015-06-13 18:26:47 UTC
Created attachment 305217 [details] [review]
proposed patch
Comment 4 Bastien Nocera 2015-09-18 16:33:56 UTC
Review of attachment 305217 [details] [review]:

All the JavaScript is now in a GResource, I'm guess this isn't a problem anymore?
Comment 5 Cosimo Cecchi 2015-09-18 17:01:50 UTC
Yeah this should be obsolete with the package.js port that Alessandro and Debarshi did this cycle.
Closing as such, feel free to reopen if it's still a problem with Documents 3.17.90 or later.