McDonnell Douglas Corp. will pay $50 million to settle a six-year-old legal war with Northrop Corp. over which of the aerospace giants can act as prime contractor for foreign sales of the F-18 Hornet attack-fighter jet made jointly by the two companies.

In announcing the settlement today, St. Louis-based McDonnell and Los Angeles-based Northrop said they have dismissed all lawsuits against each other involving the Hornet, a twin-engine fighter jet intended for use from Navy carriers. The companies said that McDonnell Douglas will be prime contractor in all sales of the F-18 and that Northrop will be the principal subcontractor.

Neither company would comment beyond a joint statement, which emphasized that the $50 million payment will have no effect on McDonnell Douglas' earnings this year because the company had previously written off that amount as a precaution in case of a settlement.

The settlement ends a bitter battle over profits from foreign sales of the Hornet jet. Foreign sales are a key source of revenue for defense contractors, helping offset the cost of developing and building a weapons program for the Pentagon.

The legal battle over the Hornet began in October 1979 when Northrop filed suit in U.S. District Court in Los Angeles accusing McDonnell Douglas of promising foreign countries the chance to build parts of the jet that had been promised to Northrop.

Specifically, Northrop alleged that McDonnell Douglas, while seeking a contract to provide Canada with a new fighter jet, violated a 1975 agreement by promising that Canadian companies could manufacture parts of the plane's center and rear fuselage.