Doing Melacha for a gentile or animal:
All the Melachos of Ochel Nefesh were only permitted to be performed for the need of the eating of a Jew. It is however [Biblically] forbidden to perform Melacha of Ochel Nefesh for the sake of feeding a gentile or animal. This applies even to animals that are dependent on oneself for their food, such as pets. It is forbidden to perform to perform even Rabbinical Melacha on their behalf, such as to carry their food from a Reshus Hayachid to a Karmalis.
May one perform Meleches Ochel Nefesh on behalf of a non-religious Jew?
A Jew who is a Mumar or desecrates Shabbos in public has the status of a gentile with regards to all matters. It is thus forbidden to perform Meleches Ochel Nefesh on behalf of such Jews on Yom Tov. [See Halacha ?? regarding non-religious guests!] Some Poskim however rule it is permitted to perform Melaches Ochel Nefesh on behalf of any Jew. This especially applies if the Jew is a Tinok Shenishba.
 Admur 512/11; Michaber 512/1 [gentile] and 3 [dogs] regarding cooking; Michaber 518/2 regarding carrying; Beitza 21a-b regarding cooking for gentile; Rebbe Yossi Hagelili Beitza ibid regarding cooking for dogs; Chayeh Adam 21/1 and Kaf Hachaim 512/2 that this applies to all Melacha; Levush and Tur that this applies to all animals; See Yom Tov Kehilchaso 5;
Other opinions: Some Poskim rule it is permitted to perform Meleches Ochel Nefesh for the sake of animals. [Rebbe Akiva Beitza ibid; Ravaya; Razah; Raavad in Tamim Deim; See Bach 512]
 The reason: As the verse states “Hu Levado Yeiaseh Lachem” from which we learn that the Melacha may only be done for you and not for gentiles, for you and not for animals. [Admur ibid; Taz 512/1; Beitza ibid]
 Admur 512/3 and 7; Olas Shabbos 512/4; Elya Raba 512/10; M”B 512/16; Kaf Hachaim 512/32
 Admur 512/7
 Admur O.C. 39/1 “He is like a gentile for all matters”; Michaber Yoreh Deah 2/5 “He is like a gentile”; Admur Y.D. 2/10 “He is a like a gentile regarding Shechita and for the entire Torah, except for Kiddushin”; Rashba 7/53; Tiferes Lemoshe 113/9 [brought in Pischeiy teshuvah 113/1] regarding Bishul Akum [however not Pas Akum]; Erech Hashulchan 112/2; Kaf Hachaim 112/11; Ketzos Hashulchan 101/5 and Kitzur Shulchan Aruch 72: “Anyone who publicly desecrates Shabbos is considered like an idle worshiper and [thus] if he touches wine he forbids it, and the bread which he bakes is like Pas Akum, as well as the food which he cooks is like Bishul Akum.”
 Mabit 1/38 in name of Rabbeinu Shimshon; P”M 512 A”A 1 and M”Z 1; M”B 512/2; Kaf Hachaim 512/4
 Yearos Devash end of volume 1
 Maharam Shick 281 that so is opinion of Maharashach brought in M”A 512/1 regarding the Karaim; See P”M ibid
 See M”A 512/1; M”B 512/2; Kaf Hachaim 512/3
 Reb Betzalel 63 in name of Radbaz; 1st opinion in M”A 512/1, Kneses Hagedola 512, Elya Raba 512/1, M”B 512/2
 Maharshach 3/15; 2nd opinion in M”A 512/1, Kneses Hagedola 512, Elya Raba 512/1, P”M 512 A”A 1, M”B 512/2