Bug#161803: Build problems on Redhat 7.2
Package: dpkg
Version: 1.10.6
I'm building dpkg on a (yuck!) Redhat system, and get the following type of
error message from 'make':
make[2]: *** No rule to make target `archtable', needed by `archtable.h'.
Stop.
make[2]: Leaving directory `/home/henning/agenda/work/y/dpkg-1.10.6/main'
make[1]: *** [all-main] Error 2
This type of error also exists for every subdirectory during 'make install'.
I'm using make-3.79.1-8 on Redhat 7.2.
The reason seems to be the order of defines at the top of all the Makefile.in
files. It currently is:
VPATH = @srcdir@
srcdir = @srcdir@
top_srcdir = @top_srcdir@
top_builddir = ..
default: all
include ../Makefile.conf
Which, on my machine defines top_srcdir to be "." (because it is redefined in
Makefile.conf), which is wrong. The fix seems to be to move the definition of
top_srcdir to after the include statement:
VPATH = @srcdir@
srcdir = @srcdir@
top_builddir = ..
default: all
include ../Makefile.conf
top_srcdir = @top_srcdir@
After applying these changes, the package builds. There is one more bugfix:
the man/pt_BR/Makefile.in defines a variable ptman8dir, but installs the
Makefiles to svman8dir - THIS SEEMS LIKE A GENUINE BUG. On my system, this
also causes 'make' to fail.
A patch file is included below.
Many regards,
Henning
-----------------------------------------------
--- dpkg-1.10.6/dpkg-deb/Makefile.in.orig Sat Sep 21 19:40:49 2002
+++ dpkg-1.10.6/dpkg-deb/Makefile.in Sat Sep 21 19:40:55 2002
@@ -1,13 +1,13 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
top_builddir = ..
default: all
include ../Makefile.conf
+top_srcdir = @top_srcdir@
SOURCES = build.c extract.c info.c main.c
--- dpkg-1.10.6/dselect/Makefile.in.orig Sat Sep 21 19:47:10 2002
+++ dpkg-1.10.6/dselect/Makefile.in Sat Sep 21 19:47:15 2002
@@ -1,10 +1,10 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
top_builddir = ..
default: all
include ../Makefile.conf
+top_srcdir = @top_srcdir@
CXX_SOURCES = basecmds.cc baselist.cc basetop.cc bindings.cc curkeys.cc \
main.cc methkeys.cc methlist.cc method.cc methparse.cc \
--- dpkg-1.10.6/main/Makefile.in.orig Sat Sep 21 19:38:03 2002
+++ dpkg-1.10.6/main/Makefile.in Sat Sep 21 19:37:12 2002
@@ -1,10 +1,10 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
top_builddir = ..
default: all
include ../Makefile.conf
+top_srcdir = @top_srcdir@
SOURCES = main.c enquiry.c filesdb.c archives.c processarc.c \
cleanup.c select.c packages.c configure.c remove.c \
--- dpkg-1.10.6/man/de/Makefile.in.orig Sat Sep 21 19:48:04 2002
+++ dpkg-1.10.6/man/de/Makefile.in Sat Sep 21 19:48:08 2002
@@ -1,9 +1,9 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
default: all
include ../../Makefile.conf
+top_srcdir = @top_srcdir@
deman1dir = $(subst $(mandir),$(mandir)/de,$(man1dir))
deman5dir = $(subst $(mandir),$(mandir)/de,$(man5dir))
--- dpkg-1.10.6/man/en/Makefile.in.orig Sat Sep 21 19:48:17 2002
+++ dpkg-1.10.6/man/en/Makefile.in Sat Sep 21 19:48:19 2002
@@ -1,9 +1,9 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
default: all
include ../../Makefile.conf
+top_srcdir = @top_srcdir@
MAN5PAGES = deb-control.5 deb-old.5 deb.5 dpkg.cfg.5 dselect.cfg.5
--- dpkg-1.10.6/man/fr/Makefile.in.orig Sat Sep 21 19:48:21 2002
+++ dpkg-1.10.6/man/fr/Makefile.in Sat Sep 21 19:48:24 2002
@@ -1,9 +1,9 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
default: all
include ../../Makefile.conf
+top_srcdir = @top_srcdir@
frman1dir = $(subst $(mandir),$(mandir)/fr,$(man1dir))
frman5dir = $(subst $(mandir),$(mandir)/fr,$(man5dir))
--- dpkg-1.10.6/man/ja/Makefile.in.orig Sat Sep 21 19:48:28 2002
+++ dpkg-1.10.6/man/ja/Makefile.in Sat Sep 21 19:48:31 2002
@@ -1,9 +1,9 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
default: all
include ../../Makefile.conf
+top_srcdir = @top_srcdir@
jaman1dir = $(subst $(mandir),$(mandir)/ja,$(man1dir))
jaman5dir = $(subst $(mandir),$(mandir)/ja,$(man5dir))
--- dpkg-1.10.6/man/pt_BR/Makefile.in.orig Sat Sep 21 19:48:35 2002
+++ dpkg-1.10.6/man/pt_BR/Makefile.in Sat Sep 21 19:55:38 2002
@@ -1,9 +1,9 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
default: all
include ../../Makefile.conf
+top_srcdir = @top_srcdir@
ptman8dir = $(subst $(mandir),$(mandir)/pt_BR,$(man8dir))
@@ -19,10 +19,10 @@
install: install-doc
install-doc:
- $(mkinstalldirs) $(DESTDIR)$(svman8dir)
+ $(mkinstalldirs) $(DESTDIR)$(ptman8dir)
set -e ; for i in $(MAN8PAGES) ; do \
if test -f $$i ; then d= ; else d="$(srcdir)/" ; fi ; \
- $(INSTALL_DATA) $$d$$i $(DESTDIR)$(svman8dir) ; \
+ $(INSTALL_DATA) $$d$$i $(DESTDIR)$(ptman8dir) ; \
done
.PHONY: all clean distclean install install-doc
--- dpkg-1.10.6/man/ru/Makefile.in.orig Sat Sep 21 19:48:41 2002
+++ dpkg-1.10.6/man/ru/Makefile.in Sat Sep 21 19:48:43 2002
@@ -1,9 +1,9 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
default: all
include ../../Makefile.conf
+top_srcdir = @top_srcdir@
ruman1dir = $(subst $(mandir),$(mandir)/ru,$(man1dir))
ruman5dir = $(subst $(mandir),$(mandir)/ru,$(man5dir))
--- dpkg-1.10.6/man/sv/Makefile.in.orig Sat Sep 21 19:48:47 2002
+++ dpkg-1.10.6/man/sv/Makefile.in Sat Sep 21 19:48:50 2002
@@ -1,9 +1,9 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
default: all
include ../../Makefile.conf
+top_srcdir = @top_srcdir@
svman1dir = $(subst $(mandir),$(mandir)/sv,$(man1dir))
svman5dir = $(subst $(mandir),$(mandir)/sv,$(man5dir))
--- dpkg-1.10.6/man/Makefile.in.orig Sat Sep 21 19:56:36 2002
+++ dpkg-1.10.6/man/Makefile.in Sat Sep 21 19:56:41 2002
@@ -1,11 +1,11 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
SUBDIRS = de en fr ja pt_BR ru sv
default: all
include ../Makefile.conf
+top_srcdir = @top_srcdir@
clean: clean-recursive
--- dpkg-1.10.6/methods/Makefile.in.orig Sat Sep 21 19:47:33 2002
+++ dpkg-1.10.6/methods/Makefile.in Sat Sep 21 19:47:36 2002
@@ -1,9 +1,9 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
default: all
include ../Makefile.conf
+top_srcdir = @top_srcdir@
# Available methods
METHODS = disk floppy
--- dpkg-1.10.6/scripts/Makefile.in.orig Sat Sep 21 19:39:16 2002
+++ dpkg-1.10.6/scripts/Makefile.in Sat Sep 21 19:39:22 2002
@@ -1,9 +1,9 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
default: all
include ../Makefile.conf
+top_srcdir = @top_srcdir@
BIN_SCRIPTS = dpkg-name dpkg-source dpkg-genchanges \
dpkg-gencontrol dpkg-shlibdeps dpkg-buildpackage \
--- dpkg-1.10.6/split/Makefile.in.orig Sat Sep 21 19:43:41 2002
+++ dpkg-1.10.6/split/Makefile.in Sat Sep 21 19:43:45 2002
@@ -1,10 +1,10 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
default: all
include ../Makefile.conf
+top_srcdir = @top_srcdir@
SPLIT_SOURCES = queue.c split.c info.c join.c main.c
SPLIT_OBJECTS = $(patsubst %.c, %.o, $(SPLIT_SOURCES))
--- dpkg-1.10.6/utils/Makefile.in.orig Sat Sep 21 19:46:44 2002
+++ dpkg-1.10.6/utils/Makefile.in Sat Sep 21 19:46:47 2002
@@ -1,10 +1,10 @@
VPATH = @srcdir@
srcdir = @srcdir@
-top_srcdir = @top_srcdir@
default: all
include ../Makefile.conf
+top_srcdir = @top_srcdir@
CFLAGS += -I$(top_srcdir)/optlib
Reply to: