Change relative path calculation to actually work in the case where paths can be above the current directory.
Change relative path calculation to actually work in the case where
paths can be above the current directory.

For example:
In this directory tree:
  bob/
    joe/
  jim/
    sam/
      paul/
        smith/
If you are currently in bob/joe:
 RelativePath('./', '../../jim/sam/paul/smith')
currently yields: ../../../.. which is wrong.
It should yield: ../../bob/joe

The fix is to convert both paths to absolute paths before applying the current
method.

BUG=84
TEST=None


Review URL: http://codereview.chromium.org/242154

git-svn-id: e7e1075985beda50ea81ac4472467b4f6e91fc78@678 78cadc50-ecff-11dd-a971-7dbc132099af

cysp/gyp,Jack-Q/GYP-copy,mgamer/gyp,Omegaphora/external_chromium_org_tools_gyp,saghul/gyn,pandaxcl/gyp,sanyaade-teachings/gyp,amoikevin/gyp,sdklite/gyp,openpeer/webrtc-gyp,mgamer/gyp,dougbeal/gyp,amoikevin/gyp,adblockplus/gyp,MIPS/external-chromium_org-tools-gyp,Danath/gyp,adblockplus/gyp,duanhjlt/gyp,geekboxzone/lollipop_external_chromium_org_tools_gyp,cchamberlain/gyp,mistydemeo/gyp,lianliuwei/gyp,azunite/gyp,sport-monkey/GYP,mumble-voip/libmumble-gyp,duanhjlt/gyp,alexcrichton/gyp,saghul/gyn,lukeweber/gyp-override,Chilledheart/gyp,turbulenz/gyp,Phuehvk/gyp,cysp/gyp,pandaxcl/gyp,ttyangf/gyp,alexcrichton/gyp,cchamberlain/gyp,mumble-voip/libmumble-gyp,luvit/gyp,kevinchen3315/gyp-git,ttyangf/gyp,turbulenz/gyp,enkripsi/gyp,bnoordhuis/gyp,okumura/gyp,ttyangf/pdfium_gyp,mkrautz/gyp-libmumble,yinquan529/platform-external-chromium_org-tools-gyp,IllusionRom-deprecated/android_platform_external_chromium_org_tools_gyp,mapbox/gyp,lianliuwei/gyp,sport-monkey/GYP,azunite/gyp,svn2github/gyp,bulldy80/gyp_unofficial,AOSPU/external_chromium_org_tools_gyp,azunite/gyp_20150930,erikge/watch_gyp,AOSPU/external_chromium_org_tools_gyp,cchamberlain/gyp,bulldy80/gyp_unofficial,mkrautz/gyp-libmumble,dougbeal/gyp,Jack-Q/GYP-copy,ttyangf/pdfium_gyp,mgamer/gyp,mgamer/gyp,mistydemeo/gyp,sdklite/gyp,omasanori/gyp,xin3liang/platform_external_chromium_org_tools_gyp,ttyangf/pdfium_gyp,yangrongwei/gyp,channing/gyp,enkripsi/gyp,springmeyer/gyp,mkrautz/gyp-libmumble,ryfx/gyp,svn2github/gyp,sport-monkey/GYP,yangrongwei/gyp,LazyCodingCat/gyp,bpsinc-native/src_tools_gyp,sfiera/gyp,msc-/gyp,azunite/gyp_20150930,svn2github/gyp,erikge/watch_gyp,bdarnell/gyp,springmeyer/gyp,mistydemeo/gyp,trafi/gyp,openpeer/webrtc-gyp,msc-/gyp,carlTLR/gyp,Phuehvk/gyp,tarc/gyp,AOSPU/external_chromium_org_tools_gyp,yinquan529/platform-external-chromium_org-tools-gyp,turbulenz/gyp,chromium/gyp,carlTLR/gyp,pandaxcl/gyp,ryfx/gyp,android-ia/platform_external_chromium_org_tools_gyp,ttyangf/gyp,geekboxzone/lollipop_external_chromium_org_tools_gyp,Jack-Q/GYP-copy,LazyCodingCat/gyp,LazyCodingCat/gyp,duanhjlt/gyp,xin3liang/platform_external_chromium_org_tools_gyp,bnq4ever/gypgoogle,bdarnell/gyp,dougbeal/gyp,bpsinc-native/src_tools_gyp,geekboxzone/lollipop_external_chromium_org_tools_gyp,trafi/gyp,dougbeal/gyp,trafi/gyp,sanyaade-teachings/gyp,ryfx/gyp,bnoordhuis/gyp,luvit/gyp,cchamberlain/gyp,Danath/gyp,duanhjlt/gyp,AWhetter/gyp,kevinchen3315/gyp-git,sport-monkey/GYP,omasanori/gyp,Jack-Q/GYP-copy,azunite/gyp_20150930,trafi/gyp,pandaxcl/gyp,clar/gyp,Chilledheart/gyp,Jack-Q/GYP-copy,AWhetter/gyp,dougbeal/gyp,bnq4ever/gypgoogle,sloanyang/gyp,MIPS/external-chromium_org-tools-gyp,bdarnell/gyp,sloanyang/gyp,carlTLR/gyp,pandaxcl/gyp,Phuehvk/gyp,carlTLR/gyp,channing/gyp,bnq4ever/gypgoogle,mumble-voip/libmumble-gyp,Danath/gyp,lianliuwei/gyp,mapbox/gyp,AWhetter/gyp,yinquan529/platform-external-chromium_org-tools-gyp,openpeer/webrtc-gyp,clar/gyp,cchamberlain/gyp,cysp/gyp,svn2github/gyp,bdarnell/gyp,azunite/gyp,svn2github/kgyp,yjhjstz/gyp,MIPS/external-chromium_org-tools-gyp,bulldy80/gyp_unofficial,AWhetter/gyp,ttyangf/gyp,channing/gyp,mistydemeo/gyp,alexcrichton/gyp,sdklite/gyp,svn2github/kgyp,ttyangf/pdfium_gyp,bpsinc-native/src_tools_gyp,omasanori/gyp,mapbox/gyp,luvit/gyp,sfiera/gyp,tarc/gyp,Danath/gyp,mapbox/gyp,sfiera/gyp,amoikevin/gyp,Omegaphora/external_chromium_org_tools_gyp,bnoordhuis/gyp,msc-/gyp,cysp/gyp,mkrautz/gyp-libmumble,azunite/gyp_20150930,openpeer/webrtc-gyp,kevinchen3315/gyp-git,trafi/gyp,erikge/watch_gyp,azunite/gyp,xin3liang/platform_external_chromium_org_tools_gyp,alexcrichton/gyp,bulldy80/gyp_unofficial,clar/gyp,enkripsi/gyp,sport-monkey/GYP,chromium/gyp,tarc/gyp,Chilledheart/gyp,pyokagan/gyp,okumura/gyp,saghul/gyn,saghul/gyn,saghul/gyn,adblockplus/gyp,LazyCodingCat/gyp,AOSPU/external_chromium_org_tools_gyp,springmeyer/gyp,pyokagan/gyp,Phuehvk/gyp,adblockplus/gyp,openpeer/webrtc-gyp,okwasi/gyp,cysp/gyp,kevinchen3315/gyp-git,sanyaade-teachings/gyp,yjhjstz/gyp,IllusionRom-deprecated/android_platform_external_chromium_org_tools_gyp,luvit/gyp,okumura/gyp,clar/gyp,lukeweber/gyp-override,yinquan529/platform-external-chromium_org-tools-gyp,MIPS/external-chromium_org-tools-gyp,ttyangf/gyp,Omegaphora/external_chromium_org_tools_gyp,clar/gyp,pyokagan/gyp,chromium/gyp,bpsinc-native/src_tools_gyp,lianliuwei/gyp,ryfx/gyp,sloanyang/gyp,Phuehvk/gyp,ttyangf/pdfium_gyp,android-ia/platform_external_chromium_org_tools_gyp,bnoordhuis/gyp,android-ia/platform_external_chromium_org_tools_gyp,bulldy80/gyp_unofficial,Danath/gyp,svn2github/gyp,adblockplus/gyp,android-ia/platform_external_chromium_org_tools_gyp,msc-/gyp,lukeweber/gyp-override,okwasi/gyp,sloanyang/gyp,amoikevin/gyp,bnq4ever/gypgoogle,IllusionRom-deprecated/android_platform_external_chromium_org_tools_gyp,Chilledheart/gyp,duanhjlt/gyp,yjhjstz/gyp,okwasi/gyp,bnq4ever/gypgoogle,yangrongwei/gyp,turbulenz/gyp,azunite/gyp_20150930,xin3liang/platform_external_chromium_org_tools_gyp,svn2github/kgyp,sanyaade-teachings/gyp,pyokagan/gyp,mumble-voip/libmumble-gyp,enkripsi/gyp,brson/gyp,mgamer/gyp,AWhetter/gyp,svn2github/kgyp,LazyCodingCat/gyp,yjhjstz/gyp,sdklite/gyp,channing/gyp,tarc/gyp,enkripsi/gyp,IllusionRom-deprecated/android_platform_external_chromium_org_tools_gyp,springmeyer/gyp,amoikevin/gyp,erikge/watch_gyp,bnoordhuis/gyp,svn2github/kgyp,lukeweber/gyp-override,tarc/gyp,turbulenz/gyp,springmeyer/gyp,erikge/watch_gyp,mapbox/gyp,ryfx/gyp,geekboxzone/lollipop_external_chromium_org_tools_gyp,okwasi/gyp,Omegaphora/external_chromium_org_tools_gyp,chromium/gyp,carlTLR/gyp,pyokagan/gyp,okumura/gyp,omasanori/gyp,yjhjstz/gyp,msc-/gyp,brson/gyp,azunite/gyp,Chilledheart/gyp,chromium/gyp,yangrongwei/gyp,sanyaade-teachings/gyp,brson/gyp,brson/gyp,sdklite/gyp