chomp removes any trailing string that corresponds to the contents of the special variable $/
You shouldn't, under most circumstances, need to worry whether a specific platform uses \r\n or \n. Perl generally uses \n as the logical newline, and adapts to whatever platform it's being used on. You can read up on this topic in perlport.
About the only times you have to worry about cross-platform line ending issues are when you're reading documents written on one platform, from another platform; and also when you've moved a script from one platform to another without properly converting the script's own line endings.