This paper investigates the expansions of Melnikov functions near a homoclinic loop with a nilpotent cusp of order m. It presents a methodology for calculating all coefficients in these expansions, which can be employed to study the problem of limit cycle bifurcation. As an application, by utilizing the obtained results, the paper rigorously establishes that a polynomial Liénard system of degree n+1 has at least n+[n4] limit cycles near the homoclinic loop with a nilpotent cusp of order one. This work not only updates and generalizes existing results, but also provides a rigorous application of the obtained findings in the context of limit cycle bifurcation.