Monday, June 29, 2009

cuda-gdb error on CentOS

CUDA 2.2 comes with its native debugger support through cuda-gdb. However, I had some problems configuring cuda-gdb on my Linux distro (CentOS).
When I execute cuda-gdb fresh after my installation, here's what I see:
$ cuda-gdb
cuda-gdb: error while loading shared libraries: libtermcap.so.2: cannot open shared object file: No such file or directory

I tried searching for the missing library libtermcap.so.2 using
locate libtermcap

A google search led me to http://forums.nvidia.com/index.php?showtopic=96987
and I installed libncurses and linked it correctly.
sudo yum install ncurses.x86_64
sudo ln -s /usr/lib64/libncurses.so /usr/local/cuda/lib/libtermcap.so.2

That seemed to do the trick !!!
$ cuda-gdb
NVIDIA (R) CUDA Debugger
BETA release
Portions Copyright (C) 2008,2009 NVIDIA Corporation
GNU gdb 6.6
Copyright (C) 2006 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "x86_64-unknown-linux-gnu".
(cuda-gdb)

For more info on cuda-gdb refer to: http://developer.download.nvidia.com/compute/cuda/2_2/toolkit/docs/CUDA_GDB_User_Manual_2.2beta.pdf

No comments:

Post a Comment