Catalyzes the addition of isopentenyl diphosphate (IPP) onto dimethylallyl diphosphate (DMAPP) to form geranyl pyrophosphate (GPP) (PubMed:21237161, PubMed:30301210). Is probably involved in the biosynthesis of decaprenyl diphosphate, which is required for mycobacterial cell wall synthesis (PubMed:21237161). Could be required for host endothelial-cell invasion and/or intracellular survival (PubMed:16586367). dimethylallyl diphosphate + isopentenyl diphosphate = (2E)-geranyl diphosphate + diphosphate Binds 2 Mg(2+) ions per subunit. Isoprenoid biosynthesis; geranyl diphosphate biosynthesis; geranyl diphosphate from dimethylallyl diphosphate and isopentenyl diphosphate: step 1/1. Highly up-regulated during the early stages of invasion of the human blood-brain barrier. Contains two aspartate-rich motifs, designated as FARM (the first aspartate-rich motif) and SARM (the second aspartate-rich motif). Rv0989c contains arginine in place of the second Asp in its FARM and first Asp in its SARM. The primary role of the FARM and SARM is the chelation of the divalent magnesium ion cofactors that assist substrate binding and catalysis, but it may also play a role in determining product chain length. Invasion of the infant human brain microvascular endothelial-cell monolayer is significantly decreased in transposon mutant. Belongs to the FPP/GGPP synthase family.