There are numerous prohibitions which relate to running a business on Shabbat.
Two of them, working one’s slave or beast, are of Torah origin and are dependent on ownership. Practically, the problem is limited to animals, since few-publicly owned corporations own slaves (though it may be that the definition of slave or servant for the purposes of Shabbat is broader than for other laws; see Rambam Shabbat 20:14). It is advisable not to hold stock of a corporation which owns animals that labor on Shabbat.
The other restrictions, relating to the ban on directing others to do one’s labor on Shabbat or even having them do so without orders, are of rabbinic origin and relate primarily to direct control. According to R. Feinstein (Igrot Moshe OC Vol. IV, 54), control is in the hands of management; the management resembles a sharecropper or contractor who acts on his own initiative, and not a hired worker. Therefore, a Jew may hold even a majority interest in a corporation which does business on Shabbat, provided that the controlling management is predominantly non-Jewish. (Minchat Yitzchak Vol. III, 1 rules likewise).
If the management is primarily Jewish, severe problems arise, since it is still prohibited to have a Jew work on Shabbat even on his own initiative. Several authorities have permitted, in case of great need, a partnership with a Jew who would have worked on Shabbat regardless, if a condition is made that the business belongs to the shomer-Shabbat partner only on weekdays (Igrot Moshe OC Vol. IV, 55, Chelkat Ya’akov Vol. II, 54, Tzitz Eliezer OC Vol. II, 65); perhaps the company management, who are the representatives of the shareholders, are empowered to authorize such a condition with an individual shareholder.
If the company’s business cannot be conducted without Shabbat operations, this resembles the case of having the market day on Shabbat, and it is difficult to be lenient (see Shulchan Arukh OC 307:4 and Mishna Berura 15, Sha’ar Ha-tziun 15). This presumably refers to a case where business is impracticable, and not merely unprofitable, on weekdays only.