Use Devel::CheckLib
authorMarius Gavrilescu <marius@ieval.ro>
Mon, 11 Apr 2016 13:15:32 +0000 (16:15 +0300)
committerMarius Gavrilescu <marius@ieval.ro>
Mon, 11 Apr 2016 13:15:32 +0000 (16:15 +0300)
Makefile.PL

index 3abc42e66576104bbe64284ab7265a4210c68047..ef281e86187984b667065abcf8253159d83f2b58 100644 (file)
@@ -1,6 +1,10 @@
 use 5.014000;
 use 5.014000;
+use Devel::CheckLib;
 use ExtUtils::MakeMaker;
 
 use ExtUtils::MakeMaker;
 
+check_lib_or_exit
+  lib => 'openalprpy';
+
 WriteMakefile(
        NAME              => 'Image::OpenALPR',
        VERSION_FROM      => 'lib/Image/OpenALPR.pm',
 WriteMakefile(
        NAME              => 'Image::OpenALPR',
        VERSION_FROM      => 'lib/Image/OpenALPR.pm',
@@ -9,13 +13,17 @@ WriteMakefile(
        MIN_PERL_VERSION  => '5.14.0',
        LICENSE           => 'open_source',
        SIGN              => 1,
        MIN_PERL_VERSION  => '5.14.0',
        LICENSE           => 'open_source',
        SIGN              => 1,
+       CONFIGURE_REQUIRES => {
+               qw/Devel::CheckLib     0
+                  ExtUtils::MakeMaker 0/,
+       },
        PREREQ_PM         => {
                qw/Class::Accessor::Fast 0
                   JSON::MaybeXS 0/,
        },
        LIBS              => ['-lopenalprpy'],
        META_ADD          => {
        PREREQ_PM         => {
                qw/Class::Accessor::Fast 0
                   JSON::MaybeXS 0/,
        },
        LIBS              => ['-lopenalprpy'],
        META_ADD          => {
-               dynamic_config => 0,
+               dynamic_config => 1,
                resources      => {
                        repository   => 'https://git.ieval.ro/?p=image-openalpr.git',
                },
                resources      => {
                        repository   => 'https://git.ieval.ro/?p=image-openalpr.git',
                },
This page took 0.010686 seconds and 4 git commands to generate.