adonthell-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Adonthell-general] not able to find googletest


From: shirish शिरीष
Subject: [Adonthell-general] not able to find googletest
Date: Tue, 19 Mar 2013 12:12:52 +0530

Hi all,
I have google test installed :-

$ aptitude search libgtest-dev
i A libgtest-dev
    - Google's framework for writing C++ tests - header files

$ dpkg -l libgtest-dev
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name                              Version
Architecture          Description
+++-=================================-=====================-=====================-========================================================================
ii  libgtest-dev                      1.6.0-2               amd64
           Google's framework for writing C++ tests - header files


But when I run :-

http://adonthell.berlios.de/doc/index.php/Development:Compiling#CMake

and specifically :-

cmake -DCMAKE_INSTALL_PREFIX=/home/shirish/games/adonthell/
-DDEVBUILD=1 ../adonthell

I get this :-

 ~/games/adonthell/adonthell-build$ cmake
-DCMAKE_INSTALL_PREFIX=/home/shirish/games/adonthell/ -DDEVBUILD=1
../adonthell
-- The C compiler identification is GNU 4.8.0
-- The CXX compiler identification is GNU 4.7.2
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Adonthell data directory: /home/shirish/games/adonthell/share/games/adonthell
-- Check if the system is big endian
-- Searching 16 bit integer
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for stddef.h
-- Looking for stddef.h - found
-- Check size of unsigned short
-- Check size of unsigned short - done
-- Using unsigned short
-- Check if the system is big endian - little endian
-- SDL 1.2 has been found:
--      CFLAGS : /usr/include/SDL
--      LDFLAGS: -lSDL
-- Found SDL_mixer: /usr/lib/x86_64-linux-gnu/libSDL_mixer.so (found
version "1.2.12")
-- SDL Mixer has been found:
--      CFLAGS : /usr/include/SDL
--      LDFLAGS: /usr/lib/x86_64-linux-gnu/libSDL_mixer.so
-- Found PythonLibs: /usr/lib/x86_64-linux-gnu/libpython2.7.so (found
version "2.7.3")
-- Python has been found:
--      CFLAGS : /usr/include/python2.7
--      LDFLAGS: /usr/lib/x86_64-linux-gnu/libpython2.7.so
-- Found PythonInterp: /usr/bin/python (found version "2.7.3")
--      VERSION: python2.7
--      LDEXTRA: -lm;-lpthread -ldl  -lutil
--      SITEPKG: /usr/lib/python2.7/dist-packages
-- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.7")
-- PNG has been found:
--      CFLAGS : /usr/include/libpng12
--      LDFLAGS: -lpng12
-- Found SWIG: /usr/bin/swig2.0 (found version "2.0.7")
-- SWIG is present on the system.
-- LibXml2 has been found:
--      CFLAGS : /usr/include/libxml2
--      LDFLAGS: -lxml2
-- LibFreetype2 has been found:
--      CFLAGS : -I/usr/include/freetype2
--      LDFLAGS: -lfreetype
-- libglog has been found:
--      CFLAGS :

--      LDFLAGS: -lglog
CMake Error at CMakeLists.txt:322 (message):
  libgtest is required.


-- Configuring incomplete, errors occurred!

I tried to see if maybe the library is not installed properly or
something but it wasn't anything like that :-

$ dpkg -L libgtest-dev
/.
/usr
/usr/src
/usr/src/gtest
/usr/src/gtest/src
/usr/src/gtest/src/gtest-port.cc
/usr/src/gtest/src/gtest-typed-test.cc
/usr/src/gtest/src/gtest-internal-inl.h
/usr/src/gtest/src/gtest_main.cc
/usr/src/gtest/src/gtest-test-part.cc
/usr/src/gtest/src/gtest-printers.cc
/usr/src/gtest/src/gtest.cc
/usr/src/gtest/src/gtest-death-test.cc
/usr/src/gtest/src/gtest-all.cc
/usr/src/gtest/src/gtest-filepath.cc
/usr/src/gtest/CMakeLists.txt
/usr/src/gtest/cmake
/usr/src/gtest/cmake/internal_utils.cmake
/usr/include
/usr/include/gtest
/usr/include/gtest/gtest-spi.h
/usr/include/gtest/gtest-message.h
/usr/include/gtest/gtest-typed-test.h
/usr/include/gtest/gtest_prod.h
/usr/include/gtest/gtest.h
/usr/include/gtest/gtest-printers.h
/usr/include/gtest/gtest-param-test.h.pump
/usr/include/gtest/gtest-death-test.h
/usr/include/gtest/gtest-test-part.h
/usr/include/gtest/internal
/usr/include/gtest/internal/gtest-internal.h
/usr/include/gtest/internal/gtest-type-util.h
/usr/include/gtest/internal/gtest-death-test-internal.h
/usr/include/gtest/internal/gtest-tuple.h.pump
/usr/include/gtest/internal/gtest-param-util-generated.h
/usr/include/gtest/internal/gtest-filepath.h
/usr/include/gtest/internal/gtest-string.h
/usr/include/gtest/internal/gtest-param-util-generated.h.pump
/usr/include/gtest/internal/gtest-type-util.h.pump
/usr/include/gtest/internal/gtest-linked_ptr.h
/usr/include/gtest/internal/gtest-port.h
/usr/include/gtest/internal/gtest-param-util.h
/usr/include/gtest/internal/gtest-tuple.h
/usr/include/gtest/gtest-param-test.h
/usr/include/gtest/gtest_pred_impl.h
/usr/share
/usr/share/doc
/usr/share/doc/libgtest-dev
/usr/share/doc/libgtest-dev/copyright
/usr/share/doc/libgtest-dev/README.gz
/usr/share/doc/libgtest-dev/README.Debian
/usr/share/doc/libgtest-dev/examples
/usr/share/doc/libgtest-dev/examples/samples
/usr/share/doc/libgtest-dev/examples/samples/sample2.h
/usr/share/doc/libgtest-dev/examples/samples/sample10_unittest.cc.gz
/usr/share/doc/libgtest-dev/examples/samples/sample1_unittest.cc.gz
/usr/share/doc/libgtest-dev/examples/samples/sample4_unittest.cc
/usr/share/doc/libgtest-dev/examples/samples/sample4.cc
/usr/share/doc/libgtest-dev/examples/samples/sample5_unittest.cc.gz
/usr/share/doc/libgtest-dev/examples/samples/sample7_unittest.cc.gz
/usr/share/doc/libgtest-dev/examples/samples/prime_tables.h
/usr/share/doc/libgtest-dev/examples/samples/sample9_unittest.cc.gz
/usr/share/doc/libgtest-dev/examples/samples/sample8_unittest.cc.gz
/usr/share/doc/libgtest-dev/examples/samples/sample4.h
/usr/share/doc/libgtest-dev/examples/samples/sample3_unittest.cc.gz
/usr/share/doc/libgtest-dev/examples/samples/sample6_unittest.cc.gz
/usr/share/doc/libgtest-dev/examples/samples/sample2.cc
/usr/share/doc/libgtest-dev/examples/samples/sample1.cc
/usr/share/doc/libgtest-dev/examples/samples/sample2_unittest.cc
/usr/share/doc/libgtest-dev/examples/samples/sample3-inl.h.gz
/usr/share/doc/libgtest-dev/examples/samples/sample1.h
/usr/share/doc/libgtest-dev/examples/make
/usr/share/doc/libgtest-dev/examples/make/Makefile
/usr/share/doc/libgtest-dev/changelog.Debian.gz
/usr/share/doc/libgtest-dev/changelog.gz

As can be seen it's all there.

and the .so files are in :-

$ dpkg -L libgtest0
/.
/usr
/usr/share
/usr/share/doc
/usr/share/doc/libgtest0
/usr/share/doc/libgtest0/copyright
/usr/share/doc/libgtest0/changelog.Debian.gz
/usr/share/doc/libgtest0/changelog.gz
/usr/lib
/usr/lib/libgtest.so.0.0.0
/usr/lib/libgtest_main.so.0.0.0
/usr/lib/libgtest.so.0
/usr/lib/libgtest_main.so.0

I tried to see the message lines to see and came here :-

#############################################################################
# If this is a developer build, turn on testing and check for gtest and gmock
#############################################################################

if(DEVBUILD)
  ENABLE_TESTING()
  PKGCONFIG_FOUND(libgtest LIBGTEST_FOUND)
  IF(LIBGTEST_FOUND)
    PKGCONFIG(libgtest LIBGTEST_INCLUDE_PATH LIBGTEST_LIBADD
LIBGTEST_LIBRARIES LIBGTEST_CFLAGS)
    PKGCONFIG_VERSION(libgtest GLOG_VERSION)
        message(STATUS
          "libgtest has been found:")
        message(STATUS
          "\tCFLAGS : ${LIBGTEST_CFLAGS}")
        message(STATUS
          "\tLDFLAGS: ${LIBGTEST_LIBRARIES}")
  ELSE(LIBGTEST_FOUND)
    message(FATAL_ERROR
      "libgtest is required.")
  ENDIF(LIBGTEST_FOUND)

Maybe I need to add something to my .bashrc as I did earlier :-

#Putting my path variables for the user.

export            PATH="$PATH:$HOME/games/adonthell:/usr/lib/pkgconfig"
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:$HOME/games/adonthell/lib/pkgconfig"
export      
PYTHONPATH=${PYTHONPATH}:$HOME/games/adonthell/lib/python2.7/site-packages/
export 
ADONTHELL_MODULES_PATH=${ADONTHELL_MODULES_PATH}:$HOME/games/adonthell/lib/adonthell/

Any help would be great.
-- 
          Regards,
          Shirish Agarwal  शिरीष अग्रवाल
  My quotes in this email licensed under CC 3.0
http://creativecommons.org/licenses/by-nc/3.0/
http://flossexperiences.wordpress.com
065C 6D79 A68C E7EA 52B3  8D70 950D 53FB 729A 8B17



reply via email to

[Prev in Thread] Current Thread [Next in Thread]