Opened 13 months ago

Closed 6 weeks ago

#61487 closed defect (fixed)

glew @2.1.0: Undefined symbols: "_CGLReleaseContext" on Tiger

Reported by: kencu (Ken) Owned by: jmroot (Joshua Root)
Priority: Normal Milestone:
Component: ports Version:
Keywords: tiger Cc:
Port: glew

Description

It may be a stretch, but I thought I would try glew on Tiger PPC.

I got to here:

src/glewinfo.c:16748: warning: implicit declaration of function 'CGLReleaseContext'
/opt/local/bin/gcc-apple-4.2 -Os -Wall -W -Iinclude -dynamic -fno-common -pedantic -fPIC -arch ppc -std=c89 -o bin/glewinfo tmp/darwin/default/shared/glewinfo.o -Llib  -lGLEW -arch ppc -framework OpenGL
Undefined symbols:
  "_CGLReleaseContext", referenced from:
      _glewDestroyContext in glewinfo.o
  "_CGLReleasePixelFormat", referenced from:
      _glewCreateContext in glewinfo.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
make: *** [bin/glewinfo] Error 1

Attachments (2)

glew-2.1.0-fail-tiger-ppc.log (614.6 KB) - added by kencu (Ken) 13 months ago.
patch-glew-tiger-ppc.diff (3.1 KB) - added by kencu (Ken) 13 months ago.

Download all attachments as: .zip

Change History (6)

Changed 13 months ago by kencu (Ken)

comment:1 Changed 13 months ago by kencu (Ken)

simple fix, in the end:

$ port -v installed glew
The following ports are currently installed:
  glew @1.12.0_0 platform='darwin 8' archs='ppc' date='2016-07-20T20:26:43-0700'
  glew @2.1.0_0 (active) platform='darwin 8' archs='ppc' date='2020-11-15T16:02:02-0800'

patch coming

Changed 13 months ago by kencu (Ken)

Attachment: patch-glew-tiger-ppc.diff added

comment:2 Changed 13 months ago by kencu (Ken)

I slightly modified the Makefile patch, to remove -pedantic and thereby remove hundreds of warnings from gcc about this:

src/glew.c:12151: warning: ISO C forbids conversion of object pointer to function pointer type

comment:3 Changed 13 months ago by kencu (Ken)

One more little thing needs to be done on Tiger, to change the glew.h header to include AvailabilityMacros.h instead of Availability.h.

comment:4 Changed 6 weeks ago by evanmiller (Evan Miller)

Resolution: fixed
Status: assignedclosed

In 0fb6fdd68b1975814d5f7b7bacc45b9be591768f/macports-ports (master):

glew: fix build on Tiger

Patch from @kencu's TigerPorts

Closes: #61487

Note: See TracTickets for help on using tickets.