1 # --- T2-COPYRIGHT-NOTE-BEGIN ---
2 # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
4 # T2 SDE: package/.../lilo/compile.patch.dietlibc
5 # Copyright (C) 2004 - 2016 The T2 SDE Project
6 # Copyright (C) 1998 - 2004 ROCK Linux Project
8 # More information can be found in the files COPYING and README.
10 # This patch file is dual-licensed. It is available under the license the
11 # patched project is licensed under, as long as it is an OpenSource license
12 # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
13 # of the GNU General Public License as published by the Free Software
14 # Foundation; either version 2 of the License, or (at your option) any later
16 # --- T2-COPYRIGHT-NOTE-END ---
18 --- lilo-22.5.6/partition.h.orig Fri Jun 6 19:07:45 2003
19 +++ lilo-22.5.6/partition.h Fri Sep 5 17:42:53 2003
21 enum {PTW_OKAY=0, PTW_DOS=1, PTW_OS2=2, PTW_SWAP, PTW_XFS,
22 PTW_mask=7, PTW_NTFS=8};
26 #define LLSECTORSIZE ((long long)SECTOR_SIZE)
30 loff_t llseek(unsigned int fd, loff_t offs, unsigned int whence);
32 --- lilo-22.5.6/partition.c.orig Fri Sep 5 17:41:58 2003
33 +++ lilo-22.5.6/partition.c Fri Sep 5 17:47:18 2003
40 +#include <asm/posix_types.h>
51 _syscall5(int, _llseek, uint, fd, ulong, hi, ulong, lo,
52 loff_t *, res, uint, wh);
55 return _llseek(fd, offs>>32, offs, &res, whence) < 0 ?
61 int anywhere(void *buf, unsigned char *str)
65 while (i<=pe && base) {
67 + if (lseek(fd, LLSECTORSIZE*(base+second) + PART_TABLE_OFFSET, SEEK_SET) < 0)
68 + die("secondary lseek failed");
70 if (llseek(fd, LLSECTORSIZE*(base+second) + PART_TABLE_OFFSET, SEEK_SET) < 0)
71 die("secondary llseek failed");
73 if (read(fd, part_table, sizeof(part_table)) != sizeof(part_table)) die("secondary read pt failed");
74 if ( read(fd, &boot_sig, sizeof(boot_sig)) != sizeof(boot_sig) ||
75 boot_sig != BOOT_SIGNATURE ) die("read second boot signature failed");
77 if (pt[count].sys_ind && pt[count].boot_ind != flag) {
78 pt[count].boot_ind = flag;
79 printf("pt[%d] -> %2x\n", count+1, (int)flag);
81 + if (lseek(fd, daddr[count], SEEK_SET) < 0) die("PT lseek failed");
83 if (llseek(fd, daddr[count], SEEK_SET) < 0) die("PT llseek failed");
86 if (write(fd, &pt[count], sizeof(pt[0])) != sizeof(pt[0]) )
87 die("PT write failure");
91 daddr = LLSECTORSIZE*(base+second) + PART_TABLE_OFFSET;
93 + if (lseek(fd, daddr, SEEK_SET) < 0)
94 + die("secondary lseek failed");
96 if (llseek(fd, daddr, SEEK_SET) < 0)
97 die("secondary llseek failed");
99 if (read(fd, pt, sizeof(pt)) != sizeof(pt)) die("secondary read pt failed");
100 if ( read(fd, &boot_sig, sizeof(boot_sig)) != sizeof(boot_sig) ||
101 boot_sig != BOOT_SIGNATURE ) die("read second boot signature failed");
102 --- lilo-22.5.6/Makefile~ Mon Jun 30 03:45:19 2003
103 +++ lilo-22.5.6/Makefile Fri Sep 5 18:27:38 2003
105 # XL_SECS=n Support for extra large (non-standard) floppies.
107 CONFIG=-DBDATA -DDSECS=3 -DEVMS -DIGNORECASE -DLVM -DONE_SHOT -DPASS160 \
108 - -DREISERFS -DREWRITE_TABLE -DSOLO_CHAIN -DVERSION -DVIRTUAL
109 + -DREWRITE_TABLE -DSOLO_CHAIN -DVERSION -DVIRTUAL
111 # set the compiler optimization level
113 --- lilo-22.5.6/boot.c~ Tue Jun 24 22:23:10 2003
114 +++ lilo-22.5.6/boot.c Fri Sep 5 18:35:27 2003
120 +#include <linux/a.out.h>
124 #include <sys/stat.h>
127 --- lilo-22.5.6/bsect.c.orig Mon Jun 30 02:34:44 2003
128 +++ lilo-22.5.6/bsect.c Fri Sep 5 18:41:20 2003
132 #include <sys/types.h>
133 +#ifndef __dietlibc__
134 #include <sys/statfs.h>
136 #include <sys/stat.h>
139 --- lilo-22.5.6/partition.c~ Fri Sep 5 17:47:18 2003
140 +++ lilo-22.5.6/partition.c Fri Sep 5 18:44:06 2003
146 +#include <linux/a.out.h>
150 #include <sys/stat.h>
151 #include <sys/types.h>
152 #include <asm/unistd.h>
153 --- lilo-22.5.6/edit.c.orig Sun Feb 23 19:14:12 2003
154 +++ lilo-22.5.6/edit.c Mon Sep 8 07:48:20 2003
158 #include <sys/types.h>
160 +#include <sys/vfs.h>
162 #include <sys/statfs.h>
164 #include <sys/stat.h>