[perl-gtk2-traymanager] Makefile.PL: added META_MERGE block with 'configure_requires'



commit 8ada7a459e9609a7f25a8cf204b5286fd28fb02c
Author: Brian Manning <bmanning src gnome org>
Date:   Tue Oct 20 17:18:57 2020 -0700

    Makefile.PL: added META_MERGE block with 'configure_requires'
    
    - Added a '%pre_reqs' hash with build prereqs for use in various places

 Makefile.PL | 17 +++++++++--------
 1 file changed, 9 insertions(+), 8 deletions(-)
---
diff --git a/Makefile.PL b/Makefile.PL
index 1ce4fcb..8ac68a3 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -15,6 +15,12 @@ our %build_reqs = (
        'perl-Gtk2'               => '1.00',
 );
 
+our %pre_reqs = (
+   'Glib'                => $build_reqs{'perl-Glib'},
+   'Gtk2'                => $build_reqs{'perl-Gtk2'},
+   'ExtUtils::Depends'   => $build_reqs{'perl-ExtUtils-Depends'},
+   'ExtUtils::PkgConfig' => $build_reqs{'perl-ExtUtils-PkgConfig'},
+);
 # Writing a fake Makefile ensures that CPAN will pick up the correct
 # dependencies and install them.
 unless (eval "use ExtUtils::Depends;"
@@ -29,12 +35,7 @@ unless (eval "use ExtUtils::Depends;"
    warn "$@\n";
    WriteMakefile(
          PREREQ_FATAL => 1,
-         PREREQ_PM    => {
-            Glib::                => $build_reqs{'perl-Glib'},
-            Gtk2::                => $build_reqs{'perl-Gtk2'},
-            ExtUtils::Depends::   => $build_reqs{'perl-ExtUtils-Depends'},
-            ExtUtils::PkgConfig:: => $build_reqs{'perl-ExtUtils-PkgConfig'},
-         },
+         PREREQ_PM    => \%pre_reqs,
    );
    exit 1; # not reached
 }
@@ -82,8 +83,8 @@ WriteMakefile(
     # ABSTRACT_FROM   => 'TrayManager.pm', # retrieve abstract from module
     XSPROTOARG      => '-noprototypes',
     $traymanager->get_makefile_vars,
-    PREREQ_PM       =>  {
-       Gtk2 => $build_reqs{'perl-Gtk2'},
+    META_MERGE    => {
+        configure_requires => \%pre_reqs,
     },
 );
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]