summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorDamien Doligez <damien.doligez-inria.fr>2015-07-15 14:53:12 +0000
committerDamien Doligez <damien.doligez-inria.fr>2015-07-15 14:53:12 +0000
commit871de903670914c181d108aedd81081569a99334 (patch)
treea853221824f30683d314168280545b630ddac326 /configure
parentca2db8a939dc16c2a88cba9ecb8f7e22fc21d076 (diff)
downloadocaml-871de903670914c181d108aedd81081569a99334.tar.gz
add libbfd configuration for MacOS
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16211 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure14
1 files changed, 13 insertions, 1 deletions
diff --git a/configure b/configure
index 3afcdb49a5..8d6edd0b18 100755
--- a/configure
+++ b/configure
@@ -1609,9 +1609,21 @@ if sh ./hasgot -DPACKAGE=ocaml -i bfd.h && \
inf "BFD library found."
echo "#define HAS_LIBBFD" >> s.h
echo "LIBBFD_LINK=-lbfd -ldl -liberty -lz" >> Makefile
+ echo LIBBFD_INCLUDE= >>Makefile
+elif sh ./hasgot -DPACKAGE=ocaml -I/opt/local/include -i bfd.h && \
+ sh ./hasgot -DPACKAGE=ocaml -L/opt/local/lib -lbfd -ldl \
+ -liberty -lz -lintl bfd_openr
+then
+ # MacOSX with binutils from MacPorts
+ inf "BFD library found."
+ echo "#define HAS_LIBBFD" >> s.h
+ echo "LIBBFD_LINK=-L/opt/local/lib -lbfd -ldl -liberty -lz -lintl" >> Makefile
+ echo LIBBFD_INCLUDE=-I/opt/local/include >>Makefile
else
- wrn "BFD library not found, 'objinfo' will be unable to display info on .cmxs files."
+ wrn "BFD library not found, 'objinfo' will be unable to display info" \
+ " on .cmxs files."
echo "LIBBFD_LINK=" >> Makefile
+ echo "LIBBFD_INCLUDE=" >> Makefile
fi
# Check whether assembler supports CFI directives