In this paper, we consider the problem of topology design for both unprotected and one-link protected all-optical networks. We investigate the problem of selecting switching sites to minimize total cost of the network. The cost of an optical network is expressed as a sum of three main factors: the site cost, the link cost, and the switch cost. For unprotected networks with linear cost model, we present a mixed integer linear programming (MILP) formulation of the problem. We also present an efficient heuristic to approximate the solution. The experimental results show good performance of the linear cost model heuristic. In 16% of the experiments with 10 nodes network topologies, the linear cost model heuristic had no error. Moreover, for 54% and 86% of the experiments with 10 nodes network topologies, the linear cost model heuristic's solution is within 2% and 5% of its optimal value respectively. Finally, we extend our approach to one-link protected networks, and present an efficient survivable heuristic, and representative experimental results.