Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 7 Jan 2014 17:48:38 GMT
From:      Jan Henrik Sylvester <me@janh.de>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/185558: [PATCH] x11-toolkits/sdl_pango fix build on 10.0
Message-ID:  <201401071748.s07Hmcp0028659@oldred.freebsd.org>
Resent-Message-ID: <201401071750.s07Ho0sV088179@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         185558
>Category:       ports
>Synopsis:       [PATCH] x11-toolkits/sdl_pango fix build on 10.0
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Jan 07 17:50:00 UTC 2014
>Closed-Date:
>Last-Modified:
>Originator:     Jan Henrik Sylvester
>Release:        10.0-RC4 amd64
>Organization:
>Environment:
>Description:
[Patch sent to maintainer for comments on 2013-12-31 without response. Repeating it here for it not to get lost.]

x11-toolkits/sdl_pango fails on 10 due to clang expecting a prototype and later detecting a conflict to the implicit definition:
SDL_Pango.c:345:5: warning: implicit declaration of function
      'SDLPango_CopyFTBitmapToSurface' is invalid in C99
      [-Wimplicit-function-declaration]
    SDLPango_CopyFTBitmapToSurface(
    ^
SDL_Pango.c:661:1: error: conflicting types for
'SDLPango_CopyFTBitmapToSurface'
SDLPango_CopyFTBitmapToSurface(
^

Remark: x11-toolkits/sdl_pango did build earlier on 10, but it fails now.
>How-To-Repeat:
Try to build x11-toolkits/sdl_pango on 10.0-RC4/amd64.
>Fix:
With the patch attached, x11-toolkits/sdl_pango builds, packages, and runs (a port using it runs fine) on 10.0-RC4/amd64.

Since the patch only declares a prototype exactly as the function is defined later in that file, it should be safe considering other FreeBSD versions.

The patch is applied to a file with DOS linebreaks on does contain them from line 7 to line 17. In case this is lost here, I can upload it somewhere or mail it encoded differently.

Patch attached with submission follows:

--- x11-toolkits/sdl_pango/files/patch-src_SDL_Pango.c.orig	1970-01-01 01:00:00.000000000 +0100
+++ x11-toolkits/sdl_pango/files/patch-src_SDL_Pango.c	2013-12-31 15:27:37.000000000 +0100
@@ -0,0 +1,14 @@
+--- src/SDL_Pango.c~	2013-12-31 14:26:31.000000000 +0000
++++ src/SDL_Pango.c	2013-12-31 14:22:36.000000000 +0000
+@@ -330,6 +330,11 @@
+     @param *rect [in] Draw on this area
+     @param baseline [in] Horizontal location of glyphs
+ */
++void SDLPango_CopyFTBitmapToSurface(
++    const FT_Bitmap *bitmap,
++    SDL_Surface *surface,
++    const SDLPango_Matrix *matrix,
++    SDL_Rect *rect);
+ static void
+ drawGlyphString(
+     SDLPango_Context *context,


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201401071748.s07Hmcp0028659>