At first glance, HP (HPQ 0.49%) and Xerox (XRX) look like dusty old tech stocks that are owned for income instead of growth. But on closer inspection, both companies' core businesses are changing substantially due to recent developments. Let's discuss these changes, and see if they're making one of these companies a better long-term investment than the other.

An HP printer (L) and a Xerox photocopier (R). Image source: Company websites.

How are HP and Xerox changing?

Hewlett-Packard split into two companies last year. Hewlett-Packard Enterprise (HPE -1.29%) retained the enterprise hardware and software businesses, while HP (HPQ 0.49%) kept selling computers, printers, and imaging devices. Those businesses are all slow growth, but the company hopes that its expansion into high-end 3D printers can revive its top-line growth. HP also recently agreed to buy Samsung's printing business for $1.05 billion to scale up its operations.

Xerox plans to spin off its business-processing outsourcing operations as a new company called Conduent by the end of the year. Xerox will retain its document and services business, which competes against HP's imaging businesses. Xerox was expected to merge its document and services business with print and publishing company R.R. Donnelley earlier this year, but it rejected that deal in July.

HP's strengths and weaknesses

No one is expecting much growth from HP. Its revenue is expected to fall 7% this year and another 4% next year. It's unclear how much revenue the Samsung acquisition will add to HP's top line because the unit's sales figures haven't been disclosed.

Both of HP's main target markets are wobbly. Last quarter, personal systems (PC) sales fell 13% annually as printing revenues plunged 17%. But HP's earnings from continuing operations, boosted heavily by layoffs and buybacks, still rose 20% during that quarter.

Gartner recently reported that worldwide PC shipments fell annually for the eighth straight quarter. But between the third quarters of 2015 and 2016, HP's market share in PCs rose from 18.8% to 20.4%, putting it in second place after market leader Lenovo.

HP is the biggest maker of printers in the world, but its market share fell from 40.8% to 36.6% between the second quarters of 2015 and 2016, according to IDC, as rivals Canon and Epson both grew their shares. That market is still shrinking -- IDC reports that worldwide hardcopy peripheral sales fell nearly 4% annually in the second quarter. On the bright side, sales of large format and 3D printers have been improving.

Xerox's strengths and weaknesses

Xerox's Document Technology revenue fell 7% annually last quarter, and Services revenue fell 2%. Analysts expect Xerox's total revenue (not accounting for the Conduent split) to fall 3% this year and another 1% next year. The businesses that make up Conduent generated $7 billion, or 39% of Xerox's revenue last year.

While Xerox's top-line growth looks weak, many investors, including Carl Icahn, believe that the Conduent spinoff will strengthen both companies' earnings by streamlining their businesses and cutting costs across the board. Xerox already cut thousands of jobs earlier this year ahead of the spinoff. Those cuts, along with big buybacks, are expected to boost Xerox's full-year earnings by 15% this year.

Like HP, Xerox's top line will likely benefit from higher demand for large-format printers. The company also announced that it would expand its presence in the 3D printing market in May.

Growth, valuations, and dividends

Analysts expect HP's annual earnings to grow at an average rate of just 2% over the next five years. That gives it a five-year PEG ratio of just 4.8. Because a PEG ratio under 1 is considered undervalued, HP isn't cheap relative to its earnings growth potential.

Xerox's earnings, excluding the impact of the Conduent spinoff, are expected to rise 3% per year during that same period -- which gives it a lower PEG ratio of 3. However, investors looking for businesses with fewer moving parts should wait until after the spinoff concludes to determine which half of Xerox is a better long-term play.

HP pays a forward yield of 3.2%, which is easily supported by its payout ratio of 22%. Xerox pays a 3.1% yield, but its payout ratio is a much higher 74%. Once again, income investors should wait for the split to see which half ends up with a higher yield. If Xerox follows HP's example (giving the "higher growth" HPE a lower dividend than the "slower growth" HP), Xerox should pay a much higher dividend than Conduent.

So which stock is the better buy?

I'm not bullish on either stock right now, but HP seems to be a better buy. HP is gaining economies of scale by acquiring Samsung's printing business, its PC sales could recover as enterprise demand returns, and it pays a higher dividend with a lower payout ratio. Xerox, however, is tough to recommend until it spins off Conduent, and offers investors a clearer picture of both companies' futures.