#!/usr/bin/perl print < EOT for $manual () { if($manual eq 'manual.txt') { $name = "HelpText"; # Some languages don't have translated manuals yet, so use English $ifdef = "#if defined(LDLANG_EN) || defined(LDLANG_ES) || defined(LDLANG_IT) || " . "defined(LDLANG_PT)"; } elsif($manual =~ /manual-(.)(.)\.txt/) { $p = uc($1) . lc($2); $ifdef = "#ifdef LDLANG_" . uc($1 . $2); $name = "HelpText$p"; } else { die; } print <) { chomp; s/\\/\\\\/g; s/"/\\"/g; print qq{ "$_",\n}; } close IN; print <