Here is a generic Leica M to Sony NEX E-mount lens adapter. The adapter allows for infinity focus but it occurs before the infinity mark. We wanted to get closer to the infinity mark so we took off the (4) screws that attach the silver part to the black part. We used a precision slotted screwdriver and made sure not to strip the very tiny screws.
We used pieces of aluminum foil to add thickness to the adapter. This will get the Leica M lens farther away from the Sony NEX sensor and infinity focus should be closer to the infinity mark on the lens. If the foil is too thick, the lens will be too far away and infinity focus may not be achieved.
Reassemble the adapter and test the lens for infinity focus.