-cat >mk/build.mk <<END
-# nothing!
-END
-
-# touch happy generated files; so that in non-bootstrapping mode for
-# installation, no attempt is made to call happy
-#
-touch ghc/compiler/rename/ParseIface.hs
-touch ghc/compiler/parser/Parser.hs
-touch ghc/compiler/main/ParsePkgConf.hs
-
-echo "*** Building hsc..."
+case configopts in
+*--enable-hc-boot-unregisterised*)
+ cat >mk/build.mk <<END
+ GhcWithInterpreter=NO
+ GhcWithNativeCodeGen=NO
+ END
+ ;;
+*)
+ cat >mk/build.mk <<END
+ # empty
+ END
+esac
+
+echo "*** Building compiler..."