httpd-apreq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Randy Kobes <ra...@theoryx5.uwinnipeg.ca>
Subject Re: die on version_check?
Date Sun, 01 May 2005 21:20:00 GMT
On Sun, 1 May 2005, Joe Schaefer wrote:

> Randy Kobes <randy@theoryx5.uwinnipeg.ca> writes:
>
> > Should we perhaps die for unsatisfied non-perl requirements
> > and warn for those of perl modules?
>
> Sounds ok to me; do we just need to adjust the
> test_prereq stuff in Makefile.PL, or do you think
> more significant changes are necessary?

I think for Makefile.PL just a

========================================================
Index: Makefile.PL
===================================================================
--- Makefile.PL	(revision 165542)
+++ Makefile.PL	(working copy)
@@ -10,7 +10,7 @@

 sub test_prereq {
     system (PERL_PATH, "build/version_check.pl", @_) == 0
-        or die "Please upgrade $_[0] first.\n";
+        or warn "Please upgrade $_[0] first.\n";
 }

 test_prereq perl => PERL_PATH;

===============================================================

is sufficient, but ./configure also tests the prerequisites,
and uses AC_MSG_ERROR() if they're not satisfied. I'm not
too familiar with this end of things, but would changing
the AC_MSG_ERROR() in acinclude.m4 to AC_MSG_WARN() when
testing the perl module prerequisites be OK? It worked for
me in a simple test of a prerequisite not being there.

==============================================================
Index: acinclude.m4
===================================================================
--- acinclude.m4	(revision 164524)
+++ acinclude.m4	(working copy)
@@ -112,25 +112,25 @@

             AC_MSG_CHECKING(for ExtUtils::XSBuilder)
             if test -z "`$prereq_check ExtUtils::XSBuilder`"; then
-                AC_MSG_ERROR([Bad ExtUtils::XSBuilder version])
+                AC_MSG_WARN([Bad ExtUtils::XSBuilder version])
             fi
             AC_MSG_RESULT(yes)

             AC_MSG_CHECKING(for mod_perl)
             if test -z "`$prereq_check mod_perl`"; then
-                AC_MSG_ERROR([Bad mod_perl version])
+                AC_MSG_WARN([Bad mod_perl version])
             fi
             AC_MSG_RESULT(yes)

             AC_MSG_CHECKING(for Apache::Test)
             if test -z "`$prereq_check Apache::Test`"; then
-                AC_MSG_ERROR([Bad Apache::Test version])
+                AC_MSG_WARN([Bad Apache::Test version])
             fi
             AC_MSG_RESULT(yes)

             AC_MSG_CHECKING(for ExtUtils::MakeMaker)
             if test -z "`$prereq_check ExtUtils::MakeMaker`"; then
-                AC_MSG_ERROR([Bad ExtUtils::MakeMaker version])
+                AC_MSG_WARN([Bad ExtUtils::MakeMaker version])
             fi
             AC_MSG_RESULT(yes)

====================================================================

-- 
best regards,
randy

Mime
View raw message