FS#55511 - [subsurface] compilation fails

Attached to Project: Community Packages
Opened by Erich Eckner (deepthought) - Tuesday, 05 September 2017, 07:23 GMT
Last edited by Gaetan Bisson (vesath) - Tuesday, 05 September 2017, 17:43 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Gaetan Bisson (vesath)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

The build in a clean chroot fails with:

[ 18%] Building CXX object desktop-widgets/plugins/facebook/CMakeFiles/facebook_integration.dir/facebookconnectwidget.cpp.o
In file included from /build/subsurface/src/Subsurface-4.6.4/desktop-widgets/plugins/facebook/facebookconnectwidget.cpp:24:0:
/build/subsurface/src/Subsurface-4.6.4/desktop-widgets/./mainwindow.h:16:10: fatal error: ui_mainwindow.h: No such file or directory
#include "ui_mainwindow.h"
^~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [desktop-widgets/plugins/facebook/CMakeFiles/facebook_integration.dir/build.make:95: desktop-widgets/plugins/facebook/CMakeFiles/facebook_integration.dir/facebookconnectwidget.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1127: desktop-widgets/plugins/facebook/CMakeFiles/facebook_integration.dir/all] Error 2
make: *** [Makefile:130: all] Error 2
==> ERROR: A failure occurred in build().
Aborting...

Additional info:
* package version(s)
subsurface-4.6.4-2
* config and/or log files etc.
full log is attached

Steps to reproduce:
> git clone https://git.archlinux.org/svntogit/community.git/
> cd community
> git checkout 4f5bc798979b75b0afdce1f4c488f32074e30fc1
> cd subsurface/trunk
> staging-x86_64-build
   log (21.4 KiB)
This task depends upon

Closed by  Gaetan Bisson (vesath)
Tuesday, 05 September 2017, 17:43 GMT
Reason for closing:  Fixed
Additional comments about closing:  in SVN
Comment by Gaetan Bisson (vesath) - Tuesday, 05 September 2017, 16:45 GMT
Yeah it's got a race condition. I told upstream a while ago but nobody found the time to fix it (and as far as I knew I was the only one to run into it). The good news is you can circumvent it if you build with several jobs (job one will generate ui_mainwindow.h before job two needs it). Add "MAKEFLAGS='-j4'" to your ~/.makepkg.conf and things should work. Or report this issue upstream and hope someone has the time to look into it. Cheers.
Comment by Eli Schwartz (eschwartz) - Tuesday, 05 September 2017, 17:05 GMT
MAKEFLAGS that are needed in order to build should not be left for the ~/.makepkg.conf, why not use

```
cmake \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=/usr \
-DMARBLE_LIBRARIES=/usr/lib/libssrfmarblewidget.so \
-DMARBLE_INCLUDE_DIR=/usr/include/subsurface/marble \
..
# race condition means we need parallel jobs to create ui_mainwindow.h before it is needed
make -j4
```

Loading...