[CMake] Copying DLLs to output directory

Daniel Schepler dschepler at scalable-networks.com
Fri Oct 31 16:46:22 EDT 2014


And what if there are more dependencies?  For example, we have a project here that uses Qt, Boost, OGRE, MYGUI, GDAL, Protobuf and EXPAT at least.  And then if some of those builds aren't self-contained, you could add in dependencies like OpenSSL, libjpeg, libpng, etc.  It seems like all those PATH entries could easily end up overflowing Windows' limit on the length of PATH.
-- 
Daniel

-----Original Message-----
From: CMake [mailto:cmake-bounces at cmake.org] On Behalf Of Bill Somerville
Sent: Friday, October 31, 2014 12:52 PM
To: cmake at cmake.org
Subject: Re: [CMake] Copying DLLs to output directory

On 31/10/2014 19:42, Michael Jackson wrote:
> Never said it was pretty, but here is the code I use for Qt4 based projects. I think I had to revamp a lot of this for Qt5. I call it like so:
>
> CMP_COPY_QT4_RUNTIME_LIBRARIES( "QtCore;QtGui;QtNetwork")
This seems an awful lot of messing around when qt-project.org already dump all the debug and release libraries into the installation bin directory so all you need is to ensure that the installation bin directory is on your PATH when you run or debug executables, just like you have to to build using the tools like moc, qmake, dumpcpp, qrc, etc..

IMHO put he Qt bin directory on PATH for debugging and use BundleUtils FixupBundle to make deployable kits. No need to do any manual or scripted copying of libraries at all.

Regards
Bill.
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake



More information about the CMake mailing list