you must first find out where the smell is coming from, and what i mean is, find out where its leaking. contained diesel does not emit a smell, but diesel that is leaking to atmosphere will.
is it coming from the engine area?... there are a few spots on the engine that could leak fuel, and if the fuel is getting to a warm surface, it will create a much stronger smell than diesel that is dripping onto a cool surface.
also dont rule out engine blow-by... it should be directed back into the intake, but if the hose has deteriorated or has came unhooked, it will create a smell in the boat.
to check for diesel leaks, start the engine cold and let it run for 45-60 seconds and then shut it off.
you want the fuel pressure to maximize to show itself at the source of the leak, but you dont want the engine warm as it will vaporize the fuel from the area.
then after 2 or 3 minutes start looking.
dont look for a drip, but look for slight dampness on line or fitting. when you find a suspect area, use a square of toilet paper to gently touch the area at the bottom... and if there is any perceptable sign of dampness, clean/wipe the area well and then start the engine again and retest.
But first,
very closely inspect the whole fuel system first and then clean all the areas so you can reinspect all at the same time, this way you only have to restart the engine once or twice for the entire inspection and repair
also to check, what condition is the fuel tank in, any corrosion/leaks? and the vent hose?.. and how about the sending unit gauge gasket?... the filler hose and clamps?... filter base gaskets and fittings?... these can all create a smell if there is any slight sign of dampness.
when i first got my 34, because it was neglected for a few years, it had a strong smell whenever the engine got warmed up... and it did have an oil leak at the mechanical tach connection, (which is not being used)... i repaired the leak but still had the smell.
after a couple of months i finally decided to spray the entire engine and engine compartment with a degreaser (i used whitewall cleaner for tires, its strongest degreaser you can get that is readily available for consumer use) i let it set 5 minutes and used a hose with a good sprayer end to wash it down...
then i did it again... it took three times to get the engine red and the compartment white, but now it looks great and without any smells coming from it since the bath....
this wash down did make a mess in the bilge, and the bilge sump in my keel is only 8 inches wide, 5 ft long and the bottom is 4ft below salon level so it took some time to figure out how to get the gunk out because it was a mess and i couldnt reach it....
but i pumped out what i could, then used a fan to dry out the water (took a couple weeks)...
then once it was all dry I used a grabber tool (like the handicapped use to pick things up when they cant bend over) to pick out years of accumulated tools, nuts, bolts, washers, screws, zip ties, clumps of old sealer, trash and other unknown debris from the recess.
then on top of the two inches of gunk, I dumped some kitty litter.
i let it set a couple days and stirred it around to pick up any dampness and/or oil mess, then vacuumed it out. now the bilge is as clean and dry as the engine compartment.