Fix build with --with-included-glib on Darwin

Dan Nicholson nicholson at endlessm.com
Fri Feb 26 17:14:49 UTC 2016


On Fri, Jan 29, 2016 at 8:03 PM, Adam Mercer <ramercer at gmail.com> wrote:
> On Sun, Nov 8, 2015 at 8:33 AM, Rudá Moura <ruda.moura at gmail.com> wrote:
>> This proposed patch correctly build pkg-config with option
>> --with-included-glib enabled on Darwin.
>>
>> Darwin (OS X) requires Carbon and CoreFoundation frameworks linked,
>> otherwise
>> there will be missing symbols:
>>
>> Undefined symbols for architecture x86_64:
>>   "_CFRelease", referenced from:
>>       _find_folder in libglib-2.0.a(libglib_2_0_la-gutils.o)
>>   "_CFStringGetCString", referenced from:
>>       _find_folder in libglib-2.0.a(libglib_2_0_la-gutils.o)
>>   "_CFStringGetCStringPtr", referenced from:
>>       _find_folder in libglib-2.0.a(libglib_2_0_la-gutils.o)
>>   "_CFStringGetLength", referenced from:
>>       _find_folder in libglib-2.0.a(libglib_2_0_la-gutils.o)
>>   "_CFURLCopyFileSystemPath", referenced from:
>>       _find_folder in libglib-2.0.a(libglib_2_0_la-gutils.o)
>>   "_CFURLCreateFromFSRef", referenced from:
>>       _find_folder in libglib-2.0.a(libglib_2_0_la-gutils.o)
>>   "_FSFindFolder", referenced from:
>>       _find_folder in libglib-2.0.a(libglib_2_0_la-gutils.o)
>>   "_kCFAllocatorSystemDefault", referenced from:
>>       _find_folder in libglib-2.0.a(libglib_2_0_la-gutils.o
>
> Just ran into this issue myself and this patch fixed it for me.


Sorry for being slow on this. This is also
https://bugs.freedesktop.org/show_bug.cgi?id=92902. Upstream seems to
have fixed this slightly differently. Can you try out the following
patch?

https://git.gnome.org/browse/glib/commit/?id=8d037c678


More information about the pkg-config mailing list