[build] Move userland utility into subdir
authorShao Miller <Shao.Miller@yrdsb.edu.on.ca>
Fri, 30 Apr 2010 21:26:12 +0000 (17:26 -0400)
committerShao Miller <Shao.Miller@yrdsb.edu.on.ca>
Fri, 30 Apr 2010 21:26:12 +0000 (17:26 -0400)
Makefile
makeutils.bat
src/util/mount.c [moved from src/mount.c with 99% similarity]

index cf9892b..fa1378e 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -49,15 +49,15 @@ bin/loader32.exe: src/loader/obj/loader32.o Makefile
        gcc $(INCLUDES) -Wall src/loader/obj/loader32.o -o bin/loader32.exe -lsetupapi
        strip bin/loader32.exe
 
-src/obj/mount.o: src/mount.c src/portable.h src/mount.h Makefile
+src/util/obj/mount.o: src/util/mount.c src/portable.h src/mount.h Makefile
        @mkdir -p src/obj
-       @rm -rf src/obj/mount.o bin/aoe.exe
-       gcc -Wall -c src/mount.c -o src/obj/mount.o
+       @rm -rf src/util/obj/mount.o bin/aoe.exe
+       gcc -Wall -c src/util/mount.c -o src/util/obj/mount.o
 
-bin/aoe.exe: src/obj/mount.o Makefile
+bin/aoe.exe: src/util/obj/mount.o Makefile
        @mkdir -p bin
        @rm -rf bin/aoe.exe
-       gcc -Wall src/obj/mount.o -o bin/aoe.exe
+       gcc -Wall src/util/obj/mount.o -o bin/aoe.exe
        strip bin/aoe.exe
 
 src/obj/driver.o: src/driver.c src/portable.h src/driver.h Makefile
index 3f2ba61..81d1e23 100644 (file)
@@ -4,9 +4,12 @@ call config.bat
 cd src\r
 pushd .\r
 call %ddkdir%\bin\setenv.bat %ddkdir% w2k\r
-popd\r
-cl /I%CRT_INC_PATH% /DWIN32_LEAN_AND_MEAN mount.c /Fe..\bin\winvblk.exe /link /LIBPATH:%DDK_LIB_DEST%\i386 /LIBPATH:%Lib%\crt\i386 bufferoverflowU.lib\r
+popd
+pushd .
+cd util\r
+cl /I%CRT_INC_PATH% /DWIN32_LEAN_AND_MEAN mount.c /Fe..\..\bin\winvblk.exe /link /LIBPATH:%DDK_LIB_DEST%\i386 /LIBPATH:%Lib%\crt\i386 bufferoverflowU.lib\r
 del mount.obj
+popd
 pushd .
 cd loader\r
 cl /I%CRT_INC_PATH% /DWIN32_LEAN_AND_MEAN loader.c /Fe..\..\bin\loader32.exe /link /LIBPATH:%DDK_LIB_DEST%\i386 /LIBPATH:%Lib%\crt\i386 setupapi.lib bufferoverflowU.lib
similarity index 99%
rename from src/mount.c
rename to src/util/mount.c
index 6a2efff..975a774 100644 (file)
@@ -30,9 +30,9 @@
 #include <winioctl.h>
 #include <stdio.h>
 
-#include "winvblock.h"
-#include "portable.h"
-#include "mount.h"
+#include "../winvblock.h"
+#include "../portable.h"
+#include "../mount.h"
 
 typedef enum
 { CommandScan, CommandShow, CommandMount, CommandUmount, CommandAttach,