On 01/05/02 23:33 -0700, Clint Olsen wrote:
> Perhaps this is a problem with MakeMaker, but when I pass anything in LIBS,
> it's not showing up in the auto-generated Makefile. I've seen other
> references to this on this list and on newsgroups, however I've never seen
> a response to it.
I think that LIBS behaviour is non-obvious. I played with it directly this
morning and could not get it to affect the Makefile. However, I *know* this
stuff works because I've used it before. So I grabbed an example from the
Inline::C-Cookbook (the one for Term::Readline) and ran it on a Linux system
with the NOCLEAN option. Here's the relevant bits from the Makefile:
(Makefile.PL)
'LIBS' => [
'-lreadline -lncurses -lterminfo -ltermcap '
],
(Makefile)
# LIBS => [q[-lreadline -lncurses -lterminfo -ltermcap]]
....
# --- MakeMaker const_loadlibs section:
EXTRALIBS = -lreadline -lncurses -ltermcap
LDLOADLIBS = -lreadline -lncurses -ltermcap
....
# --- MakeMaker dynamic_lib section:
# This section creates the dynamically loadable $(INST_DYNAMIC)
# from $(OBJECT) and possibly $(MYEXTLIB).
ARMAYBE = :
OTHERLDFLAGS =
INST_DYNAMIC_DEP =
$(INST_DYNAMIC): $(OBJECT) $(MYEXTLIB) $(BOOTSTRAP) $(INST_ARCHAUTODIR)/.exists
$(EXPORT_LIST) $(PERL_ARCHIVE) $(PERL_ARCHIVE_AFTER) $(INST_DYNAMIC_DEP)
$(RM_F) $@
LD_RUN_PATH="$(LD_RUN_PATH)" $(LD) $(LDDLFLAGS) $(LDFROM) $(OTHERLDFLAGS) -o
$@ $(MYEXTLIB) $(PERL_ARCHIVE) $(LDLOADLIBS) $(PERL_ARCHIVE_AFTER) $(EXPORT_LIST)
$(CHMOD) $(PERM_RWX) $@
....
Hope this helps, Brian