Package Details: mingw-w64-cairo 1.14.6-1

Git Clone URL: https://aur.archlinux.org/mingw-w64-cairo.git (read-only)
Package Base: mingw-w64-cairo
Description: Cairo vector graphics library (mingw-w64)
Upstream URL: http://cairographics.org/
Keywords: cairo mingw mingw-w64
Licenses: MPL, LGPL
Conflicts: mingw-w64-cairo-bootstrap
Provides: mingw-w64-cairo-bootstrap
Replaces: mingw-w64-cairo-bootstrap
Submitter: Schala
Maintainer: Schala
Last Packager: Schala
Votes: 10
Popularity: 0.095286
First Submitted: 2012-09-05 18:20
Last Updated: 2015-12-12 20:56

Sources (4)

Latest Comments

Schala commented on 2015-12-16 22:35

mingw-w64-cairo-bootstrap is available

Schala commented on 2015-10-16 01:12

Yeah, feel free to make one.

lantw44 commented on 2015-10-15 15:19

mingw-w64-librsvg and mingw-w64-poppler are optional makedepends. You can remove them to get mingw-w64-cairo build without prebuilts.

I think we should have a bootstrap PKGBUILD for newly installed systems.

yan12125 commented on 2015-10-15 15:04

@Schala Are ant32's binaries the only solution on a newly installed system?

Schala commented on 2015-10-11 15:31

I know. I'm doing my best to match up to native cairo. Luckily ant32 has prebuilts if you need to bootstrap: http://sourceforge.net/projects/mingw-w64-archlinux/files/

lantw44 commented on 2015-10-11 07:00

Circular dependency:

mingw-w64-cairo -> mingw-w64-librsvg -> mingw-w64-pango -> mingw-w64-cairo
mingw-w64-cairo -> mingw-w64-poppler -> mingw-w64-cairo

Schala commented on 2015-10-10 16:55

okay

lantw44 commented on 2015-10-09 20:48

mingw-w64-cairo 1.14.2 is too old for mingw-w64-gtk3 3.18.1:

checking for CAIRO_BACKEND... yes
checking for CAIRO... yes
checking for cairo_win32_surface_create_with_format in -lcairo... no
configure: error: cairo_win32_surface_create_with_format is not found in cairo library
You need cairo version newer than 2015-04-14

Can you backport patches required by gtk3 or add a git snapshot package?

xantares commented on 2014-06-10 15:27

hi,

the build issue mentionned earlier was when it tried to build sphinx:

/tmp/yaourt-tmp-root/aur-mingw-w64-cairo/src/cairo-1.12.16/util/cairo-sphinx/sphinx.c:8:22: fatal error: sys/mman.h: No such file or directory

fedora had this patch:
https://bugs.freedesktop.org/attachment.cgi?id=77338&action=edit

can you include it ?

chenxiaolong commented on 2014-06-05 17:38

Fixed the gcc-4.9 build issue :)

Schala commented on 2013-10-20 04:44

It doesn't define it for me.

xantares commented on 2013-10-16 07:44

Hi, seems it does not build:

/tmp/yaourt-tmp-root/aur-mingw-w64-cairo/src/cairo-1.12.16/util/cairo-sphinx/sphinx.c:8:22: fatal error: sys/mman.h: No such file or directory
#include <sys/mman.h>
^
compilation terminated.

There is no guard from including sys/mman.h:
/tmp/yaourt-tmp-root/aur-mingw-w64-cairo/src/cairo-1.12.16/config.h.in:220:#undef HAVE_SYS_MMAN_H

x.

Schala commented on 2012-10-13 05:53

Thanks for the help. I do want packages that actually work, so I'll be looking into it.

entidi commented on 2012-10-12 13:48

The fact is without setting any pkg-config environment variable the package will link against the system libraries (and this would also explain why xcb was working), resulting (if successfull) in unusable libraries. I didn't think it was ever possible to link libraries from different platforms so it took me a while to discover this issue.

All your mingw-w64 PKGBUILDs suffer from this problem, so I really don't understand how the whole mingw-w64 GTK+2 toolchain can work. Anyway or I am missing something really huge or there is a problem. In the latter case, I suggest to add the PKG_CONFIG_... settings to all your packages that rely on pkg-config or add mingw-w64-pkg-config (https://aur.archlinux.org/packages.php?ID=52216) to makedepends (it does the same thing with wrapper scripts).

I'm building my own toolchain based on Fedora so don't consider yourself pushed to make a decision.

Schala commented on 2012-10-12 01:44

Builds fine for me but I added the extra parameters specified in your version and fixed the PKG_CONFIG_* variable.

Schala commented on 2012-10-11 21:31

It builds fine for me, but I'll consider tweaking it a bit.

Schala commented on 2012-10-11 21:29

It builds fine for me. Would you like a prebuilt?

entidi commented on 2012-10-11 20:51

This package wont build. It has some serious issue:

1. no PKG_CONFIG_LIBDIR/PKG_CONFIG_PATH set;
2. xcb must be disabled because there is no X server on windows;
3. cairo 1.12 is buggy on win64 platforms (see https://bugs.freedesktop.org/show_bug.cgi?id=48750 and https://bugs.freedesktop.org/show_bug.cgi?id=53121).

I downgraded the package to 1.10.2 and followed the Fedora directives at http://pkgs.fedoraproject.org/cgit/mingw-cairo.git/tree/. Here is a working PKGBUILD:

--
pkgname=mingw-w64-cairo
pkgver=1.10.2
pkgrel=1
pkgdesc="Cairo vector graphics library (mingw-w64)"
arch=(any)
url="http://cairographics.org/"
license=("LGPL" "MPL")
makedepends=(mingw-w64-gcc)
depends=(mingw-w64-crt mingw-w64-glib2 mingw-w64-libpng mingw-w64-fontconfig mingw-w64-pixman)
options=(!libtool !strip !buildflags)
source=("http://cairographics.org/releases/cairo-$pkgver.tar.gz"
"http://pkgs.fedoraproject.org/cgit/mingw-cairo.git/plain/mingw32-cairo-fix-ffs-declaration.patch?h=f18"
"http://pkgs.fedoraproject.org/cgit/mingw-cairo.git/plain/mingw32-cairo-A1_surfaces.patch?h=f18"
"http://pkgs.fedoraproject.org/cgit/mingw-cairo.git/plain/mingw32-cairo-reset_clip.patch?h=f18")
md5sums=('f101a9e88b783337b20b2e26dfd26d5f'
'ab9be7532af22d092b79a9659e650727'
'197e184a45b039338af30b50c873e399'
'7613b505f1350a8780d516a1b1b02bef')


_architectures="i686-w64-mingw32 x86_64-w64-mingw32"

build() {
local tardir="$srcdir/${pkgname#mingw-w64-}-$pkgver"

# Apply patches from fedora repository
cd "$tardir"
patch -p0 < '../mingw32-cairo-fix-ffs-declaration.patch?h=f18'
patch -p1 < '../mingw32-cairo-A1_surfaces.patch?h=f18'
patch -p1 < '../mingw32-cairo-reset_clip.patch?h=f18'

# The libtool bundled with this package is too old for win64 support
NOCONFIGURE=1 ./autogen.sh

for _arch in ${_architectures}; do
mkdir -p "${srcdir}/${pkgname}-${pkgver}-build-${_arch}"
cd "${srcdir}/${pkgname}-${pkgver}-build-${_arch}"
export PKG_CONFIG_LIBDIR="/usr/${_arch}/lib/pkgconfig"
export CFLAGS="-O2 -pipe -mms-bitfields"
unset LDFLAGS PKG_CONFIG_PATH
"$tardir/configure" \
--prefix=/usr/${_arch} \
--build=$CHOST \
--host=${_arch} \
--disable-pthread \
--disable-xlib \
--disable-xcb \
--enable-win32 \
--enable-fc \
--enable-ft \
--enable-png \
--enable-static \
--enable-gobject \
--enable-tee
make
done
}

package() {
for _arch in ${_architectures}; do
cd "${srcdir}/${pkgname}-${pkgver}-build-${_arch}"
make DESTDIR="$pkgdir" install
find "$pkgdir/usr/${_arch}" -name '*.exe' -o -name '*.bat' -o -name '*.def' -o -name '*.exp' | xargs -rtl1 rm
find "$pkgdir/usr/${_arch}" -name '*.dll' | xargs -rtl1 ${_arch}-strip -g -x
find "$pkgdir/usr/${_arch}" -name '*.a' | xargs -rtl1 ${_arch}-strip -g
rm -r "$pkgdir/usr/${_arch}/share"
done
}