Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 746590 - sci-geosciences/grass-7.8.3 fails to compile
Summary: sci-geosciences/grass-7.8.3 fails to compile
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: mario.haustein
URL:
Whiteboard:
Keywords: PATCH, PullRequest
Depends on:
Blocks:
 
Reported: 2020-10-04 19:28 UTC by Agostino Sarubbo
Modified: 2020-11-25 08:16 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log.xz (build.log.xz,130.78 KB, application/x-xz)
2020-10-04 19:28 UTC, Agostino Sarubbo
Details
grass-7.8-flock.patch (grass-7.8-flock.patch,577 bytes, patch)
2020-10-10 14:27 UTC, mario.haustein
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Agostino Sarubbo gentoo-dev 2020-10-04 19:28:25 UTC
https://blogs.gentoo.org/ago/2020/07/04/gentoo-tinderbox/

Issue: sci-geosciences/grass-7.8.3 fails to compile.
Discovered on: amd64 (internal ref: ci)
Comment 1 Agostino Sarubbo gentoo-dev 2020-10-04 19:28:29 UTC
Created attachment 663784 [details]
build.log.xz

build log and emerge --info (compressed because it exceeds attachment limit, use 'xzless' to read it)
Comment 2 Agostino Sarubbo gentoo-dev 2020-10-04 19:28:30 UTC
Possible context of error(s):

Error: x86_64-pc-linux-gnu-gcc -E        -I/var/tmp/portage/sci-geosciences/grass-7.8.3/work/grass-7.8.3/dist.x86_64-pc-linux-gnu/include -I/var/tmp/portage/sci-geosciences/grass-7.8.3/work/grass-7.8.3/dist.x86_64-pc-linux-gnu/include -D__GLIBC_HAVE_LONG_LONG: /var/tmp/portage/sci-geosciences/grass-7.8.3/work/grass-7.8.3/dist.x86_64-pc-linux-gnu/include/grass/gprojects.h:32:14: fatal error: ogr_srs_api.h: No such file or directory
/usr/bin/install: cannot change permissions of '/var/tmp/portage/sci-geosciences/grass-7.8.3/work/grass-7.8.3/dist.x86_64-pc-linux-gnu/docs/html/raster3d_layout.png': No such file or directory
Details: <[Errno 2] No such file or directory: 'r.in.png': 'r.in.png'>
Details: <[Errno 2] No such file or directory: 'r.in.lidar': 'r.in.lidar'>
Details: <[Errno 2] No such file or directory: 'v.in.lidar': 'v.in.lidar'>
Details: <[Errno 2] No such file or directory: 'r.out.png': 'r.out.png'>
Details: <[Errno 2] No such file or directory: 'v.out.postgis': 'v.out.postgis'>
Details: <[Errno 2] No such file or directory: 'r3.out.ascii': 'r3.out.ascii'>
Details: <[Errno 2] No such file or directory: 'm.nviz.image': 'm.nviz.image'>
Details: <[Errno 2] No such file or directory: 'r.viewshed': 'r.viewshed'>
Details: <[Errno 2] No such file or directory: 'r.terraflow': 'r.terraflow'>
Details: <[Errno 2] No such file or directory: 'r.surf.fractal': 'r.surf.fractal'>
Details: <[Errno 2] No such file or directory: 'v.buffer': 'v.buffer'>
Details: <[Errno 2] No such file or directory: 'i.zc': 'i.zc'>
Details: <[Errno 2] No such file or directory: 'i.fft': 'i.fft'>
Details: <[Errno 2] No such file or directory: 'i.ifft': 'i.ifft'>
Details: <[Errno 2] No such file or directory: 'i.atcorr': 'i.atcorr'>
Details: <[Errno 2] No such file or directory: 'r.in.png': 'r.in.png'>
Details: <[Errno 2] No such file or directory: 'r.in.lidar': 'r.in.lidar'>
Details: <[Errno 2] No such file or directory: 'v.in.lidar': 'v.in.lidar'>
Details: <[Errno 2] No such file or directory: 'r.out.png': 'r.out.png'>
Details: <[Errno 2] No such file or directory: 'v.out.postgis': 'v.out.postgis'>
Details: <[Errno 2] No such file or directory: 'r3.out.ascii': 'r3.out.ascii'>
Details: <[Errno 2] No such file or directory: 'r.viewshed': 'r.viewshed'>
Details: <[Errno 2] No such file or directory: 'r.terraflow': 'r.terraflow'>
Details: <[Errno 2] No such file or directory: 'r.surf.fractal': 'r.surf.fractal'>
Details: <[Errno 2] No such file or directory: 'v.buffer': 'v.buffer'>
Details: <[Errno 2] No such file or directory: 'i.zc': 'i.zc'>
Details: <[Errno 2] No such file or directory: 'i.fft': 'i.fft'>
Details: <[Errno 2] No such file or directory: 'i.ifft': 'i.ifft'>
Details: <[Errno 2] No such file or directory: 'i.atcorr': 'i.atcorr'>
Details: <[Errno 2] No such file or directory: 'g.gui.dbmgr': 'g.gui.dbmgr'>
Error: x86_64-pc-linux-gnu-gcc -E        -I/var/tmp/portage/sci-geosciences/grass-7.8.3/work/grass-7.8.3/dist.x86_64-pc-linux-gnu/include -I/var/tmp/portage/sci-geosciences/grass-7.8.3/work/grass-7.8.3/dist.x86_64-pc-linux-gnu/include -D__GLIBC_HAVE_LONG_LONG: /var/tmp/portage/sci-geosciences/grass-7.8.3/work/grass-7.8.3/dist.x86_64-pc-linux-gnu/include/grass/gprojects.h:32:14: fatal error: ogr_srs_api.h: No such file or directory
Comment 3 mario.haustein 2020-10-05 08:31:40 UTC
The errors of comment #2 are not the cause of the build failure. The error messages are meaningless, because the modules cannot be found since they are not built by the choosen USE flags. This seems to be an odd behaviour of the build system of GRASS GIS, but not relevant to this bug.


The build log shows that the error arises from the module r3.out.ascii.

make[1]: Leaving directory '/var/tmp/portage/sci-geosciences/grass-7.8.3/work/grass-7.8.3'
GRASS GIS 7.8.3 exported compilation log
--------------------------------------------------
Started compilation: Sun Oct  4 17:28:40 CEST 2020
--
Errors in:
/var/tmp/portage/sci-geosciences/grass-7.8.3/work/grass-7.8.3/raster3d/r3.out.ascii
--
In case of errors please change into the directory with error and run 'make'.
If you get multiple errors, you need to deal with them in the order they
appear in the error log. If you get an error building a library, you will
also get errors from anything which uses the library.
--
Finished compilation: Sun Oct  4 17:29:52 CEST 2020
make: *** [Makefile:70: default] Error 1


But I'm not able to reproduce the failure in my test setup nor can I find anything suspicious in the build log. Can you please provide a build log with MAKEOPTS="-j1" to rule out a race condition issue during the build process?
Comment 4 mario.haustein 2020-10-10 14:26:35 UTC
Seems to be a race condition during files installation:

/usr/lib/portage/python3.7/ebuild-helpers/xattr/install -c  -m 644 raster3d_layout.png /var/tmp/portage/sci-geosciences/grass-7.8.3/work/grass-7.8.3/dist.x86_64-pc-linux-gnu/docs/html/raster3d_layout.png
...
/usr/lib/portage/python3.7/ebuild-helpers/xattr/install -c  -m 644 raster3d_layout.png /var/tmp/portage/sci-geosciences/grass-7.8.3/work/grass-7.8.3/dist.x86_64-pc-linux-gnu/docs/html/raster3d_layout.png
...
/usr/bin/install: cannot change permissions of '/var/tmp/portage/sci-geosciences/grass-7.8.3/work/grass-7.8.3/dist.x86_64-pc-linux-gnu/docs/html/raster3d_layout.png': No such file or directory
make[3]: *** [../../include/Make/HtmlRules.make:14: /var/tmp/portage/sci-geosciences/grass-7.8.3/work/grass-7.8.3/dist.x86_64-pc-linux-gnu/docs/html/raster3d_layout.png] Error 1
make[3]: *** Waiting for unfinished jobs....

Locking the target file should fix it. Unfortunately I cannot test the fix, because I don't have access to a machine with so many CPUs.
Comment 5 mario.haustein 2020-10-10 14:27:23 UTC
Created attachment 664546 [details, diff]
grass-7.8-flock.patch

proposed patch
Comment 6 Larry the Git Cow gentoo-dev 2020-11-25 08:16:54 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=55963a3f7ff33af3182040c076132590fc9be166

commit 55963a3f7ff33af3182040c076132590fc9be166
Author:     Mario Haustein <mario.haustein@hrz.tu-chemnitz.de>
AuthorDate: 2020-10-10 14:34:30 +0000
Commit:     Joonas Niilola <juippis@gentoo.org>
CommitDate: 2020-11-25 08:16:46 +0000

    sci-geosciences/grass: fix build failure
    
    Fix build failure during highly parallel build.
    
    Closes: https://bugs.gentoo.org/746590
    Signed-off-by: Mario Haustein <mario.haustein@hrz.tu-chemnitz.de>
    Package-Manager: Portage-3.0.4, Repoman-3.0.1
    Signed-off-by: Joonas Niilola <juippis@gentoo.org>

 sci-geosciences/grass/files/grass-7.8-flock.patch | 17 +++++++++++++++++
 sci-geosciences/grass/grass-7.8.3.ebuild          |  5 +++++
 2 files changed, 22 insertions(+)