Subject: Bug#3547: Problems encountered while compiling "mc" on m68k arch

From: llucius <[email-masked]>
Date: Sun, 7 Jul 1996 01:40:03 -0500 (CDT)

Package: mc
Version: 3.2.1-1

The following problems were encountered while building on m68k arch:

1)  "debian.rules" contained hardcoded architecture.
2)  "debian.rules" created improperly named .deb binaries (new standard).
3)  "debian.control" file contained hardcoded architecture.

The following patches correct these problems:

--- orig/mc-3.2.1/debian.control	Wed May 22 23:23:26 1996
+++ mc-3.2.1/debian.control	Sat Jul  6 18:52:31 1996
@@ -1,5 +1,6 @@
 Package: mc
 Version: =V-=D
+Architecture: =A
 Maintainer: Fernando Alegre <[email-masked]>
 depends: libc5, ncurses3.0, ncurses-base
 Suggests: gpm
@@ -10,6 +11,5 @@
  It does not use libncurses, but it uses the terminfo database.
  Support for XView and TCL/Tk is available, but it is still experimental. It
  is not included in the current binary.
-Architecture: i386
 Section: misc
 Priority: low
--- orig/mc-3.2.1/debian.rules	Wed May 22 23:22:39 1996
+++ mc-3.2.1/debian.rules	Sat Jul  6 22:12:33 1996
@@ -8,6 +8,7 @@
 p = mc
 v = 3.2.1
 d = 1
+a = $(shell dpkg --print-architecture)
 
 build:
 	CFLAGS="-O2" ./configure --prefix=/usr --with-ncurses
@@ -35,7 +36,7 @@
 	install -d -g root -m 755 -o root debian-tmp/usr/doc/copyright
 	install -g root -m 644 -o root debian.README \
 	  debian-tmp/usr/doc/copyright/$(p)
-	sed -e '2s/=V/$(v)/' -e '2s/=D/$(d)/' debian.control \
+	sed -e '2s/=V/$(v)/' -e '2s/=D/$(d)/' -e '3s/=A/$(a)/' debian.control \
 	  > debian-tmp/DEBIAN/control
 	chmod 644 debian-tmp/DEBIAN/control
 	install -d -g root -m 755 -o root debian-tmp/usr/doc/mc
@@ -46,8 +47,7 @@
 	install -g root -m 755 -o root debian.prerm debian-tmp/DEBIAN/prerm
 	install -g root -m 755 -o root debian.postrm debian-tmp/DEBIAN/postrm
 	strip debian-tmp/usr/bin/mc
-	dpkg --build debian-tmp
-	mv debian-tmp.deb ../$(p)-$(v)-$(d).i386.deb
+	dpkg --build debian-tmp && dpkg-name -o -s .. debian-tmp.deb
 
 source:
 	-test -f stamp-build && make -f debian.rules clean