Bug 248902 - multimedia/obs-studio: fix new linker duplicate symbol error
Summary: multimedia/obs-studio: fix new linker duplicate symbol error
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Many People
Assignee: Tobias C. Berner
URL:
Keywords: needs-qa
Depends on:
Blocks: 248756
  Show dependency treegraph
 
Reported: 2020-08-25 09:16 UTC by Dave Cottlehuber
Modified: 2020-08-29 00:38 UTC (History)
2 users (show)

See Also:
bugzilla: maintainer-feedback? (yuri)
koobs: merge-quarterly?


Attachments
patch linker duplicate symbol error (672 bytes, text/plain)
2020-08-25 09:16 UTC, Dave Cottlehuber
no flags Details
same patch but bump PORTREVISION also (1.01 KB, patch)
2020-08-25 09:47 UTC, Dave Cottlehuber
koobs: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dave Cottlehuber freebsd_committer 2020-08-25 09:16:22 UTC
Created attachment 217515 [details]
patch linker duplicate symbol error

fix linker duplicate symbol gladGetProcAddressPtr

The following error comes during build (poudriere 13.0-CURRENT amd64)"
    
    ld: error: duplicate symbol: gladGetProcAddressPtr
    >>> defined at glad.c
    >>>            deps/glad/CMakeFiles/glad.dir/src/glad.c.o:(gladGetProcAddressPtr)
    >>> defined at glad_glx.c
    >>>            deps/glad/CMakeFiles/glad.dir/src/glad_glx.c.o:(.bss+0x8)
    cc: error: linker command failed with exit code 1 (use -v to see invocation)
    ninja: build stopped: subcommand failed.

Plucked from upstream commit c7f84f8fc4e90ef779a204ac268f5ee1a962e324 from Jimi Huotari <chiitoo@gentoo.org>:

    deps/glad: Fix build with GCC-10
    
    GCC-10 defaults to '-fno-common' [1], which triggers issues with
    defining global variables multiple times.  To fix the build, use
    'extern' to turn the first definition of 'gladGetProcAddressPtr'
    into a declaration.
    
    1. https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85678
    
    Closes https://github.com/obsproject/obs-studio/issues/2828
Comment 1 Dave Cottlehuber freebsd_committer 2020-08-25 09:47:27 UTC
Created attachment 217517 [details]
same patch but bump PORTREVISION also

Mea culpa, this should have PORTREVISION bumped as well.
Comment 2 Kubilay Kocak freebsd_committer freebsd_triage 2020-08-26 05:52:07 UTC
Comment on attachment 217517 [details]
same patch but bump PORTREVISION also

@Dave, build, run, package fixes are:

Approved by: portmgr (blanket: build fix)
MFH: 2020Q3 (blanket: build fix)
Comment 3 Kyle Evans freebsd_committer 2020-08-29 00:38:12 UTC
Fix was committed as r546339 independently, but the same patch. Thanks! Assigning to committer that committed and closing as FIXED.