- my %probe =
- (
- name => "FT1",
- inccheck => sub { -e File::Spec->catfile($_[0], "ftnameid.h") },
- libbase => "ttf",
- testcode => _ft1_test_code(),
- testcodeheaders => [ "freetype.h", "stdio.h" ],
- incpaths => \@incpaths,
- libpaths => \@libpaths,
- alternatives =>
- [
- {
- incsuffix => "freetype",
- }
- ],
- verbose => $VERBOSE,
- );
- my $probe_res = Imager::Probe->probe(\%probe);
- $IMAGER_LIBS{FT1} = defined $probe_res;
- if ($probe_res) {
- $formats{FT1}{enabled} = 1;
- @{$formats{FT1}}{qw/DEFINE INC LIBS/} =
- @$probe_res{qw/DEFINE INC LIBS/};
+ if (grep $_ eq "FT1", @enabled_bundled) {
+ my %probe =
+ (
+ name => "FT1",
+ inccheck => sub { -e File::Spec->catfile($_[0], "ftnameid.h") },
+ libbase => "ttf",
+ testcode => _ft1_test_code(),
+ testcodeheaders => [ "freetype.h", "stdio.h" ],
+ incpaths => \@incpaths,
+ libpaths => \@libpaths,
+ alternatives =>
+ [
+ {
+ incsuffix => "freetype",
+ }
+ ],
+ verbose => $VERBOSE,
+ );
+ my $probe_res = Imager::Probe->probe(\%probe);
+ $IMAGER_LIBS{FT1} = defined $probe_res;
+ if ($probe_res) {
+ $formats{FT1}{enabled} = 1;
+ @{$formats{FT1}}{qw/DEFINE INC LIBS/} =
+ @$probe_res{qw/DEFINE INC LIBS/};
+ }