SHA256
1
0
forked from pool/syslinux

Accepting request 67961 from system:install:head

Accepted submit request 67961 from user babelworx

OBS-URL: https://build.opensuse.org/request/show/67961
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/syslinux?expand=0&rev=30
This commit is contained in:
Sascha Peilicke 2011-04-27 13:16:20 +00:00 committed by Git OBS Bridge
commit 5ec31ca789
13 changed files with 340 additions and 1219 deletions

View File

@ -26,14 +26,21 @@ open F, $file or die "$file: $!\n";
sysread F, $file_buf, -s($file);
close F;
die "$file: is not isolinux\n" unless (length $file_buf > (8 << 10)) && ($file_buf =~ m#(/boot(/[\x20-\xff]*)\x00*)\x00isolinux.cfg\x00#s);
if((length $file_buf > (8 << 10)) && ($file_buf =~ m#(/boot(/[\x20-\xff]*)\x00*)\x00isolinux.cfg\x00#s)) {
$format = 1;
}
elsif((length $file_buf > (8 << 10)) && ($file_buf =~ m#(/boot(/[\x20-\xff]*)\x00*)\x00/boot/syslinux\x00#s)) {
$format = 2;
}
die "$file: is not isolinux\n" unless $format;
$start = length $`;
$base_buf = $1;
$old_base = $2;
if(defined $opt_base) {
($base = $opt_base) =~ s#^/*##;;
($base = $opt_base) =~ s#^/*##;
$base = "/boot/$base";
die "$opt_base: file name too long\n" if length($base) > length($base_buf);

View File

@ -1,686 +0,0 @@
From b6b0153590283ea5c19973837b2978710f170b29 Mon Sep 17 00:00:00 2001
From: Steffen Winterfeldt <wfeldt@opensuse.org>
Date: Tue, 13 Apr 2010 17:38:39 +0200
Subject: [PATCH 1/4] support MENU LABEL statement
Signed-off-by: Steffen Winterfeldt <wfeldt@opensuse.org>
---
com32/gfxboot/gfxboot.c | 49 +++++++++++++++++++++++++++++++++++++---------
1 files changed, 39 insertions(+), 10 deletions(-)
diff --git a/com32/gfxboot/gfxboot.c b/com32/gfxboot/gfxboot.c
index bfdd8cc..e0ff8f5 100644
--- a/com32/gfxboot/gfxboot.c
+++ b/com32/gfxboot/gfxboot.c
@@ -165,7 +165,7 @@ void gfx_done(void);
int gfx_input(void);
ssize_t save_read(int fd, void *buf, size_t size);
void *load_one(char *file, ssize_t *file_size);
-void boot(void);
+void boot(int index);
void boot_entry(menu_t *menu_ptr, char *arg);
@@ -234,7 +234,7 @@ int main(int argc, char **argv)
}
// does not return if it succeeds
- boot();
+ boot(menu_index);
}
if(argc > 2) show_message(argv[2]);
@@ -374,6 +374,20 @@ int read_config_file(void)
(menu_ptr ?: menu_default)->ipappend = strdup(t);
continue;
}
+
+ if(!strcmp(s, "menu") && menu_ptr) {
+ s = skip_spaces(t);
+ t = skip_nonspaces(s);
+ if(*t) *t++ = 0;
+ t = skip_spaces(t);
+
+ if(!strcmp(s, "label")) {
+ menu_ptr->label = strdup(t);
+ u = strlen(t);
+ if(u > label_size) label_size = u;
+ continue;
+ }
+ }
}
fclose(f);
@@ -686,20 +700,35 @@ void *load_one(char *file, ssize_t *file_size)
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-// Locate menu entry and boot.
+// Boot menu entry.
//
-void boot(void)
+// cmdline can optionally start with label string.
+//
+void boot(int index)
{
- char *label, *arg, *s;
+ char *arg;
menu_t *menu_ptr;
+ int label_len;
+
+ for(menu_ptr = menu; menu_ptr; menu_ptr = menu_ptr->next, index--) {
+ if(!index) break;
+ }
+
+ // invalid index or menu entry
+ if(!menu_ptr || !menu_ptr->label) return;
- label = skip_spaces(cmdline);
- arg = skip_spaces(s = skip_nonspaces(label));
- *s = 0;
+ arg = skip_spaces(cmdline);
+ label_len = strlen(menu_ptr->label);
- for(menu_ptr = menu; menu_ptr; menu_ptr = menu_ptr->next) {
- if(menu_ptr->label && !strcmp(menu_ptr->label, label)) break;
+ // if it does not start with label string, skip first word
+ if(strncmp(arg, menu_ptr->label, label_len)) {
+ arg = skip_nonspaces(arg);
}
+ else {
+ arg += label_len;
+ }
+
+ arg = skip_spaces(arg);
boot_entry(menu_ptr, arg);
}
--
1.6.4.2
From 190f963602576b46ef3b01543f5a586bea84156c Mon Sep 17 00:00:00 2001
From: Steffen Winterfeldt <wfeldt@opensuse.org>
Date: Tue, 13 Apr 2010 17:39:46 +0200
Subject: [PATCH 2/4] make config statements case-insensitive
Signed-off-by: Steffen Winterfeldt <wfeldt@opensuse.org>
---
com32/gfxboot/gfxboot.c | 22 +++++++++++-----------
1 files changed, 11 insertions(+), 11 deletions(-)
diff --git a/com32/gfxboot/gfxboot.c b/com32/gfxboot/gfxboot.c
index e0ff8f5..c300dcb 100644
--- a/com32/gfxboot/gfxboot.c
+++ b/com32/gfxboot/gfxboot.c
@@ -321,19 +321,19 @@ int read_config_file(void)
if(*t) *t++ = 0;
t = skip_spaces(t);
- if(!strcmp(s, "timeout")) {
+ if(!strcasecmp(s, "timeout")) {
timeout = atoi(t);
continue;
}
- if(!strcmp(s, "default")) {
+ if(!strcasecmp(s, "default")) {
menu_default->label = strdup(t);
u = strlen(t);
if(u > label_size) label_size = u;
continue;
}
- if(!strcmp(s, "label")) {
+ if(!strcasecmp(s, "label")) {
menu_ptr = *menu_next = calloc(1, sizeof **menu_next);
menu_next = &menu_ptr->next;
menu_idx++;
@@ -343,45 +343,45 @@ int read_config_file(void)
continue;
}
- if(!strcmp(s, "kernel") && menu_ptr) {
+ if(!strcasecmp(s, "kernel") && menu_ptr) {
menu_ptr->kernel = strdup(t);
continue;
}
- if(!strcmp(s, "linux") && menu_ptr) {
+ if(!strcasecmp(s, "linux") && menu_ptr) {
menu_ptr->linux = strdup(t);
continue;
}
- if(!strcmp(s, "localboot") && menu_ptr) {
+ if(!strcasecmp(s, "localboot") && menu_ptr) {
menu_ptr->localboot = strdup(t);
continue;
}
- if(!strcmp(s, "initrd") && menu_ptr) {
+ if(!strcasecmp(s, "initrd") && menu_ptr) {
menu_ptr->initrd = strdup(t);
continue;
}
- if(!strcmp(s, "append")) {
+ if(!strcasecmp(s, "append")) {
(menu_ptr ?: menu_default)->append = strdup(t);
u = strlen(t);
if(u > append_size) append_size = u;
continue;
}
- if(!strcmp(s, "ipappend")) {
+ if(!strcasecmp(s, "ipappend")) {
(menu_ptr ?: menu_default)->ipappend = strdup(t);
continue;
}
- if(!strcmp(s, "menu") && menu_ptr) {
+ if(!strcasecmp(s, "menu") && menu_ptr) {
s = skip_spaces(t);
t = skip_nonspaces(s);
if(*t) *t++ = 0;
t = skip_spaces(t);
- if(!strcmp(s, "label")) {
+ if(!strcasecmp(s, "label")) {
menu_ptr->label = strdup(t);
u = strlen(t);
if(u > label_size) label_size = u;
--
1.6.4.2
From 0c511ba970405ea54c8fd6c351f20137966b5e89 Mon Sep 17 00:00:00 2001
From: Steffen Winterfeldt <wfeldt@opensuse.org>
Date: Tue, 13 Apr 2010 17:42:12 +0200
Subject: [PATCH 3/4] handle IPAPPEND
Signed-off-by: Steffen Winterfeldt <wfeldt@opensuse.org>
---
com32/gfxboot/gfxboot.c | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/com32/gfxboot/gfxboot.c b/com32/gfxboot/gfxboot.c
index c300dcb..daf0056 100644
--- a/com32/gfxboot/gfxboot.c
+++ b/com32/gfxboot/gfxboot.c
@@ -709,6 +709,8 @@ void boot(int index)
char *arg;
menu_t *menu_ptr;
int label_len;
+ unsigned u, ipapp;
+ const struct syslinux_ipappend_strings *ipappend;
for(menu_ptr = menu; menu_ptr; menu_ptr = menu_ptr->next, index--) {
if(!index) break;
@@ -730,6 +732,16 @@ void boot(int index)
arg = skip_spaces(arg);
+ // handle IPAPPEND
+ if(menu_ptr->ipappend && (ipapp = atoi(menu_ptr->ipappend))) {
+ ipappend = syslinux_ipappend_strings();
+ for(u = 0; u < ipappend->count; u++) {
+ if((ipapp & (1 << u)) && ipappend->ptr[u]) {
+ sprintf(arg + strlen(arg), " %s", ipappend->ptr[u]);
+ }
+ }
+ }
+
boot_entry(menu_ptr, arg);
}
--
1.6.4.2
From 9a0a0e2307ffa0140fe6ea4a31c2f4040176513d Mon Sep 17 00:00:00 2001
From: Steffen Winterfeldt <wfeldt@opensuse.org>
Date: Tue, 13 Apr 2010 17:42:44 +0200
Subject: [PATCH 4/4] turn off graphics before starting kernel
Signed-off-by: Steffen Winterfeldt <wfeldt@opensuse.org>
---
com32/gfxboot/gfxboot.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/com32/gfxboot/gfxboot.c b/com32/gfxboot/gfxboot.c
index daf0056..96aadd8 100644
--- a/com32/gfxboot/gfxboot.c
+++ b/com32/gfxboot/gfxboot.c
@@ -848,6 +848,8 @@ void boot_entry(menu_t *menu_ptr, char *arg)
__farcall(gfx.code_seg, gfx.jmp_table[GFX_CB_PROGRESS_DONE], &r, &r);
+ gfx_done();
+
syslinux_boot_linux(kernel, kernel_size, initrd, arg);
}
--
1.6.4.2
From 6d89bc005f25b923728822706bf508ea7ebc1714 Mon Sep 17 00:00:00 2001
From: Steffen Winterfeldt <wfeldt@opensuse.org>
Date: Wed, 14 Apr 2010 17:43:16 +0200
Subject: [PATCH] fix localboot
Signed-off-by: Steffen Winterfeldt <wfeldt@opensuse.org>
---
com32/gfxboot/gfxboot.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/com32/gfxboot/gfxboot.c b/com32/gfxboot/gfxboot.c
index 96aadd8..3460c18 100644
--- a/com32/gfxboot/gfxboot.c
+++ b/com32/gfxboot/gfxboot.c
@@ -766,7 +766,7 @@ void boot_entry(menu_t *menu_ptr, char *arg)
if(menu_ptr->localboot) {
gfx_done();
- syslinux_local_boot(atoi(arg));
+ syslinux_local_boot(strtol(menu_ptr->localboot, NULL, 0));
return;
}
--
1.6.4.2
From 19dfdc33016f69e7d20f6c8eda9eb420b91577f9 Mon Sep 17 00:00:00 2001
From: Steffen Winterfeldt <wfeldt@opensuse.org>
Date: Fri, 16 Apr 2010 13:18:46 +0200
Subject: [PATCH] better error handling
Signed-off-by: Steffen Winterfeldt <wfeldt@opensuse.org>
---
com32/gfxboot/gfxboot.c | 118 +++++++++++++++++++++++++++++++++++++---------
1 files changed, 95 insertions(+), 23 deletions(-)
diff --git a/com32/gfxboot/gfxboot.c b/com32/gfxboot/gfxboot.c
index 3460c18..c5112f4 100644
--- a/com32/gfxboot/gfxboot.c
+++ b/com32/gfxboot/gfxboot.c
@@ -118,6 +118,7 @@ typedef struct menu_s {
struct menu_s *next;
char *label;
char *kernel;
+ char *alt_kernel;
char *linux;
char *localboot;
char *initrd;
@@ -149,6 +150,9 @@ char cmdline[MAX_CMDLINE_LEN];
void *save_buf;
unsigned save_buf_size;
+// progress bar is visible
+unsigned progress_active;
+
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
void show_message(char *file);
@@ -163,6 +167,10 @@ int gfx_init(char *file);
int gfx_menu_init(void);
void gfx_done(void);
int gfx_input(void);
+void gfx_infobox(int type, char *str1, char *str2);
+void gfx_progress_init(ssize_t kernel_size, char *label);
+void gfx_progress_update(ssize_t size);
+void gfx_progress_done(void);
ssize_t save_read(int fd, void *buf, size_t size);
void *load_one(char *file, ssize_t *file_size);
void boot(int index);
@@ -486,6 +494,8 @@ int gfx_init(char *file)
void *lowmem = lowmem_buf;
unsigned lowmem_size = lowmem_buf_size;
+ progress_active = 0;
+
printf("Loading %s...\n", file);
if(loadfile(file, &archive, &archive_size)) return 1;
@@ -603,6 +613,8 @@ void gfx_done(void)
{
com32sys_t r;
+ gfx_progress_done();
+
__farcall(gfx.code_seg, gfx.jmp_table[GFX_CB_DONE], &r, &r);
}
@@ -631,6 +643,61 @@ int gfx_input(void)
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+void gfx_infobox(int type, char *str1, char *str2)
+{
+ com32sys_t r;
+
+ r.eax.l = type;
+ r.esi.l = (uint32_t) str1;
+ r.edi.l = (uint32_t) str2;
+ __farcall(gfx.code_seg, gfx.jmp_table[GFX_CB_INFOBOX_INIT], &r, &r);
+ r.edi.l = r.eax.l = 0;
+ __farcall(gfx.code_seg, gfx.jmp_table[GFX_CB_INPUT], &r, &r);
+ __farcall(gfx.code_seg, gfx.jmp_table[GFX_CB_INFOBOX_DONE], &r, &r);
+}
+
+
+// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+void gfx_progress_init(ssize_t kernel_size, char *label)
+{
+ com32sys_t r;
+
+ if(!progress_active) {
+ r.eax.l = kernel_size >> gfx_config.sector_shift; // in sectors
+ r.esi.l = (uint32_t) label;
+ __farcall(gfx.code_seg, gfx.jmp_table[GFX_CB_PROGRESS_INIT], &r, &r);
+ }
+
+ progress_active = 1;
+}
+
+
+// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+void gfx_progress_update(ssize_t advance)
+{
+ com32sys_t r;
+
+ if(progress_active) {
+ r.eax.l = advance >> gfx_config.sector_shift; // in sectors
+ __farcall(gfx.code_seg, gfx.jmp_table[GFX_CB_PROGRESS_UPDATE], &r, &r);
+ }
+}
+
+
+// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+void gfx_progress_done(void)
+{
+ com32sys_t r;
+
+ if(progress_active) {
+ __farcall(gfx.code_seg, gfx.jmp_table[GFX_CB_PROGRESS_DONE], &r, &r);
+ }
+
+ progress_active = 0;
+}
+
+
+// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
// Like read(2) but preserve bounce buffer.
//
ssize_t save_read(int fd, void *buf, size_t size)
@@ -652,14 +719,16 @@ void *load_one(char *file, ssize_t *file_size)
{
int fd;
void *buf = NULL;
+ char *str;
struct stat sbuf;
ssize_t size = 0, cur, i;
- com32sys_t r;
*file_size = 0;
if((fd = open(file, O_RDONLY)) == -1) {
- printf("%s: file not found\n", file);
+ asprintf(&str, "%s: file not found", file);
+ gfx_infobox(0, str, NULL);
+ free(str);
return buf;
}
@@ -671,23 +740,26 @@ void *load_one(char *file, ssize_t *file_size)
buf = malloc(size);
for(i = 1, cur = 0 ; cur < size && i > 0; cur += i) {
i = save_read(fd, buf + cur, CHUNK_SIZE);
- r.eax.l = i >> gfx_config.sector_shift;
- __farcall(gfx.code_seg, gfx.jmp_table[GFX_CB_PROGRESS_UPDATE], &r, &r);
+ if(i == -1) break;
+ gfx_progress_update(i);
}
}
else {
do {
buf = realloc(buf, size + CHUNK_SIZE);
i = save_read(fd, buf + size, CHUNK_SIZE);
+ if(i == -1) break;
size += i;
- r.eax.l = i >> gfx_config.sector_shift;
- __farcall(gfx.code_seg, gfx.jmp_table[GFX_CB_PROGRESS_UPDATE], &r, &r);
+ gfx_progress_update(i);
} while(i > 0);
}
close(fd);
if(i == -1) {
+ asprintf(&str, "%s: read error @ %d", file, size);
+ gfx_infobox(0, str, NULL);
+ free(str);
free(buf);
buf = NULL;
size = 0;
@@ -706,10 +778,10 @@ void *load_one(char *file, ssize_t *file_size)
//
void boot(int index)
{
- char *arg;
+ char *arg, *alt_kernel;
menu_t *menu_ptr;
- int label_len;
- unsigned u, ipapp;
+ int i, label_len;
+ unsigned ipapp;
const struct syslinux_ipappend_strings *ipappend;
for(menu_ptr = menu; menu_ptr; menu_ptr = menu_ptr->next, index--) {
@@ -722,9 +794,12 @@ void boot(int index)
arg = skip_spaces(cmdline);
label_len = strlen(menu_ptr->label);
- // if it does not start with label string, skip first word
+ // if it does not start with label string, assume first word is kernel name
if(strncmp(arg, menu_ptr->label, label_len)) {
+ alt_kernel = arg;
arg = skip_nonspaces(arg);
+ if(*arg) *arg++ = 0;
+ if(*alt_kernel) menu_ptr->alt_kernel = alt_kernel;
}
else {
arg += label_len;
@@ -735,14 +810,16 @@ void boot(int index)
// handle IPAPPEND
if(menu_ptr->ipappend && (ipapp = atoi(menu_ptr->ipappend))) {
ipappend = syslinux_ipappend_strings();
- for(u = 0; u < ipappend->count; u++) {
- if((ipapp & (1 << u)) && ipappend->ptr[u]) {
- sprintf(arg + strlen(arg), " %s", ipappend->ptr[u]);
+ for(i = 0; i < ipappend->count; i++) {
+ if((ipapp & (1 << i)) && ipappend->ptr[i]) {
+ sprintf(arg + strlen(arg), " %s", ipappend->ptr[i]);
}
}
}
boot_entry(menu_ptr, arg);
+
+ gfx_progress_done();
}
@@ -759,7 +836,6 @@ void boot_entry(menu_t *menu_ptr, char *arg)
char *file, *cmd_buf;
int fd;
struct stat sbuf;
- com32sys_t r;
char *s, *s0, *t, *initrd_arg;
if(!menu_ptr) return;
@@ -771,7 +847,8 @@ void boot_entry(menu_t *menu_ptr, char *arg)
return;
}
- file = menu_ptr->kernel;
+ file = menu_ptr->alt_kernel;
+ if(!file) file = menu_ptr->kernel;
if(!file) file = menu_ptr->linux;
if(!file) {
gfx_done();
@@ -782,21 +859,18 @@ void boot_entry(menu_t *menu_ptr, char *arg)
// first, load kernel
- r.eax.l = 0; // kernel size in sectors
+ kernel_size = 0;
if((fd = open(file, O_RDONLY)) >= 0) {
- if(!fstat(fd, &sbuf) && S_ISREG(sbuf.st_mode)) r.eax.l = sbuf.st_size >> gfx_config.sector_shift;
+ if(!fstat(fd, &sbuf) && S_ISREG(sbuf.st_mode)) kernel_size = sbuf.st_size;
close(fd);
}
- r.esi.l = (uint32_t) file;
- __farcall(gfx.code_seg, gfx.jmp_table[GFX_CB_PROGRESS_INIT], &r, &r);
+ gfx_progress_init(kernel_size, file);
kernel = load_one(file, &kernel_size);
if(!kernel) {
- gfx_done();
- printf("%s: read error\n", file);
return;
}
@@ -846,8 +920,6 @@ void boot_entry(menu_t *menu_ptr, char *arg)
free(s0);
- __farcall(gfx.code_seg, gfx.jmp_table[GFX_CB_PROGRESS_DONE], &r, &r);
-
gfx_done();
syslinux_boot_linux(kernel, kernel_size, initrd, arg);
--
1.6.4.2
From bf3fd44448fb81ac481a2a1ac6d90f5a27e4d1de Mon Sep 17 00:00:00 2001
From: Steffen Winterfeldt <wfeldt@opensuse.org>
Date: Mon, 19 Apr 2010 15:17:57 +0200
Subject: [PATCH] fix menu label handling
Signed-off-by: Steffen Winterfeldt <wfeldt@opensuse.org>
---
com32/gfxboot/gfxboot.c | 48 +++++++++++++++++++++++++++-------------------
1 files changed, 28 insertions(+), 20 deletions(-)
diff --git a/com32/gfxboot/gfxboot.c b/com32/gfxboot/gfxboot.c
index c5112f4..a6c95fe 100644
--- a/com32/gfxboot/gfxboot.c
+++ b/com32/gfxboot/gfxboot.c
@@ -116,14 +116,15 @@ typedef struct __attribute__ ((packed)) {
// menu description
typedef struct menu_s {
struct menu_s *next;
- char *label;
- char *kernel;
- char *alt_kernel;
- char *linux;
- char *localboot;
- char *initrd;
- char *append;
- char *ipappend;
+ char *label; // config entry name
+ char *menu_label; // text to show in boot menu
+ char *kernel; // name of program to load
+ char *alt_kernel; // alternative name in case user has replaced it
+ char *linux; // de facto an alias for 'kernel'
+ char *localboot; // boot from local disk
+ char *initrd; // initrd as separate line (instead of as part of 'append')
+ char *append; // kernel args
+ char *ipappend; // append special pxelinux args (see doc)
} menu_t;
@@ -345,7 +346,7 @@ int read_config_file(void)
menu_ptr = *menu_next = calloc(1, sizeof **menu_next);
menu_next = &menu_ptr->next;
menu_idx++;
- menu_ptr->label = strdup(t);
+ menu_ptr->label = menu_ptr->menu_label = strdup(t);
u = strlen(t);
if(u > label_size) label_size = u;
continue;
@@ -390,7 +391,7 @@ int read_config_file(void)
t = skip_spaces(t);
if(!strcasecmp(s, "label")) {
- menu_ptr->label = strdup(t);
+ menu_ptr->menu_label = strdup(t);
u = strlen(t);
if(u > label_size) label_size = u;
continue;
@@ -404,15 +405,22 @@ int read_config_file(void)
label_size++;
append_size++;
- gfx_menu.entries = menu_idx;
- gfx_menu.label_size = label_size;
- gfx_menu.arg_size = append_size;
+ // ensure we have a default entry
+ if(!menu_default->label) menu_default->label = menu->label;
- gfx_menu.default_entry = menu_default->label;
- if(!gfx_menu.default_entry && menu) {
- gfx_menu.default_entry = menu->label;
+ if(menu_default->label) {
+ for(menu_ptr = menu; menu_ptr; menu_ptr = menu_ptr->next) {
+ if(!strcmp(menu_default->label, menu_ptr->label)) {
+ menu_default->menu_label = menu_ptr->menu_label;
+ break;
+ }
+ }
}
+ gfx_menu.entries = menu_idx;
+ gfx_menu.label_size = label_size;
+ gfx_menu.arg_size = append_size;
+ gfx_menu.default_entry = menu_default->menu_label;
gfx_menu.label_list = calloc(menu_idx, label_size);
gfx_menu.arg_list = calloc(menu_idx, append_size);
@@ -420,7 +428,7 @@ int read_config_file(void)
if(!menu_ptr->append) menu_ptr->append = menu_default->append;
if(!menu_ptr->ipappend) menu_ptr->ipappend = menu_default->ipappend;
- if(menu_ptr->label) strcpy(gfx_menu.label_list + u * label_size, menu_ptr->label);
+ if(menu_ptr->menu_label) strcpy(gfx_menu.label_list + u * label_size, menu_ptr->menu_label);
if(menu_ptr->append) strcpy(gfx_menu.arg_list + u * append_size, menu_ptr->append);
}
@@ -789,13 +797,13 @@ void boot(int index)
}
// invalid index or menu entry
- if(!menu_ptr || !menu_ptr->label) return;
+ if(!menu_ptr || !menu_ptr->menu_label) return;
arg = skip_spaces(cmdline);
- label_len = strlen(menu_ptr->label);
+ label_len = strlen(menu_ptr->menu_label);
// if it does not start with label string, assume first word is kernel name
- if(strncmp(arg, menu_ptr->label, label_len)) {
+ if(strncmp(arg, menu_ptr->menu_label, label_len)) {
alt_kernel = arg;
arg = skip_nonspaces(arg);
if(*arg) *arg++ = 0;
--
1.6.4.2

View File

@ -1,57 +0,0 @@
diff --git a/core/keywords b/core/keywords
index c289ae2..b7d4c4b 100644
--- a/core/keywords
+++ b/core/keywords
@@ -6,6 +6,7 @@ initrd
config
default
ui
+gfxboot
display
font
implicit
diff --git a/core/keywords.inc b/core/keywords.inc
index d0f7db3..fc00ad7 100644
--- a/core/keywords.inc
+++ b/core/keywords.inc
@@ -91,6 +91,7 @@ keywd_table:
keyword f0, pc_filename, FKeyN(10)
keyword f11, pc_filename, FKeyN(11)
keyword f12, pc_filename, FKeyN(12)
+ keyword gfxboot, pc_gfxboot
%if IS_PXELINUX
keyword ipappend, pc_ipappend
%endif
diff --git a/core/parseconfig.inc b/core/parseconfig.inc
index 65d71c9..2302536 100644
--- a/core/parseconfig.inc
+++ b/core/parseconfig.inc
@@ -30,6 +30,20 @@ pc_default: cmp ax,[DefaultLevel]
ret
;
+; "gfxboot" command; Shorthand for "ui gfxboot.c32"
+;
+pc_gfxboot:
+ mov ax,2
+ mov [DefaultLevel],ax ; Setup UI mode
+ mov si,gfxboot_cmd
+ mov di,default_cmd
+ call strcpy
+ dec di
+ call getline
+ mov byte [di-1],0 ; null-terminate
+ ret
+
+;
; "ontimeout" command
;
pc_ontimeout: mov di,Ontimeout
@@ -439,6 +453,7 @@ commit_vk:
section .data
vk_overflow_msg db 'Out of memory parsing config file', CR, LF, 0
SerialNotice db 1 ; Only print this once
+gfxboot_cmd db 'gfxboot.c32 ', 0
section .bss
alignb 4

View File

@ -1,283 +0,0 @@
diff --git a/core/isolinux.asm b/core/isolinux.asm
index 23429bd..54f2e19 100644
--- a/core/isolinux.asm
+++ b/core/isolinux.asm
@@ -1135,73 +1135,23 @@ all_read:
; (which will be at 16 only for a single-session disk!); from the PVD
; we should be able to find the rest of what we need to know.
;
-get_fs_structures:
- mov eax,[bi_pvd]
- mov bx,trackbuf
- call getonesec
-
- mov eax,[trackbuf+156+2]
- mov [RootDir+dir_lba],eax
- mov [CurrentDir+dir_lba],eax
-%ifdef DEBUG_MESSAGES
- mov si,dbg_rootdir_msg
- call writemsg
- call writehex8
- call crlf
-%endif
- mov eax,[trackbuf+156+10]
- mov [RootDir+dir_len],eax
- mov [CurrentDir+dir_len],eax
- add eax,SECTOR_SIZE-1
- shr eax,SECTOR_SHIFT
- mov [RootDir+dir_clust],eax
- mov [CurrentDir+dir_clust],eax
-
- ; Look for an isolinux directory, and if found,
- ; make it the current directory instead of the root
- ; directory.
- ; Also copy the name of the directory to CurrentDirName
- mov word [CurrentDirName],ROOT_DIR_WORD ; Write '/',0 to the CurrentDirName
+ call iso_mount
mov di,boot_dir ; Search for /boot/isolinux
- mov al,02h
- push di
- call searchdir_iso
- pop di
- jnz .found_dir
- mov di,isolinux_dir
- mov al,02h ; Search for /isolinux
- push di
- call searchdir_iso
- pop di
- jz .no_isolinux_dir
+ call setcwd
+ jnc .found_dir
+ mov di,isolinux_dir ; Search for /isolinux
+ call setcwd
.found_dir:
- ; Copy current directory name to CurrentDirName
- push si
- push di
- mov si,di
- mov di,CurrentDirName
- call strcpy
- mov byte [di],0 ;done in case it's not word aligned
- dec di
- mov byte [di],'/'
- pop di
- pop si
- mov [CurrentDir+dir_len],eax
- mov eax,[si+file_left]
- mov [CurrentDir+dir_clust],eax
- xor eax,eax ; Free this file pointer entry
- xchg eax,[si+file_sector]
- mov [CurrentDir+dir_lba],eax
%ifdef DEBUG_MESSAGES
push si
mov si,dbg_isodir_msg
call writemsg
pop si
+ mov eax,[CurrentDir+dir_lba]
call writehex8
call crlf
%endif
-.no_isolinux_dir:
;
; Locate the configuration file
@@ -1706,6 +1656,90 @@ getfssec:
TRACER 'f'
ret
+;
+; setcwd: Set current working directory.
+;
+; On entry:
+; DI -> directory name
+; On exit:
+; CF = 1 -> error
+;
+; On error, the old working directory is kept.
+;
+setcwd:
+ mov al,02h
+ push di
+ call searchdir_iso
+ pop di
+ stc
+ jz .err
+ mov [CurrentDir+dir_len],eax
+ mov eax,[si+file_left]
+ mov [CurrentDir+dir_clust],eax
+ xor eax,eax
+ xchg eax,[si+file_sector]
+ mov [CurrentDir+dir_lba],eax
+ mov si,di
+ mov di,CurrentDirName
+ cmp si,di
+ jz .ok
+ mov cx,FILENAME_MAX
+ push ds
+ pop es
+.copy:
+ lodsb
+ stosb
+ or al,al
+ loopnz .copy
+ mov byte [di-1],0
+ jnz .err
+.ok:
+ clc
+.err:
+ ret
+
+;
+; Read fs meta data and setup RootDir and CurrentDir.
+;
+; On exit:
+; CF = 1 -> error
+;
+iso_mount:
+ mov eax,[bi_pvd]
+ mov bx,trackbuf
+ call getonesec
+
+ mov eax,[trackbuf+156+10]
+ mov [RootDir+dir_len],eax
+ add eax,SECTOR_SIZE-1
+ shr eax,SECTOR_SHIFT
+ mov [RootDir+dir_clust],eax
+ mov eax,[trackbuf+156+2]
+ mov [RootDir+dir_lba],eax
+
+ push ds
+ pop es
+ mov si,RootDir
+ mov di,CurrentDir
+ mov cx,dir_t_size
+ rep movsb
+
+%ifdef DEBUG_MESSAGES
+ mov si,dbg_rootdir_msg
+ call writemsg
+ call writehex8
+ call crlf
+%endif
+
+ mov di,CurrentDirName
+ call setcwd
+ jnc .ok
+ mov word [CurrentDirName],ROOT_DIR_WORD
+.ok:
+ clc
+ ret
+
+
; -----------------------------------------------------------------------------
; Common modules
; -----------------------------------------------------------------------------
diff --git a/core/comboot.inc b/core/comboot.inc
index f8a7853..37bd0f2 100644
--- a/core/comboot.inc
+++ b/core/comboot.inc
@@ -970,6 +970,45 @@ comapi_shufraw:
mov ecx,P_ECX
jmp shuffle_and_boot_raw
+
+;
+; INT 22h AX=0025h Set current working directory
+;
+%if IS_ISOLINUX
+comapi_setcwd:
+ mov si,P_BX
+ mov di,TmpDirName
+ mov cx,FILENAME_MAX
+ mov ds,P_ES
+.copy:
+ lodsb
+ stosb
+ or al,al
+ loopnz .copy
+ push cs
+ pop ds
+ stc
+ jnz .err
+ mov di,TmpDirName
+ call setcwd
+.err:
+ ret
+%else
+comapi_setcwd equ comapi_err
+%endif
+
+
+;
+; INT 22h AX=0026h Read filesystem meta data
+;
+%if IS_ISOLINUX
+comapi_mount:
+; call iso_mount
+ ret
+%else
+comapi_mount equ comapi_err
+%endif
+
section .data
%macro int21 2
@@ -1029,6 +1068,8 @@ int22_table:
dw comapi_closedir ; 0022 close directory
dw comapi_shufsize ; 0023 query shuffler size
dw comapi_shufraw ; 0024 cleanup, shuffle and boot raw
+ dw comapi_setcwd ; 0025 set current working directory
+ dw comapi_mount ; 0026 read fs structures (aka mount)
int22_count equ ($-int22_table)/2
APIKeyWait db 0
@@ -1049,8 +1090,9 @@ feature_flags_len equ ($-feature_flags)
err_notdos db ': attempted DOS system call INT ',0
err_comlarge db 'COMBOOT image too large.', CR, LF, 0
- section .bss1
+ section .bss2
alignb 4
DOSErrTramp resd 33 ; Error trampolines
+TmpDirName resb FILENAME_MAX
ConfigName resb FILENAME_MAX
CurrentDirName resb FILENAME_MAX
diff --git a/doc/comboot.txt b/doc/comboot.txt
index eb43708..13d18f6 100644
--- a/doc/comboot.txt
+++ b/doc/comboot.txt
@@ -949,3 +949,20 @@ AX=0024h [3.80] Cleanup, shuffle and boot, raw version
with read/write data segments, matching the respective code
segment. For mode 0, B=0 and the limits will be 64K, for mode
1, B=1 and the limits will be 4 GB.
+
+
+AX=0025h [3.84] Set current working directory
+ Input: AX 00025h
+ ES:BX null-terminated directory name string
+ Output: None
+
+ Sets the current working directory. For SYSLINUX, ISOLINUX,
+ and PXELINUX, this will be an absolute path.
+
+
+AX=0026h [3.84] Read file system metadata [ISOLINUX]
+ Input: AX 00026h
+ Output: None
+
+ Reads filesystem data (e.g. after a CDROM change).
+
diff --git a/modules/Makefile b/modules/Makefile
index 77020ea..f318364 100644
--- a/modules/Makefile
+++ b/modules/Makefile
@@ -19,7 +19,7 @@ include $(topdir)/MCONFIG.embedded
INCLUDES = -I$(com32)/include
-BINS = pxechain.com gfxboot.com poweroff.com int18.com
+BINS = pxechain.com poweroff.com int18.com
all: $(BINS)

View File

@ -1,180 +0,0 @@
diff --git a/Makefile b/Makefile
index 2393faa..c7daebb 100644
--- a/Makefile
+++ b/Makefile
@@ -68,7 +68,7 @@ INSTALL_SBIN = extlinux/extlinux
# Things to install in /usr/lib/syslinux
INSTALL_AUX = core/pxelinux.0 gpxe/gpxelinux.0 core/isolinux.bin \
core/isolinux-debug.bin \
- dos/syslinux.com win32/syslinux.exe \
+ dos/syslinux.com \
mbr/*.bin $(MODULES)
INSTALL_AUX_OPT = win32/syslinux.exe
diff --git a/core/Makefile b/core/Makefile
index 65418c4..fbb38b5 100644
--- a/core/Makefile
+++ b/core/Makefile
@@ -66,6 +66,7 @@ kwdhash.gen: keywords genhash.pl
iso%.bin: iso%.elf checksumiso.pl
$(OBJCOPY) -O binary $< $@
$(PERL) checksumiso.pl $@
+ -./add_crc $@
# Standard rule for {ldlinux,pxelinux,extlinux}.bin
%.bin: %.elf
diff --git a/core/add_crc b/core/add_crc
new file mode 100644
index 0000000..0da2307
--- /dev/null
+++ b/core/add_crc
@@ -0,0 +1,57 @@
+#! /usr/bin/perl
+
+use integer;
+
+# for isolinux
+#
+# Ensure checksum over (first sector - 64 bytes) [internally: FirstSecSum]
+# is 0 by adjusting the variable csum_value.
+#
+# Though isolinux checks the integrity with a separate checksum after all
+# data has been loaded this does not help with BIOSes that don't get even
+# the first 2k right. Hence this additional check. :-(
+#
+
+$file = shift;
+$list = "$file";
+$list =~ s/\.bin$/.lsr/;
+
+open F, $list;
+
+while(<F>) {
+ if(/^\s*\d+\s*(\S+)\s*0+\s*(\<\d+\>\s*)?csum_value\s*dd\s*0/) {
+ $ofs = hex $1;
+ }
+}
+close F;
+
+die "oops 1\n" unless $ofs && !($ofs & 3);
+
+# print "$ofs\n";
+
+open F, $file or die "$file: $!\n";
+
+$file_size = -s $file;
+
+sysread F, $buf, $file_size;
+
+close F;
+
+die "oops 1\n" if $file_size != length($buf);
+
+@x = unpack "V512", $buf;
+
+for ($sum = 0, $i = 16; $i < 512; $i++) {
+ $sum += $x[$i];
+}
+
+# printf "0x%08x\n", $sum;
+
+$ns = pack "V", -$sum;
+
+substr($buf, $ofs, 4) = $ns;
+
+open F, ">$file" or die "$file: $!\n";
+
+syswrite F, $buf;
+
diff --git a/core/isolinux.asm b/core/isolinux.asm
index 54f2e19..72be12a 100644
--- a/core/isolinux.asm
+++ b/core/isolinux.asm
@@ -308,6 +308,22 @@ initial_csum: xor edi,edi
mov [FirstSecSum],edi
mov [DriveNumber],dl
+
+ ; check whether the BIOS did load us correctly
+ cmp dl,80h ; some BIOSes try to do floppy emulation...
+ jb bios_err
+ cmp dword [FirstSecSum], byte 0
+ jmp bios_ok ; ##############
+ jz bios_ok
+bios_err:
+ mov si,broken_bios_msg
+ call writemsg
+ jmp short $
+broken_bios_msg db 13, 10, 'Cannot boot from this CD. Please try a BIOS update.', 13, 10, 0
+ align 4
+csum_value dd 0
+bios_ok:
+
%ifdef DEBUG_MESSAGES
mov si,startup_msg
call writemsg
@@ -336,6 +352,9 @@ initial_csum: xor edi,edi
cmp word [BIOSType],bios_cdrom
jne found_drive ; If so, no spec packet...
+%if 0
+ ; Some BIOSes don't like that call.
+
; Now figure out what we're actually doing
; Note: use passed-in DL value rather than 7Fh because
; at least some BIOSes will get the wrong value otherwise
@@ -356,6 +375,8 @@ initial_csum: xor edi,edi
call crlf
%endif
+%endif
+
found_drive:
; Alright, we have found the drive. Now, try to find the
; boot file itself. If we have a boot info table, life is
@@ -480,6 +501,9 @@ integrity_ok:
%endif
jmp all_read ; Jump to main code
+%if 0
+ ; doesn't work anyway, see above
+
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Start of BrokenAwardHack --- 10-nov-2002 Knut_Petersen@t-online.de
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@@ -671,6 +695,7 @@ spec_query_failed:
mov si,trysbm_msg
call writemsg
jmp .found_drive ; Pray that this works...
+%endif
fatal_error:
mov si,nothing_msg
@@ -936,8 +961,18 @@ maxtrans:
getlinsec_cdrom:
mov si,dapa ; Load up the DAPA
mov [si+4],bx
- mov [si+6],es
mov [si+8],eax
+
+ ; seems that some BIOSes have problems if the target
+ ; segment is 0 (don't ask); to avoid this, we normalize
+ ; the buffer address here
+ ; -> seen on Acer TravelMate C102Ti
+ and word [si+4],0fh
+ mov ax,es
+ shr bx,4
+ add ax,bx
+ mov [si+6],ax
+
.loop:
push bp ; Sectors left
cmp bp,[MaxTransferCD]
@@ -1770,6 +1805,7 @@ default_str db 'default', 0
default_len equ ($-default_str)
boot_dir db '/boot' ; /boot/isolinux
isolinux_dir db '/isolinux', 0
+zb 64
config_name db 'isolinux.cfg', 0
err_disk_image db 'Cannot load disk image (invalid file)?', CR, LF, 0

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:82a8d2a242f869cb4c34b3a074871f472762343e1879a4dca23d7ce5c4dcd06d
size 3735823

45
syslinux-4.04-cwd.diff Normal file
View File

@ -0,0 +1,45 @@
diff --git a/com32/gfxboot/gfxboot.c b/com32/gfxboot/gfxboot.c
index 9a39e79..35d180a 100644
--- a/com32/gfxboot/gfxboot.c
+++ b/com32/gfxboot/gfxboot.c
@@ -102,6 +102,8 @@ typedef struct __attribute__ ((packed)) {
// 0: GFX_CB_MENU_INIT accepts 32 bit addresses
// 1: knows about xmem_start, xmem_end
uint16_t reserved_1; // 62:
+ uint32_t gfxboot_cwd; // 64: if set, points to current gfxboot working directory relative
+ // to syslinux working directory
} gfx_config_t;
@@ -181,6 +183,7 @@ int main(int argc, char **argv)
{
int menu_index;
const union syslinux_derivative_info *sdi;
+ char working_dir[256];
openconsole(&dev_stdcon_r, &dev_stdcon_w);
@@ -224,6 +227,10 @@ int main(int argc, char **argv)
return 0;
}
+ if(getcwd(working_dir, sizeof working_dir)) {
+ gfx_config.gfxboot_cwd = (uint32_t) working_dir;
+ }
+
if(gfx_init(argv[1])) {
printf("Error setting up gfxboot\n");
if(argc > 2) show_message(argv[2]);
@@ -806,6 +813,12 @@ void boot(int index)
int i, label_len;
unsigned ipapp;
const struct syslinux_ipappend_strings *ipappend;
+ char *gfxboot_cwd = (char *) gfx_config.gfxboot_cwd;
+
+ if(gfxboot_cwd) {
+ chdir(gfxboot_cwd);
+ gfx_config.gfxboot_cwd = 0;
+ }
for(menu_ptr = menu; menu_ptr; menu_ptr = menu_ptr->next, index--) {
if(!index) break;

View File

@ -0,0 +1,38 @@
diff --git a/core/fs/iso9660/iso9660.c b/core/fs/iso9660/iso9660.c
index 3cd3ac4..9bbc299 100644
--- a/core/fs/iso9660/iso9660.c
+++ b/core/fs/iso9660/iso9660.c
@@ -228,14 +228,25 @@ static int iso_readdir(struct file *file, struct dirent *dirent)
/* Load the config file, return 1 if failed, or 0 */
static int iso_load_config(void)
{
- static const char *search_directories[] = {
- "/boot/isolinux",
- "/isolinux",
- "/boot/syslinux",
- "/syslinux",
- "/",
- NULL
- };
+ /*
+ * Put search_directories[] to different section so it
+ * won't be compressed (and we can patch it later).
+ */
+ __asm__(
+ ".section .data16\n"
+ ".s1: .ascii \"/boot\"\n"
+ ".s2: .string \"/isolinux\"\n"
+ ".fill 64, 1, 0\n"
+ ".s3: .ascii \"/boot\"\n"
+ ".s4: .string \"/syslinux\"\n"
+ ".s5: .string \"/\"\n"
+ ".align 4\n"
+ "search_directories:\n"
+ ".long .s1, .s2, .s3, .s4, .s5, 0\n"
+ ".text\n"
+ );
+ extern const char *search_directories[];
+
static const char *filenames[] = {
"isolinux.cfg",
"syslinux.cfg",

View File

@ -0,0 +1,39 @@
diff --git a/com32/mboot/mboot.c b/com32/mboot/mboot.c
index 35450e0..a124a21 100644
--- a/com32/mboot/mboot.c
+++ b/com32/mboot/mboot.c
@@ -97,9 +97,14 @@ static int get_modules(char **argv, struct module_data **mdp)
int arglen;
const char module_separator[] = "---";
+ char *bootif = 0;
for (argp = argv; *argp; argp++) {
if (!strcmp(*argp, module_separator))
module_count++;
+ /* BOOTIF= gets only appended for last group by syslinux, but it may be needed also
+ for other modules. So let's copy it. Esp. needed for XEN booting, Dom0 kernel needs it */
+ if (!strncmp(*argp, "BOOTIF=", 7))
+ bootif = *argp;
}
*mdp = mp = malloc(module_count * sizeof(struct module_data));
@@ -133,11 +138,19 @@ static int get_modules(char **argv, struct module_data **mdp)
mp->cmdline = strdup("");
} else {
char *p;
+ if (bootif) {
+ arglen += strlen(bootif) + 1;
+ }
+
mp->cmdline = p = malloc(arglen);
for (; *argp && strcmp(*argp, module_separator); argp++) {
p = stpcpy(p, *argp);
*p++ = ' ';
}
+ if (bootif) {
+ p = stpcpy(p, bootif);
+ *p++ = ' ';
+ }
*--p = '\0';
}
mp++;

View File

@ -0,0 +1,21 @@
diff --git a/com32/gfxboot/gfxboot.c b/com32/gfxboot/gfxboot.c
index 3749920..9a39e79 100644
--- a/com32/gfxboot/gfxboot.c
+++ b/com32/gfxboot/gfxboot.c
@@ -922,11 +922,15 @@ void boot_entry(menu_t *menu_ptr, char *arg)
*skip_nonspaces(s) = 0;
initrd_arg = s;
}
+ else if(initrd_arg) {
+ free(s0);
+ initrd_arg = s0 = strdup(initrd_arg);
+ }
if(initrd_arg) {
initrd = initramfs_init();
- while((t = strsep(&s, ","))) {
+ while((t = strsep(&initrd_arg, ","))) {
initrd_buf = load_one(t, &initrd_size);
if(!initrd_buf) {

BIN
syslinux-4.04.tar.bz2 (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -1,3 +1,182 @@
-------------------------------------------------------------------
Wed Apr 20 11:27:23 CEST 2011 - snwint@suse.de
- adrian: mboot: replicate BOOTIF option for all modules
-------------------------------------------------------------------
Tue Apr 19 15:29:10 CEST 2011 - snwint@suse.de
- handle case where a separate initrd config line is used instead of an
initrd= kernel option
-------------------------------------------------------------------
Tue Apr 19 10:48:40 CEST 2011 - snwint@suse.de
- update to version 4.04
* PXELINUX: Fix handling of unqualified DNS names.
* PXELINUX: Fix timer bug when PXELINUX might be unloaded
(Gene Cumm).
* core/writedec.inc: Fix duplicate declaration and overflow
(Gene Cumm).
* GCC 4.5 fixes.
* sample directory: Fix Makefile include (Gene Cumm).
* ver.com: New universal DOS/COMBOOT application to display
version information (includes DRMK) (Gene Cumm).
* rosh.c32: updated; Using getopt() for internal commands to aid
parsing options; Fix bugs in ls; add warm reboot and echo
(Gene Cumm).
* com32: fix a file descriptor leak.
* gfxboot.c32: handle TEXT..ENDTEXT; error out on no LABELs
found (Sebastian Herbszt).
* Fix booting on non-partitioned devices.
* MBR, isohybrid: Workaround for a BIOS issue on Acer
Travelmate and possibly other machines.
* COM32: Adding ACPI parsing libary
* HDT: Release 0.4.1 to support ACPI parsing,
improved mutli-core/cpu reporting
* LUA: Updating to 5.1.4-2
* SYSLINUX: core/diskstart.inc: Reset DS after checksum in case
it isn't 0 (Gene Cumm).
* win64: Script update for additional mingw compiler names
(Gene Cumm).
* diag: New directory for diagnostic-related tools. Add a
handoff MBR/VBR and geometry display images (Gene Cumm).
* MEMDISK: use "mem=" parameter to mark available memory above
this point as reserved (core already does alignment) (Gene Cumm).
* MEMDISK: Additional disk probe checks and debug output
(Shao Miller, Gene Cumm).
* gpxe: add gpxelinuxk.0, based off of undionly.kpxe + new
script (Gene Cumm).
* isohybrid: install the isohdpfx*.bin/isohdppx*.bin files to
make isohybrid images in one step with GNU xorriso.
* PXELINUX: disable a hack that would make localboot work on
some machines, but break just about as many. Some machines
which worked with "localboot 0" in previous versions may
need "localboot -1" in this one. If you have a machine
which requires "localboot -1", a copy of the dmidecode
or sysdump output would be appreciated.
* Include a set of diagnostics by Gene Cumm.
* Fixes for gcc 4.6 and binutils 2.21.51.
* chain.c32: Allow "uuid" as a synonym to "guid".
* Handle directory names starting with .. for vfat and
iso9660.
* New MENU HIDDENKEY command to provide a one-keystroke way to
activate a boot option from a hidden menu intro screen.
-------------------------------------------------------------------
Mon Apr 18 17:35:01 CEST 2011 - snwint@suse.de
- update to version 4.03
* Major code base changes; all filesystem rewritten in C.
This work was done primarily by Liu Aleaxander (Yuanhan Liu).
* Better support for booting from MBRs which don't pass
handover information.
* EXTLINUX: Try to be smarter about finding the partition
offset.
* chain.c32: support chainloading Dell Real Mode Kernel (Gene
Cumm).
* chain.c32: fix booting in CHS mode.
* Fix the -s option to the syslinux/extlinux installer (Arwin
Vosselman).
* isohybrid: fix padding of large images (PJ Pandit).
* SYSLINUX: correctly handle the case where the -d option is
specified with a non-absolute path, i.e. "syslinux -d
syslinux" instead of "syslinux -d /syslinux".
* ISOLINUX: recognize the directory names /boot/syslinux and
/syslinux, and the filename syslinux.cfg in addition to the
isolinux-specific names. Thus, "syslinux.cfg" is now a
generic name, whereas "isolinux.cfg" or "extlinux.conf" is
specific to different derivative.
* chain.c32: support setting alternate config filename for
stage2 of GRUB Legacy (Gert Hulselmans).
* whichsys.c32: execute specific command, based on Syslinux
bootloader variant (Gert Hulselmans).
* lua.c32: a lot of new bindings added to the "syslinux"
namespace: VESA, PCI, DMI, kernel loading (Marcel Ritter).
* btrfs: print a comprehensive error message if compressed or
encrypted files are encountered (neither is currently
supported.)
* SYSLINUX: mtools installer: honor TMPDIR, error out on disk
full.
* Handle fallbacks from EDD to CHS, to deal with systems which
announce EDD support but don't actually have it.
* SYSLINUX: the mtools, DOS and win32 installers now use the new
command line options.
* PXELINUX: fix the use of IP addresses in TFTP :: or tftp://
host syntax.
* SYSLINUX: experimental Win64 installer (syslinux64.exe).
* ISOLINUX: fix initialization on systems which don't zero
low memory.
* SYSLINUX/EXTLINUX: fix handing of disk read retries in
EDD mode.
* ISOLINUX: change the initialization sequence to avoid
problems with certain (old) BIOSes. Special thanks to
Helmut Hullen for invaluable debugging support.
* ifplop.c32: new module which detects if the PLoP Boot Loader
already has booted a CDROM or USB drive (Gert Hulselmans).
* Correct a severe memory overwrite bug, triggered primarily
when selecting a very long command line in the menu system.
* lua.c32: Lua script interpreter, currently experimental
(Alexey Zaytsev, Marcel Ritter, Geert Stappers).
* PXELINUX: new option IPAPPEND 4 to append the system UUID to
the kernel command line.
* PXELINUX: display BOOTIF and SYSUUID at startup time, and
when Ctrl-N is pressed on the command line.
* EXTLINUX: btrfs and ext4 support. btrfs support was done by
Alek Du of Intel.
* EXTLINUX is no longer a separate derivative; extlinux and
syslinux both install the same loader (ldlinux.sys); for the
Linux-based installers the extlinux binary is used for a
mounted filesystem; the syslinux binary for an unmounted
filesystem.
* When loading a new configuration file with the CONFIG
command, one can now also specify a new current directory
with an APPEND statement.
* Full ADV support for Syslinux, to boot-once and MENU SAVE
works.
* Full support of GPT-partitioned disks, including disks
and/or parititions larger than 2 TiB (if supported by BIOS.)
* The GPT handover protocol adjusted to the current T13
committee draft; see doc/gpt.txt.
* HDT: code cleanup, small bugfixes
* The "linux" syslinux installer (syslinux-nomtools) now has a
command-line syntax closer to the extlinux installer. The
mtools, dos and win32 installers will get this new syntax
eventually, but it is not implemented yet.
* chain.c32: support booting GPT partitions by index, GUID, label.
* chain.c32: support booting the Syslinux partition with "fs".
* chain.c32: implement gpt.txt hand-over protocol.
* chain.c32: support for chainloading Grub stage 2.
* PXELINUX: TFTP URL syntax (tftp://) supported even when not
running gPXE/gpxelinux.
* New ls.c32 module to display the contents of the disk from
the command line, and pwd.c32 to display the current
directory.
* rosh.c32 (read only shell) updated and hopefully usable.
* PXELINUX: Support "localboot -1", just like the other
derivatives.
* gfxboot.com removed in favor of gfxboot.c32.
* New MENU HELP statement to display fullscreen help text as a
result of a menu selection.
* memdiskfind utility that can be used with the phram driver
in the Linux kernel to mount a memdisk.
* ifcpu.c32: Adding usage when no parameters are given,
adding PAE support.
* ifcpu.c32, ifcpu64.c32: handle more than one argument per
target.
* isohybrid: C version which does not require Perl.
* New command MENU IMMEDIATE to permit hotkeys to activate
immediately without needing Enter.
* mdiskchk.com supports a --no-sequential (or -n) option to
suppress the classic all-drive-probing heuristic. Useful
on BIOSes who crash/hang when certain drive numbers are
probed.
* ElTorito.Sys DOS driver now scans drive numbers upwards
instead of downwards, in order to avoid a fairly common
bug on some BIOSes where probing drive 0xFF causes a
failure.
-------------------------------------------------------------------
Tue Apr 27 17:33:10 CEST 2010 - snwint@suse.de

View File

@ -19,22 +19,22 @@
Name: syslinux
ExclusiveArch: %ix86 x86_64
BuildRequires: libpng-devel nasm netpbm python
BuildRequires: libpng-devel nasm netpbm python xz
Url: http://syslinux.zytor.com/
License: GPLv2+
Group: System/Boot
Requires: mtools
AutoReqProv: on
Summary: Boot Loader for Linux
Version: 3.86
Version: 4.04
Release: 4
Source: %{name}-%{version}.tar.bz2
Source1: isolinux-config
Source2: README.gfxboot
Patch0: %{name}-%{version}-gfxboot.diff
Patch1: %{name}-%{version}-suse.diff
Patch2: %{name}-%{version}-compat.diff
Patch3: %{name}-%{version}-com32.diff
Patch0: %{name}-%{version}-iso9660.diff
Patch1: %{name}-%{version}-cwd.diff
Patch2: %{name}-%{version}-noinitrd.diff
Patch3: %{name}-%{version}-mboot_bootif.diff
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
@ -59,8 +59,6 @@ Authors:
%build
cp %{SOURCE2} .
export CFLAGS="$RPM_OPT_FLAGS"
chmod +x core/add_crc
rm -f modules/gfxboot.com
make spotless
make