[project @ 2004-07-19 11:29:34 by simonpj]
[ghc-hetmet.git] / mk / target.mk
index 40ce44e..109dbfc 100644 (file)
@@ -234,8 +234,8 @@ ifneq "$(HS_PROG)" ""
 all :: $(HS_PROG)
 
 ifneq "$(BootingFromHc)" "YES"
-$(HS_PROG) :: $(HS_OBJS) $(C_OBJS)
-       $(HC) -o $@ $(HC_OPTS) $(LD_OPTS) $(HS_OBJS) $(C_OBJS)
+$(HS_PROG) :: $(OBJS)
+       $(HC) -o $@ $(HC_OPTS) $(LD_OPTS) $(OBJS)
 else
 # see bootstrap.mk
 $(HS_PROG) :: $(OBJS)
@@ -324,7 +324,7 @@ HC_SPLIT_PRE = \
     $(RM) $@; if [ ! -d $(basename $@)_split ]; then mkdir $(basename $@)_split; else \
     $(FIND) $(basename $@)_split -name '*.$(way_)o' -print | xargs $(RM) __rm_food; fi
 ifeq "$(GhcWithInterpreter)" "YES"
-HC_SPLIT_POST = (cd $(dir $@) && $(LD) -r $(LD_X) -o $(notdir $@) $(basename $(notdir $@))_split/*.$(way_)o)
+HC_SPLIT_POST = (cd $(basename $@)_split && $(LD) -r $(LD_X) -o ../$(notdir $@) *.$(way_)o)
 else
 HC_SPLIT_POST = touch $@
 endif # GhcWithInterpreter == YES
@@ -795,12 +795,14 @@ install:: $(INSTALL_INCLUDES)
 endif
 
 ifneq "$(INSTALL_DOCS)" ""
+ifneq "$(SGMLDocWays)" ""
 install-docs:: $(INSTALL_DOCS)
        @$(INSTALL_DIR) $(datadir)      
        for i in $(INSTALL_DOCS); do \
                $(INSTALL_DATA) $(INSTALL_OPTS) $$i $(datadir); \
        done
 endif
+endif
 
 ifneq "$(INSTALL_SGML_DOC)" ""
 ifneq "$(SGMLDocWays)" ""