Merge pull request #4280 from lite3/develop

[ci skip]fix path for windows
This commit is contained in:
minggo 2013-11-16 05:22:09 -08:00
commit bac14ab3e5
1 changed files with 3 additions and 1 deletions

View File

@ -33,9 +33,11 @@ def gen_android_mk(mkfile, pathes, suffix = ("c", "cpp",), exclude = ()):
# generate file list string # generate file list string
filestrio = cStringIO.StringIO() filestrio = cStringIO.StringIO()
mkfilepath = os.path.dirname(os.path.join(COCOS_ROOT, mkfile))
for filename in filelst: for filename in filelst:
filestrio.write(' \\\n') filestrio.write(' \\\n')
filestrio.write(os.path.relpath(filename, os.path.dirname(os.path.join(COCOS_ROOT, mkfile)))) filepath = os.path.relpath(filename, mkfilepath)
filestrio.write(filepath.replace('\\', '/'))
filestrio.write('\n') filestrio.write('\n')
# read mk file # read mk file