AbbVie, the U.S. based pharmaceutical company, said Friday it will buy U.K.-based drug maker Shire for $54 billion. The deal is designed to lower AbbVie's tax rate.

This will be the largest inversion deal ever. It's a move that has been common for pharmaceutical companies, moving their legal residences overseas to lower taxes. Washington hasn't been pleased with the tactics of these companies.

Since January 2012, 20 different U.S. companies have shifted their legal addresses from the U.S. addresses to overseas addresses, according to Bloomberg data.

Treasury Secretary Jacob Lew has urged Congress to do something about the outbreak of inversion deals, but Republicans and Democrats don't have any pending agreements to do anything about it.

Shire's board approves of AbbVie's deal to acquire them. It seems that AbbVie's main reason to acquire Shire is for the tax savings. Earlier this week, Pittsburgh-based Mylan Laboratories did a similar manuever by acquiring Abbot Laboratories international drug business. The deal will allow Mylan to move its legal residence to the Netherlands, thus saving them on taxes.

Shire shareholders will get cash and stock valued at 52.48 pounds per share.

"It's very, very sweet for Shire," Guillaume van Renterghem, an analyst at UBS AG in London, told Bloomberg. "The beauty of this AbbVie-Shire deal is that everybody gets out of this deal in even better shape than they entered it."

With adding Shire to its portfolio of drugs, AbbVie gets drugs for treating attention deficit disorder (ADD) and rare diseases. Last year, 39 percent of Shire's revenue came from ADD drugs. That's a big boost for AbbVie, which mostly focuses on its rheumatoid arthritis medicine Humira.

Since big companies like Walgreen's and Pfizer are considering making similar moves, these inversion deals are likely to keep happening unless new legislation is passed against it. The Obama Administration and some Democrats are supporting legislation that would limit inversion deals.

AbbVie shares were up more than 2 percent Friday on the news of the deal.