[CMake] FindLibrary only looks for lib under Windows

2010-09-14 Thread emeplease
Hi, I have modified the FindAPR.cmake module to look for the APR library 
under Windows.


Using Find_Library ,
the library that it should look for is "libapr-1.dll" , however, cmake 
fails to find it. If I change the name from  "libapr-1.dll" to 
"libapr-1.lib" , CMake can successfully locate it.


I am using CMake 2.8 with Visual Studio Express 2008


The structure is like



IF(WIN32)
SET(APR_INCLUDE_SEARCH_PATH ${CMAKE_SOURCE_DIR}/ 
SET(APR_LIB_SEARCH_PATH ${CMAKE_SOURCE_DIR}/...
ELSE(WIN32)

ENDIF(WIN32)




It then looks for the library by

FIND_LIBRARY( APR_LIBRARY NAMES ${APR_NAMES} PATHS ${APR_LIB_SEARCH_PATH} )




Many thanks
John




___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake


Re: [CMake] CTest: Cannot find any coverage files. Ignoring Coverage request.

2010-08-25 Thread emeplease

Thank you David, my issue is solved.
It's because the SET( CMAKE_CXX_FLAGS ) inside CTest script has no effect ,
instead, I need to insert lines into

   SET (CTEST_INITIAL_CACHE "
   ...
   )


Also, I mistakenly override the CMAKE_CXX_FLAGS in the root CMakeList.txt


Regards,
Joseph
On 08/25/2010 10:54 PM, hgc-01...@hkedcity.net wong wrote:

Hi, David , Thank you for your quick reply.

  I am so sorry to have missed this important detail :  cmake-2.6.4-7.el5.
  I am trying to get the coverage report by running  -S script,   the
  script basically
  works by  "ctest -D NighlyBuild,  ctest -D NightlyCoverage" ...

  I have noticed that the executable built by cmake does not generate
  any coverage
  files like ".gcof" .  But during compilation, it does show that it's
  compiling and linking with -fprofile-arcs and  -ftest-coverage.


   

2010/8/25 David Cole:
 

How are you running ctest to try to get the coverage reported?
With -D NightlyCoverage?
With a -S script?

What version of ctest?

On Wed, Aug 25, 2010 at 3:31 AM, emeplease  wrote:
   


Hi,  I am going to enable coverage test in my project,

I have enabled the following compile options:

---
CXXFLAGS="-g -O0 -Wall -Wshadow \
  -Wunused-function -Wunused -Wno-system-headers \
  -Wno-deprecated -Woverloaded-virtual -Wwrite-strings -fprofile-arcs \
  -ftest-coverage" \
CFLAGS="-g -O0 -Wall -W -fprofile-arcs -ftest-coverage" \
LDFLAGS="-fprofile-arcs -ftest-coverage" \

---

Inside DartConfiguration.tcl :
CoverageCommand: /usr/bin/gcov


---
Inside CMakeCache.txt :
COVERAGE_COMMAND:FILEPATH=/usr/bin/gcov


---



However, I am not able to use coverage test:

Performing coverage
  Cannot find any coverage files. Ignoring Coverage request.



Thank you very much.


Regards,
Joseph


___
Powered by www.kitware.com

Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at:
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake
 


   
 


___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake


[CMake] CTest: Cannot find any coverage files. Ignoring Coverage request.

2010-08-25 Thread emeplease



Hi,  I am going to enable coverage test in my project,

I have enabled the following compile options:
---
CXXFLAGS="-g -O0 -Wall -Wshadow \
 -Wunused-function -Wunused -Wno-system-headers \
 -Wno-deprecated -Woverloaded-virtual -Wwrite-strings -fprofile-arcs \
 -ftest-coverage" \
CFLAGS="-g -O0 -Wall -W -fprofile-arcs -ftest-coverage" \
LDFLAGS="-fprofile-arcs -ftest-coverage" \
---

Inside DartConfiguration.tcl :
CoverageCommand: /usr/bin/gcov

---
Inside CMakeCache.txt :
COVERAGE_COMMAND:FILEPATH=/usr/bin/gcov

---



However, I am not able to use coverage test:

Performing coverage
 Cannot find any coverage files. Ignoring Coverage request.



Thank you very much.


Regards,
Joseph


___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake