|
Hi guys, I have a Makefile which looks like this, but at he moment it chucks all the .objs and .pchs into the same directory as the source files.
I'm not that good with nmake Makefile syntax, do you know how (like the Vis Studio IDE does) you can get it to put the .objs into a subdirectory like say Debug/Direct.obj or Release/Direct.obj or XBox/Direct.obj to save cluttering up the source directory?
Cheers in advance...
CPP =d:\xdk\xbox\bin\vc71\cl.exe LINK=d:\xdk\xbox\bin\vc71\link.exe IMAGEBLD=d:\xdk\xbox\bin\imagebld.exe
CFLAGS=/nologo /D_XBOX /I. /Id:\xdk\xbox\include /W4 /Ox /MT /YX LFLAGS= /libpath:d:\xdk\xbox\lib /subsystem:xbox /map
OBJS=DSound.obj Emu.obj Input.obj LightCal.obj Loop.obj Main.obj Rom.obj \ Direct.obj FileMenu.obj Font.obj TexScreen.obj \ Unzip.obj zlib.lib \ ..\Mast\mast.lib
LIBS=d3d8.lib d3dx8.lib xapilib.lib xboxkrnl.lib xgraphics.lib dsound.lib
all : default.xbe
# Convert .exe to XBox .xbe: default.xbe : default.exe $(IMAGEBLD) default.exe /out:default.xbe del default.exe del *.map xbcp /y /t default.xbe xe:\DegaBox\DegaBox.xbe
# Link into .exe: default.exe : $(OBJS) $(LINK) $(LFLAGS) /out:default.exe $(OBJS) $(LIBS)
# Compile .cpp files: .cpp.obj: @$(CPP) $(CFLAGS) /c $*.cpp
CLEANUP=*.xbe default.exe *.map *.obj *.pch clean : for %i in ( $(CLEANUP) ) do if exist %i del %i
You learn something old everyday...
|