[Geany-devel] OSX build error: ld: unknown option: --export-dynamic
mbrush at xxxxx
Tue Jul 17 20:43:08 UTC 2012
On 12-07-17 01:32 PM, Sean Felipe Wolfe wrote:
> Sorry to be kind of spammy today. Just ran into what looks like a
> build error? I cloned the git repo, ran autogen.sh, and make is giving
> me this error:
> CC utils.o
> CC vte.o
> CXXLD geany
> ld: unknown option: --export-dynamic
> This is on osx Lion. Any suggestions?
Yep, this and your last problem were both things I had to figure out
too. This export dynamic problem is because Geany doesn't deal with OSX
separately and lumps it in with "non-Windows" in the Makefile.
Unfortunately this linker flag is invalid on OSX but is needed on Linux
(and others?) for Glade to connect to the signal handlers at runtime.
Quick Fix: Just delete everywhere you see `-Wl,--export-dynamic` in the
Makefile.am files (probably only in `src/Makefile.am`). We can't do this
in Geany proper because it won't work correctly on Linux then.
Real Fix: In the configure.ac, detect OSX somehow and do an
AM_CONDITIONAL or something like this so that the Makefile can set the
LDFLAGS differently for OSX than other Unices. If done correctly, a
patch would be most welcome. I can't remember if I fixed this properly
in my changes or if I just did the quick fix.
More information about the Devel