Bootstrap2.c 656 B

123456789101112131415161718192021222324
  1. #include "pal.h"
  2. #include "pal_debug.h"
  3. int main (int argc, char ** argv, char ** envp)
  4. {
  5. /* check if the program is loaded */
  6. pal_printf("User Program Started\n");
  7. /* check control block */
  8. /* check executable name */
  9. pal_printf("Loaded Executable: %s\n", pal_control.executable);
  10. /* check manifest name */
  11. char manifest[30] = "";
  12. DkStreamGetName(pal_control.manifest_handle, manifest, 30);
  13. pal_printf("Loaded Manifest: %s\n", manifest);
  14. /* check arguments */
  15. pal_printf("# of Arguments: %d\n", argc);
  16. for (int i = 0 ; i < argc ; i++)
  17. pal_printf("argv[%d] = %s\n", i, argv[i]);
  18. return 0;
  19. }