(Reuters) - Deere & Co DE.N said on Thursday it would buy privately held German company Wirtgen Group for about $4.88 billion to expand its road construction operations as it looks to cut down its dependence on its slowing farm business.

John Deere tractors are seen for sale at a dealer in Longmont, Colorado, U.S., February 21, 2017. REUTERS/Rick Wilking

Deere’s share rose 3.1 percent to $126.29 in premarket trading, and were set to open at their highest ever.

Wirtgen makes construction equipment used in laying roads and its products would be complementary to Deere’s portfolio, Deere said in a statement.

Deere makes equipment for part of the road-building process - loaders and dump trucks to load rocks into crushers from quarries, earthmoving tools at construction sites, and dozers and motorgraders that help grade roads.

Wirtgen makes crushers that break down large rocks, milling machines, plants to supply hot asphalt for road projects, and pavers and rollers. It has a network of company-owned and independent dealers in about 100 countries.

“The acquisition will help Deere diversify its business which has been heavily reliant on agriculture while improving the distribution of its North American centric construction business,” William Blair analyst Lawrence De Maria told Reuters.

“While there are growth opportunities, this allows for greater scale in construction markets and extends the equipment portfolio.”

Deere’s sales had taken a hit over the past three years as bumper corn and soybeans harvests drove down prices, leaving farmers with less cash to spend on equipment. In Europe, the agriculture market was also under pressure due to lower farm income.

To cope, the company cut jobs and lowered production of its trademark green tractors and harvesting combines.

Things have improved of late, though. Last month, Deere said demand was improving in South America, and raised its full-year sales and profit forecast for the second time.

The company’s agriculture and turf business contributed about 70 percent to its total revenue last year, while construction and forestry accounted for just over a fifth.

Deere said on Thursday it expected the Wirtgen acquisition to close in the first quarter of 2018.

Citigroup was Deere’s financial adviser. Linklaters LLP was the company’s deal legal counsel, Kirkland & Ellis LLP was securities legal counsel. Boston Consulting Group served as a strategic adviser.