arm-native/processor.resource: build for raspi target
[AROS.git] / test / dos / runcommand.c
blobc126a5dcef66d5b8c3ac5bfa1288545401973e0a
1 /*
2 Copyright © 1995-2014, The AROS Development Team. All rights reserved.
3 $Id$
4 */
6 #include <proto/dos.h>
7 #include <proto/exec.h>
8 #include <dos/bptr.h>
9 #include <dos/dos.h>
10 #include <string.h>
11 #include <stdlib.h>
12 #include <stdio.h>
14 static LONG get_default_stack_size()
16 struct CommandLineInterface *cli = Cli();
17 return cli->cli_DefaultStack * CLI_DEFAULTSTACK_UNIT;
20 int main(int argc, char **argv)
22 char *fname = "SYS:Utilities/Clock";
23 char *full = "";
24 int lastresult = RETURN_OK;
26 if(fname) {
27 BPTR seglist = LoadSeg(fname);
28 if(seglist)
30 SetProgramName(fname);
31 lastresult=RunCommand(seglist,get_default_stack_size(),
32 full,strlen(full));
33 UnLoadSeg(seglist);
37 exit(lastresult);