2 Copyright © 2015-2016, The AROS Development Team. All rights reserved.
6 #include <exec/types.h>
8 #include <proto/exec.h>
11 #include <aros/symbolsets.h>
12 #include <hidd/hidd.h>
14 #include "system_intern.h"
16 #include LC_LIBDEFS_FILE
19 #include <aros/debug.h>
22 static int Systsem_Init(LIBBASETYPEPTR LIBBASE
)
24 struct class_static_data
*csd
= &LIBBASE
->hsi_csd
;
25 struct Library
*OOPBase
= csd
->cs_OOPBase
;
27 D(bug("[HiddSystsem] %s()\n", __PRETTY_FUNCTION__
));
29 OOP_Object
*hwroot
= OOP_NewObject(NULL
, CLID_HW_Root
, NULL
);
30 csd
->hwAttrBase
= OOP_ObtainAttrBase(IID_HW
);
32 if (HW_AddDriver(hwroot
, csd
->oopclass
, NULL
))
34 D(bug("[HiddSystsem] %s: initialised\n", __PRETTY_FUNCTION__
));
37 D(bug("[HiddSystsem] %s: failed\n", __PRETTY_FUNCTION__
));
42 static int Systsem_Expunge(LIBBASETYPEPTR LIBBASE
)
44 struct class_static_data
*csd
= &LIBBASE
->hsi_csd
;
46 struct Library
*OOPBase
= csd
->cs_OOPBase
;
49 D(bug("[HiddSystsem] %s(csd=%p)\n", __PRETTY_FUNCTION__
, csd
));
54 ADD2INITLIB(Systsem_Init
, -2)
55 ADD2EXPUNGELIB(Systsem_Expunge
, -2)