Skip to main content
Enterprise Agile Planning Image

This post is from the CollabNet VersionOne blog and has not been updated since the original publish date.

Last Updated Apr 17, 2007 — Enterprise Agile Planning expert

Compiling JavaHL On Mac OS X

Enterprise Agile Planning

 

Usually compiling JavaHL is pretty simple: just follow the directions
mentioned in the source code. Not on OS X though, there is an anomaly on
OS X when running "make javahl" or "make
install-javahl". When you run these make targets on OS X, you get
output like this:

ld: multiple definitions of symbol ___divdi3
/usr/lib/gcc/powerpc-apple-darwin8/4.0.1/libgcc.a(_divdi3.o) private external definition of
___divdi3 in section (__TEXT,__text)
/usr/lib/libgcc_s.10.4.dylib(_divdi3_s.o) definition of ___divdi3
ld: multiple definitions of symbol ___udivdi3
/usr/lib/gcc/powerpc-apple-darwin8/4.0.1/libgcc.a(_udivdi3.o) private external definition of
__udivdi3 in section (__TEXT,__text)
/usr/lib/libgcc_s.10.4.dylib(_udivdi3_s.o) definition of ___udivdi3
ld: multiple definitions of symbol ___umoddi3
/usr/lib/gcc/powerpc-apple-darwin8/4.0.1/libgcc.a(_umoddi3.o) private external definition of
___umoddi3 in section (__TEXT,__text)
/usr/lib/libgcc_s.10.4.dylib(_umoddi3_s.o) definition of ___umoddi3
/usr/bin/libtool: internal link edit command failed
make: *** [subversion/bindings/java/javahl/native/libsvnjavahl-1.la] Error 1

After digging around, I finally joined the #fink irc channel on
irc.freenode.net and started asking questions (I heard they had a working
script to compile the JavaHL bindings.) After talking to a few people in
#fink, they passed me this nice little snippet that fixed the problem:

perl -pi -e "s/-all_load//g" libtool

The above Perl call removes the "-all_load" flag from libtool to
work around a libtool issue on the Mac. Going into deeper detail is really
a libtool matter and I’ll omit that here but let me give you a little cheat sheet for building the JavaHL bindings from
scratch. Here are the brief steps:

  1. Download Subversion source.
  2. Change directory to where you downloaded the Subversion source.
  3. Run "./autogen.sh".
        
  4. Run "./configure <your_flags>". 
  5. Run "make". 
  6. Run "perl -pi -e  "s/-all_load//g" libtool". 
  7. Run "make javahl".
        
  8. Run "make install-javahl".

If you follow the steps above, you’ll have a working JavaHL
installation on your OS X system.  Enjoy.

More from the Blog

View more
Apr 08, 2021

Making IT services more agile

Enterprise Agile Planning
The agile revolution completely transformed how we create digital prod ...
Read More
Feb 14, 2021

Reflecting on the 20th anniversary of the Agile Manifesto

Enterprise Agile Planning
Over the past 20 years, it’s been amazing to watch an idea from ...
Read More
Feb 08, 2021

How does agile apply to an entire organization?

Enterprise Agile Planning
Before we dive into the main subject of this blog post, it is importan ...
Read More
Feb 03, 2021

It took a pandemic to realize why digital transformation actually matters

Enterprise Agile Planning
Before anyone had ever heard of COVID-19, businesses across the globe ...
Read More
Contact Us