[CMake] Problem finding DLLS to use with tests

Stephen Torri stephen.torri at gmail.com
Wed Jun 22 15:12:07 EDT 2011


I am using cmake 2.8 for building MSVC solutions for a project.
The project builds fine as do the tests on Windows. The problem
comes when I try to run the tests. I usually get an error message
that the dependent DLLs cannot be found. I have searched on google
for an answer and came up with a variety of possible solutions. I was
not able to get any of them to work. So I am looking for suggestions.
The methods I found were:

1. Add the directory to the DLLs to the PATH environment.

2. Copy the DLLs from their installation directory to the directory of the
    test binary.

3. Statically link the dependent libraries to the target executable/library.

I was wondering if someone can point me towards an example, tutorial or
appropriate documentation that shows how I can best solve this problem.

Stephen
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20110622/7b3c00a0/attachment.htm>


More information about the CMake mailing list