There is rsync, the built-in Unix syncing command, and apps that are a front-end for it.
There are many file and folder syncing apps, the King of which is Chronosync. I use it to sync my Document folder between my desktop and laptop Macs.
Syncing an iTunes Library is a bit more difficult. You can't just add the files to the folders. You could synchronise (i.e. overwrite) the iTunes Library file, though this may cause problems if the user account names or file paths are different.
Similarly, you don't want to synchronise your user Library cache and preferences files, as they relate to the specific machines.
You can create Smart Folders of files that are shared from the other computer, which have been recently modified or added, and then you can drag them over to iTunes. iPhoto would be a bit more complex.