[CMake] How to install a shared library on a windows system

Ryan Pavlik rpavlik at iastate.edu
Fri Jun 11 13:16:12 EDT 2010


On 06/11/2010 12:14 PM, Torri, Stephen CIV NSWCDD, W15 wrote:
>> From: cmake-bounces at cmake.org on behalf of Ryan Pavlik
>> Sent: Fri 6/11/2010 12:34 PM
>> To: cmake at cmake.org
>> Subject: Re: [CMake] How to install a shared library on a windows system
>>
>>
>> Stephen,
>>
>> The catch is that windows searches for the DLL at runtime in specific
>> locations: http://msdn.microsoft.com/en-us/library/7d83bc18%28VS.80%29.aspx
>>      
> I see that it searches the directories listed in the PATH variable. How can you tell CPACK to just always install itself to the PATH variable instead of asking?
>    
You generally don't want to put your install directory in the PATH 
environment variable system-wide (or install to c:\windows\system32): 
you'll probably either want to a: install a launcher script that appends 
to the path at run time (see my other recent mailing list post), or b: 
use something like my example so your dll ends up in the same directory 
as your exe.

Ryan

-- 
Ryan Pavlik
HCI Graduate Student
Virtual Reality Applications Center
Iowa State University

rpavlik at iastate.edu
http://academic.cleardefinition.com



More information about the CMake mailing list