The Libra Foundation is selling Mars Hill-based Pineland Farms Potato Co. to Bob Evans Foods in a deal worth $115 million.

The Mars Hill factory, founded by local businessman Rodney McCrum in 1997 as Naturally Potatoes, makes mashed and pre-cooked potatoes. The Libra Foundation, the Portland-based private foundation that started the Pineland brand of companies, was a major investor in the potato factory starting in 1999 and acquired the company as a majority owner in 2010 from a California company that purchased it in 2005.

Bill Haggett, chairman and CEO of Pineland Farms Potato Co., said it made sense for the Libra Foundation to sell the business to a larger, national company.

“We have made tremendous strides in Maine, but there are practical limitations on how much further current owners would be able to take this business,” Haggett said in a news release.

“This industry leader’s entry into Maine is something we have been working toward for a long time,” Libra Foundation president and chief operating officer Jere Michelson said. “They are the ideal stewards for the enterprise and its people.”

The 125,000-square-foot potato facility employs almost 200 people and buys about 100 million pounds of potatoes from 25 local growers annually. The company expanded its production in recent years and serves restaurants, grocery stores and also Bob Evans, now one of its largest buyers, Haggett said. Within a few months, Haggett said in an interview, the factory could ramp up its full capacity to handle 180 million pounds of spuds per year.

The deal is expected to close by May and will not affect the separate Pineland Farms meat, cheese or New Gloucester campus operations. Haggett said that under the agreement the Pineland cheese packaging operation at the Mars Hill factory will be phased out within a year.

Bob Evans, a publicly traded company based in New Albany, Ohio, is acquiring Pineland Farms Potato Co. at the same time it’s splitting its restaurant and processed food businesses in two. A private equity firm is buying Bob Evans restaurants for $565 million and taking the business private.

The remaining Bob Evans Farms food division, which makes mashed potatoes, sausage and other prepared dishes, will become a standalone company that will include Pineland Farms Potato Co.

“The sale of Bob Evans Restaurants enables us to concentrate exclusively on BEF Foods, our fastest growing and most profitable segment,” Bob Evans CEO Saed Mohseni said in a news release.

The $115 million purchase price for the Mars Hill potato facility may be increased as much as $25 million if certain financial metrics are met in the two years after the deal is closed, according to a news release by Bob Evans.

McCrum, the founder and current president and chief operating officer of Pineland Farms Potato Co., is expected to remain on the management team of the facility, along with his staff, according to the release.

The Mars Hill potato factory has helped sell a value-added potato product from Aroostook County and in recent years has expanded to the point that it purchased its own farming operation in 2012, a 600-acre farm in St. Agatha that produces about 8 percent of the company’s potatoes.

“Our investment in the potato company some years ago was intended to build a first-class Maine potato business, to provide a value-added outlet for area growers and to create good jobs,” Craig Denekas, chairman and CEO of the Libra Foundation, said. “We couldn’t be more pleased with an outcome that propels all facets of the company on to the next level nationally.”