SOURCES: pldcpan.pl - use Module::Build by default (when available)

migo migo at pld-linux.org
Fri Nov 11 20:51:39 CET 2005


Author: migo                         Date: Fri Nov 11 19:51:39 2005 GMT
Module: SOURCES                       Tag: HEAD
---- Log message:
- use Module::Build by default (when available)

---- Files affected:
SOURCES:
   pldcpan.pl (1.25 -> 1.26) 

---- Diffs:

================================================================
Index: SOURCES/pldcpan.pl
diff -u SOURCES/pldcpan.pl:1.25 SOURCES/pldcpan.pl:1.26
--- SOURCES/pldcpan.pl:1.25	Fri Nov 11 20:47:49 2005
+++ SOURCES/pldcpan.pl	Fri Nov 11 20:51:34 2005
@@ -27,8 +27,8 @@
 
 options:
 	-v|--verbose      shout, and shout loud
-	-B|--modulebuild  prefer Module::Build
-	-M|--makemaker    prefer ExtUtils::MakeMaker (default)
+	-B|--modulebuild  prefer Module::Build (default)
+	-M|--makemaker    prefer ExtUtils::MakeMaker
 
 This program uncompresses given archives in the current directory
 and -- more or less successfully -- attempts to write corresponding
@@ -604,14 +604,7 @@
 %setup -q -n [% dir_unexp %][% IF is_impolite %]-c[% END %]
 
 %build
-[% IF uses_makemaker -%]
-%{__perl} Makefile.PL \
-	INSTALLDIRS=vendor
-%{__make}[% IF test_is_xs -%] \
-	OPTIMIZE="%{rpmcflags}"[% END %]
-
-%{?with_tests:%{__make} test}
-[% ELSIF uses_module_build -%]
+[% IF uses_module_build -%]
 %{__perl} Build.PL \
 [% IF test_is_xs %]	config="optimize='%{rpmcflags}'" \[% END -%]
 	destdir=$RPM_BUILD_ROOT \
@@ -619,6 +612,13 @@
 ./Build
 
 %{?with_tests:./Build test}
+[% ELSIF uses_makemaker -%]
+%{__perl} Makefile.PL \
+	INSTALLDIRS=vendor
+%{__make}[% IF test_is_xs -%] \
+	OPTIMIZE="%{rpmcflags}"[% END %]
+
+%{?with_tests:%{__make} test}
 [% ELSE -%]
 %{__perl} -MExtUtils::MakeMaker -wle 'WriteMakefile(NAME=>"[% parts_joined %]")' \
 	INSTALLDIRS=vendor
@@ -631,11 +631,11 @@
 %install
 rm -rf $RPM_BUILD_ROOT
 
-[% IF uses_makemaker || !uses_module_build -%]
+[% IF uses_module_build || !uses_makemaker -%]
+./Build install
+[% ELSE -%]
 %{__make} install \
 	DESTDIR=$RPM_BUILD_ROOT
-[% ELSE -%]
-./Build install
 [% END -%]
 [% IF test_has_examples -%]
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SOURCES/pldcpan.pl?r1=1.25&r2=1.26&f=u




More information about the pld-cvs-commit mailing list