[LLVMbugs] [Bug 10886] New: Cmake scripts with Clang don't work in trunk as of revision 139290

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Sep 8 04:40:43 PDT 2011


http://llvm.org/bugs/show_bug.cgi?id=10886

           Summary: Cmake scripts with Clang don't work in trunk as of
                    revision 139290
           Product: Build scripts
           Version: trunk
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P
         Component: cmake
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: peter.rundberg at autodesk.com
                CC: llvmbugs at cs.uiuc.edu, ofv at wanadoo.es


Trying to configure LLVM with Clang included using cmake fails on Windows and
MacOS (the only ones I have tried).

Configuring and building using the configure scripts on MacOS works.

Without Clang included it works using Cmake.

Steps to reproduce:

svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm
cd llvm\tools
svn co http://llvm.org/svn/llvm-project/cfe/trunk clang
cd ..\..
mkdir build
cd build
cmake.exe -G "Visual Studio 10 Win64" ..\llvm\

Errors look like the following...


CMake Error at cmake/modules/AddLLVM.cmake:81 (add_executable):
  add_executable cannot create target "SupportTests" because another target
  with the same name already exists.  The existing target is an executable
  created in source directory
  "C:/Work/LLVM/llvm-3.0/llvm/tools/clang/unittests".  See documentation for
  policy CMP0002 for more details.
Call Stack (most recent call first):
  unittests/CMakeLists.txt:13 (add_llvm_executable)
  unittests/CMakeLists.txt:129 (add_llvm_unittest)


CMake Error at cmake/modules/AddLLVM.cmake:86 (target_link_libraries):
  Attempt to add link library "gtest" to target "SupportTests" which is not
  built in this directory.
Call Stack (most recent call first):
  unittests/CMakeLists.txt:13 (add_llvm_executable)
  unittests/CMakeLists.txt:129 (add_llvm_unittest)


CMake Error at cmake/modules/AddLLVM.cmake:86 (target_link_libraries):
  Attempt to add link library "gtest_main" to target "SupportTests" which is
  not built in this directory.
Call Stack (most recent call first):
  unittests/CMakeLists.txt:13 (add_llvm_executable)
  unittests/CMakeLists.txt:129 (add_llvm_unittest)


CMake Error at cmake/modules/AddLLVM.cmake:86 (target_link_libraries):
  Attempt to add link library "LLVMSupport" to target "SupportTests" which is
  not built in this directory.
Call Stack (most recent call first):
  unittests/CMakeLists.txt:13 (add_llvm_executable)
  unittests/CMakeLists.txt:129 (add_llvm_unittest)


CMake Error at cmake/modules/AddLLVM.cmake:83 (add_executable):
  add_executable cannot create target "KillTheDoctor" because another target
  with the same name already exists.  The existing target is an executable
  created in source directory
  "C:/Work/LLVM/llvm-3.0/llvm/tools/clang/utils/KillTheDoctor".  See
  documentation for policy CMP0002 for more details.
Call Stack (most recent call first):
  cmake/modules/AddLLVM.cmake:122 (add_llvm_executable)
  utils/KillTheDoctor/CMakeLists.txt:1 (add_llvm_utility)


CMake Error at utils/KillTheDoctor/CMakeLists.txt:5 (target_link_libraries):
  Attempt to add link library "LLVMSupport" to target "KillTheDoctor" which
  is not built in this directory.

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list