—The notion of p-cycle (Preconfigured Protection Cycle) allows capacity efficient schemes to be designed for fast span protection in WDM mesh networks. Conventional p-cycle construction algorithms need to enumerate/pre-select candidate cycles before ILP (Integer Linear Program) can be applied. In this paper, we propose a new algorithm which is only based on ILP. When the required number of p-cycles is not too large, our ILP can generate optimal/suboptimal solutions in reasonable amount of running time. Keywords-Fast span protection, ILP (Integer Linear Program), p-cycle, WDM (Wavelength Division Multiplexing).