<table cellspacing="0" cellpadding="0" border="0" ><tr><td valign="top" style="font: inherit;"><DIV>Hi,<BR><BR> The 'ctest' version I am using is "ctest version 2.6-patch 3"<BR> The files of my sample project and their contents are as follows :<BR><BR> [girish@ps0485 CTEST]$ ls<BR> CMakeLists.txt CTestConfig.cmake ctestrun.ctest test.cpp<BR></DIV>
<DIV> test.cpp : is a simple c++ program.</DIV>
<DIV><BR> Contents of CMakeLists.txt :<BR> cmake_minimum_required (VERSION 2.6)<BR> ADD_EXECUTABLE (a.out test.cpp)<BR> ENABLE_TESTING ()<BR> INCLUDE(CTest)<BR> ADD_TEST (a.out /home/girish/CTEST/a.out)<BR><BR> Contents of CTestConfig.cmake :<BR> set(PROJECT_NAME "VALG1")<BR> set(CTEST_NIGHTLY_START_TIME "15:59:00 IST")<BR> set(CTEST_DROP_METHOD "http")<BR> set(CTEST_DROP_SITE "<A href="http://my.cdash.org/" target=_blank><SPAN class=yshortcuts id=lw_1264776372_0>my.cdash.org</SPAN></A>")<BR> set(CTEST_DROP_LOCATION "/submit.php?project=VALG1")<BR> set(CTEST_DROP_SITE_CDASH TRUE)<BR><BR> Contents of ctestrun.ctest :<BR> #ctest_memcheck(BUILD “${CTEST_BINARY_DIRECTORY}”)<BR> #set(CTEST_MEMORYCHECK_COMMAND "/usr/bin/valgrind")<BR>
#set(CTEST_MEMORYCHECK_COMMAND_OPTIONS "--log-file=vlogs --leak-check=full --xml=yes")<BR> SET(CTEST_SOURCE_DIRECTORY "$ENV{HOME}/CTEST/")<BR> SET(CTEST_BINARY_DIRECTORY "${CTEST_SOURCE_DIRECTORY}/")<BR> SET(CTEST_CMAKE_GENERATOR "@CMAKE_GENERATOR@")<BR> SET(CTEST_BUILD_COMMAND "/usr/bin/make")<BR> CTEST_START("Experimental")<BR> CTEST_CONFIGURE(BUILD "${CTEST_BINARY_DIRECTORY}")<BR> CTEST_BUILD(BUILD "${CTEST_BINARY_DIRECTORY}")<BR> CTEST_TEST(BUILD "${CTEST_BINARY_DIRECTORY}")<BR> CTEST_SUBMIT()<BR><BR> I am giving commands in the following sequence :<BR> * cmake .<BR> * make<BR> * ctest -S ctestrun.ctest<BR> Output of this last command is :<BR> Error(s) when updating the project<BR> Error when uploading file:
/home/girish/CTEST/Testing/20100129-1229/Build.xml<BR> <SPAN class=yshortcuts id=lw_1264776372_1 style="CURSOR: hand; BORDER-BOTTOM: #0066cc 1px dashed">Error message</SPAN> was: couldn't connect to host<BR> Problems when submitting via HTTP<BR><BR> I tried to check with 'netstat -atn' and shows me below line :<BR> (tcp 0 1 10.88.88.143:34869 66.194.253.26:80 SYN_SENT)<BR><BR> If I uncomment first 3 lines in ctestrun.ctest and give this command then it gives me <SPAN class=yshortcuts id=lw_1264776372_2 style="CURSOR: hand; BORDER-BOTTOM: #0066cc 1px dashed">Segmentation fault</SPAN>.<BR> * ctest -S ctestrun.ctest <----- Segmentation fault.<BR><BR>
Can you please let me know,<BR> * why its not able to connect to HTTP port of my.cdash.org?<BR> * why its crashing when I uncomment lines related to 'valgrind'?<BR><BR>Regards,<BR>Girish <BR><BR>--- On <B>Thu, 1/28/10, Bill Hoffman <I><bill.hoffman@kitware.com></I></B> wrote:<BR></DIV>
<BLOCKQUOTE style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: rgb(16,16,255) 2px solid"><BR>From: Bill Hoffman <bill.hoffman@kitware.com><BR>Subject: Re: [Cdash] ctest, valgrind and cdash<BR>To: "girish hilage" <girish_hilage@yahoo.com><BR>Cc: cdash@public.kitware.com<BR>Date: Thursday, January 28, 2010, 3:24 PM<BR><BR>
<DIV class=plainMail>girish hilage wrote:<BR>> Hi Bill,<BR>> Thanks for your reply.<BR>> I tried this. But 'ctest' gave me a Segmentation Fault.<BR>> The backtrace is as follows :<BR>> <BR><BR>What version of ctest?<BR><BR>Also, exactly what input did you give to ctest? My example was not complete. Here is a more complete example:<BR><BR>SET(CTEST_SOURCE_DIRECTORY "$ENV{HOME}/My Builds/CMake/Tests/Tutorial/Step7")<BR>SET(CTEST_BINARY_DIRECTORY "${CTEST_SOURCE_DIRECTORY}-build2")<BR>SET(CTEST_CMAKE_GENERATOR "Visual Studio 8 2005")<BR>CTEST_START("Experimental")<BR>CTEST_CONFIGURE(BUILD "${CTEST_BINARY_DIRECTORY}")<BR>CTEST_BUILD(BUILD "${CTEST_BINARY_DIRECTORY}")<BR>CTEST_TEST(BUILD "${CTEST_BINARY_DIRECTORY}")<BR>CTEST_SUBMIT()<BR><BR><BR>> (gdb) bt<BR>> #0 0x082b2115 in cmsys::SystemTools::SplitPathRootComponent(char const*, std::string*) ()<BR>> #1
0x082b2fb3 in cmsys::SystemTools::SplitPath(char const*, std::vector<std::string, std::allocator<std::string> >&, bool) ()<BR>> #2 0x082b3473 in cmsys::SystemTools::CollapseFullPath(char const*, char const*) ()<BR>> #3 0x082b3781 in cmsys::SystemTools::CollapseFullPath(char const*) ()<BR>> #4 0x08121caa in cmCTestHandlerCommand::InitialPass(std::vector<std::string, std::allocator<std::string> > const&, cmExecutionStatus&) ()<BR>> #5 0x080f1671 in cmCommand::InvokeInitialPass(std::vector<cmListFileArgument, std::allocator<cmListFileArgument> > const&, cmExecutionStatus&) ()<BR>> #6 0x08166597 in cmMakefile::ExecuteCommand(cmListFileFunction const&, cmExecutionStatus&) ()<BR>> #7 0x0816752b in cmMakefile::ReadListFile(char const*, char const*, std::string*, bool) ()<BR>> #8 0x080ed1b7 in
cmCTestScriptHandler::ReadInScript(std::string const&) ()<BR>> #9 0x080f0b11 in cmCTestScriptHandler::RunConfigurationScript(std::string const&, bool) ()<BR>> #10 0x080f0f40 in cmCTestScriptHandler::ProcessHandler() ()<BR>> #11 0x080bb096 in cmCTest::Run(std::vector<std::string, std::allocator<std::string> >&, std::string*) ()<BR>> #12 0x080ac28b in main ()<BR>> (gdb)<BR>> <BR>> Regards,<BR>> Girish<BR>> <BR>> --- On *Thu, 1/28/10, Bill Hoffman /<<A href="http://us.mc576.mail.yahoo.com/mc/compose?to=bill.hoffman@kitware.com" ymailto="mailto:bill.hoffman@kitware.com">bill.hoffman@kitware.com</A>>/* wrote:<BR>> <BR>> <BR>> From: Bill Hoffman <<A href="http://us.mc576.mail.yahoo.com/mc/compose?to=bill.hoffman@kitware.com" ymailto="mailto:bill.hoffman@kitware.com">bill.hoffman@kitware.com</A>><BR>> Subject: Re: [Cdash] ctest,
valgrind and cdash<BR>> To: "girish hilage" <<A href="http://us.mc576.mail.yahoo.com/mc/compose?to=girish_hilage@yahoo.com" ymailto="mailto:girish_hilage@yahoo.com">girish_hilage@yahoo.com</A>><BR>> Cc: <A href="http://us.mc576.mail.yahoo.com/mc/compose?to=cdash@public.kitware.com" ymailto="mailto:cdash@public.kitware.com">cdash@public.kitware.com</A><BR>> Date: Thursday, January 28, 2010, 1:37 PM<BR>> <BR>> You are mixing ctest scripting with cmake scripting.<BR>> <BR>> The cmake file should just build and run the tests:<BR>> cmake_minimum_required (VERSION 2.6)<BR>> ENABLE_TESTING ()<BR>> INCLUDE(CTest)<BR>> ADD_TEST (a.out /home/girish/a.out)<BR>> <BR>> <BR>> Then in
a separate file CTestConfig.cmake, this stuff:<BR>> <BR>> set(PROJECT_NAME "VALG1")<BR>> set(NIGHTLY_START_TIME "00:00:00 EST")<BR>> set(DROP_METHOD "http")<BR>> set(DROP_SITE "my.cdash.org")<BR>> set(DROP_LOCATION "/submit.php?project=VALG1")<BR>> set(DROP_SITE_CDASH TRUE)<BR>> <BR>> <BR>> Then in yet another file:<BR>> ctestrun.ctest<BR>> # this script also needs to configure and build the project<BR>> ctest_memcheck(BUILD ${CTEST_BINARY_DIRECTORY})<BR>> set(CTEST_MEMORYCHECK_COMMAND "/usr/bin/valgrind")<BR>> set(CTEST_MEMORYCHECK_COMMAND_OPTIONS "--log-file=vlogs<BR>> --leak-check=full
--xml=yes")<BR>> <BR>> <BR>> ctest -S ctestrun.ctest<BR>> <BR>> girish hilage wrote:<BR>> > Hi,<BR>> > I am using ctest, cdash for the first time.<BR>> > I do not have any code to build.<BR>> > I only want to run test on some executable a.out using valgrind<BR>> and see the results on my.cdash.org.<BR>> > I have created file 'CMakeLists.txt' :<BR>> > cmake_minimum_required (VERSION 2.6)<BR>> > ENABLE_TESTING ()<BR>> > set(PROJECT_NAME "VALG1")<BR>> > set(NIGHTLY_START_TIME "00:00:00 EST")<BR>> > set(DROP_METHOD "http")<BR>> > set(DROP_SITE "my.cdash.org")<BR>>
> set(DROP_LOCATION "/submit.php?project=VALG1")<BR>> > set(DROP_SITE_CDASH TRUE)<BR>> > INCLUDE(CTest)<BR>> > ADD_TEST (a.out /home/girish/a.out)<BR>> > When I run 'ctest -D Experimental', I get the following output.<BR>> > ----- OUTPUT START -----<BR>> > [girish@ps0485 CTEST]$ ctest -D Experimental<BR>> > Site: ps0485.persistent.co.in<BR>> > Build name: Linux-c++<BR>> > Create new tag: 20100127-1055 - Experimental<BR>> > Start processing tests<BR>> > Configure project<BR>> > Each . represents 1024 bytes of output<BR>> > . Size of output: 0K<BR>> > Build
project<BR>> > Each symbol represents 1024 bytes of output.<BR>> > '!' represents an error and '*' a warning.<BR>> > Size of output: 0K<BR>> > 0 Compiler errors<BR>> > 0 Compiler warnings<BR>> > Test project /home/girish/CTEST<BR>> > 1/ 1 Testing a.out Passed<BR>> > 100% tests passed, 0 tests failed out of 1<BR>> > Performing coverage<BR>> > Cannot find any coverage files. Ignoring Coverage request.<BR>> > Submit files (using http)<BR>> > Using HTTP submit method<BR>> > Drop site: <A href="http://my.cdash.org/submit.php?project=VALG1" target=_blank>http://my.cdash.org/submit.php?project=VALG1</A><BR>>
> Uploaded: /home/girish/CTEST/Testing/20100127-1055/Build.xml<BR>> > Uploaded: /home/girish/CTEST/Testing/20100127-1055/Configure.xml<BR>> > Uploaded: /home/girish/CTEST/Testing/20100127-1055/Test.xml<BR>> > Using HTTP trigger method<BR>> > Trigger site:<BR>> <A href="http://my.cdash.org/cgi-bin/Submit-Random-TestingResults.cgi" target=_blank>http://my.cdash.org/cgi-bin/Submit-Random-TestingResults.cgi</A><BR>> > Dart server triggered...<BR>> > Submission successful<BR>> > ----- OUTPUT END -----<BR>> > I have created a project VALG1 on my.cdash.org.<BR>> > But, after I run the above command; I do not see any results on<BR>> the page <A
href="http://my.cdash.org/index.php?project=VALG1" target=_blank>http://my.cdash.org/index.php?project=VALG1</A>.<BR>> > Now, if I have a CMakeLists.txt as follows :<BR>> > cmake_minimum_required (VERSION 2.6)<BR>> > ENABLE_TESTING ()<BR>> > INCLUDE(CTest)<BR>> > ADD_TEST (a.out /home/girish/a.out)<BR>> > and CTestConfig.cmake as follows :<BR>> > set(CTEST_PROJECT_NAME "VALG1")<BR>> > set(CTEST_NIGHTLY_START_TIME "15:59:00 IST")<BR>> > set(CTEST_DROP_METHOD "http")<BR>> > set(CTEST_DROP_SITE "my.cdash.org")<BR>> > set(CTEST_DROP_LOCATION "/submit.php?project=VALG1")<BR>> > set(CTEST_DROP_SITE_CDASH TRUE)<BR>> >
ctest_memcheck(BUILD “${CTEST_BINARY_DIRECTORY}â€)<BR>> > set(CTEST_MEMORYCHECK_COMMAND "/usr/bin/valgrind")<BR>> > set(CTEST_MEMORYCHECK_COMMAND_OPTIONS "--log-file=vlogs<BR>> --leak-check=full --xml=yes")<BR>> > and if I give the command 'cmake .' then it gives me following<BR>> error :<BR>> > ----- OUTPUT START -----<BR>> > .......<BR>> > .......<BR>> > -- Detecting CXX compiler ABI info<BR>> > -- Detecting CXX compiler ABI info - done<BR>> > CMake Error at CTestConfig.cmake:9 (ctest_memcheck):<BR>> > Unknown CMake command "ctest_memcheck".<BR>> > Call Stack (most recent call first):<BR>>
> /usr/share/cmake/Modules/CTest.cmake:50 (INCLUDE)<BR>> > CMakeLists.txt:14 (INCLUDE)<BR>> > -- Configuring incomplete, errors occurred!<BR>> > ----- OUTPUT END -----<BR>> > So, I would like to know :<BR>> > 1. What I need to do in order to see the results on my.cdash.org?<BR>> > 2. Why is it saying Unknown CMake command "ctest_memcheck"?<BR>> > 3. How do I make 'valgrind' run on the test?<BR>> > Regards,<BR>> > Girish<BR>> ><BR>> ><BR>> ><BR>> ><BR>> ------------------------------------------------------------------------<BR>>
><BR>> > _______________________________________________<BR>> > Cdash mailing list<BR>> > <A href="http://us.mc576.mail.yahoo.com/mc/compose?to=Cdash@public.kitware.com" ymailto="mailto:Cdash@public.kitware.com">Cdash@public.kitware.com</A><BR>> <<A href="http://us.mc576.mail.yahoo.com/mc/compose?to=Cdash@public.kitware.com" target=_blank>http://us.mc576.mail.yahoo.com/mc/compose?to=Cdash@public.kitware.com</A>><BR>> > <A href="http://public.kitware.com/cgi-bin/mailman/listinfo/cdash" target=_blank>http://public.kitware.com/cgi-bin/mailman/listinfo/cdash</A><BR>> <BR>> <BR>> -- Bill Hoffman<BR>> Kitware, Inc.<BR>> 28 Corporate Drive<BR>> Clifton Park, NY 12065<BR>> <A
href="http://us.mc576.mail.yahoo.com/mc/compose?to=bill.hoffman@kitware.com" ymailto="mailto:bill.hoffman@kitware.com">bill.hoffman@kitware.com</A><BR>> <<A href="http://us.mc576.mail.yahoo.com/mc/compose?to=bill.hoffman@kitware.com" target=_blank>http://us.mc576.mail.yahoo.com/mc/compose?to=bill.hoffman@kitware.com</A>><BR>> <A href="http://www.kitware.com/" target=_blank>http://www.kitware.com</A> <<A href="http://www.kitware.com/" target=_blank>http://www.kitware.com/</A>><BR>> 518 881-4905 (Direct)<BR>> 518 371-3971 x105<BR>> Fax (518) 371-4573<BR>> <BR>> <BR><BR><BR>-- Bill Hoffman<BR>Kitware, Inc.<BR>28 Corporate Drive<BR>Clifton Park, NY 12065<BR><A href="http://us.mc576.mail.yahoo.com/mc/compose?to=bill.hoffman@kitware.com"
ymailto="mailto:bill.hoffman@kitware.com">bill.hoffman@kitware.com</A><BR><A href="http://www.kitware.com/" target=_blank>http://www.kitware.com</A><BR>518 881-4905 (Direct)<BR>518 371-3971 x105<BR>Fax (518) 371-4573<BR></DIV></BLOCKQUOTE></td></tr></table><br>