-all: args.exe
-
+#
+#
+#
OBJECTS= ../common/crt0.o args.o
LIBS= ../../lib/kernel32/kernel32.a ../../lib/ntdll/ntdll.a
+all: args.exe
+
+.phony: all
+
+clean:
+ - $(RM) args.o
+ - $(RM) args.exe
+ - $(RM) args.sym
+
+.phony: clean
+
args.exe: $(OBJECTS) $(LIBS)
$(CC) -specs=../../specs $(OBJECTS) $(LIBS) -lgcc -o args.exe
$(NM) --numeric-sort args.exe > args.sym
-all: hello.exe
-
+#
+#
+#
OBJECTS = ../common/crt0.o hello.o
LIBS = ../../lib/kernel32/kernel32.a ../../lib/ntdll/ntdll.a
+CLEAN_FILES = hello.o hello.exe
+
+all: hello.exe
+
+clean: $(CLEAN_FILES:%=%_clean)
+
+$(CLEAN_FILES:%=%_clean): %_clean:
+ - $(RM) $*
+
+.phony: clean $(CLEAN_FILES:%=%_clean)
hello.exe: $(OBJECTS) $(LIBS)
$(LD) $(OBJECTS) $(LIBS) -o hello.exe
LIBS= ../../lib/kernel32/kernel32.a ../../lib/ntdll/ntdll.a
+CLEAN_FILES = $(OBJECTS) cmd.exe cmd.sym
+
+clean: $(CLEAN_FILES:%=%_clean)
+
+$(CLEAN_FILES:%=%_clean): %_clean:
+ - $(RM) $*
+
+.phony: clean $(CLEAN_FILES:%=%_clean)
cmd.bin: $(OBJECTS)
$(LD) -Ttext 0x10000 $(OBJECTS) $(LIBS) -o cmd.exe
-all: shell.exe
-
+#
+#
+#
OBJECTS= ../common/crt0.o shell.o
LIBS= ../../lib/kernel32/kernel32.a ../../lib/ntdll/ntdll.a
+CLEAN_FILES= shell.o shell.exe shell.sym
+
+all: shell.exe
+
+clean: $(CLEAN_FILES:%=%_clean)
+
+$(CLEAN_FILES:%=%_clean): %_clean:
+ - $(RM) $*
+
+.phony: clean $(CLEAN_FILES:%=%_clean)
shell.exe: $(OBJECTS) $(LIBS)
$(CC) -specs=../../specs $(OBJECTS) $(LIBS) -lgcc -o shell.exe
#
#
#
-
OBJECTS = beep.o ../../../ntoskrnl/ntoskrnl.a
all: beep.sys
.PHONY: all
+clean:
+ - $(RM) beep.o
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) beep.sys
+
+.phony: clean
+
beep.sys: $(OBJECTS)
$(CC) -specs=../../svc_specs -mdll -o junk.tmp -Wl,--defsym,_end=end \
-Wl,--defsym,_edata=__data_end__ -Wl,--defsym,_etext=etext \
#include <internal/debug.h>
#define IDMAP_BASE (0xd0000000)
-
-/*
- * Return a linear address which can be used to access the physical memory
- * starting at x
- */
-extern inline unsigned int physical_to_linear(unsigned int x)
-{
- return(x+IDMAP_BASE);
-}
-
-extern inline unsigned int linear_to_physical(unsigned int x)
-{
- return(x-IDMAP_BASE);
-}
-
-
#define VIDMEM_BASE 0xb8000
#define NR_ROWS 50
--- /dev/null
+#
+#
+#
+OBJECTS = blue.o ../../../ntoskrnl/ntoskrnl.a
+
+all: blue.sys
+
+.phony: all
+
+clean:
+ - $(RM) blue.o
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) blue.sys
+
+.phony: clean
+
+blue.sys: $(OBJECTS)
+ $(CC) -specs=../../svc_specs -mdll -o junk.tmp -Wl,--defsym,_end=end \
+ -Wl,--defsym,_edata=__data_end__ -Wl,--defsym,_etext=etext \
+ -Wl,--base-file,base.tmp $(OBJECTS)
+ - $(RM) junk.tmp
+ $(DLLTOOL) --dllname blue.sys --base-file base.tmp \
+ --output-exp temp.exp
+ - $(RM) base.tmp
+ $(CC) --verbose -Wl,--image-base,0x10000 -Wl,-e,_DriverEntry@8 \
+ -specs=../../svc_specs -mdll -o blue.sys $(OBJECTS) -Wl,temp.exp
+ - $(RM) temp.exp
+
+
+#
+#
+#
+OBJECTS = ide.o ../../../ntoskrnl/ntoskrnl.a
+
all: ide.sys
-OBJECTS = ide.o ../../../ntoskrnl/ntoskrnl.a
+.phony: all
+
+clean:
+ - $(RM) ide.o
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) ide.sys
+
+.phony: clean
ide.sys: $(OBJECTS)
$(CC) -specs=../../svc_specs -mdll -o junk.tmp -Wl,--defsym,_end=end \
$(CC) --verbose -Wl,--image-base,0x10000 -Wl,-e,_DriverEntry@8 \
-specs=../../svc_specs -mdll -o ide.sys $(OBJECTS) -Wl,temp.exp
- $(RM) temp.exp
+
+#
+#
+#
+OBJECTS = keyboard.o ../../../ntoskrnl/ntoskrnl.a
+
all: keyboard.sys
-OBJECTS = keyboard.o ../../../ntoskrnl/ntoskrnl.a
+.phony: all
+
+clean:
+ - $(RM) keyboard.o
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) keyboard.sys
+
+.phony: clean
keyboard.sys: $(OBJECTS)
$(CC) -specs=../../svc_specs -mdll -o junk.tmp -Wl,--defsym,_end=end \
+#
+#
+#
+OBJECTS= mouse.o ../../../ntoskrnl/ntoskrnl.a
+
all: mouse.o
+
+.phony: all
+
+clean:
+ - $(RM) mouse.o
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) mouse.sys
+
+.phony: clean
+
+mouse.sys: $(OBJECTS)
+ $(CC) -specs=../../svc_specs -mdll -o junk.tmp -Wl,--defsym,_end=end \
+ -Wl,--defsym,_edata=__data_end__ -Wl,--defsym,_etext=etext \
+ -Wl,--base-file,base.tmp $(OBJECTS)
+ - $(RM) junk.tmp
+ $(DLLTOOL) --dllname mouse.sys --base-file base.tmp \
+ --output-exp temp.exp
+ - $(RM) base.tmp
+ $(CC) --verbose -Wl,--image-base,0x10000 -Wl,-e,_DriverEntry@8 \
+ -specs=../../svc_specs -mdll -o mouse.sys $(OBJECTS) -Wl,temp.exp
+ - $(RM) temp.exp
+
+
-all: null.o
+#
+#
+#
+OBJECTS= null.o ../../../ntoskrnl/ntoskrnl.a
+
+all: null.sys
+
+.phony: all
+
+clean:
+ - $(RM) null.o
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) null.sys
+
+.phony: clean
+
+null.sys: $(OBJECTS)
+ $(CC) -specs=../../svc_specs -mdll -o junk.tmp -Wl,--defsym,_end=end \
+ -Wl,--defsym,_edata=__data_end__ -Wl,--defsym,_etext=etext \
+ -Wl,--base-file,base.tmp $(OBJECTS)
+ - $(RM) junk.tmp
+ $(DLLTOOL) --dllname null.sys --base-file base.tmp \
+ --output-exp temp.exp
+ - $(RM) base.tmp
+ $(CC) --verbose -Wl,--image-base,0x10000 -Wl,-e,_DriverEntry@8 \
+ -specs=../../svc_specs -mdll -o null.sys $(OBJECTS) -Wl,temp.exp
+ - $(RM) temp.exp
+
+
+#
+#
+#
+OBJECTS= parallel.o ../../../ntoskrnl/ntoskrnl.a
+
all: parallel.o
+
+.phony: all
+
+clean:
+ - $(RM) parallel.o
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) parallel.sys
+
+.phony: clean
+
+parallel.sys: $(OBJECTS)
+ $(CC) -specs=../../svc_specs -mdll -o junk.tmp -Wl,--defsym,_end=end \
+ -Wl,--defsym,_edata=__data_end__ -Wl,--defsym,_etext=etext \
+ -Wl,--base-file,base.tmp $(OBJECTS)
+ - $(RM) junk.tmp
+ $(DLLTOOL) --dllname parallel.sys --base-file base.tmp \
+ --output-exp temp.exp
+ - $(RM) base.tmp
+ $(CC) --verbose -Wl,--image-base,0x10000 -Wl,-e,_DriverEntry@8 \
+ -specs=../../svc_specs -mdll -o parallel.sys $(OBJECTS) -Wl,temp.exp
+ - $(RM) temp.exp
+
+
-all: sdisk.o
+#
+#
+#
+OBJECTS= sdisk.o ../../../ntoskrnl/ntoskrnl.a
+
+all: sdisk.sys
+
+.phony: all
+
+clean:
+ - $(RM) sdisk.o
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) sdisk.sys
+
+.phony: clean
+
+sdisk.sys: $(OBJECTS)
+ $(CC) -specs=../../svc_specs -mdll -o junk.tmp -Wl,--defsym,_end=end \
+ -Wl,--defsym,_edata=__data_end__ -Wl,--defsym,_etext=etext \
+ -Wl,--base-file,base.tmp $(OBJECTS)
+ - $(RM) junk.tmp
+ $(DLLTOOL) --dllname sdisk.sys --base-file base.tmp \
+ --output-exp temp.exp
+ - $(RM) base.tmp
+ $(CC) --verbose -Wl,--image-base,0x10000 -Wl,-e,_DriverEntry@8 \
+ -specs=../../svc_specs -mdll -o sdisk.sys $(OBJECTS) -Wl,temp.exp
+ - $(RM) temp.exp
WIN32_LEAN_AND_MEAN = yes
include ../../../rules.mak
+
+#
+#
+#
+OBJECTS= serial.o ../../../ntoskrnl/ntoskrnl.a
+
all: serial.o
+
+.phony: all
+
+clean:
+ - $(RM) serial.o
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) serial.sys
+
+.phony: clean
+
+serial.sys: $(OBJECTS)
+ $(CC) -specs=../../svc_specs -mdll -o junk.tmp -Wl,--defsym,_end=end \
+ -Wl,--defsym,_edata=__data_end__ -Wl,--defsym,_etext=etext \
+ -Wl,--base-file,base.tmp $(OBJECTS)
+ - $(RM) junk.tmp
+ $(DLLTOOL) --dllname serial.sys --base-file base.tmp \
+ --output-exp temp.exp
+ - $(RM) base.tmp
+ $(CC) --verbose -Wl,--image-base,0x10000 -Wl,-e,_DriverEntry@8 \
+ -specs=../../svc_specs -mdll -o serial.sys $(OBJECTS) -Wl,temp.exp
+ - $(RM) temp.exp
+
+
+#
+#
+#
+OBJECTS= sound.o ../../../ntoskrnl/ntoskrnl.a
+
+all: sound.sys
+
+.phony: all
+
+clean:
+ifeq ($(DOSCLI),yes)
+ - $(RM) sound.o
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) sound.sys
+else
+ - $(RM) sound.o junk.tmp base.tmp temp.exp sound.sys
+endif
+
+.phony: clean
+
+sound.sys: $(OBJECTS)
+ $(CC) -specs=../../svc_specs -mdll -o junk.tmp -Wl,--defsym,_end=end \
+ -Wl,--defsym,_edata=__data_end__ -Wl,--defsym,_etext=etext \
+ -Wl,--base-file,base.tmp $(OBJECTS)
+ - $(RM) junk.tmp
+ $(DLLTOOL) --dllname sound.sys --base-file base.tmp \
+ --output-exp temp.exp
+ - $(RM) base.tmp
+ $(CC) --verbose -Wl,--image-base,0x10000 -Wl,-e,_DriverEntry@8 \
+ -specs=../../svc_specs -mdll -o sound.sys $(OBJECTS) -Wl,temp.exp
+
sound.o: sound.c dsp.c mixer.c wave.h wave.c
-all: sound.o
+
+
+#
+#
+#
+OBJECTS= test.o ../../../ntoskrnl/ntoskrnl.a
+
all: test.sys
-OBJECTS = test.o ../../../ntoskrnl/ntoskrnl.a
+.phony: all
+
+clean:
+ - $(RM) test.o
+ - $(RM) test.a
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) test.sys
+
+.phony: clean
-# --def test.def --def test.def
test.sys: test.o
$(DLLTOOL) --dllname test.sys --output-lib test.a
$(CC) -specs=$(KM_SPECS) -mdll -o junk.tmp -Wl,--defsym,_end=end \
$(DLLTOOL) --dllname test.sys --base-file base.tmp \
--output-exp temp.exp
- $(RM) base.tmp
- $(CC) --verbose -Wl,--image-base,0x10000 -Wl,-e,_DriverEntry -specs=$(KM_SPECS) -mdll -o test.sys $(OBJECTS) -Wl,temp.exp
+ $(CC) --verbose -Wl,--image-base,0x10000 -Wl,-e,_DriverEntry -specs=$(KM_SPECS) \
+ -mdll -o test.sys $(OBJECTS) -Wl,temp.exp
- $(RM) temp.exp
+
-all: ext2fs.sys
-
+#
+#
+#
OBJECTS = super.o blockdev.o inode.o file.o dir.o rw.o \
../../../ntoskrnl/ntoskrnl.a
+all: ext2fs.sys
+
+.phony: all
+
+clean:
+ - $(RM) super.o
+ - $(RM) blockdev.o
+ - $(RM) inode.o
+ - $(RM) file.o
+ - $(RM) dir.o
+ - $(RM) rw.o
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) ext2fs.sys
+
+.phony: clean
+
ext2fs.sys: $(OBJECTS)
$(CC) -specs=$(KM_SPECS) -mdll -o junk.tmp -Wl,--defsym,_end=end \
-Wl,--defsym,_edata=__data_end__ -Wl,--defsym,_etext=etext \
$(CC) --verbose -Wl,--image-base,0x10000 -Wl,-e,_DriverEntry \
-specs=$(KM_SPECS) -mdll -o ext2fs.sys $(OBJECTS) -Wl,temp.exp
$(RM) temp.exp
+
+#
+#
+#
OBJECTS = block.o rw.o inode.o dir.o mount.o blockdev.o
all: minix.o
+.phony: all
+
+clean:
+ - $(RM) minix.o
+ - $(RM) rw.o
+ - $(RM) inode.o
+ - $(RM) dir.o
+ - $(RM) mount.o
+ - $(RM) blockdev.o
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) minix.sys
+
+.phony: clean
+
minix.o: $(OBJECTS)
$(LD) -r $(OBJECTS) -o minix.o
+minix.sys: $(OBJECTS)
+ $(CC) -specs=../../svc_specs -mdll -o junk.tmp -Wl,--defsym,_end=end \
+ -Wl,--defsym,_edata=__data_end__ -Wl,--defsym,_etext=etext \
+ -Wl,--base-file,base.tmp $(OBJECTS)
+ - $(RM) junk.tmp
+ $(DLLTOOL) --dllname minix.sys --base-file base.tmp \
+ --output-exp temp.exp
+ - $(RM) base.tmp
+ $(CC) --verbose -Wl,--image-base,0x10000 -Wl,-e,_DriverEntry@8 \
+ -specs=../../svc_specs -mdll -o minix.sys $(OBJECTS) -Wl,temp.exp
+ - $(RM) temp.exp
+
WIN32_LEAN_AND_MEAN = yes
include ../../../rules.mak
+++ /dev/null
- U _CbAcquireForRead
- U _CbInitDccb
- U _CbReleaseFromRead
- U _DbgPrint
- U _ExAllocatePool
- U _ExFreePool
- U _IoAttachDeviceToDeviceStack
- U _IoBuildSynchronousFsdRequest
- U _IoCallDriver
- U _IoCompleteRequest
- U _IoCreateDevice
- U _IoGetCurrentIrpStackLocation
- U _IoRegisterFileSystem
- U _KeInitializeEvent
- U _KeWaitForSingleObject
- U _MmGetSystemAddressForMdl
- U _RtlAnsiStringToUnicodeString
- U _RtlCopyMemory
- U _RtlInitAnsiString
- U _wcschr
-00000000 t .text
-00000000 t LC0
-00000000 t ___gnu_compiled_c
-00000000 t gcc2_compiled.
-00000008 t LC1
-00000011 t LC2
-00000022 T _MinixCheckPoint
-0000004b t LC3
-0000006c t _MinixGetBlock
-000000b0 t L147
-0000010a t L148
-00000124 t L151
-0000012b t L150
-00000135 t LC4
-00000143 t LC5
-0000014d t LC6
-00000155 t LC7
-0000015d t LC8
-00000196 T _MinixReadBlock
-0000029c t .text
-0000029c t LC0
-0000029c t ___gnu_compiled_c
-0000029c t gcc2_compiled.
-000002a1 t LC1
-000002aa t LC2
-000002ce T _MinixWrite
-00000319 t LC3
-0000033d t LC4
-0000035c t LC5
-00000363 t LC6
-00000388 t LC7
-00000393 t LC8
-000003ba T _MinixRead
-00000492 t L151
-000004a2 t L152
-00000508 t L181
-0000059e t L191
-000005d1 t L153
-000005d6 t L199
-00000635 t L257
-000006a1 t L228
-000006bb t L256
-000006c4 t .text
-000006c4 T _MinixDeleteInode
-000006c4 t ___gnu_compiled_c
-000006c4 t gcc2_compiled.
-0000071a t _MinixAllocateInode
-00000778 t L167
-000007c2 t L166
-000007de t L165
-000007e6 t L173
-000007ee T _MinixNewInode
-0000081a t L175
-0000081c t L176
-00000824 T _MinixWriteInode
-000008a2 T _MinixReadInode
-0000090c t .text
-0000090c T _MinixCompareUnicodeStringToAnsi
-0000090c t ___gnu_compiled_c
-0000090c t gcc2_compiled.
-00000920 t L140
-00000936 t L141
-0000093f t L142
-0000094b t L139
-00000950 t L144
-00000958 t LC0
-0000095e t LC1
-00000967 t LC2
-00000996 t LC3
-0000099d t LC4
-000009b2 t LC5
-000009ca T _MinixDirLookup
-00000a26 t L153
-00000aa3 t L163
-00000ad8 t L158
-00000b68 t L152
-00000b80 t L151
-00000bb6 t L186
-00000bde t L191
-00000be6 t LC6
-00000c1c t LC7
-00000c2b t LC8
-00000c3f t LC9
-00000c5c T _MinixOpen
-00000cc0 t L206
-00000d26 t L205
-00000d3d t L198
-00000d43 t L237
-00000d5c t L207
-00000d6c t L208
-00000da7 t L236
-00000daf t LC10
-00000dd4 T _MinixClose
-00000e40 t LC11
-00000e66 t LC12
-00000e7a t LC13
-00000e9a t LC14
-00000ea6 T _MinixCreate
-00000fa7 t L260
-00000fc8 t .text
-00000fc8 T _MinixMount
-00000fc8 t ___gnu_compiled_c
-00000fc8 t gcc2_compiled.
-0000103b t LC0
-0000106c T _MinixFileSystemControl
-000010bc t L139
-000010c1 t L140
-000010e2 t LC1
-000010f3 t LC2
-00001102 T _DriverEntry
-000011b1 t L142
-000011b8 t .text
-000011b8 T _MinixReadSector
-000011b8 t ___gnu_compiled_c
-000011b8 t gcc2_compiled.
-00001232 t L140
-00001252 t L141
-00001258 t L143
-0000125a t L142
-00001262 T _MinixWriteSector
-000012c3 t L145
-000012ce t L146
-000012d0 t L147
-00002000 b .bss
-00002000 b .bss
-00002000 b .bss
-00002000 b .bss
-00002000 b .bss
-00002000 d .data
-00002000 d .data
-00002000 d .data
-00002000 d .data
-00002000 d .data
-00002000 d .data
-00002000 b _DriverObject
-00002004 b .bss
-all: template.o
+#
+#
+#
+OBJECTS = template.o
+
+all: tfsd.o
+
+.phony: all
+
+clean:
+ - $(RM) template.o
+ - $(RM) tfsd.o
+
+.phony: clean
+
+tfsd.o: template.o
$(LD) -r template.o -o tfsd.o
+#
+#
+#
+OBJECTS = blockdev.o dir.o dirwr.o iface.o ../../../ntoskrnl/ntoskrnl.a
+
all: vfatfsd.sys
-OBJECTS = blockdev.o dir.o dirwr.o iface.o ../../../ntoskrnl/ntoskrnl.a
+.phony: all
+
+clean:
+ifeq ($(DOSCLI),yes)
+ - $(RM) blockdev.o
+ - $(RM) dir.o
+ - $(RM) dirwr.o
+ - $(RM) iface.o
+ - $(RM) junk.tmp
+ - $(RM) base.tmp
+ - $(RM) temp.exp
+ - $(RM) vfatfsd.sys
+else
+ - $(RM) blockdev.o dir.o dirwr.o iface.o junk.tmp base.tmp temp.exp vfatfsd.sys
+endif
+
+.phony: clean
vfatfsd.sys: $(OBJECTS)
$(CC) -specs=../../svc_specs -mdll -o junk.tmp -Wl,--defsym,_end=end \
$(CC) --verbose -Wl,--image-base,0x10000 -Wl,-e,_DriverEntry@8 \
-specs=../../svc_specs -mdll -o vfatfsd.sys $(OBJECTS) -Wl,temp.exp
- $(RM) temp.exp
+
+
$(NAPI_FILES): sysfuncs.lst genntdll$(EXE_POSTFIX)
genntdll$(EXE_POSTFIX) sysfuncs.lst ../../lib/ntdll/napi.c ../../include/ntdll/napi.h
+# (rjj) i removed the following option from line below: -If:\gnu\mingw32\include
genntdll$(EXE_POSTFIX): genntdll.c
- $(NATIVE_CC) -If:\gnu\mingw32\include -g genntdll.c -o genntdll$(EXE_POSTFIX)
+ $(NATIVE_CC) -g genntdll.c -o genntdll$(EXE_POSTFIX)
clean:
- - $(RM) ../../lib/ntdll/sysfuncs.lst
+ - $(RM) genntdll$(EXE_POSTFIX)
+ifeq ($(DOSCLI),yes)
+ - $(RM) ..\..\lib\ntdll\napi.c
+ - $(RM) ..\..\include\ntdll\napi.h
+else
+ - $(RM) ../../lib/ntdll/napi.c
- $(RM) ../../include/ntdll/napi.h
+endif
.PHONY: all clean
--- /dev/null
+kernel32.a
+kernel32.dll
+kernel32.lib
+base.tmp
+junk.tmp
+temp.exp
+
$(PROCESS_OBJECTS) $(STRING_OBJECTS) $(MEM_OBJECTS) \
$(INTERNAL_OBJECTS) $(SYNCH_OBJECTS) $(EXCEPT_OBJECTS)
+ifeq ($(DOSCLI),yes)
+CLEAN_FILES = except\*.o file\*.o internal\*.o mem\*.o misc\*.o nls\*.o \
+ process\*.o string\*.o synch\*.o thread\*.o \
+ kernel32.o kernel32.a junk.tmp base.tmp temp.exp kernel32.dll kernel32.sym
+else
+CLEAN_FILES = except/*.o file/*.o internal/*.o mem/*.o misc/*.o nls/*.o \
+ process/*.o string/*.o synch/*.o thread/*.o \
+ kernel32.o kernel32.a junk.tmp base.tmp temp.exp kernel32.dll kernel32.sym
+endif
+
kernel32.a: $(OBJECTS)
$(AR) csr kernel32.a $(OBJECTS)
- $(RM) temp.exp
$(NM) --numeric-sort kernel32.dll > kernel32.sym
+clean: $(CLEAN_FILES:%=%_clean)
+
+$(CLEAN_FILES:%=%_clean): %_clean:
+ - $(RM) $*
+
+.PHONY: clean $(CLEAN_FILES:%=%_clean)
+
include ../../rules.mak
napi.asm
+napi.c
ntdll.lib
base.tmp
junk.tmp
string/strlen.o string/strncmp.o string/strncpy.o string/strnlen.o \
string/strrchr.o string/wstring.o stubs/stubs.o rtl/heap.o \
rtl/critical.o rtl/mem.o ldr/utils.o
+ifeq ($(DOSCLI),yes)
+CLEAN_FILES = napi.o ldr\*.o rtl\*.o stdio\*.o string\*.o stubs\*.o ntdll.a \
+ main\dllmain.o ntdll.o ntdll.dll junk.tmp base.tmp temp.exp ntdll.sym
+else
+CLEAN_FILES = napi.o ldr/*.o rtl/*.o stdio/*.o string/*.o stubs/*.o ntall.a \
+ main/dllmain.o ntdll.o ntdll.dll junk.tmp base.tmp temp.exp ntdll.sym
+endif
ntdll.a: $(OBJECTS)
$(AR) csr ntdll.a $(OBJECTS)
- $(RM) temp.exp
$(NM) --numeric-sort ntdll.dll > ntdll.sym
+clean: $(CLEAN_FILES:%=%_clean)
+
+$(CLEAN_FILES:%=%_clean): %_clean:
+ - $(RM) $*
+
+.PHONY: clean $(CLEAN_FILES:%=%_clean)
+
#WARNINGS_ARE_ERRORS = yes
include ../../rules.mak
+
loadros.com: loadros.asm
nasm -fbin loadros.asm -o loadros.com
+
+clean:
+ - $(RM) loadros.com
+
+.PHONY: clean
+
+include ../../rules.mak
#
# Select your host
#
-#HOST = djgpp-linux
#HOST = mingw32-linux
-#HOST = djgpp-msdos
HOST = mingw32-windows
-ifeq ($(HOST),mingw32-windows)
-TOPDIR := /TEMP/M32/REACTOS
-endif
-
include rules.mak
#
# Required to run the system
#
-# crtdll mingw32
-COMPONENTS = iface_native ntoskrnl ntdll kernel32
+COMPONENTS = iface_native ntoskrnl
+DLLS = ntdll kernel32
+#DLLS = crtdll mingw32
#
# Select the server(s) you want to build
# Select the loader(s) you want to build
#
LOADERS = dos
+# LOADERS = boot
#
# Select the device drivers and filesystems you want
-#
-KERNEL_SERVICES = blue parallel keyboard null mouse serial sound ide test sdisk \
- minix vfat
+#
+DEVICE_DRIVERS = blue ide keyboard mouse null parallel sdisk serial
+# DEVICE_DRIVERS = beep event floppy ide_test sound test test1
+FS_DRIVERS = minix vfat ext2
+# FS_DRIVERS = template
+KERNEL_SERVICES = $(DEVICE_DRIVERS) $(FS_DRIVERS)
-# cmd
-APPS = hello shell cmd
+APPS = args hello shell
+# APPS = cmd
-all: $(COMPONENTS) $(LOADERS) $(KERNEL_SERVICES) $(APPS)
+all: $(COMPONENTS) $(DLLS) $(LOADERS) $(KERNEL_SERVICES) $(APPS)
.PHONY: all
-clean: $(COMPONENTS:%=%_clean) $(LOADERS:%=%_clean) \
+clean: $(COMPONENTS:%=%_clean) $(DLLS:%=%_clean) $(LOADERS:%=%_clean) \
$(KERNEL_SERVICES:%=%_clean) $(APPS:%=%_clean)
.PHONY: clean
$(APPS:%=%_clean): %_clean:
make -C apps/$* clean
-.PHONY: $(APPS:%=%) $(APPS:%=%_clean)
+.PHONY: $(APPS) $(APPS:%=%_clean)
#
# Interfaces
#
# Device driver rules
#
-vfat: dummy
- make -C services/fs/vfat
-
-sdisk: dummy
- make -C services/dd/sdisk
-
-minix: dummy
- make -C services/fs/minix
-
-template: dummy
- make -C services/fs/template
-
-ide-test: dummy
- make -C services/dd/ide-test
-
-ide: dummy
- make -C services/dd/ide
-
-test: dummy
- make -C services/dd/test
-
-test1: dummy
- make -C services/dd/test1
+$(DEVICE_DRIVERS): %:
+ make -C services/dd/$*
-null: dummy
- make -C services/dd/null
+$(DEVICE_DRIVERS:%=%_clean): %_clean:
+ make -C services/dd/$* clean
-parallel: dummy
- make -C services/dd/parallel
+.PHONY: $(DEVICE_DRIVERS) $(DEVICE_DRIVERS:%=%_clean)
-keyboard: dummy
- make -C services/dd/keyboard
+$(FS_DRIVERS): %:
+ make -C services/fs/$*
-blue: dummy
- make -C services/dd/blue --file=makefile
+$(FS_DRIVERS:%=%_clean): %_clean:
+ make -C services/fs/$* clean
-mouse: dummy
- make -C services/dd/mouse
-
-serial: dummy
- make -C services/dd/serial
-
-sound: dummy
- make -C services/dd/sound
+.PHONY: $(FS_DRIVERS) $(FS_DRIVERS:%=%_clean)
#
# Kernel loaders
#
-dos: dummy
- make -C loaders/dos
+$(LOADERS): %:
+ make -C loaders/$*
+
+$(LOADERS:%=%_clean): %_clean:
+ make -C loaders/$* clean
+
+.PHONY: $(LOADERS) $(LOADERS:%=%_clean)
#
# Required system components
#
-ntoskrnl: dummy
+ntoskrnl:
make -C ntoskrnl
-kernel32: dummy
- make -C lib/kernel32
+ntoskrnl_clean:
+ make -C ntoskrnl clean
+
+.PHONY: ntoskrnl ntoskrnl_clean
+
+#
+# Required DLLs
+#
+
+$(DLLS): %:
+ make -C lib/$*
-ntdll: dummy
- make -C lib/ntdll
+$(DLLS:%=%_clean): %_clean:
+ make -C lib/$* clean
-crtdll: dummy
- make -C lib/crtdll
+.PHONY: $(DLLS) $(DLLS:%=%_clean)
-mingw32: dummy
- make -C lib/mingw32
-dummy:
#
# Required to run the system
#
-COMPONENTS = iface_native ntoskrnl ntdll kernel32
+COMPONENTS = iface_native ntoskrnl
+DLLS = ntdll kernel32
+#DLLS = crtdll mingw32
#
# Select the server(s) you want to build
# Select the loader(s) you want to build
#
LOADERS = dos
+# LOADERS = boot
#
# Select the device drivers and filesystems you want
#
-KERNEL_SERVICES = parallel keyboard blues null mouse serial ide \
- minix vfat ext2
+DEVICE_DRIVERS = blue ide keyboard mouse null parallal serial
+# DEVICE_DRIVERS = beep event floppy ide_test sound test test1
+FS_DRIVERS = minix vfat ext2
+# FS_DRIVERS = template
+KERNEL_SERVICES = $(DEVICE_DRIVERS) $(FS_DRIVERS)
-APPS = hello shell args
+APPS = args hello shell
+# APPS = cmd
-all: $(COMPONENTS) $(LOADERS) $(KERNEL_SERVICES) $(APPS)
+all: $(COMPONENTS) $(DLLS) $(LOADERS) $(KERNEL_SERVICES) $(APPS)
+.PHONY: all
-clean: dummy
- make -C iface/native clean
+clean: $(COMPONENTS:%=%_clean) $(DLLS:%=%_clean) $(LOADERS:%=%_clean) \
+ $(KERNEL_SERVICES:%=%_clean) $(APPS:%=%_clean)
+.PHONY: clean
#
# Applications
#
-hello: dummy
- make -C apps/hello
-
-args: dummy
- make -C apps/args
+$(APPS): %:
+ make -C apps/$*
-cmd: dummy
- make -C apps/cmd
+$(APPS:%=%_clean): %_clean:
+ make -C apps/$* clean
-shell: dummy
- make -C apps/shell
+.PHONY: $(APPS) $(APPS:%=%_clean)
#
# Interfaces
#
-iface_native: dummy
+iface_native:
make -C iface/native
+iface_native_clean:
+ make -C iface/native clean
+
+.PHONY: iface_native iface_native_clean
+
#
# Device driver rules
#
-vfat: dummy
- make -C services/fs/vfat
-
-sdisk: dummy
- make -C services/dd/sdisk
-
-minix: dummy
- make -C services/fs/minix
-
-template: dummy
- make -C services/fs/template
-
-
-ide-test: dummy
- make -C services/dd/ide-test
-
-ide: dummy
- make -C services/dd/ide
-
-test: dummy
- make -C services/dd/test
-
-test1: dummy
- make -C services/dd/test1
+$(DEVICE_DRIVERS): %:
+ make -C services/dd/$*
-null: dummy
- make -C services/dd/null
+$(DEVICE_DRIVERS:%=%_clean): %_clean:
+ make -C services/dd/$* clean
-parallel: dummy
- make -C services/dd/parallel
+.PHONY: $(DEVICE_DRIVERS) $(DEVICE_DRIVERS:%=%_clean)
-keyboard: dummy
- make -C services/dd/keyboard
+$(FS_DRIVERS): %:
+ make -C services/fs/$*
-blues: dummy
- make -C services/dd/blue
+$(FS_DRIVERS:%=%_clean): %_clean:
+ make -C services/fs/$* clean
-mouse: dummy
- make -C services/dd/mouse
-
-serial: dummy
- make -C services/dd/serial
-
-sound: dummy
- make -C services/dd/sound
-
-ext2: dummy
- make -C services/fs/ext2
+.PHONY: $(FS_DRIVERS) $(FS_DRIVERS:%=%_clean)
#
# Kernel loaders
#
-dos: dummy
- make -C loaders/dos
+$(LOADERS): %:
+ make -C loaders/$*
+
+$(LOADERS:%=%_clean): %_clean:
+ make -C loaders/$* clean
+
+.PHONY: $(LOADERS) $(LOADERS:%=%_clean)
#
# Required system components
#
-ntoskrnl: dummy
+ntoskrnl:
make -C ntoskrnl
-kernel32: dummy
- make -C lib/kernel32
+ntoskrnl_clean:
+ make -C ntoskrnl clean
+
+.PHONY: ntoskrnl ntoskrnl_clean
+
+#
+# Required DLLs
+#
+
+$(DLLS): %:
+ make -C lib/$*
-ntdll: dummy
- make -C lib/ntdll
+$(DLLS:%=%_clean): %_clean:
+ make -C lib/$* clean
-crtdll: dummy
- make -C lib/crtdll
+.PHONY: $(DLLS) $(DLLS:%=%_clean)
-mingw32: dummy
- make -C lib/mingw32
-dummy:
objects/se.o objects/cm.o objects/dbg.o\
objects/nt.o objects/cc.o objects/ldr.o
+ifeq ($(DOSCLI),yes)
+CLEAN_FILES = objects\*.o cc\*.o cm\*.o dbg\*.o ex\*.o hal\x86\*.o io\*.o \
+ ke\*.o ldr\*.o mm\*.o nt\*.o ob\*.o ps\*.o rtl\*.o se\*.o \
+ utils\export\export.exe ntoskrnl.o ntoskrnl.a junk.tmp base.tmp \
+ temp.exp ntoskrnl.exe ntoskrnl.sym
+else
+CLEAN_FILES = objects/*.o cc/*.o cm/*.o dbg/*.o ex/*.o hal/x86/*.o io/*.o \
+ ke/*.o ldr/*.o mm/*.o nt/*.o ob/*.o ps/*.o rtl/*.o se/*.o \
+ utils/export/export ntoskrnl.o ntoskrnl.a junk.tmp base.tmp \
+ temp.exp ntoskrnl.exe ntoskrnl.sym
+endif
+
utils/export/export$(EXE_POSTFIX): utils/export/export.c
$(NATIVE_CC) -g utils/export/export.c -o utils/export/export$(EXE_POSTFIX)
-Wl,--defsym,_etext=etext -Wl,temp.exp
- $(RM) temp.exp
$(NM) --numeric-sort ntoskrnl.exe > ntoskrnl.sym
-
-dummy:
+
+clean: $(CLEAN_FILES:%=%_clean)
+
+$(CLEAN_FILES:%=%_clean): %_clean:
+ - $(RM) $*
+
+.PHONY: clean $(CLEAN_FILES:%=%_clean)
ex/napi.o: ex/napi.c ../include/ntdll/napi.h
WIN32_LEAN_AND_MEAN = yes
#WARNINGS_ARE_ERRORS = yes
include ../rules.mak
+
CP = copy
DLLTOOL = $(PREFIX)dlltool --as=$(PREFIX)as
NASM_CMD = nasm
-RM = DELETE
+RM = del
KM_SPECS = specs
+DOSCLI = yes
endif
#
LIBS= ../../lib/kernel32/kernel32.a ../../lib/ntdll/ntdll.a
+CLEAN_FILES = $(OBJECTS) cmd.exe cmd.sym
+
+clean: $(CLEAN_FILES:%=%_clean)
+
+$(CLEAN_FILES:%=%_clean): %_clean:
+ - $(RM) $*
+
+.phony: clean $(CLEAN_FILES:%=%_clean)
cmd.bin: $(OBJECTS)
$(LD) -Ttext 0x10000 $(OBJECTS) $(LIBS) -o cmd.exe