[precise] can't build: OpenMP linking error
Submitted by Adam Dingle
Link to original bug (#718101)
Description
---- Reported by adam@yorba.org 2012-01-04 08:41:00 -0800 ----
Original Redmine bug id: 4558
Original URL: http://redmine.yorba.org/issues/4558
Searchable id: yorba-bug-4558
Original author: Adam Dingle
Original description:
On Ubuntu Precise, a Shotwell build from git master fails with these link errors:
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../lib/libraw_r.so: undefined reference to `omp_get_thread_num'
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../lib/libraw_r.so: undefined reference to `omp_get_num_threads'
...
The problem seems to be that libraw on Precise is build with OpenMP support, but we're not linking Shotwell with -fopenmp. This issue arose before as 3032 and we thought it was fixed there, but the bug still occurs.
Ubuntu works around this in their Shotwell build by applying a patch that adds -fopenmp to the command that links Shotwell. We want Shotwell to build after a checkout with no changes, however.
Related issues:
- related to shotwell - 3032: Linking error in case libraw was built with -fopenmp (Invalid)
---- Additional Comments From shotwell-maint@gnome.bugs 2013-05-01 11:38:00 -0700 ----
History
Comment 1
Updated by andreas - almost 2 years ago
adding the whole error message for search engine purposes.. wasn't able to quickly find it with just the first error line
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../lib/libraw_r.so: undefined reference to `GOMP_parallel_start'
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../lib/libraw_r.so: undefined reference to `GOMP_loop_end'
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../lib/libraw_r.so: undefined reference to `GOMP_barrier'
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../lib/libraw_r.so: undefined reference to `GOMP_loop_dynamic_start'
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../lib/libraw_r.so: undefined reference to `omp_get_thread_num'
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../lib/libraw_r.so: undefined reference to `GOMP_loop_dynamic_next'
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../lib/libraw_r.so: undefined reference to `GOMP_parallel_end'
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../lib/libraw_r.so: undefined reference to `omp_get_num_threads'
collect2: ld returned 1 exit status
make: *** [shotwell] Error 1
Comment 2
Updated by Adam Dingle almost 2 years ago
I investigated. It turns out that if you install liblcms2-dev on Precise, then Shotwell will build without error.
The problem is that if liblcms2-dev is absent, then 'pkg-config --libs libraw' fails with this error:
Package 'lcms2', required by 'libraw', not found
So presumably libraw-dev should require liblcms2-dev.
Comment 3
Updated by Adam Dingle almost 2 years ago
- Status changed from Open to 5
- Resolution set to invalid
I now think this is an Ubuntu packaging bug. I've reported this to Ubuntu at
https://bugs.launchpad.net/ubuntu/+source/libraw/+bug/924587
Closing.
Comment 4
Updated by Adam Dingle almost 2 years ago
- Status changed from 5 to Open
-
Resolution deleted (
<strike>
_invalid_</strike>
)
Actually let's leave this open until the underlying packaging bug is fixed, in the hope that it will help others attempting to build Shotwell on Precise.
Comment 5
Updated by Adam Dingle almost 2 years ago
- Status changed from Open to 5
- Resolution set to fixed
The Ubuntu packaging bug has been fixed. Closing.
Comment 6
Updated by Charles Lindsay 7 months ago
- Status changed from 5 to Fixed
--- Bug imported by chaz@yorba.org 2013-11-25 21:55 UTC ---
This bug was previously known as bug 4558 at http://redmine.yorba.org/show_bug.cgi?id=4558
Unknown Component Using default product and component set in Parameters Unknown milestone "unknown in product shotwell. Setting to default milestone for this product, "---". Setting qa contact to the default for this product. This bug either had no qa contact or an invalid one.
Version: 0.12
Resolution: RESOLVED FIXED