Skip to content

Commit e802889

Browse files
fayeshineVijay Vasudevan
authored andcommitted
solve the bug which the python include config gives out repeat results (tensorflow#3742)
``` ./configure Please specify the location of python. [Default is /home/wenjian/anaconda3/bin/python]: Do you wish to build TensorFlow with Google Cloud Platform support? [y/N] N No Google Cloud Platform support will be enabled for TensorFlow Found possible Python library paths: /home/wenjian/anaconda3/lib/python3.5/site-packages /home/wenjian/anaconda3/lib/python3.5/site-packages Please input the desired Python library path to use. Default is [/home/wenjian/anaconda3/lib/python3.5/site-packages] ``` it shows repeat result in config on python includes, it is because the old code show paths[0] and ret_paths at the same time, so I modify the condition and do some simple optimization by using `join`
1 parent 50d7231 commit e802889

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

util/python/python_config.sh

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -69,10 +69,9 @@ for path in all_paths:
6969
7070
if len(paths) == 1:
7171
print(paths[0])
72-
ret_paths = ""
73-
for path in paths:
74-
ret_paths += path + " "
75-
print(ret_paths)
72+
else:
73+
ret_paths = " ".join(paths)
74+
print(ret_paths)
7675
END
7776
}
7877

0 commit comments

Comments
 (0)