Package: mbr Version: 1.1.8-1 Severity: wishlist I've been avoiding installing 1.1.8-1 because it wants to pull in libc6-i386, which is several megabytes of crap I don't need.
So I created the following patch to build a 64-bit install-mbr binary. It also fixes a few compile warnings. (The = to := changes in the makefile save a few microseconds of compile time.) As-is, it unconditionally disables the harness directory, which isn't needed on any architecture and can't function on a 64-bit kernel anyway. I don't know enough about debian package construction to know how to make that architecture-dependent. diff -r -u mbr-1.1.8/Makefile.in mbr-1.1.8local/Makefile.in --- mbr-1.1.8/Makefile.in 2006-08-13 10:00:33.000000000 -0400 +++ mbr-1.1.8local/Makefile.in 2006-08-13 09:52:49.000000000 -0400 @@ -67,7 +67,7 @@ PACKAGE = @PACKAGE@ VERSION = @VERSION@ -SUBDIRS = harness +#SUBDIRS = harness sbin_PROGRAMS = install-mbr install_mbr_SOURCES = install-mbr.c mbr.S86 mbr.h install_mbr_LDADD = mbr.o y2k.o diff -r -u mbr-1.1.8/debian/control mbr-1.1.8local/debian/control --- mbr-1.1.8/debian/control 2006-08-13 10:00:33.000000000 -0400 +++ mbr-1.1.8local/debian/control 2006-08-13 09:51:17.000000000 -0400 @@ -3,7 +3,7 @@ Priority: optional Maintainer: Santiago Garcia Mantinan <[EMAIL PROTECTED]> Standards-Version: 3.7.2 -Build-Depends: bin86, libc6-dev-i386 [amd64], ia32-libs [amd64] +Build-Depends: bin86 Package: mbr Architecture: i386 amd64 diff -r -u mbr-1.1.8/debian/rules mbr-1.1.8local/debian/rules --- mbr-1.1.8/debian/rules 2006-08-13 10:00:33.000000000 -0400 +++ mbr-1.1.8local/debian/rules 2006-08-13 09:50:39.000000000 -0400 @@ -1,15 +1,14 @@ #!/usr/bin/make -f -package = mbr -docdir = debian/tmp/usr/share/doc/$(package) +package := mbr +docdir := debian/tmp/usr/share/doc/$(package) KERNEL_ARCH := $(shell uname -m) -CC = gcc -m32 -LD = ld -melf_i386 +CC := gcc -CFLAGS = -g -Wall -W -INSTALL_PROGRAM = install +CFLAGS := -g -Wall -W +INSTALL_PROGRAM := install ifeq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) CFLAGS += -O2 diff -r -u mbr-1.1.8/install-mbr.c mbr-1.1.8local/install-mbr.c --- mbr-1.1.8/install-mbr.c 2006-08-13 10:00:33.000000000 -0400 +++ mbr-1.1.8local/install-mbr.c 2006-08-13 09:58:04.000000000 -0400 @@ -132,6 +132,7 @@ struct mbr_params_v1 *params; uint ver_compat; + (void)quiet; #if 0 fprintf(stderr, "Looking for params at %p\n", mbr); #endif @@ -172,6 +173,8 @@ static const char sig[] = MP_V2_SIG; struct mbr_params_v2 *params = (void*)(dsc->data + offset); + (void)quiet; + /* Check the signature. */ if (memcmp(params->sig, sig, sizeof(sig))) return NULL; @@ -763,10 +766,8 @@ static void install_mbr(struct data *dp) { - ui8_t *code, *params; struct change_params new_params; int mbr_fd = -1; - size_t mbr_size; ui8_t mbr_in[BUFFER_SIZE]; ui8_t mbr_out[BUFFER_SIZE]; struct file_desc target_orig={mbr_in, dp->target.path, 0}; @@ -1417,7 +1418,7 @@ /* flags */ 0, /* change_params structure */ - {0, 0, 0, 0, 0, 0, 0, 0xff, 0, 0xff, 0 }}; + {0, 0, 0, 0, 0, 0, 0, 0xff, 0, 0xff, 0, 0, 0 }}; assert(MBR_SIZE==BUFFER_SIZE); assert(Y2K_SIZE==BUFFER_SIZE); -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]