Add Allwinner Technology to the vendor ID list
[AROS.git] / rom / exec / exec_autoinit.c
blob865006f922039313e2576c74c39050af324fb2a9
1 /*
2 * Copyright (C) 2012, The AROS Development Team
3 * All right reserved.
4 * Author: Jason S. McMullan <jason.mcmullan@gmail.com>
6 * Licensed under the AROS PUBLIC LICENSE (APL) Version 1.1
7 */
9 #include <aros/symbolsets.h>
10 #include <aros/asmcall.h>
11 #include <aros/autoinit.h>
13 #include <exec/libraries.h>
15 #include <proto/exec.h>
16 #include <proto/dos.h>
18 /* Linklib to provide a 'SysBase' symbol. Also verifies that
19 * the symbol is set appropriately.
21 struct ExecBase *SysBase;
22 extern const LONG const __aros_libreq_SysBase __attribute__((weak));
24 static int SysBase_autoinit(struct ExecBase *sysBase)
26 if (sysBase == NULL)
27 return FALSE;
29 SysBase = sysBase;
31 if (__aros_libreq_SysBase > SysBase->LibNode.lib_Version) {
32 IPTR arr[] = {
33 (IPTR)(FindTask(NULL)->tc_Node.ln_Name),
34 __aros_libreq_SysBase,
35 SysBase->LibNode.lib_Version
37 __showerror("%s: Requires exec.library v%ld, found v%ld\n",arr);
38 return FALSE;
41 return TRUE;
44 ADD2INIT(SysBase_autoinit,-128)