<font size=2 face="sans-serif">My bad. I forget the address for the mailing
list all the time, and didn't know that would happen.</font>
<br>
<br><font size=2 face="sans-serif">That solution would certainly work,
and might be what I have to use in the future. I was wondering why the
INSTALL(TARGET command cares what directory the target was in? Can't it
just do what is right?</font>
<br>
<br><font size=2 face="sans-serif">-------------------------------------------------------------<br>
Aaron Wright</font>
<br>
<br>
<br>
<br>
<table width=100%>
<tr valign=top>
<td><font size=1 color=#5f5f5f face="sans-serif">From:</font>
<td><font size=1 face="sans-serif">Rolf Eike Beer &lt;eike@sf-mail.de&gt;</font>
<tr valign=top>
<td><font size=1 color=#5f5f5f face="sans-serif">To:</font>
<td><font size=1 face="sans-serif">cmake@cmake.org</font>
<tr valign=top>
<td><font size=1 color=#5f5f5f face="sans-serif">Date:</font>
<td><font size=1 face="sans-serif">07/16/2010 10:10 AM</font>
<tr valign=top>
<td><font size=1 color=#5f5f5f face="sans-serif">Subject:</font>
<td><font size=1 face="sans-serif">Re: [CMake] INSTALL(TARGET ...) Target
not in this folder</font>
<tr valign=top>
<td><font size=1 color=#5f5f5f face="sans-serif">Sent by:</font>
<td><font size=1 face="sans-serif">cmake-bounces@cmake.org</font></table>
<br>
<hr noshade>
<br>
<br>
<br><tt><font size=2>Am Friday 16 July 2010 schrieb Aaron_Wright@selinc.com:<br>
<br>
Please do not reply to a random message to start a new discussion. This
makes <br>
thread sorting appear completely random.<br>
<br>
&gt; I have sort of an interesting directory structure for my projects.
I have<br>
&gt; a folder for libraries, a folder for executables, and a folder for<br>
&gt; packages. The packages folder contains debian packages that combine<br>
&gt; libraries and executables from the other two folders. So they look
sort of<br>
&gt; like:<br>
&gt; <br>
&gt; IF(NOT TARGET executable_a)<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; ADD_SUBDIRECTORY(<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot;${PROJECT_SOURCE_DIR}/../../executables/executable_a&quot;<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot;${CMAKE_BINARY_DIR}/executable_a&quot;)<br>
&gt; ENDIF()<br>
&gt; <br>
&gt; INSTALL(<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; TARGET executable_a<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; DESTINATION bin)<br>
<br>
[...]<br>
<br>
&gt; On a side note, I don't put the INSTALL(TARGET command in executable_a's<br>
&gt; folder because not everyone that ADD_SUBDIRECTORY on that folder wants<br>
&gt; executable_a to be installed. In fact this is the problem I was trying
to<br>
&gt; solve by moving the INSTALL command up a level.<br>
<br>
Why not making that install decision depend on a variable then?<br>
<br>
IF (DO_INSTALL_EXE_A)<br>
 &nbsp; INSTALL(TARGETS ...)<br>
ENDIF ()<br>
<br>
Putting this in the executables directory and setting all the DO_INSTALL_*
<br>
things right in the deb directory should do the trick.<br>
<br>
Eike<br>
[attachment &quot;signature.asc&quot; deleted by Aaron Wright/SEL] _______________________________________________<br>
Powered by </font></tt><a href=www.kitware.com><tt><font size=2>www.kitware.com</font></tt></a><tt><font size=2><br>
<br>
Visit other Kitware open-source projects at </font></tt><a href=http://www.kitware.com/opensource/opensource.html><tt><font size=2>http://www.kitware.com/opensource/opensource.html</font></tt></a><tt><font size=2><br>
<br>
Please keep messages on-topic and check the CMake FAQ at: </font></tt><a href=http://www.cmake.org/Wiki/CMake_FAQ><tt><font size=2>http://www.cmake.org/Wiki/CMake_FAQ</font></tt></a><tt><font size=2><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
</font></tt><a href=http://www.cmake.org/mailman/listinfo/cmake><tt><font size=2>http://www.cmake.org/mailman/listinfo/cmake</font></tt></a>
<br>