An indirect Gauss pseudospectral method based path-following guidance law is presented in this paper. A virtual target moving along the desired path with explicitly specified speed is introduced to formulate the guidance problem. By establishing a virtual target-fixed coordinate system, the path-following guidance is transformed into a terminal guidance with impact angle constraints, which is then solved by using indirect Gauss pseudospectral method. Meanwhile, the acceleration dynamics are modeled as the first-order lag to the command. Using the receding horizon technique a closed-loop guidance law, which considers generalized weighting functions (even discontinuous) of both the states and the control cost, is derived. The accuracy and effectiveness of the proposed guidance law are validated by numerical comparisons. A STM32 Nucleo board based on the ARM Cortex-M7 processor is used to evaluate the real-time computational performance of the proposed indirect Gauss pseudospectral method. Simulations for various types of desired paths are presented to show that the proposed guidance law has better performance when compared with the existing results for pure pursuit, a nonlinear guidance law, and trajectory shaping path-following guidance and provides more degrees of freedom in path-following guidance design applications.