I found out it's not TARGETS, but DESTINATION that matters for CPACK_NSIS_MODIFY_PATH to work. When I set DESTINATION to bin rather than libW32, it's added to Windows PATH without a problem. That's really strange.