Opened 6 years ago

Closed 6 years ago

#18364 closed defect (duplicate)

Building libgd fails if libvpx 1.4 is installed

Reported by: gagern Owned by:
Priority: major Milestone: sage-duplicate/invalid/wontfix
Component: packages: standard Keywords:
Cc: Merged in:
Authors: Reviewers: Martin von Gagern
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges


I currently fail to build sage 6.7.beta1 from scratch:

libtool: compile:  gcc -std=gnu99 -DHAVE_CONFIG_H -I. -I…/sage/local/include/libpng12 -I…/sage/local/include/freetype2 -g -fvisibility=hidden -MT webpimg.lo -MD -MP -MF .deps/webpimg.Tpo -c webpimg.c  -fPIC -DPIC -o .libs/webpimg.o
webpimg.c: In function 'VPXEncode':
webpimg.c:714:24: error: 'IMG_FMT_I420' undeclared (first use in this function)
     vpx_img_wrap(&img, IMG_FMT_I420,
webpimg.c:714:24: note: each undeclared identifier is reported only once for each function it appears in
webpimg.c:716:16: error: 'PLANE_Y' undeclared (first use in this function)
     img.planes[PLANE_Y] = (uint8*)(Y);
webpimg.c:717:16: error: 'PLANE_U' undeclared (first use in this function)
     img.planes[PLANE_U] = (uint8*)(U);
webpimg.c:718:16: error: 'PLANE_V' undeclared (first use in this function)
     img.planes[PLANE_V] = (uint8*)(V);
Makefile:773: recipe for target 'webpimg.lo' failed
make[5]: *** [webpimg.lo] Error 1
make[5]: Leaving directory '…/sage/local/var/tmp/sage/build/libgd-2.1.0.p0/src/src'
Makefile:439: recipe for target 'all' failed
make[4]: *** [all] Error 2
make[4]: Leaving directory '…/sage/local/var/tmp/sage/build/libgd-2.1.0.p0/src/src'
Makefile:341: recipe for target 'all-recursive' failed
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory '…/sage/local/var/tmp/sage/build/libgd-2.1.0.p0/src'
Error building gd.

This is related to the auto-detected configure setting

   Support for VPX library:          yes

Fortunately I've recently encountered the same issue for Gentoo with the libgd bundled with php (Gentoo bug #547310). The issue is related to this change for libvpx, which removed some legacy symbols. Prefixing those symbols with VPX_ solves the issue, as done in this commit to the GD-2.1 branch.

I think we have at least four solutions at our disposal:

  1. Fix symbol names in libgd 2.1 by patching in this commit
  2. Explicitely disable libvpx support, to avoid linking against system library there
  3. Bundle libvpx at a given version to become independent of system library
  4. Upgrade to libgd 2.2 (once that's available), which should use libwebp instead of libvpx according to libgd ticket #129

Which solution would you prefer? 1. differs the least from what we currently do, but that doesn't neccessarily make it the best solution.

Change History (3)

comment:1 Changed 6 years ago by aapitzsch

  • Milestone changed from sage-6.7 to sage-duplicate/invalid/wontfix
  • Status changed from new to needs_review

Duplicate of #18293.

comment:2 Changed 6 years ago by gagern

  • Reviewers set to Martin von Gagern
  • Status changed from needs_review to positive_review

comment:3 Changed 6 years ago by vbraun

  • Resolution set to duplicate
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.