terça-feira, 1 de abril de 2014

C++ - Opening a windows with the man page for the word under the cursor - VIM

How to get help when stay developing in VIM?
Como obter ajuda quando estiver desenvolvendo em VIM?

Put the cursor at the word that you want and click "shift + k", the man page of specific command will open
Coloque o cursor na palavra que deseja e click "shift + k", a página do comando específico irá abri

Is the same that you do in command line:


    man 3 <word>

Section of man page on Unix:


Section
Description
1
General commands
1M
System administration commands and daemons
2
System calls
3
C library functions
4
File formats and conventions
5
Miscellanea
6
Games and screensavers
7
Special files (usually devices, those found in /dev) and drivers







Unix Command - How to see library dependencies of programs? - ldd

Viewing library dependencies of programs in Unix with ldd:

command:

     ldd <path_of_binary>


We would see something like this:


 ldd /bin/grep

        linux-vdso.so.1 =>  (0x00007fffad1ff000)
        libpcre.so.0 => /lib64/libpcre.so.0 (0x00000032fe600000)
        libc.so.6 => /lib64/libc.so.6 (0x00000037eaa00000)
        /lib64/ld-linux-x86-64.so.2 (0x00000037ea600000)




The environment var to load the library is LD_LIBRARY_PATH whether some library was not loaded.