diff options
| author | Amlal El Mahrouss <amlal.elmahrouss@icloud.com> | 2024-07-09 09:25:20 +0200 |
|---|---|---|
| committer | Amlal El Mahrouss <amlal.elmahrouss@icloud.com> | 2024-07-09 09:25:20 +0200 |
| commit | be8ec12ba13de33616ace33be6e2c310a2b2fe05 (patch) | |
| tree | 29cf33504e6539353799003c6a5fe98d0c3a238d | |
| parent | fca3de82a3871b54ec840415640594bbbf62f300 (diff) | |
MHR-36: See below.
- Add ARM64 linker script.
- Replace Drv with Drivers (not really relevant).
- Replace ReadMe.md in DDK.
Signed-off-by: Amlal El Mahrouss <amlal.elmahrouss@icloud.com>
| -rw-r--r-- | Comm/compile_flags.txt | 3 | ||||
| -rw-r--r-- | Comm/newstd.hxx | 2 | ||||
| -rw-r--r-- | DDK/ReadMe.md | 9 | ||||
| -rw-r--r-- | DDK/ReadMe.txt | 4 | ||||
| -rw-r--r-- | Drivers/.gitkeep (renamed from Drv/.gitkeep) | 0 | ||||
| -rw-r--r-- | Drivers/Hello/CheckStack.c (renamed from Drv/Hello/CheckStack.c) | 0 | ||||
| -rw-r--r-- | Drivers/Hello/DriverRsrc.rsrc (renamed from Drv/Hello/DriverRsrc.rsrc) | 0 | ||||
| -rw-r--r-- | Drivers/Hello/Hello.c (renamed from Drv/Hello/Hello.c) | 0 | ||||
| -rw-r--r-- | Drivers/Hello/compile_flags.txt | 3 | ||||
| -rw-r--r-- | Drivers/Hello/x86_64.mk (renamed from Drv/Hello/x86_64.mk) | 0 | ||||
| -rw-r--r-- | Drivers/SampleDriver/CheckStck.c (renamed from Drv/SampleDriver/CheckStck.c) | 0 | ||||
| -rw-r--r-- | Drivers/SampleDriver/DriverRsrc.rsrc (renamed from Drv/SampleDriver/DriverRsrc.rsrc) | 0 | ||||
| -rw-r--r-- | Drivers/SampleDriver/SampleDriver.c (renamed from Drv/SampleDriver/SampleDriver.c) | 0 | ||||
| -rw-r--r-- | Drivers/SampleDriver/compile_flags.txt | 3 | ||||
| -rw-r--r-- | Drivers/SampleDriver/x86_64.mk (renamed from Drv/SampleDriver/x86_64.mk) | 0 | ||||
| -rw-r--r-- | Drivers/VideoDrv/CheckStck.c (renamed from Drv/VideoDrv/CheckStck.c) | 0 | ||||
| -rw-r--r-- | Drivers/VideoDrv/DriverRsrc.rsrc (renamed from Drv/VideoDrv/DriverRsrc.rsrc) | 0 | ||||
| -rw-r--r-- | Drivers/VideoDrv/VideoDrv.cxx (renamed from Drv/VideoDrv/VideoDrv.cc) | 0 | ||||
| -rw-r--r-- | Drivers/VideoDrv/compile_flags.txt | 3 | ||||
| -rw-r--r-- | Drivers/VideoDrv/x86_64.make (renamed from Drv/VideoDrv/x86_64.make) | 2 | ||||
| -rw-r--r-- | Kernel/Linker/16x0.json | 2 | ||||
| -rw-r--r-- | Kernel/Linker/32x0.json | 2 | ||||
| -rw-r--r-- | Kernel/Linker/64x0.json | 2 | ||||
| -rw-r--r-- | Kernel/Linker/arm64.json | 8 |
24 files changed, 36 insertions, 7 deletions
diff --git a/Comm/compile_flags.txt b/Comm/compile_flags.txt index e1f07ac3..509e3eed 100644 --- a/Comm/compile_flags.txt +++ b/Comm/compile_flags.txt @@ -1,3 +1,4 @@ -I./
--I../Kerne;
+-I../Kernel
+-I../
-std=c++20
diff --git a/Comm/newstd.hxx b/Comm/newstd.hxx index 2ec50df6..70abe793 100644 --- a/Comm/newstd.hxx +++ b/Comm/newstd.hxx @@ -45,7 +45,7 @@ typedef char UTFChar; typedef UInt32 MBCIType;
/**
- @brief Application class.
+ @brief System call class.
*/
class NSyscall
{
diff --git a/DDK/ReadMe.md b/DDK/ReadMe.md new file mode 100644 index 00000000..09f7a261 --- /dev/null +++ b/DDK/ReadMe.md @@ -0,0 +1,9 @@ +# DDK (Device Driver Kit) + +A kit used to write kernel HALs, using the NDK compiler suite. + +## How to use + +Simply link against these files. + +###### Copyright 2024 Zeta Electronics Corporation, all rights reserved. diff --git a/DDK/ReadMe.txt b/DDK/ReadMe.txt deleted file mode 100644 index 61feadea..00000000 --- a/DDK/ReadMe.txt +++ /dev/null @@ -1,4 +0,0 @@ -=== Device Driver Kit === - --> A kit used to write kernel HALs. --> Use MPCC to compile the code. diff --git a/Drv/.gitkeep b/Drivers/.gitkeep index e69de29b..e69de29b 100644 --- a/Drv/.gitkeep +++ b/Drivers/.gitkeep diff --git a/Drv/Hello/CheckStack.c b/Drivers/Hello/CheckStack.c index 3ffbe3e2..3ffbe3e2 100644 --- a/Drv/Hello/CheckStack.c +++ b/Drivers/Hello/CheckStack.c diff --git a/Drv/Hello/DriverRsrc.rsrc b/Drivers/Hello/DriverRsrc.rsrc index 12add0e2..12add0e2 100644 --- a/Drv/Hello/DriverRsrc.rsrc +++ b/Drivers/Hello/DriverRsrc.rsrc diff --git a/Drv/Hello/Hello.c b/Drivers/Hello/Hello.c index ba3d9733..ba3d9733 100644 --- a/Drv/Hello/Hello.c +++ b/Drivers/Hello/Hello.c diff --git a/Drivers/Hello/compile_flags.txt b/Drivers/Hello/compile_flags.txt new file mode 100644 index 00000000..10bdb71e --- /dev/null +++ b/Drivers/Hello/compile_flags.txt @@ -0,0 +1,3 @@ +-I../../ +-I../../Kernel +-std=c++20 diff --git a/Drv/Hello/x86_64.mk b/Drivers/Hello/x86_64.mk index 564fe970..564fe970 100644 --- a/Drv/Hello/x86_64.mk +++ b/Drivers/Hello/x86_64.mk diff --git a/Drv/SampleDriver/CheckStck.c b/Drivers/SampleDriver/CheckStck.c index 3eb157ba..3eb157ba 100644 --- a/Drv/SampleDriver/CheckStck.c +++ b/Drivers/SampleDriver/CheckStck.c diff --git a/Drv/SampleDriver/DriverRsrc.rsrc b/Drivers/SampleDriver/DriverRsrc.rsrc index 54940e43..54940e43 100644 --- a/Drv/SampleDriver/DriverRsrc.rsrc +++ b/Drivers/SampleDriver/DriverRsrc.rsrc diff --git a/Drv/SampleDriver/SampleDriver.c b/Drivers/SampleDriver/SampleDriver.c index 85bd8d54..85bd8d54 100644 --- a/Drv/SampleDriver/SampleDriver.c +++ b/Drivers/SampleDriver/SampleDriver.c diff --git a/Drivers/SampleDriver/compile_flags.txt b/Drivers/SampleDriver/compile_flags.txt new file mode 100644 index 00000000..10bdb71e --- /dev/null +++ b/Drivers/SampleDriver/compile_flags.txt @@ -0,0 +1,3 @@ +-I../../ +-I../../Kernel +-std=c++20 diff --git a/Drv/SampleDriver/x86_64.mk b/Drivers/SampleDriver/x86_64.mk index 5655902f..5655902f 100644 --- a/Drv/SampleDriver/x86_64.mk +++ b/Drivers/SampleDriver/x86_64.mk diff --git a/Drv/VideoDrv/CheckStck.c b/Drivers/VideoDrv/CheckStck.c index 633636b4..633636b4 100644 --- a/Drv/VideoDrv/CheckStck.c +++ b/Drivers/VideoDrv/CheckStck.c diff --git a/Drv/VideoDrv/DriverRsrc.rsrc b/Drivers/VideoDrv/DriverRsrc.rsrc index 79d4cc92..79d4cc92 100644 --- a/Drv/VideoDrv/DriverRsrc.rsrc +++ b/Drivers/VideoDrv/DriverRsrc.rsrc diff --git a/Drv/VideoDrv/VideoDrv.cc b/Drivers/VideoDrv/VideoDrv.cxx index 1af02b4a..1af02b4a 100644 --- a/Drv/VideoDrv/VideoDrv.cc +++ b/Drivers/VideoDrv/VideoDrv.cxx diff --git a/Drivers/VideoDrv/compile_flags.txt b/Drivers/VideoDrv/compile_flags.txt new file mode 100644 index 00000000..10bdb71e --- /dev/null +++ b/Drivers/VideoDrv/compile_flags.txt @@ -0,0 +1,3 @@ +-I../../ +-I../../Kernel +-std=c++20 diff --git a/Drv/VideoDrv/x86_64.make b/Drivers/VideoDrv/x86_64.make index a74a8d21..5897aa1e 100644 --- a/Drv/VideoDrv/x86_64.make +++ b/Drivers/VideoDrv/x86_64.make @@ -38,7 +38,7 @@ endif .PHONY: compile-amd64 compile-amd64: $(WINDRES) DriverRsrc.rsrc -O coff -o DriverRsrc.o - $(CC_GNU) $(FLAG_GNU) $(DEBUG) $(wildcard *.c) $(wildcard ../../DDK/*.c) $(wildcard ../../DDK/*.S) + $(CC_GNU) $(FLAG_GNU) $(DEBUG) $(wildcard *.cxx) $(wildcard *.c) $(wildcard ../../DDK/*.c) $(wildcard ../../DDK/*.S) .PHONY: clean clean: diff --git a/Kernel/Linker/16x0.json b/Kernel/Linker/16x0.json index 77235537..fd7f167a 100644 --- a/Kernel/Linker/16x0.json +++ b/Kernel/Linker/16x0.json @@ -1,6 +1,8 @@ { + "linker": "link.exe", "executable_type": "kernel", "output_name": "newoskrnl.exe", "start_proc": "__ImageStart", + "arch": "16x0", "format": "PEF" } diff --git a/Kernel/Linker/32x0.json b/Kernel/Linker/32x0.json index 77235537..a827de05 100644 --- a/Kernel/Linker/32x0.json +++ b/Kernel/Linker/32x0.json @@ -1,6 +1,8 @@ { + "linker": "link.exe", "executable_type": "kernel", "output_name": "newoskrnl.exe", "start_proc": "__ImageStart", + "arch": "32x0", "format": "PEF" } diff --git a/Kernel/Linker/64x0.json b/Kernel/Linker/64x0.json index 77235537..f1a6611e 100644 --- a/Kernel/Linker/64x0.json +++ b/Kernel/Linker/64x0.json @@ -1,6 +1,8 @@ { + "linker": "link.exe", "executable_type": "kernel", "output_name": "newoskrnl.exe", "start_proc": "__ImageStart", + "arch": "64x0", "format": "PEF" } diff --git a/Kernel/Linker/arm64.json b/Kernel/Linker/arm64.json new file mode 100644 index 00000000..eb7ff4d2 --- /dev/null +++ b/Kernel/Linker/arm64.json @@ -0,0 +1,8 @@ +{ + "linker": "link.exe", + "executable_type": "kernel", + "output_name": "newoskrnl.exe", + "start_proc": "__ImageStart", + "arch": "arm64", + "format": "PEF" +} |
