Skip to content

Instantly share code, notes, and snippets.

@pithyless
Forked from jpwatts/mac-homebrew-pyexiv2.sh
Created January 22, 2012 17:19
Show Gist options
  • Save pithyless/1657734 to your computer and use it in GitHub Desktop.
Save pithyless/1657734 to your computer and use it in GitHub Desktop.
In which I finally get pyexiv2 working on my Mac using Homebrew and a series of disgusting hacks
#!/bin/sh
brew install python scons boost exiv2
curl -O http://launchpadlibrarian.net/83595798/pyexiv2-0.3.2.tar.bz2
tar xjvf pyexiv2-0.3.2.tar.bz2
cd pyexiv2-0.3.2
# https://answers.launchpad.net/pyexiv2/+question/140742
echo "env['FRAMEWORKS'] += ['Python']" >> src/SConscript
scons BOOSTLIB=boost_python-mt
# https://answers.launchpad.net/pyexiv2/+question/132670
install_name_tool -change /usr/local/Cellar/python/2.7.2/Frameworks/Python.framework/Versions/2.7/Python \
/usr/local/Cellar/python/2.7.2/Frameworks/Python.framework/Versions/2.7/lib/libpython2.7.dylib \
build/libexiv2python.dylib
scons BOOSTLIB=boost_python-mt install
# https://answers.launchpad.net/pyexiv2/+question/140742
ln -s /usr/local/Cellar/python/2.7.2/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/libexiv2python.dylib \
/usr/local/Cellar/python/2.7.2/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/libexiv2python.so
@pithyless
Copy link
Author

Updated to the newest pyexiv2 version and homebrew's python 2.7.2.

Unfortunately, I'm getting segfaults on 'import pyexiv2'....

@deeGraYve
Copy link

Any luck with importing pyexiv2?

@pithyless
Copy link
Author

@deeGraYve Sorry, but I don't even remember why I needed pyexiv2. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment