CMAKE ERROR: another target with the same name already exists
Created by: pmajchrzak
There is an error during CMake work. It appears with commit: https://github.com/PaddlePaddle/Paddle/commit/fab8bbf25bb34d6989a59df4c1b0536051a59344
Run sequence:
cmake .. -DCMAKE_BUILD_TYPE=Release -DWITH_GPU=OFF -DWITH_MKLDNN=ON -DWITH_TESTING=ON -DWITH_PROFILER=ON -DWITH_STYLE_CHECK=OFF -DON_INFER=ON -DWITH_INFERENCE_API_TEST=ON
-- Found Paddle host system: ubuntu, version: 16.04.5
-- Found Paddle host system's CPU: 80 cores
-- The CXX compiler identification is GNU 5.4.0
-- The C compiler identification is GNU 5.4.0
Error:
CMake Error at /usr/share/cmake-3.13/Modules/ExternalProject.cmake:3051 (add_custom_target):
add_custom_target cannot create target
"extern_inference_download_MobileNet_qat_perf_tar_gz" because another
target with the same name already exists. The existing target is a custom
target created in source directory
"/repos/paddle_paddle/paddle/fluid/inference/tests/api". See documentation
for policy CMP0002 for more details.
Call Stack (most recent call first):
paddle/fluid/inference/tests/test.cmake:32 (ExternalProject_Add)
python/paddle/fluid/contrib/slim/tests/CMakeLists.txt:97 (inference_download_and_uncompress)
python/paddle/fluid/contrib/slim/tests/CMakeLists.txt:218 (download_quant_model)