Killing an innocent, desired, healthy baby in a family that can afford (and is willing to) raise him is an evil act, doesn't matter your culture/religion. (Absolute) good and evil aren't constructs.
But, an hypothetical situation presents itself: Your hero party arrives at a devastated barony whose all workforce were killed by a war. A necromancer is reanimating the dead and using them to work the fields, sharing a part of the profit from the crops with the familiies of the now-undead workers. This allowed the females to take care of the youngs and elders, using the free time for more delicate handcraft. Without the undead workers, the females would have to work the fields, leaving the children and old people to take care for themselves and, since the living can't work 24 hours a day, probably would suffer from famine.
Is this necromancer doing an evil act? I don't think so. But is he reanimating corpses? Yes he is.
How deep does the rabbit hole goes to justify a good act by using evil means?
No, it actually does matter the culture and religion. You're bringing your own personal bias into the argument and trying to say that what your personal beliefs are is "an absolute good" or "an absolute evil". Good and Evil are constructs, one need only look to feral children to see that in action. Human beings aren't born innately good or evil. We're born only with the instinct to survive and procreate. There are no other drives hard-wired into a human being. The society you are born into teaches you what is good and what is evil according to their beliefs and expects you to follow them in order to be a productive member of that society.
"Good" acts are any behavior that a society values for its continued existence or thriving. "Evil" acts are those your society devalues because that society believes them to be detrimental to the safety, productivity, and stability of that particular society. This does very wildly from society to society and any number of them will give decent reasons why they hold the beliefs they do. Usually, it keeps the society together and ensures it lasts at least to the next few generations beyond the here and now.
For all you know, that "desired and healthy baby in a family that can afford and is willing to raise them" is a family that is actually ill-equipped to raise said baby. Perhaps they lack the emotional support and basic know-how to raise the baby, so any baby they raise would more likely than not turn out to be an active problem to the society in the form of crime, laziness, or any other factor. Is it enough for a baby to be healthy and grown up? Maybe to some societies it isn't. Maybe some societies would rather kill the baby than let it be raised in an environment where the most likely outcome would be that it ends up hurting their society more than helping it (like say... engaging in murder... drug trafficking... rape... you-name-it).
Or, maybe the society thinks the baby isn't "good enough" and their viewpoint is that they only want the absolute best genetics to be present in their society in order to limit pollution of a gene pool and limit the amount of genetic defects in their populace. Maybe it just doesn't meet the high standards of that society and death is preferable to a life of absolute sub-par existence and accomplishments.
Every society values something different. Perhaps even in times of famine, some societies deem it perfectly acceptable to eat their babies and children in order to let the adults live long enough to make it through the famine and produce more offspring later when it best suits the needs of the society. Are they evil? Is it wrong? Who can say but them?
Survival is all we are born to do. We have that blind imperative and do anything to accomplish it. It is only parents who mold us to do more than survive and it is only a society that molds those parents into how best to do more than survive.
"Good" and "Evil" are absolutely constructs of a society and/or a religion. They are useful constructs that exist for the betterment of our species, no matter what form they take, but they are constructs none-the-less. There really isn't a way to argue that without exposing the personal bias of whomever argues against it... or the ignorance of the person trying to argue against it. I always bring up the "If we're born to be either good or evil, how do you explain Feral Children? Shouldn't they be hard wired to be good or evil? Why are they wired to be animalistic and basically selfish if they are feral then?" Nobody has once come up with an answer to that. At least... not without contradicting their "good and evil aren't constructs!" arguments.