To substitute Macintosh (\cM), DOS (\cM\cJ) and Unix (\cJ) linefeeds, use
s/\r\n?|\n/(something)/g.
If you just want to remove them,
tr/\cM\cJ//d is a lot faster.
2;0 juerd@ouranos:~$ perl -e'undef christmas'
Segmentation fault
2;139 juerd@ouranos:~$