$normal_pileup = "samtools mpileup -q 1 -f XXXX YYYYY";
will not execute any command but will just store samtools mpileup -q 1 -f XXXX YYYYY as a string. The same for $tumor_pileup.
If you want to execute the command use
$normal_pileup = `samtools mpileup -q 1 -f XXXX YYYYY`;
bash is not a Perl command.
`java -jar ttt.jar ...`
You "java" is also most likely wrong
with < you specify where STDIN is read. Is supposed to be a file but in your case you are specifying the output of a previous command. This will only work if the output of samtool is a file name.
if you want your java program to process the output of another command you will need a pipe
mycommand | java
Summarizing I suppose you want
` ( samtools mpileup -q 1 -f XXXX YYYYY; samtools mpileup -q 1 -f XXXX ZZZZZ ) | java -jar ttt.jar output `