Fix the failure of requiring components due to the fact that pwd is ~.