Step 1: Group the factors cleverly.
Pair them so a common quadratic appears: \[ (x-1)(x+6)=x^2+5x-6,\qquad(x+1)(x+4)=x^2+5x+4 \] Both share $x^2+5x$.
Step 2: Substitute.
Let $t=x^2+5x$, so $dt=(2x+5)\,dx$, which is exactly the numerator. The integral becomes \[ I=\int\frac{dt}{(t-6)(t+4)} \]
Step 3: Use partial fractions.
The two factors differ by 10, so \[ I=\frac{1}{10}\int\left(\frac{1}{t-6}-\frac{1}{t+4}\right)dt=\frac{1}{10}\log\left|\frac{t-6}{t+4}\right|+c \]
Step 4: Put $t$ back.
\[ I=\frac{1}{10}\log\left|\frac{x^2+5x-6}{x^2+5x+4}\right|+c \] So $f(x)=x^2+5x-6$ and $g(x)=x^2+5x+4$. A check: $\frac{f(-2)}{g(-2)}=\frac{-12}{-2}=6$, matching the given condition.
Step 5: Evaluate at $x=10$.
\[ f(10)=(10-1)(10+6)=9\times16=144,\quad g(10)=(10+1)(10+4)=11\times14=154 \]
Step 6: Simplify the ratio.
\[ \frac{f(10)}{g(10)}=\frac{144}{154}=\frac{72}{77} \] \[ \boxed{\tfrac{72}{77}} \]