X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=Makefile;h=670eac72ef7a1156f1e1cbcd688a56e0d5c8d45e;hb=50afb3c579d9eba76f4433881f3a8c67c11fa8bc;hp=4eb83e76faeb6af9e2c84728db111eba673530a3;hpb=cb80e7a5dc0b9973b1f030618be5940eae6cbcf8;p=ghc-hetmet.git diff --git a/Makefile b/Makefile index 4eb83e7..670eac7 100644 --- a/Makefile +++ b/Makefile @@ -56,14 +56,14 @@ extraclean:: # make sure it gets built early on. # ifeq "$(HAPPY)" "$(FPTOOLS_TOP_ABS)/happy/src/happy-inplace" -build : $(FPTOOLS_TOP_ABS)/happy/src/happy-inplace +build :: $(FPTOOLS_TOP_ABS)/happy/src/happy-inplace $(FPTOOLS_TOP_ABS)/happy/src/happy-inplace : glafp-utils $(MAKE) -C happy boot all endif # Build all projects that we know about -build : +build :: @case '${MFLAGS}' in *-[ik]*) x_on_err=0;; *-r*[ik]*) x_on_err=0;; *) x_on_err=1;; esac; \ for i in $(SUBDIRS); do \ if [ -d $$i ]; then \ @@ -121,6 +121,28 @@ install :: fi; \ done +# If installing on Windows with MinGW32, copy the gcc compiler, headers and libs +# and the perl interpreter and dll into the GHC prefix directory. +# Gcc and Perl source locations derived from configuration data. +ifeq "$(TARGETPLATFORM)" "i386-unknown-mingw32" +ifneq "$(WhatGccIsCalled)" "" +install :: + -mkdir $(prefix)/gcc-lib + -mkdir $(prefix)/include + -mkdir $(prefix)/include/mingw + -cp -rp $(GccDir)../include/* $(prefix)/include/mingw + -cp -rp $(GccDir)../lib/gcc-lib/mingw32/$(GccVersion)/* $(prefix)/gcc-lib + -cp $(GccDir)../lib/*.* $(prefix)/gcc-lib + -cp $(GccDir)gcc.exe $(prefix) + -cp $(GccDir)as.exe $(prefix)/gcc-lib + -cp $(GccDir)ld.exe $(prefix)/gcc-lib + -cp $(GccDir)dllwrap.exe $(prefix)/gcc-lib + -cp $(GccDir)dlltool.exe $(prefix)/gcc-lib + -cp $(GhcDir)../perl.exe $(prefix) + -cp $(GhcDir)../perl56.dll $(prefix) +endif +endif + install-docs :: @case '${MFLAGS}' in *-[ik]*) x_on_err=0;; *-r*[ik]*) x_on_err=0;; *) x_on_err=1;; esac; \ for i in $(filter-out $(ProjectsDontInstall), $(SUBDIRS)); do \ @@ -261,17 +283,18 @@ BINDIST_DOC_WAYS = html ps # BINDIST_DOC_WAYS = binary-dist :: +ifneq "$(DOCBOOK_CATALOG)" "" @for i in $(BIN_DIST_DIRS); do \ if test -d "$$i"; then \ $(MAKE) -C $$i $(MFLAGS) $(BINDIST_DOC_WAYS); \ - echo $(MAKE) -C $$i $(MFLAGS) install-docs SGMLDocWays="$(BINDIST_DOC_WAYS)" \ + echo $(MAKE) -C $$i $(MFLAGS) install-docs XMLDocWays="$(BINDIST_DOC_WAYS)" \ prefix=$(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME) \ exec_prefix=$(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME) \ bindir=$(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME)/bin/$(TARGETPLATFORM) \ libdir=$(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME)/lib/$(TARGETPLATFORM) \ libexecdir=$(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME)/lib/$(TARGETPLATFORM) \ datadir=$(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME)/share; \ - $(MAKE) -C $$i $(MFLAGS) install-docs SGMLDocWays="$(BINDIST_DOC_WAYS)" \ + $(MAKE) -C $$i $(MFLAGS) install-docs XMLDocWays="$(BINDIST_DOC_WAYS)" \ prefix=$(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME) \ exec_prefix=$(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME) \ bindir=$(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME)/bin/$(TARGETPLATFORM) \ @@ -280,6 +303,7 @@ binary-dist :: datadir=$(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME)/share; \ fi \ done +endif # Rename scripts to $i.prl and $i.sh where necessary. # ToDo: do this in a cleaner way...