sub android_ndk {
unless (%$android_ndk) {
+ if ($now_printing =~ m|^android|) {
+ return $android_ndk = { bn_ops => "BN_AUTO" };
+ }
+
my $ndk = $ENV{ANDROID_NDK};
die "\$ANDROID_NDK is not defined" if (!$ndk);
die "\$ANDROID_NDK=$ndk is invalid" if (!-d "$ndk/platforms");
our %table = ();
our %config = ();
our %withargs = ();
+our $now_printing; # set to current entry's name in print_table_entry
+ # (todo: right thing would be to encapsulate name
+ # into %target [class] and make print_table_entry
+ # a method)
# Forward declarations ###############################################
sub print_table_entry
{
- my $target = shift;
- my %target = resolve_config($target);
+ local $now_printing = shift;
+ my %target = resolve_config($now_printing);
my $type = shift;
# Don't print the templates
if ($type eq "TABLE") {
print "\n";
- print "*** $target\n";
+ print "*** $now_printing\n";
foreach (@sequence) {
if (ref($target{$_}) eq "ARRAY") {
printf "\$%-12s = %s\n", $_, join(" ", @{$target{$_}});
} elsif ($type eq "HASH") {
my $largest =
length((sort { length($a) <=> length($b) } @sequence)[-1]);
- print " '$target' => {\n";
+ print " '$now_printing' => {\n";
foreach (@sequence) {
if ($target{$_}) {
if (ref($target{$_}) eq "ARRAY") {