Bug 631 - Build fails on Redhat Linux 6.x
Summary: Build fails on Redhat Linux 6.x
Status: CLOSED WORKSFORME
Alias: None
Product: Portable OpenSSH
Classification: Unclassified
Component: Build system (show other bugs)
Version: 3.6.1p2
Hardware: All Linux
: P3 normal
Assignee: OpenSSH Bugzilla mailing list
URL:
Keywords: patch
Depends on:
Blocks: 793
  Show dependency treegraph
 
Reported: 2003-09-01 17:46 AEST by Markus Dobel
Modified: 2004-04-14 12:24 AEST (History)
0 users

See Also:


Attachments
Add build7x variable. (1.05 KB, patch)
2003-09-06 14:35 AEST, Darren Tucker
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Markus Dobel 2003-09-01 17:46:50 AEST
I needed this package for a box running Redhat 6.2. So I changed the 
build6x-define in the specfile from 0 to 1 and tried to build the package. rpm 
complained about

  error: failed build dependencies:
          db1-devel   is needed by openssh-3.6.1p1-1

caused by this part of the specfile:

  %if ! %{build6x}
  BuildPreReq: glibc-devel, pam
  %else
  BuildPreReq: db1-devel, /usr/include/security/pam_appl.h
  %endif

There is no db1 package in Redhat 6.x, db1 was intruduced in 7.x. In Redhat 6.x 
the contents of db1 are part of the glibc package. It seems like that the 
condition is the wrong way around.
Comment 1 Darren Tucker 2003-09-06 14:35:05 AEST
Created attachment 389 [details]
Add build7x variable.

There seems to be some confusion about this.

$ cvs log openssh.spec
revision 1.109
date: 2002/09/04 07:19:06;  author: djm;  state: Exp;  lines: +1 -1
 - (djm) Fix Redhat RPM build dependancy test

and from Redhat bug #55105:
"If build_6x is defined for building openssh on a 6.x box, it won't build
because it claims to need db1-devel.  However db1-devel does not exist for
6.x, as it is included in glibc-devel."

A quick survey shows db1-devel present *only* in 7.x releases, so no amount of
fiddling with build6x is going to get it right for all cases.

How about this patch?  I'm not fluent in specfile so it might be wrong, but it
works on my RH8.0 box.
Comment 2 Darren Tucker 2003-10-07 18:23:08 AEST
Is that specfile patch OK or is there a better way of doing it?
Comment 3 Damien Miller 2003-10-08 12:12:09 AEST
Perhaps we should conditionalise on the version of redhat-release or just relax
the build requirements.

The worst consequence of relaxing the build requirements is the build may fail.
Since OpenSSH doesn't take long to compile, I think this is preferable to
creating another #ifdef hell :) 
Comment 4 Damien Miller 2004-02-10 12:18:50 AEDT
hm, the spec file doesn't even have the db1-devel requirement at the moment.
Since OpenSSH doesn't depend on this directly, I'm happy to leave it to whatever
requires db1-devel to specify its dependance on it.
Comment 5 Damien Miller 2004-04-14 12:24:19 AEST
Mass change of RESOLVED bugs to CLOSED