BMC Software ( BMC) swung to a first-quarter profit and reported operating earnings that eclipsed estimates that were lowered in the wake of its July 6 profit warning. The maker of infrastructure software for businesses earned $51.8 million, or 23 cents a share, in the three months to June 30, compared with a loss of $6.1 million, or 3 cents a share, last year. Revenue rose 5% from a year ago to $326 million. Before special items, BMC earned $32.1 million, or 14 cents a share, in the most recent quarter. Analysts surveyed by Thomson First Call were forecasting earnings of 13 cents a share on revenue of $325.1 million in the latest quarter. BMC itself on July 6 forecast pro forma earnings between 11 cents and 14 cents a share on revenue of $318 million to $328 million, down from previous guidance for pro forma earnings of 12 cents to 16 cents a share on revenue of $345 million to $355 million. Looking ahead, BMC expects to post pro forma earnings of 12 cents to 16 cents a share on revenue of $340 million to $355 million in the September quarter. Analysts were looking for earnings of 15 cents a share on revenue of $350 million. For the full year, BMC expects to post pro forma earnings of 64 cents to 74 cents a share on revenue of $1.46 billion to $1.49 billion. Analysts were looking for earnings of 71 cents a share on revenue of $1.50 billion. By segment, first-quarter software license revenue fell 7% from a year ago to $100.3 million in the latest quarter, while maintenance revenue rose 12% to $204.8 million and professional services rose 11% to $20.9 million. "The first quarter presented a challenging revenue environment for our industry and for BMC," CEO Bob Beauchamp said in a release. "While disappointed with our revenue performance, which was in part due to weakness in the United States, I was pleased with our expense controls and improved operating margins in the quarter."