Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Undefined symbols for architecture x86_64: "_CFRelease"

I am quite new to the Unix world and I am trying to install a software called Meep for physics simulations. To get this I need to install a lot of libraries on my Mac OS X 10.10.5; I succeeded in many of them but I had the following error while commanding 'configure' for the script called pkg-config which works over glib.

CCLD     pkg-config
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)
ld: symbol(s) not found for architecture x86_64

Looking around I have understood that could be a linker problem to those symbols, but essentially I have no idea to solve the problem. Can anybody help me?

like image 681
G.Gatti Avatar asked Mar 01 '16 20:03

G.Gatti


1 Answers

You need to add:

-framework CoreFoundation

to the link command line of your project.

like image 126
Alex Reche Martinez Avatar answered Nov 18 '22 09:11

Alex Reche Martinez