Re: [Gimp-developer] Cross compiling gimp with mingw-w64 requires pangoft2 that is not available



OK it was just cairo that was not correctly cross-compiled (I don't know why).
There was missing symbols in the library.

That was before I recompiled cairo:
$ i686-w64-mingw32-nm /tmp/i686-w64-mingw32-cairo-1.14.2/usr/i686-w64-mingw32/lib/libcairo.a | grep 
cairo_ft_font_face_create_for_pattern

Whereas now:
$ i686-w64-mingw32-nm /tmp/i686-w64-mingw32-cairo-1.14.2/usr/i686-w64-mingw32/lib/libcairo.a | grep 
cairo_ft_font_face_create_for_pattern
00001930 t __cairo_ft_font_face_create_for_pattern
00004170 T _cairo_ft_font_face_create_for_pattern

Now, I am amble to compile pango and I have pangoft2 so gimp is happy :)
Problem solved.

On Fri, 11 Mar 2016 15:55:37 +0100
YuGiOhJCJ Mailing-List <yugiohjcj-mailinglist laposte net> wrote:

Indeed, I have not installed harfbuzz because I thought it was an optional dependency that I don't need to 
build gimp.

You compiled pango with freetype/harfbuzz/cairo on Windows 10 64 bit.
But what I am doing is a bit different: I am cross-compiling pango for Windows 32 bit on Linux 32 bit.

Anyway, interesting that you get the pangoft2-1.0-0.dll file because that is exactly what I need to build.

I have cross-compiled and installed harfbuzz and its icu4c dependency:
- icu4c-56.1
- harfbuzz-1.2.3-i486-20160311152555

But now with these new programs installed, I am not anymore able to cross-compile pango:
---
$ ./configure --prefix=/usr/i686-w64-mingw32 --host=i686-w64-mingw32
$ make
[...]
  CC       pangowin32-shape.lo
pangowin32-shape.c:39:17: warning: 'pango_win32_debug' defined but not used [-Wunused-variable]
 static gboolean pango_win32_debug = FALSE;
                 ^
  GEN      pangowin32-win32-res.o
  CCLD     libpangowin32-1.0.la
  CCLD     libpangocairo-1.0.la
.libs/pangocairo-fcfont.o: In function `pango_cairo_fc_font_create_font_face':
/tmp/build/gimp/pango-1.39.0/pango/pangocairo-fcfont.c:63: undefined reference to 
`cairo_ft_font_face_create_for_pattern'
.libs/pangocairo-fcfontmap.o: In function `pango_cairo_fc_font_map_fontset_key_substitute':
/tmp/build/gimp/pango-1.39.0/pango/pangocairo-fcfontmap.c:114: undefined reference to 
`cairo_ft_font_options_substitute'
collect2: error: ld returned 1 exit status
make[4]: *** [libpangocairo-1.0.la] Error 1
make[4]: Leaving directory `/tmp/build/gimp/pango-1.39.0/pango'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/tmp/build/gimp/pango-1.39.0/pango'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/tmp/build/gimp/pango-1.39.0/pango'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/tmp/build/gimp/pango-1.39.0'
make: *** [all] Error 2
---

An interesting thing is that when I don't have harfbuzz, that's what I see:
---
$ ./configure --prefix=/usr/i686-w64-mingw32 --host=i686-w64-mingw32
[...]
configuration:
      backends: Cairo Win32
[...]
---

Whereas when I have harfbuzz, that's what I see:
---
[...]
configuration:
      backends: Cairo Win32 FreeType
[...]
---

So, it means that having harfbuzz installed enables the FreeType backend on pango.
It means that it enables the building of pangoft2-1.0-0.dll.
Exactly what I want :)

But why I got this "undefined reference to `cairo_ft_font_face_create_for_pattern'" error please?

On Wed, 9 Mar 2016 20:16:52 +0100
"HK_Privat" <hk_priv gmx de> wrote:

Hello.

In your list, harfbuzz is missing.
I do not have checked all versions, but I compiled pango with the freetype,
harfbuzz and cairo dependencies and my
Windows 10, 64bit  compilation includes the pangoft2-1.0-0.dll

regards


-----Ursprüngliche Nachricht-----
Von: gimp-developer-list [mailto:gimp-developer-list-bounces gnome org]
Im Auftrag von YuGiOhJCJ Mailing-List
Gesendet: Dienstag, 8. März 2016 05:56
An: gimp-developer-list gnome org
Betreff: [Gimp-developer] Cross compiling gimp with mingw-w64 requires
pangoft2 that is not available

Hello,

Programs used:
- gimp-2.8.16
- cairo-1.14.2
- pango-1.39.0
- fontconfig-2.11.1
- freetype-2.4.10

How I compile pango for Windows:
$ ./configure --prefix=/usr/i686-w64-mingw32 --host=i686-w64-mingw32 $
make

When I cross compile gimp with mingw-w64 [1] I got an error telling I need
pango with the optional support for cairo [2] but I already have installed
pango and its cairo support.

Reading more carefully the config.log file, I see that "pangoft2" is
checked
too at this step [3] and that's why this error is shown.

So, I need pangoft2 but I don't think it is possible to build pango with
pangoft2 for win32 platform.

Indeed, when I compile pango for Linux, I got pangoft2, but when I compile
pango for Windows, the pangoft2 library does not come with it.

As gimp depends on pangoft2, I can't build gimp with mingw-w64.

How can I cross compile gimp for Windows whereas pangoft2 cannot be built
for this platform?

Thank you.
Best regards.

[1] http://wiki.gimp.org/wiki/Hacking:Building/Windows#Build_GIMP

[2] Error while compiling gimp for Windows:
./configure --prefix=/usr/i686-w64-mingw32 --host=i686-w64-mingw32 --
enable-introspection=no --disable-glibtest --disable-gtktest
--disable-docs --
without-libjpeg --disable-python --without-xmc --without-dbus --without-
libzma [...] checking for CAIRO... yes checking for PANGOCAIRO... no
configure: error: Test for PangoCairo failed.
*** We require Pango with the optional support for Cairo compiled in.
*** See the file 'INSTALL' for more help.

[3] The config.log file after trying to compile gimp for Windows:
$ cat config.log
[...]
configure:18051: checking for CAIRO
configure:18058: $PKG_CONFIG --exists --print-errors "cairo >= 1.10.2"
configure:18061: $? = 0
configure:18075: $PKG_CONFIG --exists --print-errors "cairo >= 1.10.2"
configure:18078: $? = 0
configure:18136: result: yes
configure:18143: checking for PANGOCAIRO
configure:18150: $PKG_CONFIG --exists --print-errors "pangocairo >= 1.29.4
pangoft2"
Package pangoft2 was not found in the pkg-config search path.
Perhaps you should add the directory containing `pangoft2.pc'
to the PKG_CONFIG_PATH environment variable No package 'pangoft2'
found
configure:18153: $? = 1
configure:18167: $PKG_CONFIG --exists --print-errors "pangocairo >= 1.29.4
pangoft2"
Package pangoft2 was not found in the pkg-config search path.
Perhaps you should add the directory containing `pangoft2.pc'
to the PKG_CONFIG_PATH environment variable No package 'pangoft2'
found
configure:18170: $? = 1
configure:18184: result: no
No package 'pangoft2' found
configure:18200: error: Test for PangoCairo failed.
*** We require Pango with the optional support for Cairo compiled in.
*** See the file 'INSTALL' for more help.
[...]
_______________________________________________
gimp-developer-list mailing list
List address:    gimp-developer-list gnome org
List membership: https://mail.gnome.org/mailman/listinfo/gimp-developer-
list
List archives:   https://mail.gnome.org/archives/gimp-developer-list

_______________________________________________
gimp-developer-list mailing list
List address:    gimp-developer-list gnome org
List membership: https://mail.gnome.org/mailman/listinfo/gimp-developer-list
List archives:   https://mail.gnome.org/archives/gimp-developer-list


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]