--- camlp4/lib/Makefile.orig Mon Sep 27 16:42:33 2004 +++ camlp4/lib/Makefile Mon Sep 27 16:42:12 2004 @@ -42,19 +42,19 @@ done install: - -$(MKDIR) "$(LIBDIR)/camlp4" - cp $(TARGET) *.mli "$(LIBDIR)/camlp4/." - cp *.cmi "$(LIBDIR)/camlp4/." - test -f $(TARGET:.cma=.cmxa) && $(MAKE) installopt LIBDIR="$(LIBDIR)" || true + -$(MKDIR) "$(DESTROOT)$(LIBDIR)/camlp4" + cp $(TARGET) *.mli "$(DESTROOT)$(LIBDIR)/camlp4/." + cp *.cmi "$(DESTROOT)$(LIBDIR)/camlp4/." + test -f $(TARGET:.cma=.cmxa) && $(MAKE) installopt LIBDIR="$(LIBDIR)" DESTROOT="$(DESTROOT)" || true installopt: for f in $(TARGET:.cma=.cmxa) $(TARGET:.cma=.p.cmxa) *.cmx ; do \ - test -f $$f && cp $$f "$(LIBDIR)/camlp4/." || true ; \ + test -f $$f && cp $$f "$(DESTROOT)$(LIBDIR)/camlp4/." || true ; \ done # Special treatment for this one: some versions of make don't like $(A) in $(TARGET:.cma=.$(A)) target="`echo $(TARGET) | sed -e 's/\.cma$$/.$(A)/'`" ; \ if test -f $$target ; then \ - cp $$target "$(LIBDIR)/camlp4/." && ( cd "$(LIBDIR)/camlp4/." && $(RANLIB) $$target ) \ + cp $$target "$(DESTROOT)$(LIBDIR)/camlp4/." && ( cd "$(DESTROOT)$(LIBDIR)/camlp4/." && $(RANLIB) $$target ) \ fi include .depend