<HTML>
<HEAD>
<TITLE>Re: [Insight-users] Problem of Cmake &install ITK</TITLE>
</HEAD>
<BODY>
<FONT FACE="Verdana"><SPAN STYLE='font-size:12.0px'>Hi Luis,<BR>
<BR>
You are right, when I download and install the cmake 2.03, it is not what I used before, the Cmake 1.80 have a gui ,even for my Mac, so I copy the Cmake 1.80 that I have in other computer.<BR>
That cause the problem.<BR>
<BR>
I type which cmake and cmake —version . The result is tcsh :cmake: command not found.<BR>
<BR>
Here is the CheckIncludefile.cmake<BR>
<BR>
CheckIncludeFile.cmake 80%#<BR>
# Check if the include file exists.<BR>
#<BR>
# CHECK_INCLUDE_FILE - macro which checks the include file exists.<BR>
# INCLUDE - name of include file<BR>
# VARIABLE - variable to return result<BR>
#<BR>
<BR>
MACRO(CHECK_INCLUDE_FILE INCLUDE VARIABLE)<BR>
IF("${VARIABLE}" MATCHES "^${VARIABLE}$")<BR>
SET(MACRO_CHECK_INCLUDE_FILE_FLAGS ${CMAKE_REQUIRED_FLAGS})<BR>
SET(CHECK_INCLUDE_FILE_VAR ${INCLUDE})<BR>
CONFIGURE_FILE(${CMAKE_ROOT}/Modules/CheckIncludeFile.c.in<BR>
${CMAKE_BINARY_DIR}/CMakeTmp/CheckIncludeFile.c IMMEDIATE)<BR>
MESSAGE(STATUS "Looking for ${INCLUDE}")<BR>
IF(${ARGC} EQUAL 3)<BR>
SET(CMAKE_C_FLAGS_SAVE ${CMAKE_C_FLAGS})<BR>
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${ARGV2}")<BR>
ENDIF(${ARGC} EQUAL 3)<BR>
<BR>
TRY_COMPILE(${VARIABLE}<BR>
${CMAKE_BINARY_DIR}<BR>
${CMAKE_BINARY_DIR}/CMakeTmp/CheckIncludeFile.c<BR>
CMAKE_FLAGS <BR>
-DCOMPILE_DEFINITIONS:STRING=${MACRO_CHECK_INCLUDE_FILE_FLAGS}<BR>
OUTPUT_VARIABLE OUTPUT) <BR>
<BR>
IF(${ARGC} EQUAL 3)<BR>
SET(CMAKE_C_FLAGS ${CMAKE_C_FLAGS_SAVE})<BR>
ENDIF(${ARGC} EQUAL 3)<BR>
<BR>
IF(${VARIABLE})<BR>
MESSAGE(STATUS "Looking for ${INCLUDE} - found")<BR>
SET(${VARIABLE} 1 CACHE INTERNAL "Have include ${INCLUDE}")<BR>
FILE(APPEND ${CMAKE_BINARY_DIR}/CMakeOutput.log <BR>
"Determining if the include file ${INCLUDE} "<BR>
"exists passed with the following output:\n"<BR>
"${OUTPUT}\n\n")<BR>
ELSE(${VARIABLE})<BR>
MESSAGE(STATUS "Looking for ${INCLUDE} - not found.")<BR>
SET(${VARIABLE} "" CACHE INTERNAL "Have include ${INCLUDE}")<BR>
FILE(APPEND ${CMAKE_BINARY_DIR}/CMakeError.log <BR>
"Determining if the include file ${INCLUDE} "<BR>
"exists failed with the following output:\n"<BR>
"${OUTPUT}\n\n")<BR>
ENDIF(${VARIABLE})<BR>
ENDIF("${VARIABLE}" MATCHES "^${VARIABLE}$")<BR>
ENDMACRO(CHECK_INCLUDE_FILE)<BR>
~<BR>
<BR>
Thank a lot!<BR>
<BR>
How I can uninstall the Cmake 2.0 ?<BR>
<BR>
yingli <BR>
<BR>
<BR>
<BR>
<BR>
On 8/19/04 20:07, "Luis Ibanez" <luis.ibanez@kitware.com> wrote:<BR>
<BR>
</SPAN></FONT><BLOCKQUOTE><SPAN STYLE='font-size:12.0px'><FONT FACE="Monaco"><TT><BR>
<BR>
Hi Yingli,<BR>
<BR>
It seems that your installation of CMake is getting a mix<BR>
of files between versions 1.8 and 2.0.<BR>
<BR>
<BR>
The file that is reporting the error:<BR>
<BR>
usr/local.share/Cmake/Modules/CheckIncludeFile.cmake:16<BR>
<BR>
Should actually have "ARGC" instead of just "ARG".<BR>
<BR>
<BR>
It seems that you tried to install CMake 1.8 on top of<BR>
CMake 2.0 and now you have an mix of both.<BR>
<BR>
<BR>
<BR>
<BR>
Could you please do the following:<BR>
<BR>
1) type the command:<BR>
<BR>
which cmake<BR>
<BR>
and post to the list the result that you get<BR>
<BR>
<BR>
2) then type the command:<BR>
<BR>
cmake --version<BR>
<BR>
and post to the list the output that you get.<BR>
<BR>
<BR>
3) Then, send us your file<BR>
<BR>
usr/local.share/Cmake/Modules/CheckIncludeFile.cmake<BR>
<BR>
<BR>
<BR>
<BR>
Thanks<BR>
<BR>
<BR>
Luis<BR>
<BR>
<BR>
<BR>
<BR>
-------------------------<BR>
yingli fan wrote:<BR>
<BR>
> Hi all,<BR>
> <BR>
> I try to install the ITK. When I use Cmake to generate the make file of <BR>
> ITK.<BR>
> <BR>
> Here is an error<BR>
> Cmake Error :Error in cmakecode at <BR>
> usr/local.share/Cmake/Modules/CheckIncludeFile.cmake:16:IF An IF command <BR>
> had incorrect arguments: $ { ARG} EQUAl 3<BR>
> <BR>
> Here is what I did:<BR>
> 1 download the ITK release 1.6.0(because the machine is panther version <BR>
> of Mac, I succeed installing ITK before with this release).<BR>
> 2 generate a new binary folder<BR>
> 3 download the Cmake : here I download release 2.0.3. (Actually with my <BR>
> successful experience, last time I use Cmake release 1.8.0. ) After I <BR>
> install the cmake 2.03 , I cant install the cmake 1.8.0, who can help <BR>
> me to uninstall the Cmake 2.0.3.<BR>
> <BR>
> Thank you for help!<BR>
> <BR>
> Yingli fan<BR>
> <BR>
> <BR>
> ------------------------------------------------------------------------<BR>
> <BR>
> _______________________________________________<BR>
> Insight-users mailing list<BR>
> <FONT COLOR="#0000FF"><U>Insight-users@itk.org<BR>
</U></FONT>> <FONT COLOR="#0000FF"><U><a href="http://www.itk.org/mailman/listinfo/insight-users">http://www.itk.org/mailman/listinfo/insight-users</a><BR>
</U></FONT><BR>
<BR>
<BR>
<BR>
</TT></FONT></SPAN></BLOCKQUOTE><SPAN STYLE='font-size:12.0px'><FONT FACE="Monaco"><TT><BR>
</TT></FONT><FONT FACE="Verdana"><BR>
<FONT COLOR="#0000FF">*******************************************************<BR>
Yingli Fan<BR>
</FONT></FONT><FONT COLOR="#0000FF"><FONT FACE="Monaco"><TT>Laboratory for Bioimaging and Anatomical Informatics<BR>
</TT></FONT><FONT FACE="Verdana">Department of Neurobiology & Anatomy<BR>
Drexel University, College of Medicine<BR>
2900 Queen Lane PA 19129<BR>
Tel: 215-9918455 Fax: 215-843-9367<BR>
Email: Yingli.Fan@drexel.edu <BR>
*******************************************************<BR>
</FONT></FONT><FONT FACE="Verdana"><BR>
</FONT></SPAN>
</BODY>
</HTML>