Subject: Bug#3709: Problems encountered while compiling "ratfor77" on m68k arch

From: llucius <[email-masked]>
Date: Mon, 8 Jul 1996 18:00:32 -0500 (CDT)

Package: ratfor77
Version: 1.0-2

The following problems were encountered while building on m68k arch:

1)  "debian.rules" did not support different architectures.
2)  "debian.rules" created improperly named .deb binaries (new standard).
3)  "debian.control" contained hardcoded architecture.

The following patches correct these problems:

--- orig/ratfor77-1.0/debian.control	Tue Jun 11 09:31:14 1996
+++ ratfor77-1.0/debian.control	Mon Jul  8 16:13:17 1996
@@ -1,6 +1,6 @@
 Package: =P
 Version: =V-=D
-Architecture: i386
+Architecture: =A
 Maintainer: Emilio C. Lopes <[email-masked]>
 Description: Rational Fortran preprocessor for Fortran 77.
  Ratfor77 is a preprocessor that converts the Rational Fortran dialect
--- orig/ratfor77-1.0/debian.rules	Mon Jun 10 18:15:15 1996
+++ ratfor77-1.0/debian.rules	Mon Jul  8 16:13:07 1996
@@ -10,6 +10,8 @@
 v = 1.0
 ## The Debian revision of the package.
 d = 2
+## The target architecture.
+a = $(shell dpkg --print-architecture)
 
 default: test_dir
 	@echo The following targets are defined:
@@ -57,11 +59,11 @@
 	install -o root -g root -m 644 copyright \
 	  debian-tmp/usr/doc/copyright/$(p)
 	install -d -o root -g root -m 755 debian-tmp/DEBIAN
-	sed -e '1s/=P/$(p)/' -e '2s/=V/$(v)/' -e '2s/=D/$(d)/' \
+	sed -e '1s/=P/$(p)/' -e '2s/=V-=D/$(v)-$(d)/' -e '3s/=A/$(a)/' \
 	  debian.control > debian-tmp/DEBIAN/control
 	chmod 644 debian-tmp/DEBIAN/control
 	dpkg --build debian-tmp
-	mv debian-tmp.deb ../$(p)-$(v)-$(d).i386.deb
+	dpkg-name -o -s .. debian-tmp.deb
 
 source: test_dir
 ## Makes a source file.