}

OSX Solution: PKG_CONFIG_PATH environment variable No package 'glib-2.0' found

Created:

The error

When you execute:

$ pkg-config --print-errors --exists glib-2.0 >= 2.48.0 if(typeof __ez_fad_position != 'undefined'){__ez_fad_position('div-gpt-ad-tutorials_technology-medrectangle-3-0')}; You have the following error:

Package glib-2.0 was not found in the pkg-config search path. Perhaps you should add the directory containing glib-2.0.pc' to the PKG\_CONFIG\_PATH environment variable No package 'glib-2.0' found Package 2.48.0 was not found in the pkg-config search path. Perhaps you should add the directory containing2.48.0.pc' to the PKG_CONFIG_PATH environment variable No package '2.48.0' found

Solution

First install glib with brew

brew install glib

In some cases, brew could output that the glib is already installed:

if(typeof __ez_fad_position != 'undefined'){__ez_fad_position('div-gpt-ad-tutorials_technology-medrectangle-4-0')};Error: glib 2.64.0 is already installed To upgrade to 2.64.1, run brew upgrade glib.

You will need to also setup the PKG_CONFIG_PATH to have the glib:

$ export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/Cellar/glib/VERSION/lib/pkgconfig