You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Udo Rader <ud...@vibe.ac> on 2003/08/22 13:50:44 UTC

temporary installation directory for mp1's make install

hi all,

for one of our webprojects I have to setup the typical
apache1-mod_perl-mod_ssl httpd, which is not too difficult. Our sysadmin
rules however require me to set this up as _one_ nice RPM package, which
should not be too difficult either, but of course there has to be some
problem.

The entire apache1, mod_perl etc. stuff has to be generally prefixed by
/usr/somedir.

Prefixing is no problem, but I run into troubles when requiring to
_temporarily_ install mod_perl to the RPM_BUILD_ROOT for later packaging
(%install section inside the SPEC-file):

I tried to do

% PREFIX=$RPM_BUILD_ROOT/usr/somedir make install

and 

% make PREFIX=$RPM_BUILD_ROOT/usr/somedir install

... but it completely ignores the (temporary) PREFIX for the
installation.

So are there any (make) switches to temporarily override the installation
directory for mod_perl 1.2.x??

Thanks

Udo Rader


-- 
Reporting bugs: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html


Re: temporary installation directory for mp1's make install

Posted by Udo Rader <sp...@vibe.ac>.
Am Fri, 22 Aug 2003 17:34:40 +0000 schrieb Stas Bekman:

> Udo Rader wrote:
>> hi all,
>> 
>> for one of our webprojects I have to setup the typical
>> apache1-mod_perl-mod_ssl httpd, which is not too difficult. Our sysadmin
>> rules however require me to set this up as _one_ nice RPM package, which
>> should not be too difficult either, but of course there has to be some
>> problem.
>> 
>> The entire apache1, mod_perl etc. stuff has to be generally prefixed by
>> /usr/somedir.
>> 
>> Prefixing is no problem, but I run into troubles when requiring to
>> _temporarily_ install mod_perl to the RPM_BUILD_ROOT for later packaging
>> (%install section inside the SPEC-file):
>> 
> 
> why not downloading one of the existing src.rpms and look how they have done 
> it? e.g search for mod_perl at http://rpm.pbone.net/ or http://rpmfind.net/

I already tried this, checked out David Harris' SRPMS on
http://perl.apache.org/rpm/distrib/, but I don't do it other than him.

But anyway, I now tracked the problem down and found the bad boy
in this game:

For various reasons we have built our own perl 5.8.0. On the system side
however, we keep up with the most current version of perl which currently
is 5.8.1-RC4. Now the problem is not our own perl but the
ExtUtils::MakeMaker version that ships with the stock (and our) perl
5.8.0.

For our (and any other "stock") perl 5.8.0 the steps below don't deliver
expected results:

% tar xzf mod_perl-1.28.tar.gz
% tar xzf apache-1.3.28.tar.gz
% cd mod_perl-1.28
% /usr/bestsolution/bin/perl Makefile.PL \
    APACHE_SRC=../apache_1.3.28/src \
    PREFIX=/usr/somewhere \
    APACHE_PREFIX=/usr/somewhere \
    DO_HTTPD=1 \
    PREP_HTTPD=1 \
    USE_APACI=1 \
    EVERYTHING=1
% make
% make pure_install PREFIX=/var/tmp/usr/somewhere

After that the files are installed in /usr/somewhere/... instead of
/var/tmp/usr/somewhere, which is completely wrong.

Doing the same with perl 5.8.1-RC4 gives the expected results, all the
files are getting correctly installed in /var/tmp/usr/somewhere.

I then compared the Makefile produced by "our" version of perl and the one
produced by 5.8.1-RC4 and there were (of course) big differences. One of
the most apparent differences is the used ExtUtils::MakeMaker version.
Stock perl 5.8.0 ships with ExtUtils::MakeMaker 6.03 rev. 1.63 while 5.8.1
comes with ExtUtils::MakeMaker 6.13 rev. 1.127. And after upgrading to the
most recent version (6.16) everything is working as it should.

So it probably would be a good idea to introduce a dependency for at least
MakeMaker 6.13 into mod_perl's Makefile.PL, maybe like this trivial patch:

-------CUT--------
--- mod_perl-1.28/Makefile.PL 2003-08-23 00:14:41.000000000 +0200 
+++ mod_perl_1.28/Makefile.PL.good    2003-08-23 00:14:34.000000000 +0200
@@ -12,11 +12,11 @@
     } 
 } 

 sub MMN_130 () { 19980527 }
 
-use ExtUtils::MakeMaker;
+use ExtUtils::MakeMaker 6.13;
 use Config ();
 use FileHandle ();
 use DirHandle ();
 use File::Compare ();
 use File::Basename qw(dirname basename);
-------CUT--------

happy hacking

udo


-- 
Reporting bugs: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html


Re: temporary installation directory for mp1's make install

Posted by Stas Bekman <st...@stason.org>.
Udo Rader wrote:
> hi all,
> 
> for one of our webprojects I have to setup the typical
> apache1-mod_perl-mod_ssl httpd, which is not too difficult. Our sysadmin
> rules however require me to set this up as _one_ nice RPM package, which
> should not be too difficult either, but of course there has to be some
> problem.
> 
> The entire apache1, mod_perl etc. stuff has to be generally prefixed by
> /usr/somedir.
> 
> Prefixing is no problem, but I run into troubles when requiring to
> _temporarily_ install mod_perl to the RPM_BUILD_ROOT for later packaging
> (%install section inside the SPEC-file):
> 

why not downloading one of the existing src.rpms and look how they have done 
it? e.g search for mod_perl at http://rpm.pbone.net/ or http://rpmfind.net/

__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com



-- 
Reporting bugs: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html


Re: temporary installation directory for mp1's make install

Posted by Udo Rader <ud...@vibe.ac>.
I digged a bit further into the issue and found that there is a
"pure_install" target in the Makefile for mod_perl-1.28 that probably
fits better than the plain install target.

However this still installs file in outside the temporary build root, so
even a

% make pure_install PREFIX=/var/tmp/mod_perl-1.28/usr/something

still installs for example:

-----CUT------
Installing
/usr/something/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi/auto/Apache/include/ap_config_auto.h
Files found in blib/arch: installing files in blib/lib into architecture
dependent library tree Installing
/usr/something/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi/Apache/MyConfig.pm
Writing
/usr/something/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi/auto/mod_perl/.packlist
-----CUT------

Correct would be to install it into the PREFIX defined above. So is that
the expected behaviour or is this a bug (in Makefile.PL)?

udo

Am Fri, 22 Aug 2003 11:50:44 +0000 schrieb Udo Rader:

> hi all,
> 
> for one of our webprojects I have to setup the typical
> apache1-mod_perl-mod_ssl httpd, which is not too difficult. Our sysadmin
> rules however require me to set this up as _one_ nice RPM package, which
> should not be too difficult either, but of course there has to be some
> problem.
> 
> The entire apache1, mod_perl etc. stuff has to be generally prefixed by
> /usr/somedir.
> 
> Prefixing is no problem, but I run into troubles when requiring to
> _temporarily_ install mod_perl to the RPM_BUILD_ROOT for later packaging
> (%install section inside the SPEC-file):
> 
> I tried to do
> 
> % PREFIX=$RPM_BUILD_ROOT/usr/somedir make install
> 
> and
> 
> % make PREFIX=$RPM_BUILD_ROOT/usr/somedir install
> 
> ... but it completely ignores the (temporary) PREFIX for the
> installation.
> 
> So are there any (make) switches to temporarily override the
> installation directory for mod_perl 1.2.x??
> 
> Thanks
> 
> Udo Rader


-- 
Reporting bugs: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html