When using relative path to specify ALT_OUTPUTDIR which contains where you want the generated files go, it will generate a redudant directory which contains nothing. This is because $(hotspot workspace)/make/defs.make is included twice, one is in the top level Makefile and the other is included in the os specific Makefile. When it is included in the os level Makefile, the working directory is the real ALT_OUTPUTDIR and there is a statement in defs.make to find out the absolute output directory (ABS_OUTPUTDIR) which makes OUTPUTDIR directory if OUTPUTDIR is still relative path.
The fix is to pass OUTPUTDIR=$(ABS_OUTPUTDIR) to MAKE_ARGS when launching make with the os level makefile. That will fix it.
Alone with the above fix, we should also avoid including defs.make from rules.make which will break the build when doing incremental build under the output directory. This is also due to the way we define GAMMADIR in defs.make. Unless GAMMADIR is specified in the make command which is true when building from the make directory, it will be re-evaluated by traversing the directory to find src directory. This of course will not work when building from the output directory.