<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html; charset=ISO-8859-1"
 http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#ffffff">
Don't pass a full path to install(TARGETS - a relative path is needed
to install in the specified prefix.<br>
Use this instead:<br>
install(TARGETS cmakehello01<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; RUNTIME DESTINATION bin)<br>
<br>
On 02/15/2010 07:25 AM, Dmitry wrote:
<blockquote
 cite="mid:e66209d31002150525w45679b5fwb3fff622187fff72@mail.gmail.com"
 type="cite">Hello!<br>
I've started using CMake not long ago, I'm not very familiar with it
yet. I need to generate a package with CMake, but when I try to do it,
I get empty packages. This is my CMakeLists.txt file (just a simple
"hello, world" application of a single .cpp file):<br>
  <br>
==============================<br>
cmake_minimum_required( VERSION 2.6 )<br>
project( cmakehello01 )<br>
  <br>
set( hello_SRCS hello.cpp )<br>
add_executable( cmakehello01 ${hello_SRCS} )<br>
  <br>
install(TARGETS cmakehello01 DESTINATION /usr/share/bin)<br>
  <br>
INCLUDE(CPack)<br>
==============================<br>
  <br>
I run:<br>
mkdir build<br>
cd build<br>
cmake ..<br>
make<br>
sudo make install<br>
sudo make package<br>
  <br>
and
after that I always get three empty packages (.sh, .tar.gz and .Z).
What am I doing wrong? I've spent a couple of hours to figure it out,
and still have no idea. I've tried to set various CPACK_xxx variables (<a
 moz-do-not-send="true"
 href="http://www.cmake.org/Wiki/CMake:Packaging_With_CPack"
 target="_blank">http://www.cmake.org/Wiki/CMake:Packaging_With_CPack</a>,
  <a moz-do-not-send="true"
 href="http://www.cmake.org/Wiki/CMake:CPackConfiguration"
 target="_blank">http://www.cmake.org/Wiki/CMake:CPackConfiguration</a>):
it seems they have no effect at all. But, afaik, it's not necessary,
since CPack script generates reasonable default values for them. I feel
like I've missed something obvious...<br>
  <br>
I'm working on Fedora 11, <br>
$ cmake --version<br>
cmake version 2.6-patch 4<br>
  <br>
Thanks.
  <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Powered by <a class="moz-txt-link-abbreviated" href="http://www.kitware.com">www.kitware.com</a>

Visit other Kitware open-source projects at <a class="moz-txt-link-freetext" href="http://www.kitware.com/opensource/opensource.html">http://www.kitware.com/opensource/opensource.html</a>

Please keep messages on-topic and check the CMake FAQ at: <a class="moz-txt-link-freetext" href="http://www.cmake.org/Wiki/CMake_FAQ">http://www.cmake.org/Wiki/CMake_FAQ</a>

Follow this link to subscribe/unsubscribe:
<a class="moz-txt-link-freetext" href="http://www.cmake.org/mailman/listinfo/cmake">http://www.cmake.org/mailman/listinfo/cmake</a></pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">-- 
Ryan Pavlik
HCI Graduate Student
Virtual Reality Applications Center
Iowa State University

<a class="moz-txt-link-abbreviated" href="mailto:rpavlik@iastate.edu">rpavlik@iastate.edu</a>
<a class="moz-txt-link-freetext" href="http://academic.cleardefinition.com">http://academic.cleardefinition.com</a>
Internal VRAC/HCI Site: <a class="moz-txt-link-freetext" href="http://tinyurl.com/rpavlik">http://tinyurl.com/rpavlik</a></pre>
</body>
</html>