Bug 15021

Summary: cairo libs are broken if compiled with Intel icc 10
Product: cairo Reporter: Ralf Lehmann <ralf>
Component: generalAssignee: Carl Worth <cworth>
Status: RESOLVED MOVED QA Contact: cairo-bugs mailing list <cairo-bugs>
Severity: critical    
Priority: high    
Version: 1.4.14   
Hardware: x86 (IA32)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:
Attachments: Warning and error output of intel Compiler (make test after a make clean)
Sorry but above attachmend contains the wrong file this is the right one

Description Ralf Lehmann 2008-03-14 19:46:38 UTC
Created attachment 15135 [details]
Warning and error output of intel Compiler  (make test after a make clean)

cairo compiles without an problem but the test suit and all applications fail with 
undefined reference warnings.
I track down this to this warnings from the compiler:
cairo.c(3434): warning #1358: declaration aliased to undefined entity "INT_cairo_status"
  slim_hidden_def (cairo_status);
  ^
cairo.c(3238): warning #1358: declaration aliased to undefined entity "INT_cairo_get_matrix"
  slim_hidden_def (cairo_get_matrix);
  ^
cairo.c(3151): warning #1358: declaration aliased to undefined entity "INT_cairo_get_current_point"
  slim_hidden_def(cairo_get_current_point);
  ^
cairo.c(3084): warning #1358: declaration aliased to undefined entity "INT_cairo_get_tolerance"
  slim_hidden_def (cairo_get_tolerance);
  ^
The compiler produce a lot of this warning's and the resulting lib is not usable.
Gcc 4.3 compile the same source witout any problem.
if tried without  Optimization flags without success.

icc version:
icc (ICC) 10.1 20080212
Comment 1 Ralf Lehmann 2008-03-14 19:51:26 UTC
Created attachment 15136 [details]
Sorry but above attachmend contains the wrong file this is the right one
Comment 2 Chris Wilson 2008-10-10 05:05:12 UTC
So this appears to be icc pretending to be gcc (in order for the slim_* to be defined to something) and then not implementing the attributes it just declared it had.

If you can extend the checks in cairo-compiler-private.h, e.g.:
  #if __GNUC__ >= 3 && defined(__ELF__) && !defined(__sun)
to work for you (and everybody else), we will happily take a patch.
Comment 3 idwakest 2009-08-04 05:58:19 UTC
The problem is that :
#if __GNUC__ >= 3 && defined(__ELF__) && !defined(__sun)
is true even when compiling with icc.

To fix the problem you can suppress or comment everthing between
#if __GNUC__ >= 3 && defined(__ELF__) && !defined(__sun)
and
#else



Idwakest
Comment 4 GitLab Migration User 2018-08-25 13:50:06 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/cairo/cairo/issues/219.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.