You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Luc Pardon <lu...@skopos.be> on 2005/10/11 10:19:39 UTC

[pre-release] rpm spec file (was: Re: [pre-release] 2.0.55 *candidate* available for testing)

"William A. Rowe, Jr." wrote:
> 
> <snip>
> This was a snafu in the way the rpm change was presented, not in the
> tarballs.  httpd-2.0's distribution tarball will always contain apr 0.9.
> 
> That doesn't mean httpd-2.2 (with apr 1.x) will do the same; that's yet
> to be determined.

    In that case the 2.0 httpd.spec files should either a) not require
pre-installed apr packages and build apr as part of the httpd rpm, or b)
build the bundled apr stuff into separate rpm packages itself.

    Solution a) would be best if httpd 2.0.55 absolutely requires apr
0.9.7 and nothing else, i.e. does not work with apr 1.2.1 or not even
with 0.9.8 if/when that comes out. 

    Otherwise, solution b) would be the way to go.

    Again, I realize that all this has been discussed at length on this
list. Normally I would look at the archives but the countdown has
started and my time is limited, so it's quicker to ask. For me, that is
...


> 
> Coming back to rpm's for the moment; I do *not* mean to suggest that
> this is the best solution for any specific platform or distribution
> method, be it .rpm, .depot, .pkg, .msi, or any other facility.

    Wise, very. Any suggestion in that area is likely to spark a flame
war <g>.

> 
>  <snip>
> 
> I'm concerned that the current .spec solution is wrong; it's very
> platform specific (platform meaning deployment mechanics, in this
> case, I'm not slamming non-unix rpm implementations).  Perhaps we
> rejigger the tree to
> 
>    httpd/
>      package/
>        roll-release/
>        win32-msi/
>        rpm/
>        pkg/
> 
> Thoughts?
> 

    Not really. The current build/rpm seems fine to me, but I wouldn't
mind if it changed either. 

    I'm only really familiar with rpm-ing on RedHat platforms, but AFAIK
the rpm specs differ in details, so you'd probably have to populate the
rpm subdir with working spec files for various platforms (collected
after the fact <g>). Or add platform-specific subdirs under rpm/.

> In the interim; is this a showstopper?  Do we generally do the right
> thing (e.g. without changes, can we package up using the existing
> rpm files?)  Obviously 2.0.54 was mispackaged as well, it's minimum
> apr package dependency should have been 0.9.6 apr, not 0.9.5.
> 
> Bill

    Showstopper probably not, as long as you document that the spec file
is broken, for example:

  "The httpd.spec file, as included in the tarball, requires apr and
apr-util and the corresponding devel packages to be installed as
separate rpm's. Although the APR source code is present in the httpd
tarball, there are currently no APR spec files. You can't build the APR
rpm's from the httpd.spec file either. In other words, if you want to
build httpd from the included spec file, you'll first have to go and
find the APR rpm's in the usual places and install them."

   Most people building rpm's themselves (as opposed to installing
pre-built binary rpm's) would IMO be able to cope with that. In fact,
I'd expect them to have pre-existing spec files anyway.

   Therefore, another solution would be to lift httpd.spec out of the
2.0.55 tarball altogether (but that's frozen, right?). 

   If you leave it in, changing the dependencies to properly require
0.9.7 (or newer?) is a trivial change to build/rpm/httpd.spec.in. So
trivial in fact that I'm willing to provide a patch <g>.

   Beyond that, any fix I can offer (e.g. to build separate apr
packages) would only be tested on my systems. 

   Luc Pardon

Re: [pre-release] rpm spec file (was: Re: [pre-release] 2.0.55 *candidate* available for testing)

Posted by Graham Leggett <mi...@sharp.fm>.
Luc Pardon said:

>    Yes, but what got me confused is that the httpd tarball comes with
> the APR source (hence the docs don't talk about it as being a
> prerequisite) whereas the current spec file requires you to go elsewhere
> and get something that is already there. It seem to me that this kind of
> defeats the purposo of bundling APR.

The APR bundled with source is historical - the APR library grew out of
the httpd code, and was only recently "promoted" to a library in it's own
right.

The removal of APR from the httpd has been discussed a number of times,
and I think will probably happen eventually once APR is widespread on it's
own.

Most of the major distros already distribute httpd and apr separately as
APR v0.9.x and httpd v2.0.x (Redhat does anyway), so in the RPM world this
isn't too much of a surprise to have them separate.

>     Agreed on both counts. That (no patches) is one of the reasons why
> I'm building my own.
>
>     But I think there are sometimes other differencies than just
> patches, no ? For example, installing into platform-dependent dirs or
> other variations in configure options ? Or init script stuff ?

The spec file has slowly got simpler and simpler, with more and more of
the "special" stuff being removed from the spec file, falling back on the
normal httpd build process.

Ideally the spec file should eventually be trivial, it shouldn't be
necessary to have to move files and directories around in a spec file when
the httpd build process contains an option to choose a directory layout
already.

>     I see. But couldn't you leave them sitting in srclib/apr, where
> rpmbuild -tb won't see them ? Or better, merge them into httpd.spec, so
> that rpmbuild -tb will produce apr packages from the bundled code in one
> go ?

There is a drive to get APR to stand on it's own as much as possible.
Combining the packaging with httpd is going backwards on a process that
should eventually see apr removed from the httpd tree entirely.

>    From a later message of yours, it seems it's too late already <g>.

I just created a patch for this, just battling to test it (stupid working
directories copied from MacOSX to Fedora grumble).

>    As an aside, is there no configure macro somewhere (something like
> APR_VERSION) that would avoid having to hard-code it in httpd.spec.in ?

If there is this would be very useful, will have to investigate.

Regards,
Graham
--


Re: [pre-release] rpm spec file (was: Re: [pre-release] 2.0.55 *candidate* available for testing)

Posted by Luc Pardon <lu...@skopos.be>.

Graham Leggett wrote:
> 
> Luc Pardon said:
> 
> >     In that case the 2.0 httpd.spec files should either a) not require
> > pre-installed apr packages and build apr as part of the httpd rpm,
> 
> A definite -1 on this. If this were so, httpd could not coexist cleanly
> with other packages that depended on APR.

    Definitely. I missed the fact that apr 0.9 and 1.x can coexist.

> 
> > or b)
> > build the bundled apr stuff into separate rpm packages itself.
> 
> APR is already available as an RPM, both for the 0.9 and 1.x trees, and
> 0.9 and 1.x can be installed simultaneously.
> 
> See the binaries/rpm directory in the download section for APR.
> 

   Yes, but what got me confused is that the httpd tarball comes with
the APR source (hence the docs don't talk about it as being a
prerequisite) whereas the current spec file requires you to go elsewhere
and get something that is already there. It seem to me that this kind of
defeats the purposo of bundling APR.

> >     I'm only really familiar with rpm-ing on RedHat platforms, but AFAIK
> > the rpm specs differ in details, so you'd probably have to populate the
> > rpm subdir with working spec files for various platforms (collected
> > after the fact <g>). Or add platform-specific subdirs under rpm/.
> 
> Different spec files for different platforms should be avoided as much as
> possible. Each distro will release an httpd version + their custom patches
> for the purposes of that distro anyway, Apache isn't a distro, so can
> release a clean httpd as is without any patches.

    Agreed on both counts. That (no patches) is one of the reasons why
I'm building my own.

    But I think there are sometimes other differencies than just
patches, no ? For example, installing into platform-dependent dirs or
other variations in configure options ? Or init script stuff ?

    Note that I'm not arguing, just wondering. Of course, having
multiple spec files (for different platforms) will break rpmbuild -tb
big time.

> 
> >   "The httpd.spec file, as included in the tarball, requires apr and
> > apr-util and the corresponding devel packages to be installed as
> > separate rpm's. Although the APR source code is present in the httpd
> > tarball, there are currently no APR spec files. You can't build the APR
> > rpm's from the httpd.spec file either. In other words, if you want to
> > build httpd from the included spec file, you'll first have to go and
> > find the APR rpm's in the usual places and install them."
> 
> There are APR spec files in the APR and APR-util archives.
> 
> They are removed from the apr tree in the httpd build, as rpm gets
> confused is there is more than one spec file in a tarball (in other words,
> rpmbuild -tb is not possible otherwise).
> 

    I see. But couldn't you leave them sitting in srclib/apr, where
rpmbuild -tb won't see them ? Or better, merge them into httpd.spec, so
that rpmbuild -tb will produce apr packages from the bundled code in one
go ? 

   Would there be any objections against the latter ?

   After all, httpd.spec already produces the httpd, httpd-devel,
httpd-manual and mod_ssl rpm's. Why not apr, apr-util, apr-devel and
apr-util-devel as well ? Nobody obliges you to install the whole set. 

    
> >    If you leave it in, changing the dependencies to properly require
> > 0.9.7 (or newer?) is a trivial change to build/rpm/httpd.spec.in. So
> > trivial in fact that I'm willing to provide a patch <g>.
> 
> Please do :)
> 

   From a later message of yours, it seems it's too late already <g>.

   As an aside, is there no configure macro somewhere (something like
APR_VERSION) that would avoid having to hard-code it in httpd.spec.in ?

   Luc

Re: [pre-release] rpm spec file (was: Re: [pre-release] 2.0.55 *candidate* available for testing)

Posted by Graham Leggett <mi...@sharp.fm>.
Luc Pardon said:

>     In that case the 2.0 httpd.spec files should either a) not require
> pre-installed apr packages and build apr as part of the httpd rpm,

A definite -1 on this. If this were so, httpd could not coexist cleanly
with other packages that depended on APR.

> or b)
> build the bundled apr stuff into separate rpm packages itself.

APR is already available as an RPM, both for the 0.9 and 1.x trees, and
0.9 and 1.x can be installed simultaneously.

See the binaries/rpm directory in the download section for APR.

>     I'm only really familiar with rpm-ing on RedHat platforms, but AFAIK
> the rpm specs differ in details, so you'd probably have to populate the
> rpm subdir with working spec files for various platforms (collected
> after the fact <g>). Or add platform-specific subdirs under rpm/.

Different spec files for different platforms should be avoided as much as
possible. Each distro will release an httpd version + their custom patches
for the purposes of that distro anyway, Apache isn't a distro, so can
release a clean httpd as is without any patches.

>   "The httpd.spec file, as included in the tarball, requires apr and
> apr-util and the corresponding devel packages to be installed as
> separate rpm's. Although the APR source code is present in the httpd
> tarball, there are currently no APR spec files. You can't build the APR
> rpm's from the httpd.spec file either. In other words, if you want to
> build httpd from the included spec file, you'll first have to go and
> find the APR rpm's in the usual places and install them."

There are APR spec files in the APR and APR-util archives.

They are removed from the apr tree in the httpd build, as rpm gets
confused is there is more than one spec file in a tarball (in other words,
rpmbuild -tb is not possible otherwise).

>    Most people building rpm's themselves (as opposed to installing
> pre-built binary rpm's) would IMO be able to cope with that. In fact,
> I'd expect them to have pre-existing spec files anyway.
>
>    Therefore, another solution would be to lift httpd.spec out of the
> 2.0.55 tarball altogether (but that's frozen, right?).
>
>    If you leave it in, changing the dependencies to properly require
> 0.9.7 (or newer?) is a trivial change to build/rpm/httpd.spec.in. So
> trivial in fact that I'm willing to provide a patch <g>.

Please do :)

There is one fix I need to make to the httpd.in file as released
concerning the xml doc files. The spec file tries to remove the xml files,
however the build was changed to remove them.

Regards,
Graham
--