added a QT_WRAP_CPP command

This commit is contained in:
Ian Scott 2001-10-15 14:19:53 -04:00
parent b6158ac39c
commit 3a316a6e0a
4 changed files with 274 additions and 49 deletions

104
CMake.rtf
View File

@ -1,11 +1,16 @@
{\rtf1\ansi\ansicpg1252\uc1 \deff0\deflang1033\deflangfe1033{\fonttbl{\f0\froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f2\fmodern\fcharset0\fprq1{\*\panose 02070309020205020404}Courier New;}
{\f3\froman\fcharset2\fprq2{\*\panose 05050102010706020507}Symbol;}{\f14\fnil\fcharset2\fprq2{\*\panose 05000000000000000000}Wingdings;}{\f23\froman\fcharset128\fprq1{\*\panose 00000000000000000000}MS Mincho{\*\falt MS ??};}
{\f3\froman\fcharset2\fprq2{\*\panose 05050102010706020507}Symbol;}{\f14\fnil\fcharset2\fprq2{\*\panose 05000000000000000000}Wingdings;}{\f23\fmodern\fcharset128\fprq1{\*\panose 02020609040205080304}MS Mincho{\*\falt MS ??};}
{\f28\fswiss\fcharset128\fprq2{\*\panose 020b0604020202020204}Arial Unicode MS;}{\f29\fswiss\fcharset0\fprq2{\*\panose 020b0604030504040204}Verdana;}{\f30\fmodern\fcharset128\fprq1{\*\panose 02020609040205080304}@MS Mincho;}
{\f31\fswiss\fcharset128\fprq2{\*\panose 00000000000000000000}@Arial Unicode MS;}{\f56\froman\fcharset238\fprq2 Times New Roman CE;}{\f57\froman\fcharset204\fprq2 Times New Roman Cyr;}{\f59\froman\fcharset161\fprq2 Times New Roman Greek;}
{\f60\froman\fcharset162\fprq2 Times New Roman Tur;}{\f61\froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\f62\froman\fcharset178\fprq2 Times New Roman (Arabic);}{\f63\froman\fcharset186\fprq2 Times New Roman Baltic;}
{\f72\fmodern\fcharset238\fprq1 Courier New CE;}{\f73\fmodern\fcharset204\fprq1 Courier New Cyr;}{\f75\fmodern\fcharset161\fprq1 Courier New Greek;}{\f76\fmodern\fcharset162\fprq1 Courier New Tur;}{\f77\fmodern\fcharset177\fprq1 Courier New (Hebrew);}
{\f78\fmodern\fcharset178\fprq1 Courier New (Arabic);}{\f79\fmodern\fcharset186\fprq1 Courier New Baltic;}{\f288\fswiss\fcharset238\fprq2 Verdana CE;}{\f289\fswiss\fcharset204\fprq2 Verdana Cyr;}{\f291\fswiss\fcharset161\fprq2 Verdana Greek;}
{\f292\fswiss\fcharset162\fprq2 Verdana Tur;}{\f295\fswiss\fcharset186\fprq2 Verdana Baltic;}}{\colortbl;\red0\green0\blue0;\red0\green0\blue255;\red0\green255\blue255;\red0\green255\blue0;\red255\green0\blue255;\red255\green0\blue0;
{\f31\fswiss\fcharset128\fprq2{\*\panose 00000000000000000000}@Arial Unicode MS;}{\f36\froman\fcharset238\fprq2 Times New Roman CE;}{\f37\froman\fcharset204\fprq2 Times New Roman Cyr;}{\f39\froman\fcharset161\fprq2 Times New Roman Greek;}
{\f40\froman\fcharset162\fprq2 Times New Roman Tur;}{\f41\froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\f42\froman\fcharset178\fprq2 Times New Roman (Arabic);}{\f43\froman\fcharset186\fprq2 Times New Roman Baltic;}
{\f52\fmodern\fcharset238\fprq1 Courier New CE;}{\f53\fmodern\fcharset204\fprq1 Courier New Cyr;}{\f55\fmodern\fcharset161\fprq1 Courier New Greek;}{\f56\fmodern\fcharset162\fprq1 Courier New Tur;}{\f57\fmodern\fcharset177\fprq1 Courier New (Hebrew);}
{\f58\fmodern\fcharset178\fprq1 Courier New (Arabic);}{\f59\fmodern\fcharset186\fprq1 Courier New Baltic;}{\f222\fmodern\fcharset0\fprq1 MS Mincho Western{\*\falt MS ??};}{\f220\fmodern\fcharset238\fprq1 MS Mincho CE{\*\falt MS ??};}
{\f221\fmodern\fcharset204\fprq1 MS Mincho Cyr{\*\falt MS ??};}{\f223\fmodern\fcharset161\fprq1 MS Mincho Greek{\*\falt MS ??};}{\f224\fmodern\fcharset162\fprq1 MS Mincho Tur{\*\falt MS ??};}
{\f227\fmodern\fcharset186\fprq1 MS Mincho Baltic{\*\falt MS ??};}{\f262\fswiss\fcharset0\fprq2 Arial Unicode MS Western;}{\f260\fswiss\fcharset238\fprq2 Arial Unicode MS CE;}{\f261\fswiss\fcharset204\fprq2 Arial Unicode MS Cyr;}
{\f263\fswiss\fcharset161\fprq2 Arial Unicode MS Greek;}{\f264\fswiss\fcharset162\fprq2 Arial Unicode MS Tur;}{\f265\fswiss\fcharset177\fprq2 Arial Unicode MS (Hebrew);}{\f266\fswiss\fcharset178\fprq2 Arial Unicode MS (Arabic);}
{\f267\fswiss\fcharset186\fprq2 Arial Unicode MS Baltic;}{\f268\fswiss\fcharset238\fprq2 Verdana CE;}{\f269\fswiss\fcharset204\fprq2 Verdana Cyr;}{\f271\fswiss\fcharset161\fprq2 Verdana Greek;}{\f272\fswiss\fcharset162\fprq2 Verdana Tur;}
{\f275\fswiss\fcharset186\fprq2 Verdana Baltic;}{\f278\fmodern\fcharset0\fprq1 @MS Mincho Western;}{\f276\fmodern\fcharset238\fprq1 @MS Mincho CE;}{\f277\fmodern\fcharset204\fprq1 @MS Mincho Cyr;}{\f279\fmodern\fcharset161\fprq1 @MS Mincho Greek;}
{\f280\fmodern\fcharset162\fprq1 @MS Mincho Tur;}{\f283\fmodern\fcharset186\fprq1 @MS Mincho Baltic;}}{\colortbl;\red0\green0\blue0;\red0\green0\blue255;\red0\green255\blue255;\red0\green255\blue0;\red255\green0\blue255;\red255\green0\blue0;
\red255\green255\blue0;\red255\green255\blue255;\red0\green0\blue128;\red0\green128\blue128;\red0\green128\blue0;\red128\green0\blue128;\red128\green0\blue0;\red128\green128\blue0;\red128\green128\blue128;\red192\green192\blue192;}{\stylesheet{
\ql \li1170\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin1170\itap0 \fs24\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 \snext0 Normal;}{\s1\ql \li1170\ri-720\keepn\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin1170\itap0
\b\fs36\ul\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 \sbasedon0 \snext0 heading 1;}{\s2\ql \li1170\ri-720\keepn\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin1170\itap0 \b\fs28\lang1033\langfe1033\cgrid\langnp1033\langfenp1033
@ -120,8 +125,8 @@
\listoverridecount0\ls8}{\listoverride\listid908342481\listoverridecount0\ls9}{\listoverride\listid1336492021\listoverridecount0\ls10}{\listoverride\listid1592200748\listoverridecount0\ls11}{\listoverride\listid1724867039\listoverridecount0\ls12}
{\listoverride\listid2012557743\listoverridecount0\ls13}{\listoverride\listid563219625\listoverridecount0\ls14}{\listoverride\listid1023172156\listoverridecount0\ls15}{\listoverride\listid1652054978\listoverridecount0\ls16}{\listoverride\listid1431699610
\listoverridecount0\ls17}{\listoverride\listid330572609\listoverridecount0\ls18}{\listoverride\listid489949201\listoverridecount0\ls19}{\listoverride\listid1987126501\listoverridecount0\ls20}{\listoverride\listid114103099\listoverridecount0\ls21}}{\info
{\title CMake Documentation}{\author Ken Martin}{\operator Ken Martin}{\creatim\yr2001\mo6\dy7\hr15\min36}{\revtim\yr2001\mo9\dy20\hr11\min51}{\printim\yr2000\mo11\dy2\hr9\min34}{\version14}{\edmins152}{\nofpages14}{\nofwords4251}{\nofchars24231}
{\*\company Kitware Inc.}{\nofcharsws0}{\vern8247}}\widowctrl\ftnbj\aendnotes\aftnstart0\hyphhotz0\aftnnar\noxlattoyen\expshrtn\noultrlspc\dntblnsbdb\nospaceforul\lytprtmet\hyphcaps0\horzdoc\dghspace180\dgvspace180\dghorigin1701\dgvorigin1984\dghshow0
{\title CMake Documentation}{\author Ken Martin}{\operator ISBE}{\creatim\yr2001\mo6\dy7\hr15\min36}{\revtim\yr2001\mo10\dy15\hr17\min6}{\printim\yr2000\mo11\dy2\hr9\min34}{\version15}{\edmins280}{\nofpages15}{\nofwords4483}{\nofchars25555}
{\*\company Kitware Inc.}{\nofcharsws31383}{\vern8247}}\widowctrl\ftnbj\aendnotes\aftnstart0\hyphhotz0\aftnnar\noxlattoyen\expshrtn\noultrlspc\dntblnsbdb\nospaceforul\lytprtmet\hyphcaps0\horzdoc\dghspace180\dgvspace180\dghorigin1701\dgvorigin1984\dghshow0
\dgvshow0\jexpand\viewkind1\viewscale75\pgbrdrhead\pgbrdrfoot\bdrrlswsix\nolnhtadjtbl \fet0\sectd \linex0\endnhere\sectdefaultcl {\*\pnseclvl1\pnucrm\pnstart1\pnindent720\pnhang{\pntxta .}}{\*\pnseclvl2\pnucltr\pnstart1\pnindent720\pnhang{\pntxta .}}
{\*\pnseclvl3\pndec\pnstart1\pnindent720\pnhang{\pntxta .}}{\*\pnseclvl4\pnlcltr\pnstart1\pnindent720\pnhang{\pntxta )}}{\*\pnseclvl5\pndec\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}{\*\pnseclvl6\pnlcltr\pnstart1\pnindent720\pnhang{\pntxtb (}
{\pntxta )}}{\*\pnseclvl7\pnlcrm\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}{\*\pnseclvl8\pnlcltr\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}{\*\pnseclvl9\pnlcrm\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}\pard\plain
@ -4812,24 +4817,24 @@ your own commands. In addition, the advanced user can add other makefile generat
\par }\pard \qj \li0\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin0\itap0 {You can download and install precompiled binaries of CMake for Windows and UNIX from }{\field\flddirty{\*\fldinst { HYPERLINK "http://public.kitware.com/CMake" }{
{\*\datafield
00d0c9ea79f9bace118c8200aa004ba90b02000000170000002000000068007400740070003a002f002f007000750062006c00690063002e006b006900740077006100720065002e0063006f006d002f0043004d0061006b0065000000e0c9ea79f9bace118c8200aa004ba90b4000000068007400740070003a002f002f00
7000750062006c00690063002e006b006900740077006100720065002e0063006f006d002f0043004d0061006b0065000000000000000000}}}{\fldrslt {\cs16\ul\cf2 http://public.kitware.com/CMake}}}{
7000750062006c00690063002e006b006900740077006100720065002e0063006f006d002f0043004d0061006b006500000000000000000000}}}{\fldrslt {\cs16\ul\cf2 http://public.kitware.com/CMake}}}{
. If you want to build CMake yourself, you can download the source code using CVS (available at }{\field\flddirty{\*\fldinst { HYPERLINK "http://cvshome.org" }{{\*\datafield
00d0c9ea79f9bace118c8200aa004ba90b02000000170000001300000068007400740070003a002f002f0063007600730068006f006d0065002e006f00720067000000e0c9ea79f9bace118c8200aa004ba90b2800000068007400740070003a002f002f0063007600730068006f006d0065002e006f00720067002f000000
000000000000}}}{\fldrslt {\cs16\ul\cf2 http://cvshome.org}}}{) and typing:
00000000000000}}}{\fldrslt {\cs16\ul\cf2 http://cvshome.org}}}{) and typing:
\par }\pard\plain \s23\ql \li0\ri0\sb100\sa100\sbauto1\saauto1\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 \f29\fs18\cf1\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {\b cvs -d :pserver:anonymous@public.kitware.com:/CMake/cvsroot login}{
\line (respond with password cmake)
\par Follow this command by checking out the source code:\line }{\b cvs -d :pserver:anonymous@public.kitware.com:/CMake/cvsroot co CMake}{
\par }\pard\plain \s22\ql \li0\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin0\itap0 \fs24\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {
\par }\pard\plain \qj \li0\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin0\itap0 \fs24\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {Then you can build CMake on Windows by loading the CMake/Source/CMakeSetup.dsw fil
e into Microsoft Visual Studio, then selecting CMakeSetup and the active project and building. On UNIX you can build and install CMake by running:
\par }\pard\plain \qj \li0\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin0\itap0 \fs24\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {Then you can build CMake on Windows by loading the CMake/Source/CMakeSetup.ds
w file into Microsoft Visual Studio, then selecting CMakeSetup and the active project and building. On UNIX you can build and install CMake by running:
\par }\pard \ql \li0\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin0\itap0 {
\par cd CMake
\par ./configure
\par make
\par make install
\par
\par On UNIX, if you are not using the GNU C++ compiler, you need to tell configure which compiler you want to use. This is done by setting the environment variable
CXX before running configure. If you need to use any special flags with your compiler use the CXXFLAGS variable.
\par On UNIX, if you are not using the GNU C++ compiler, you need to
tell configure which compiler you want to use. This is done by setting the environment variable CXX before running configure. If you need to use any special flags with your compiler use the CXXFLAGS variable.
\par
\par For example on the SGI with the 7.3X compiler, you build like this:
\par cd CMake
@ -4845,11 +4850,11 @@ CXX before running configure. If you need to use any special flags with your c
\par }\pard \ql \li0\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin0\itap0 {
\par }\pard\plain \s3\ql \li0\ri-720\keepn\widctlpar\aspalpha\aspnum\faauto\outlinelevel2\adjustright\rin-720\lin0\itap0 \b\fs24\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {Running CMake for Windows / Microsoft Visual C++ (MSVC)
\par }\pard\plain \ql \li0\ri-720\widctlpar\tx0\aspalpha\aspnum\faauto\adjustright\rin-720\lin0\itap0 \fs24\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {
\par }\pard \qj \li0\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin0\itap0 {Run CMakeSetup.exe which shoul
d be in your Start menu under Program Files, there may also be a shortcut on your desktop. A GUI will appear similar to what is shown below (but possibly different as CMake is still being developed). The top two entries are the source code and binary dire
c
tories. They allow you to specify where the source code is for what you want to compile and where the resulting binaries should be placed. You should set these two values first. If the binary directory you specify does not exist, it will be created for yo
u. The Build for option, allows you to select which type of build files are generated. Currently, on windows, visual studio 6 and Borland makefiles are supported.
\par }\pard \qj \li0\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin0\itap0 {Run CMakeSetup.exe which should be in your Start menu under Pro
gram Files, there may also be a shortcut on your desktop. A GUI will appear similar to what is shown below (but possibly different as CMake is still being developed). The top two entries are the source code and binary directories. They allow you to specif
y
where the source code is for what you want to compile and where the resulting binaries should be placed. You should set these two values first. If the binary directory you specify does not exist, it will be created for you. The Build for option, allows
you to select which type of build files are generated. Currently, on windows, visual studio 6 and Borland makefiles are supported.
\par
\par
\par
@ -15979,13 +15984,12 @@ ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80808040404005000000070101000000030000000000}}}{
\par }\pard \qj \li810\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin810\itap0 {
\par }\pard \qj \li0\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin0\itap0 {The cache values area is where you can specify differe
nt options for the build process. The example shown below is for VTK which has a large number of options. Once you have specified the source code and binary directories you should click the Configure button. This will cause CMake to read in the CMakeLists
.
txt files from the source code directory and the cache area to be updated to display any new options for the project. Adjust your cache settings if desired and click the Configure button again. New values that were caused by the configure process will be
c
olored red. To be sure you have seen all possible values you should click Configure until no values are red and your are happy with all the settings. Once you are done configuring, click the OK button, this will produce Microsoft Visual C++ workspaces
and exit CMakeSetup.exe.
\par }\pard \qj \li0\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin0\itap0 {The cache values area is where you can specify different options for the build process.
The example shown below is for VTK which has a large number of options. Once you have specified the source code and binary directories you should click the Configure button. This will cause CMake to read in the CMakeLists.txt files from the source code d
i
rectory and the cache area to be updated to display any new options for the project. Adjust your cache settings if desired and click the Configure button again. New values that were caused by the configure process will be colored red. To be sure you hav
e seen all possible values you should click Configure until no values are red and your are happy with all the settings. Once you are done configuring, click the OK button, this will produce Microsoft Visual C++ workspaces and exit CMakeSetup.exe.
\par
\par CMakeSetup.exe generates a MSVC workspace file in the binary directory you specified. Typically this file has the same name as what you are compiling (e.g. VTK.dsp, ITK.dsw etc).
\par The next step in this process is to open the workspace with MSVC. Once open, the project can be built in the normal manner of Microsoft Visual C++. The ALL_BUILD target can be used to build all of the libraries and executables in the package.
@ -16216,40 +16220,42 @@ ame PATH|NAME|EXT|NAME_WE) Set VarName to be the path (PATH), file name (NAME),
INCLUDE(file1 [OPTIONAL]) If OPTIONAL is present, then do not complain if the file does not exist.
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b INCLUDE_DIRECTORIES}{ - Add include directories to the build. \line }{\i Usage:}{ INCLUDE_DIRECTORIES(dir1 dir2 ...)
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b INCLUDE_REGULAR_EXPRESSION}{ - Set the regular expression used for dependency checking. \line }{\i Usage:}{
INCLUDE_REGULAR_EXPRESSION(regex_match [regex_complain]) Set the regular expressions used in dependency checking. Only files matching
regex_match will be traced as dependencies. Only files matching regex_complain will generate warnings if they cannot be found (standard header paths are not searched). The defaults are: regex_match = "^.*$" (match everything) regex_complain = "^$" (match
empty string only)
INCLUDE_REGULAR_EXPRESSION(regex_match [regex_complain]) Set the regular expressions used in dependency checking. Only files
matching regex_match will be traced as dependencies. Only files matching regex_complain will generate warnings if they cannot be found (standard header paths are not searched). The defaults are: regex_match = "^.*$" (match everything) regex_complain = "^
$" (match empty string only)
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b INSTALL_FILES}{ - Create install rules for files \line }{\i Usage:}{
INSTALL_FILES(path extension srclist file file srclist ...) INSTALL_FILES(path regexp) Create rules to install the listed files into the path. Path is relative to the variable CMA
KE_INSTALL_PREFIX. There are two forms for this command. In the first the files can be specified explicitly or by referenceing source lists. All files must either have the extension specified or exist with the extension appended. A typical extension is .h
etc... In the second form any files in the current directory that match the regular expression will be installed.
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b INSTALL_PROGRAMS}{ - Create install rules for programs \line }{\i Usage:}{ INSTALL_PROGRAMS(path file file ...) INSTALL_PROGRAMS(path regexp) Create rules
to install the listed programs into the path. Path is relative to the variable CMAKE_INSTALL_PREFIX. There are two forms for this command. In the first the programs can be specified explicitly. In the second form any program in the current directory that
match the regular expression will be installed.
INSTALL_FILES(path extension srclist file file srclist ...) INSTALL_FILES(path regexp) Create rules to install the listed files into the path. Path is relative to the var
iable CMAKE_INSTALL_PREFIX. There are two forms for this command. In the first the files can be specified explicitly or by referenceing source lists. All files must either have the extension specified or exist with the extension appended. A typical extens
ion is .h etc... In the second form any files in the current directory that match the regular expression will be installed.
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b INSTALL_PROGRAMS}{ - Create install rules for programs \line }{\i Usage:}{ INSTALL_PROGRAMS(path file file ...) INSTALL_PROGRAMS(path regexp) Cre
ate rules to install the listed programs into the path. Path is relative to the variable CMAKE_INSTALL_PREFIX. There are two forms for this command. In the first the programs can be specified explicitly. In the second form any program in the current direc
tory that match the regular expression will be installed.
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b INSTALL_TARGETS}{ - Create install rules for targets \line }{\i Usage:}{
INSTALL_TARGETS(path target target) Create rules to install the listed targets into the path. Path is relative to the variable PREFIX
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b LINK_DIRECTORIES}{ - Specify link directories. \line }{\i Usage:}{
LINK_DIRECTORIES(directory1 directory2 ...) Specify the paths to the libraries that will be linked in. The directories can use built in definitions like CMAKE_BINARY_DIR and CMAKE_SOURCE_DIR.
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b LINK_LIBRARIES}{ - Specify a list of libraries to be linked into executables or shared objects. \line }{\i Usage:}{
LINK_LIBRARIES(library1 library2 ...) Specify a list of libraries to be linked into executables or shared objects. This command is passed down to all other commands. The debu
g and optimized strings may be used to indicate that the next library listed is to be used only for that specific type of build
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b LOAD_CACHE}{ - load in the values from another cache. \line }{\i Usage:}{ LOAD_CACHE(pathToCacheFile [EXCLUDE entry1...] [INCLUDE_INTERNALS
entry1...]) Load in the values from another cache. This is useful for a project that depends on another project built in a different tree.EXCLUDE option can be used to provide a list of entries to be included.INCLUDE_INTERNALS can be used to provide a lis
t of internal entriesto be included. Normally, no internal entries are brougt in.
LINK_LIBRARIES(library1 library2 ...) Specify a list of libraries to be linked into executables or shared objects. This command is passed down to all other commands.
The debug and optimized strings may be used to indicate that the next library listed is to be used only for that specific type of build
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b LOAD_CACHE}{ - load in the values from another cache. \line }{\i Usage:}{ LOAD_CACHE(pathToCacheFile [EXCLUDE entry1...] [INCLUDE_I
NTERNALS entry1...]) Load in the values from another cache. This is useful for a project that depends on another project built in a different tree.EXCLUDE option can be used to provide a list of entries to be included.INCLUDE_INTERNALS can be used to prov
ide a list of internal entriesto be included. Normally, no internal entries are brougt in.
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b MAKE_DIRECTORY}{ - Create a directory in the build tree if it does not exist. Parent directories will be created if the do not exist.. \line }{\i Usage:}{ MAKE_DIRECTORY(directory)
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b MESSAGE}{ - Display a message to the user. \line }{\i Usage:}{
MESSAGE("the message to display" "Title for dialog") The first argument is the message to display. The second argument is optional and is the title for the dialog box on windows.
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b OPTION}{ - Provides an option that the user can optionally select \line }{\i Usage:}{
OPTION(USE_MPI "help string decribing the option" [initial value]) Provide an option for the user to select
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b OUTPUT_REQUIRED_FILES}{ - Output a list of required source files for a specified source file. \line }{\i Usage:}{ OUTP
UT_REQUIRED_FILES(srcfile outputfile) Outputs a list of all the source files that are required by the specified srcfile. This list is written into outputfile. This is similar to writing out the dependencies for srcfile except that it jumps from .h files i
nto .cxx, .c and .cpp files if possible.
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b OUTPUT_REQUIRED_FILES}{ - Output a list of required source files for a specified source file. \line }{\i Usage:}{
OUTPUT_REQUIRED_FILES(srcfile outputfile) Outputs a list of all the source files that are required by the specified srcfile. This list is written into outputfile. This is similar to writing out the dependencies for srcfile except that it jumps from .h
files into .cxx, .c and .cpp files if possible.
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b PROJECT}{ - Set a name for the entire project. One argument. \line }{\i Usage:}{
PROJECT(projectname) Sets the name of the Microsoft workspace .dsw file. Does nothing on UNIX currently
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b QT_WRAP_CPP}{ - Create QT moc files and add to the library.\line }{\i Usage:}{ QT_WRAP_CPP(libraryname DestName SourceLists\'85) }{Produce moc files for all the .h fi}{
le listed in the SourceLists. }{The moc files will be added to th}{e library using the DestName }{source list.}{ \line
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b SET}{ - Set a CMAKE variable to a value \line }{\i Usage:}{
SET(VAR [VALUE] [CACHE TYPE DOCSTRING]) Within CMAKE sets VAR to the value VALUE. VALUE is expanded before VAR is set to it. If CACHE is present, then the VAR is put in the cache. TYPE and DOCSTRING are required. If TYPE is INTERNAL, then the VALUE i
s Always written into the cache, replacing any values existing in the cache. If it is not a CACHE VAR, then this always writes into the current makefile.
SET(VAR [VALUE] [CACHE TYPE DOCSTRING]) Within CMAKE sets VAR to the value VALUE. VALUE is expanded before VAR is set to it. If CACHE is present, then the VAR is put in the cache. TYPE and DOCSTRING are required. If TYPE is INTERNAL, then th
e VALUE is Always written into the cache, replacing any values existing in the cache. If it is not a CACHE VAR, then this always writes into the current makefile.
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b SITE_NAME}{ - Set a CMAKE variable to the name of this computer. \line }{\i Usage:}{ SITE_NAME(NAME) Within CMAKE sets NAME to the host name of the computer.
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b SOURCE_FILES}{ - Add a list of source files, associate them with a NAME. \line }{\i Usage:}{ SOURCE_FILES(NAME file1 file2 ...)
\par {\listtext\pard\plain\f3\fs20 \loch\af3\dbch\af0\hich\f3 \'b7\tab}}{\b SOURCE_FILES_REMOVE}{ - Remove a list of source files - associated with NAME. \line }{\i Usage:}{ SOURCE_FILES_REMOVE(NAME file1 file2 ...)
@ -16291,14 +16297,14 @@ eGenerator (defined in cmMakefileGenerator.h/.cxx). Makefile generators process
\par }\pard \ql \li0\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin0\itap0 {
\par }\pard\plain \s1\ql \li0\ri-720\keepn\widctlpar\aspalpha\aspnum\faauto\outlinelevel0\adjustright\rin-720\lin0\itap0 \b\fs36\ul\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {Further Information
\par }\pard\plain \ql \li0\ri-720\widctlpar\aspalpha\aspnum\faauto\adjustright\rin-720\lin0\itap0 \fs24\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {Much of the development of CMake was performed at Kitware }{\field{\*\fldinst {
HYPERLINK "http://www.kitware.com/" }{{\*\datafield 00d0c9ea79f9bace118c8200aa004ba90b0200000003000000e0c9ea79f9bace118c8200aa004ba90b3000000068007400740070003a002f002f007700770077002e006b006900740077006100720065002e0063006f006d002f000000000000000000}}
HYPERLINK "http://www.kitware.com/" }{{\*\datafield 00d0c9ea79f9bace118c8200aa004ba90b0200000003000000e0c9ea79f9bace118c8200aa004ba90b3000000068007400740070003a002f002f007700770077002e006b006900740077006100720065002e0063006f006d002f00000000000000000000}}
}{\fldrslt {\cs16\ul\cf2 http://www.kitware.com/}}}{. The developers can be reached at }{\field{\*\fldinst { HYPERLINK "mailto:kitware@kitware.com" }{{\*\datafield
00d0c9ea79f9bace118c8200aa004ba90b0200000003000000e0c9ea79f9bace118c8200aa004ba90b360000006d00610069006c0074006f003a006b0069007400770061007200650040006b006900740077006100720065002e0063006f006d000000000000000000}}}{\fldrslt {\cs16\ul\cf2
00d0c9ea79f9bace118c8200aa004ba90b0200000003000000e0c9ea79f9bace118c8200aa004ba90b360000006d00610069006c0074006f003a006b0069007400770061007200650040006b006900740077006100720065002e0063006f006d00000000000000000000}}}{\fldrslt {\cs16\ul\cf2
mailto:kitware@kitware.com}}}{. CMake was initially developed for the NIH/NLM Insight Segmentation and Registration Toolkit, see the Web site at }{\field{\*\fldinst {HYPERLINK "http://public.kitware.com/Insight.html"}{{\*\datafield
00d0c9ea79f9bace118c8200aa004ba90b0200000003000000e0c9ea79f9bace118c8200aa004ba90b4e00000068007400740070003a002f002f007000750062006c00690063002e006b006900740077006100720065002e0063006f006d002f0049006e00730069006700680074002e00680074006d006c00000000000000
0000}}}{\fldrslt {\cs16\ul\cf2 http://public.kitware.com/Insight.html}}}{. Cmake\rquote s web page can be found at }{\field{\*\fldinst { HYPERLINK "http://public.kitware.com/CMake" }{{\*\datafield
000000}}}{\fldrslt {\cs16\ul\cf2 http://public.kitware.com/Insight.html}}}{. Cmake\rquote s web page can be found at }{\field{\*\fldinst { HYPERLINK "http://public.kitware.com/CMake" }{{\*\datafield
00d0c9ea79f9bace118c8200aa004ba90b02000000170000002000000068007400740070003a002f002f007000750062006c00690063002e006b006900740077006100720065002e0063006f006d002f0043004d0061006b0065000000e0c9ea79f9bace118c8200aa004ba90b4000000068007400740070003a002f002f00
7000750062006c00690063002e006b006900740077006100720065002e0063006f006d002f0043004d0061006b0065000000000000}}}{\fldrslt {\cs16\ul\cf2 http://public.kitware.com/CMake}}}{.
7000750062006c00690063002e006b006900740077006100720065002e0063006f006d002f0043004d0061006b006500000000000000}}}{\fldrslt {\cs16\ul\cf2 http://public.kitware.com/CMake}}}{.
\par
\par
\par }}

View File

@ -56,6 +56,7 @@
#include "cmVTKWrapJavaCommand.cxx"
#include "cmVTKWrapPythonCommand.cxx"
#include "cmVTKWrapTclCommand.cxx"
#include "cmQTWrapCPPCommand.cxx"
#include "cmWrapExcludeFilesCommand.cxx"
void GetPredefinedCommands(std::list<cmCommand*>& commands)
@ -113,6 +114,7 @@ void GetPredefinedCommands(std::list<cmCommand*>& commands)
commands.push_back(new cmVTKWrapJavaCommand);
commands.push_back(new cmVTKWrapPythonCommand);
commands.push_back(new cmVTKWrapTclCommand);
commands.push_back(new cmQTWrapCPPCommand);
commands.push_back(new cmWrapExcludeFilesCommand);
}

View File

@ -0,0 +1,139 @@
/*=========================================================================
Program: Insight Segmentation & Registration Toolkit
Module: $RCSfile$
Language: C++
Date: $Date$
Version: $Revision$
Author: Ian Scott.
Copyright (c) 2001 Insight Consortium
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
* The name of the Insight Consortium, nor the names of any consortium members,
nor of any contributors, may be used to endorse or promote products derived
from this software without specific prior written permission.
* Modified source versions must be plainly marked as such, and must not be
misrepresented as being the original software.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS ``AS IS''
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
=========================================================================*/
#include "cmQTWrapCPPCommand.h"
// cmQTWrapCPPCommand
bool cmQTWrapCPPCommand::InitialPass(std::vector<std::string> const& args)
{
if(args.size() < 3 )
{
this->SetError("called with incorrect number of arguments");
return false;
}
// Now check and see if the value has been stored in the cache
// already, if so use that value and don't look for the program
if(!m_Makefile->IsOn("QT_WRAP_CPP"))
{
return true;
}
// what is the current source dir
std::string cdir = m_Makefile->GetCurrentDirectory();
// keep the library name
m_LibraryName = args[0];
m_SourceList = args[1];
// get the list of classes for this library
cmMakefile::SourceMap &Classes = m_Makefile->GetSources();
for(std::vector<std::string>::const_iterator j = (args.begin() + 2);
j != args.end(); ++j)
{
cmMakefile::SourceMap::iterator l = Classes.find(*j);
if (l == Classes.end())
{
this->SetError("bad source list passed to QTWrapCPPCommand");
return false;
}
for(std::vector<cmSourceFile>::iterator i = l->second.begin();
i != l->second.end(); i++)
{
cmSourceFile &curr = *i;
// if we should wrap the class
if (!curr.GetWrapExclude())
{
cmSourceFile file;
file.SetIsAnAbstractClass(curr.IsAnAbstractClass());
std::string newName = "moc_" + curr.GetSourceName();
file.SetName(newName.c_str(), m_Makefile->GetCurrentOutputDirectory(),
"cxx",false);
std::string hname = cdir + "/" + curr.GetSourceName() + ".h";
m_WrapHeaders.push_back(hname);
// add starting depends
file.GetDepends().push_back(hname);
m_WrapClasses.push_back(file);
m_OriginalNames.push_back(curr.GetSourceName());
}
}
}
return true;
}
void cmQTWrapCPPCommand::FinalPass()
{
// first we add the rules for all the .h to Java.cxx files
int lastClass = m_WrapClasses.size();
std::vector<std::string> depends;
std::string wjava = "${QT_MOC_EXE}";
// wrap all the .h files
depends.push_back(wjava);
for(int classNum = 0; classNum < lastClass; classNum++)
{
// Add output to build list
m_Makefile->AddSource(m_WrapClasses[classNum],m_SourceList.c_str());
// set up moc command
std::string res = m_WrapClasses[classNum].GetSourceName() + ".cxx";
std::vector<std::string> args;
args.push_back("-o");
args.push_back(res);
args.push_back(m_WrapHeaders[classNum]);
m_Makefile->AddCustomCommand(m_WrapHeaders[classNum].c_str(),
wjava.c_str(), args, depends,
res.c_str(), m_LibraryName.c_str());
}
}

View File

@ -0,0 +1,78 @@
#ifndef cmQTWrapCPPCommand_h
#define cmQTWrapCPPCommand_h
#include "cmStandardIncludes.h"
#include "cmCommand.h"
/** \class cmQTWrapCPPCommand
* \brief Create moc file rules for QT classes
*
* cmQTWrapCPPCommand is used to create wrappers for QT classes into normal C++
*/
class cmQTWrapCPPCommand : public cmCommand
{
public:
/**
* This is a virtual constructor for the command.
*/
virtual cmCommand* Clone()
{
return new cmQTWrapCPPCommand;
}
/**
* This is called when the command is first encountered in
* the CMakeLists.txt file.
*/
virtual bool InitialPass(std::vector<std::string> const& args);
/**
* This is called at the end after all the information
* specified by the command is accumulated. Most commands do
* not implement this method. At this point, reading and
* writing to the cache can be done.
*/
virtual void FinalPass();
/**
* The name of the command as specified in CMakeList.txt.
*/
virtual const char* GetName() { return "QT_WRAP_CPP";}
/**
* Succinct documentation.
*/
virtual const char* GetTerseDocumentation()
{
return "Create QT Wrappers.";
}
/**
* More documentation.
*/
virtual const char* GetFullDocumentation()
{
return
"QT_WRAP_CPP(resultingLibraryName DestName SourceLists ...)\n"
"Produce moc files for all the .h file listed in the SourceLists.\n"
"The moc files will be added to the library using the DestName\n"
"source list.";
}
private:
/**
* List of produced files.
*/
std::vector<cmSourceFile> m_WrapClasses;
/**
* List of header files that pprovide the source for m_WrapClasses.
*/
std::vector<std::string> m_WrapHeaders;
std::vector<std::string> m_OriginalNames;
std::string m_LibraryName;
std::string m_SourceList;
};
#endif