3

Could someone please point me to some reference documentation about EFI "printf" format reference?

I mean it's not like regular printf, as it supports %g as GUID, and prints a question mark for %llu.

My best Google-bet was "efi" "print" "format" reference %g %s %a %d, but it did not gave any usable results. Other search terms came up with some color settings of some printers.

What did i do wrong? How can anyone find this info?

Thanks.

smwikipedia
  • 61,609
  • 92
  • 309
  • 482
YaniMan
  • 293
  • 2
  • 13
  • 1
    (U)EFI specifies nothing about string formatting, this is a detail of the implementation. It would be useful if you could add a tag for whichever framework you're working in. gnu-efi? edk2? – unixsmurf Jun 15 '20 at 13:33

1 Answers1

4

The flags are described in the PrintLib.h file. You can find it here: https://github.com/tianocore/edk2/blob/master/MdePkg/Include/Library/PrintLib.h.

EDIT:

The link above is valid if you use EDK2 for building you programs. The flags when building with gnu-efi are described in the print.c file. You can find it here (search for function _Print): https://sourceforge.net/p/gnu-efi/code/ci/master/tree/lib/print.c

MiSimon
  • 1,225
  • 1
  • 8
  • 10