File: dist.ini

package info (click to toggle)
libip-geolocation-mmdb-perl 1.013-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 184 kB
  • sloc: perl: 192; makefile: 3
file content (187 lines) | stat: -rw-r--r-- 5,432 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
name    = IP-Geolocation-MMDB
version = 1.013
author  = Andreas Vögele <voegelas@cpan.org>
license = Perl_5
copyright_holder = Andreas Vögele

[@Filter]
-bundle = @Basic
-remove = GatherDir
-remove = MakeMaker
-remove = Readme

[MetaResources]
homepage        = https://github.com/voegelas/IP-Geolocation-MMDB/wiki
bugtracker.web  = https://github.com/voegelas/IP-Geolocation-MMDB/issues
repository.url  = https://github.com/voegelas/IP-Geolocation-MMDB.git
repository.web  = https://github.com/voegelas/IP-Geolocation-MMDB
repository.type = git

[CPANFile]

[GatherDir]
exclude_filename = cpanfile
exclude_filename = LICENSE
exclude_filename = Makefile.PL
exclude_filename = META.json

[CopyFilesFromBuild]
copy = cpanfile
copy = LICENSE
copy = Makefile.PL
copy = META.json

[MetaProvides::Package]

[MetaJSON]

[PodCoverageTests]

[PodSyntaxTests]

[MakeMaker::Awesome]
min_perl_version = 5.014

delimiter = |

header = use Config;
header = use File::Spec::Functions qw(devnull);
header = use Math::BigInt;

header = my @defines;
header = my $byteorder = $Config{byteorder};
header = if (!defined $byteorder) {
header = | warn "\$Config{byteorder} is undefined";
header = | die "OS unsupported\n";
header = }
header = if ($byteorder == 4321 || $byteorder == 87654321) {
header = | push @defines, '-DWORDS_BIGENDIAN';
header = }
header = elsif (!($byteorder == 1234 || $byteorder == 12345678)) {
header = | warn "Unknown byte order: $byteorder\n";
header = | die "OS unsupported\n";
header = }

header = my $ccflags = '';
header = my $libs = '';
header = my $version;
header = if (eval { require Alien::libmaxminddb }) {
header = | $ccflags = Alien::libmaxminddb->cflags;
header = | $libs = Alien::libmaxminddb->libs;
header = | $version = Alien::libmaxminddb->version;
header = }
header = else {
header = | my $devnull = devnull();
header = | for my $pkgconf (qw(pkgconf pkg-config)) {
header = |  my $output = `$pkgconf --version 2>$devnull`;
header = |  if ($? == 0) {
header = |   $ccflags = `$pkgconf --cflags libmaxminddb 2>$devnull`;
header = |   last if $? != 0;
header = |   $libs = `$pkgconf --libs libmaxminddb 2>$devnull`;
header = |   last if $? != 0;
header = |   $version = `$pkgconf --modversion libmaxminddb 2>$devnull`;
header = |   last if $? != 0;
header = |   chomp($ccflags, $libs, $version);
header = |   last;
header = |  }
header = | }
header = }

header = if ($^O eq 'MSWin32' && $^V < 5.034) {
header = | # Amend the library search path
header = | my $libdir = 'C:\strawberry\c\x86_64-w64-mingw32\lib';
header = | if (-d $libdir) {
header = |  $libs = "-L$libdir $libs";
header = | }
header = }

WriteMakefile_arg = CCFLAGS => join(q{ }, $ccflags, $Config{ccflags})
WriteMakefile_arg = LIBS => [ $libs ]
WriteMakefile_arg = DEFINE => join(q{ }, @defines)

footer = package MY;

footer = # Bail out if something is wrong
footer = sub post_initialize {
footer = | my $text = '';
footer = | if (!defined $version) {
footer = |  $text = <<'TEXT';
footer = |.PHONY: die
footer = |die :
footer = |	$(NOECHO) $(ECHO) "Error: libmaxminddb not found"
footer = |	$(NOECHO) $(ECHO) "OS unsupported"
footer = |	$(FALSE)
footer = |TEXT
footer = | }
footer = | elsif ($version =~ m{^(0|1\.[01])\.}) {
footer = |  $text = <<'TEXT';
footer = |.PHONY: die
footer = |die :
footer = |	$(NOECHO) $(ECHO) "Error: libmaxminddb is too old"
footer = |	$(NOECHO) $(ECHO) "OS unsupported"
footer = |	$(FALSE)
footer = |TEXT
footer = | }
footer = | elsif (!eval { Math::BigInt->from_bytes(pack 'C6', 0xff, 0xff, 0xb0, 0x09, 0x00, 0x00)->as_hex eq '0xffffb0090000' }) {
footer = |  # Some Math::BigInt versions fail on i386 if Perl is built with -Dusequadmath.
footer = |  $text = <<'TEXT';
footer = |.PHONY: die
footer = |die :
footer = |	$(NOECHO) $(ECHO) "Error: Math::BigInt is too old or broken"
footer = |	$(NOECHO) $(ECHO) "OS unsupported"
footer = |	$(FALSE)
footer = |TEXT
footer = | }
footer = | return $text;
footer = }

footer = sub const_loadlibs {
footer = | my $text = shift->SUPER::const_loadlibs(@_);
footer = | if ($^O eq 'MSWin32' && $^V < 5.034) {
footer = |  # Ignore unneeded libraries, which may contain invalid symbols
footer = |  my $filter = sub {
footer = |   my $list = shift;
footer = |   my $pattern = $list =~ m{"} ? qr{(?<=")\h+(?=")} : qr{\h+};
footer = |   join q{ }, grep { m{ maxminddb | ws2_32 }x } split $pattern, $list;
footer = |  };
footer = |  $text =~ s{
footer = |   ^ ( (?: EXTRA | LDLOAD ) LIBS ) \h* = \h* (.*?) \h* $
footer = |  }
footer = |  {sprintf '%s = %s', $1, $filter->($2)}egxm;
footer = | }
footer = | return $text;
footer = }

footer = sub const_config {
footer = | my $text = shift->SUPER::const_config(@_);
footer = | # Some BSDs prepend -L/usr/local/lib, which may contain an old library
footer = | # version, to the library search path
footer = | $text =~ s{
footer = |  ^ ( LD(?:DL)?FLAGS \h* = .*? ) -L/usr/local/lib ( $ | \h+ (.*) $ )
footer = | }
footer = | {$1$2}gxm;
footer = | return $text;
footer = }

[Test::Kwalitee]

[Encoding]
encoding = bytes
match    = ^t/data/

[AutoPrereqs]

[Prereqs / ConfigureRequires]
Alien::libmaxminddb = 0
Math::BigInt = 1.999806

[Prereqs / BuildRequires]
Alien::libmaxminddb = 0
Math::BigInt = 1.999806

[Prereqs / DevelopRequires]
Dist::Zilla = 0
Dist::Zilla::Plugin::CopyFilesFromBuild = 0
Dist::Zilla::Plugin::MakeMaker::Awesome = 0.27
Dist::Zilla::Plugin::MetaProvides::Package = 0
Dist::Zilla::Plugin::Test::Kwalitee = 0