Bug 99474

Summary: Cairo make ignores sysroot.
Product: cairo Reporter: AlastairGrowcott
Component: generalAssignee: Chris Wilson <chris>
Status: RESOLVED MOVED QA Contact: cairo-bugs mailing list <cairo-bugs>
Severity: normal    
Priority: medium    
Version: unspecified   
Hardware: x86-64 (AMD64)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:

Description AlastairGrowcott 2017-01-20 13:32:04 UTC
I cloned Cairo from the git repository. Last commit was dd4706d0a9d123d3aa4284ac9ab35fbe165278b2, "pdf: Fix wrong cairo_pdf_outline_flags_t item prefix", last tag was 1.15.14.

I am working on Ubuntu, compiling using MinGW.

I used the following command to configure:

./configure --prefix=${HOME}/Workspace/mingw/cairo --host=x86_64-w64-mingw32 --enable-xlib=no --enable-xlib-xrender=no --enable-xcb=no --enable-xlib-xcb=no --enable-xcb-shm=no --enable-png=yes --with-sysroot=/usr/x86_64-w64-mingw32

The compile fails as follows:

In file included from /usr/include/freetype2/ft2build.h:37:0,
                 from cairo-ft.h:46,
                 from cairo-ft-private.h:41,
                 from cairo-script-surface.c:88:
/usr/include/freetype2/freetype/config/ftheader.h:78:3: error: #error unknown multiarch location for ftheader.h
 # error unknown multiarch location for ftheader.h


This error is generated from /usr/include/freetype2/freetype/config/ftheader.h but the compile SHOULD be using /usr/x86_64-w64-mingw32/include/freetype2/freetype/config/ftheader.h.

I have built all the dependencies using a similar configure line but without the "--with-sysroot" option and they all compiled fine and were evidently getting files from the right location as can be seen by the fact that header files that were on the build system and not on the target system were reported as missing.

If you want to reproduce this issue, I can save you some time with the dependencies. I have been making them available at https://gitlab.com/AGrowcott/Ubuntu-mingw-prebuilt-libs. Note that I built libpng16 rather than libpng12 though. I am going to have to edit your make files before I am finished I think.
Comment 1 AlastairGrowcott 2017-01-20 13:33:30 UTC
Sorry, typo on the commit tag. It was 1.15.4.
Comment 2 GitLab Migration User 2018-08-25 13:59:55 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/306.

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.