diff options
| author | Pierre-Alexandre Meyer <pierre@mouraf.org> | 2009-08-26 21:21:38 -0700 |
|---|---|---|
| committer | Pierre-Alexandre Meyer <pierre@mouraf.org> | 2009-08-26 21:21:38 -0700 |
| commit | d7076627ee03a2945dc6c6a217a24cc943f2abe2 (patch) | |
| tree | 75c4ecdea275b0d2f6a0af04ea213ca513d79570 /com32/gplinclude | |
| parent | af27ced68a57f2fd2c2bedb25275e4fe808497be (diff) | |
| download | syslinux-d7076627ee03a2945dc6c6a217a24cc943f2abe2.tar.gz | |
gpllib: add bootloader detection
Given an (active) partition, look for a bootloader ID.
Syslinux prints a string (SYSLINUX or EXTLINUX) between bytes
3 and 10.
After some random tests, it seems that Windows™98/98SE and Windows™ME
put MSWIN4.1 at the same place. Internet seems to confirm it:
http://www.geocities.com/thestarman3/asm/mbr/MSWin41BRinHexEd.htm
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Diffstat (limited to 'com32/gplinclude')
| -rw-r--r-- | com32/gplinclude/disk/bootloaders.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/com32/gplinclude/disk/bootloaders.h b/com32/gplinclude/disk/bootloaders.h new file mode 100644 index 00000000..6aec9b3d --- /dev/null +++ b/com32/gplinclude/disk/bootloaders.h @@ -0,0 +1,18 @@ +/* ----------------------------------------------------------------------- * + * + * Copyright 2009 Pierre-Alexandre Meyer + * + * This file is part of Syslinux, and is made available under + * the terms of the GNU General Public License version 2. + * + * ----------------------------------------------------------------------- */ + +#ifndef __BOOTLOADERS_H_ +#define __BOOTLOADERS_H_ + +#include <stdint.h> +#include <disk/geom.h> +#include <disk/partition.h> + +int get_bootloader_string(const struct driveinfo *, const struct part_entry *, char*, const int); +#endif /* __BOOTLOADERS_H_ */ |
