The @relativepath directive allows for calculating a relative path between two given paths. For example the following
@$PATH_TO_ROOT = (@relativepath(r"C:\developer\_root_",r"C:\developer\build_object\build"))
is equivalent to
@$PATH_TO_ROOT = "../../_root_"