library helloworld; // this is important - do not try a "program" here
// tell FPC that we want to compile a kernel mode application
// (NEEDS a RTL that was compiled with KMODE)
{$apptype native}
uses
// for entry point types and debug output
DDK;
// this method is called once our driver is unloaded
procedure DriverUnload(aObject: PDriverObject); stdcall;
begin
DbgPrint('Unloading driver');
end;
// during the entry point the variables DriverObject and
// RegistryPath are valid
begin
DbgPrint('Hello World!');
// we need to setup the unload routine or the driver will
// only be unloaded on shutdown!
DriverObject^.DriverUnload := @DriverUnload;
end.