NetBSD Problem Report #47543

From www@NetBSD.org  Fri Feb  8 05:49:52 2013
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [149.20.53.66])
	by www.NetBSD.org (Postfix) with ESMTP id C978963EBEB
	for <gnats-bugs@gnats.NetBSD.org>; Fri,  8 Feb 2013 05:49:52 +0000 (UTC)
Message-Id: <20130208054951.400F363EBEB@www.NetBSD.org>
Date: Fri,  8 Feb 2013 05:49:51 +0000 (UTC)
From: davshao@gmail.com
Reply-To: davshao@gmail.com
To: gnats-bugs@NetBSD.org
Subject: graphics/cairo on DragonFly i386 Define CAIRO_NO_MUTEX to 1
X-Send-Pr-Version: www-1.0

>Number:         47543
>Category:       pkg
>Synopsis:       graphics/cairo on DragonFly i386 Define CAIRO_NO_MUTEX to 1
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Feb 08 05:50:00 +0000 2013
>Closed-Date:    Fri Mar 08 02:22:43 +0000 2013
>Last-Modified:  Fri Mar 08 02:22:43 +0000 2013
>Originator:     David Shao
>Release:        DragonFly 3.3-DEVELOPMENT i386
>Organization:
>Environment:
DragonFly 3.3-DEVELOPMENT i386
>Description:
Using DragonFly 3.3-DEVELOPMENT i386 master src through:

commit a33bbb6c241cbfacccc550489091097ccf58eb41
Date:   Thu Feb 7 20:05:52 2013 +0100

    games/atc: Fix a logic bug.

and pkgsrc current master through:

commit 0229cdc7bd0bc2b8113a8d4bee33fbb1a421933a
Date:   Thu Feb 7 18:26:52 2013 -0800

# pkg_rolling-replace -uv

fails for graphics/cairo with:

checking for cairo's pthread feature... 
checking whether cairo's pthread feature could be enabled... no (can't link with -lpthread or -pthread)
...
cairo (version 1.12.12 [release]) will be compiled with:

The following surface backends:
  Image:         yes (always builtin)
  Recording:     yes (always builtin)
  Observer:      yes (always builtin)
  Mime:          yes (always builtin)
  Tee:           yes
  XML:           no (disabled, use --enable-xml to enable)
  Skia:          no (disabled, use --enable-skia to enable)
  Xlib:          yes
  Xlib Xrender:  yes
  Qt:            no (disabled, use --enable-qt to enable)
  Quartz:        no (requires CoreGraphics framework)
  Quartz-image:  no (disabled, use --enable-quartz-image to enable)
  XCB:           yes
  Win32:         no (requires a Win32 platform)
  OS2:           no (disabled, use --enable-os2 to enable)
  CairoScript:   yes
  PostScript:    yes
  PDF:           yes
  SVG:           yes
  OpenGL:        no (disabled, use --enable-gl to enable)
  OpenGL ES 2.0: no (disabled, use --enable-glesv2 to enable)
  BeOS:          no (disabled, use --enable-beos to enable)
  DirectFB:      no (disabled, use --enable-directfb to enable)
  OpenVG:        no (disabled, use --enable-vg to enable)
  DRM:           no (disabled, use --enable-drm to enable)
  Cogl:          no (disabled, use --enable-cogl to enable)

The following font backends:
  User:          yes (always builtin)
  FreeType:      yes
  Fontconfig:    yes
  Win32:         no (requires a Win32 platform)
  Quartz:        no (requires CoreGraphics framework)

The following functions:
  PNG functions:   yes
  GLX functions:   no (not required by any backend)
  WGL functions:   no (not required by any backend)
  EGL functions:   no (not required by any backend)
  X11-xcb functions: no (disabled, use --enable-xlib-xcb to enable)
  XCB-shm functions: yes

The following features and utilities:
  cairo-trace:                no (requires dynamic linker and zlib and real pthreads)
  cairo-script-interpreter:   yes

And the following internal features:
  pthread:       no (can't link with -lpthread or -pthread)
  gtk-doc:       no
  gcov support:  no
  symbol-lookup: no (requires bfd)
  test surfaces: no (disabled, use --enable-test-surfaces to enable)
  ps testing:    no (requires libspectre)
  pdf testing:   no (requires poppler-glib >= 0.17.4)
  svg testing:   no (requires librsvg-2.0 >= 2.15.0)


--- The tee surface backend feature is still under active development and is
--- included in this release only as a preview. It does NOT fully work yet
--- and incompatible changes may yet be made to tee surface backend specific
--- API.

=> Modifying libtool scripts to use pkgsrc libtool
WARNING: *** Please consider adding c++ to USE_LANGUAGES in the package Makefile.
===> Building for cairo-1.12.12nb1
/usr/pkg/bin/bmake  all-recursive
Making all in src
/usr/pkg/bin/bmake  all-am
  CC     cairo-analysis-surface.lo
In file included from cairo-mutex-type-private.h:45:0,
                 from cairo-scaled-font-private.h:45,
                 from cairoint.h:396,
                 from cairo-analysis-surface.c:37:
cairo-mutex-impl-private.h:262:3: error: #error "XXX: No mutex implementation found.  Cairo will not work with multiple threads.  Define CAIRO_NO_MUTEX to 1 to acknowledge and accept this limitation and compile cairo without thread-safety support."
In file included from cairo-mutex-type-private.h:45:0,
                 from cairo-scaled-font-private.h:45,
                 from cairoint.h:396,
                 from cairo-analysis-surface.c:37:
cairo-mutex-impl-private.h:271:3: error: unknown type name 'cairo_mutex_impl_t'
In file included from cairo-scaled-font-private.h:45:0,
                 from cairoint.h:396,
                 from cairo-analysis-surface.c:37:
cairo-mutex-type-private.h:49:3: error: #error "CAIRO_MUTEX_IMPL_LOCK not defined.  Check cairo-mutex-impl-private.h."
cairo-mutex-type-private.h:52:3: error: #error "CAIRO_MUTEX_IMPL_UNLOCK not defined.  Check cairo-mutex-impl-private.h."
cairo-mutex-type-private.h:55:3: error: #error "CAIRO_MUTEX_IMPL_NIL_INITIALIZER not defined.  Check cairo-mutex-impl-private.h."
cairo-mutex-type-private.h:139:3: error: #error "CAIRO_MUTEX_IMPL_LOCK not defined"
cairo-mutex-type-private.h:142:3: error: #error "CAIRO_MUTEX_IMPL_UNLOCK not defined"
cairo-mutex-type-private.h:151:3: error: #error "CAIRO_MUTEX_IMPL_NIL_INITIALIZER not defined"
cairo-mutex-type-private.h:161:1: error: unknown type name 'cairo_mutex_impl_t'
In file included from cairo-fixed-private.h:42:0,
                 from cairoint.h:2022,
                 from cairo-analysis-surface.c:37:
cairo-wideint-private.h:121:1: warning: '__visibility__' attribute ignored [-Wattributes]
cairo-wideint-private.h:122:1: warning: '__visibility__' attribute ignored [-Wattributes]
In file included from cairo-analysis-surface.c:45:0:
cairo-surface-snapshot-inline.h: In function '_cairo_surface_snapshot_get_target':
cairo-surface-snapshot-inline.h:54:5: warning: implicit declaration of function 'CAIRO_MUTEX_IMPL_LOCK' [-Wimplicit-function-declaration]
cairo-surface-snapshot-inline.h:56:5: warning: implicit declaration of function 'CAIRO_MUTEX_IMPL_UNLOCK' [-Wimplicit-function-declaration]
*** Error code 1


>How-To-Repeat:
# pkg_rolling-replace -uv
on latest DragonFly i386.
>Fix:

>Release-Note:

>Audit-Trail:
From: Thomas Klausner <wiz@NetBSD.org>
To: NetBSD bugtracking <gnats-bugs@NetBSD.org>
Cc: 
Subject: Re: pkg/47543: graphics/cairo on DragonFly i386 Define
 CAIRO_NO_MUTEX to 1
Date: Fri, 8 Feb 2013 10:41:57 +0100

 On Fri, Feb 08, 2013 at 05:50:00AM +0000, davshao@gmail.com wrote:
 > fails for graphics/cairo with:
 > 
 > checking for cairo's pthread feature... 
 > checking whether cairo's pthread feature could be enabled... no (can't link with -lpthread or -pthread)
 > ...

 Shouldn't this work?
 Can you please look in the config.log what the problem is here?

 Thanks,
  Thomas

State-Changed-From-To: open->feedback
State-Changed-By: reed@NetBSD.org
State-Changed-When: Sat, 23 Feb 2013 13:06:36 +0000
State-Changed-Why:
Asked for feedback.


From: David Shao <davshao@gmail.com>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: pkg/47543: graphics/cairo on DragonFly i386 Define CAIRO_NO_MUTEX
 to 1
Date: Sat, 23 Feb 2013 10:57:46 -0800

 Note the following is strictly my personal opinion and some if not
 most may be disputed by the DragonFly development team.

 The fix from

 commit 4a0e0cd7377c45dc21d5c71bcab931b5e5727e74
 Date:   Mon Feb 18 01:15:59 2013 +0100

     csu: Fix .eh_frame_hdr errors seen on i386

 corrects cairo's building on DragonFly i386 (I don't think there was a
 problem on x86_64) using the gcc 4.7.2 compiler.

 There therefore seem to me to be two viable options for now on
 DragonFly with regards to pkgsrc, but one will over time become much
 less viable:

 1) Stick with using gcc 4.4.  This has the advantage that modular xorg
 still starts using startx.  The problem I have seen appears to be in
 compiling the combination of libdrm and modular-xorg-server with gcc
 4.7.2 on DragonFly, which builds, but just does not start instead
 leaving the dreaded black screen of nothingness.  One way to stick
 with gcc 4.4, but note that it is getting more painful as time
 progresses, is to in
 /etc/make.conf
 insert the lines
 WORLD_CCVER=gcc44
 OBJFORMAT_BUILTIN_CCVER_DEFAULT=gcc44

 I don't know that OBJFORMAT_BUILTIN_CCVER_DEFAULT is necessary, only
 if one reads the patch that set the default compiler to gcc 4.7, this
 variable determines the object format which seems an important thing.

 Sticking with gcc 4.4 has the disadvantage that devel/xulrunner and I
 suppose www/firefox have to be manually built with gcc 4.7:
 # env CCVER=gcc47 bmake replace clean

 2) Accept using gcc 4.7.  Just remember to manually rebuild libdrm and
 modular-org-server (I don't know if both are needed, I just gave up
 after determining rebuilding those two were enough).

From: David Shao <davshao@gmail.com>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: pkg/47543: graphics/cairo on DragonFly i386 Define CAIRO_NO_MUTEX
 to 1
Date: Thu, 7 Mar 2013 17:50:56 -0800

 Sorry if I was not clearer in an earlier reply: this PR may now be
 closed as it has been resolved by a fix on DragonFly.

State-Changed-From-To: feedback->closed
State-Changed-By: obache@NetBSD.org
State-Changed-When: Fri, 08 Mar 2013 02:22:43 +0000
State-Changed-Why:
resolved.


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.