Learning Deductive Reasoning from Synthetic Corpus based on Formal Logic