Uses straightforward SO install name on Darwin.

When building for Darwin, the SO generated is given the install_name
"@rpath/libre2". Other SOs will as a result be unable to dlopen this.
(I haven't figured out exactly which circumstances this occurs, though
it appears to be a widespread problem---see below.) The obvious thing
to do is to give it traditional install_name, which is $(libdir)/libre2.

Homebrew, the package manager for Mac OS X, in fact incorporates a patch
of sorts to fix exactly this problem: after running "make install" with
the provided Makefile, it uses the obscure "install_name_tool" to repair
the install_name to exactly this. I have confirmed this is necessary to
dlopen libre2 on El Capitan.

(NB: This commit makes the Homebrew patch otiose.)

Change-Id: Ia5835dbaa591a66a4698a64b0b8b02c64e145de0
Reviewed-on: https://code-review.googlesource.com/4250
Reviewed-by: Paul Wankadia <junyer@google.com>
diff --git a/Makefile b/Makefile
index 645b364..1c04cb9 100644
--- a/Makefile
+++ b/Makefile
@@ -55,7 +55,7 @@
 SOEXT=dylib
 SOEXTVER=$(SONAME).$(SOEXT)
 SOEXTVER00=$(SONAME).0.0.$(SOEXT)
-MAKE_SHARED_LIBRARY=$(CXX) -dynamiclib -Wl,-install_name,@rpath/libre2.$(SOEXTVER),-exported_symbols_list,libre2.symbols.darwin $(RE2_LDFLAGS) $(LDFLAGS)
+MAKE_SHARED_LIBRARY=$(CXX) -dynamiclib -Wl,-install_name,$(libdir)/libre2.$(SOEXTVER),-exported_symbols_list,libre2.symbols.darwin $(RE2_LDFLAGS) $(LDFLAGS)
 else ifeq ($(shell uname),SunOS)
 SOEXT=so
 SOEXTVER=$(SOEXT).$(SONAME)