in reply to stuck in perlxstut, example 4
sub MY::postamble { ' $(MYEXTLIB): mylib/Makefile cd mylib && $(MAKE) $(PASSTHRU) '; }
sub MY::top_targets { ' all :: static pure_all :: static static :: libmylib$(LIB_EXT) libmylib$(LIB_EXT): $(O_FILES) $(AR) cr libmylib$(LIB_EXT) $(O_FILES) $(RANLIB) libmylib$(LIB_EXT) '; }
(Replace the leading spaces with a tab)
The command to build the library doesn't work with MS's compiler, but it should work on Cygwin. For MS's compiler, the command needs to be changed from
$(AR) cr libmylib$(LIB_EXT) $(O_FILES)
to
$(AR) /out:$(LIB_EXT) $(O_FILES)
I don't know how to do this portably.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: stuck in perlxstut, example 4 (portability)
by ikegami (Patriarch) on Jun 29, 2009 at 04:06 UTC | |
|
Re^2: stuck in perlxstut, example 4
by fugazi (Novice) on Jun 29, 2009 at 01:03 UTC |