# Linker problem with Mac OS 10.9 and libAfterImage

**URL:** <https://root-forum.cern.ch/t/linker-problem-with-mac-os-10-9-and-libafterimage/16816>\
**Category:** ROOT\
**Created:** [October 29, 2013, 11:46am UTC](https://root-forum.cern.ch/t/linker-problem-with-mac-os-10-9-and-libafterimage/16816 "2013-10-29T11:46:04Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![ohma81](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/o/e9a140/32.png) [@ohma81](https://root-forum.cern.ch/u/ohma81)\
**Post date:** [October 29, 2013, 11:46am UTC](https://root-forum.cern.ch/t/linker-problem-with-mac-os-10-9-and-libafterimage/16816/1 "2013-10-29T11:46:04Z")

</div>

Hi,

I’m having problems compiling ROOT with the head version and following the instructions here: [http://root.cern.ch/phpBB3/viewtopic.php?f=3&t=17190&start=75](http://root.cern.ch/phpBB3/viewtopic.php?f=3&t=17190&start=75)

I also installed the latest XCode, the command-line tools and re-installed XQuartz.

The error message I get is:

```auto
clang++ -m64 -pipe -Wshadow -W -Wall -Woverloaded-virtual -fsigned-char -fno-common -Iinclude -stdlib=libc++ -pthread -Igraf2d/asimage/src/libAfterImage -I. -I/Users/stefanohm/Software/root/cint/cint/inc -o graf2d/asimage/src/G __ASImage.o -c graf2d/asimage/src/G__ ASImage.cxx
clang++ -dynamiclib -single_module -Wl,-dead_strip_dylibs -install_name @rpath/libASImage.so -O2 -m64 -mmacosx-version-min=10.9 -stdlib=libc++ -o lib/libASImage.so graf2d/asimage/src/TASImage.o graf2d/asimage/src/TASPluginGS.o graf2d/asimage/src/G__ASImage.o -ldl -Llib -lGraf -lMathCore lib/libAfterImage.a -L/Users/stefanohm/Library/Enthought/Canopy_64bit/User/lib -lfreetype -lz -L/usr/local/lib -L/usr/local/lib -ljpeg -lpng -lz -L/usr/X11R6/lib -lXpm -L/usr/X11R6/lib -lXext -lX11 -Llib -lCore -lCint
Undefined symbols for architecture x86_64:
  "_png_set_longjmp_fn", referenced from:
      _ASImage2png_int in libAfterImage.a(export.o)
      _png2ASImage_int in libAfterImage.a(import.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [lib/libASImage.so] Error 1
```

I have checked the png libraries in all folders and they are compatible with 64 and 32 bit, e.g.:

```auto
/usr/local/lib/libpng.dylib: Mach-O universal binary with 2 architectures
/usr/local/lib/libpng.dylib (for architecture i386):	Mach-O dynamically linked shared library i386
/usr/local/lib/libpng.dylib (for architecture x86_64):	Mach-O 64-bit dynamically linked shared library x86_64
```

Any help on how to resolve this is greatly appreciated.

[configure.txt](https://root-forum.cern.ch/uploads/default/original/2X/e/eba96512f2e0c0a43f284f722c41ce64599fb0e1.txt) (6.81 KB)

All the best, Stefan

---

_[View the full topic](https://root-forum.cern.ch/t/linker-problem-with-mac-os-10-9-and-libafterimage/16816)._
