2005-11-02 Hollis Blanchard <hollis@penguinppc.org>

* Makefile.in (install-local): Use $(DATA).
	(uninstall): Likewise.
	* conf/powerpc-ieee1275.rmk (bin_UTILITIES): Move grub-mkimage...
	(sbin_UTILITIES): ... to here.
	(sbin_SCRIPTS): New variable.
	(grub_install_SOURCES): New variable.
	* util/powerpc/ieee1275/grub-install.in: New file.
	* util/powerpc/ieee1275/grub-mkimage.c (kernel_path): Remove
	variable.
	(add_segments): Call `grub_util_get_path'.
This commit is contained in:
hollisb 2005-11-03 05:05:05 +00:00
parent 25fe6f0349
commit 4b60267db7
6 changed files with 274 additions and 112 deletions

View file

@ -32,8 +32,6 @@
#define ALIGN_UP(addr, align) ((long)((char *)addr + align - 1) & ~(align - 1))
static char *kernel_path = "grubof";
#define GRUB_IEEE1275_NOTE_NAME "PowerPC"
#define GRUB_IEEE1275_NOTE_TYPE 0x1275
@ -165,10 +163,12 @@ add_segments (char *dir, FILE *out, int chrp, char *mods[])
Elf32_Phdr *phdrs = NULL;
Elf32_Phdr *phdr;
FILE *in;
char *kernel_path;
off_t phdroff;
int i;
/* Read ELF header. */
kernel_path = grub_util_get_path (dir, "grubof");
in = fopen (kernel_path, "rb");
if (! in)
grub_util_error ("cannot open %s", kernel_path);
@ -245,6 +245,7 @@ add_segments (char *dir, FILE *out, int chrp, char *mods[])
grub_util_write_image_at (&ehdr, sizeof (ehdr), 0, out);
free (phdrs);
free (kernel_path);
}
static struct option options[] =