Lesson 7: Packages, Software, Libraries
Homepage | Content | Slides | Video |
Warning
This lesson is under construction. Learn from it at your own risk. If you have any feedback, please fill out our General Feedback Survey.
Homepage | Content | Slides | Video |
Warning
This lesson is under construction. Learn from it at your own risk. If you have any feedback, please fill out our General Feedback Survey.
Everything that isn't hardware.
$ ldd /usr/bin/nano
linux-vdso.so.1 => (0x00007ffc1fdcd000)
libncursesw.so.5 => /lib64/libncursesw.so.5 (0x00007ff2cfaee000)
libtinfo.so.5 => /lib64/libtinfo.so.5 (0x00007ff2cf8c4000)
libc.so.6 => /lib64/libc.so.6 (0x00007ff2cf500000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007ff2cf2fc000)
/lib64/ld-linux-x86-64.so.2 (0x000055e46c4b4000)
Take care of installation and removal of software
.rpm
.deb
Yum
Apt
Examples:
How to install a package from source:
$ sudo yum install git gcc make ncurses-devel
$ git clone https://github.com/mtoyoda/sl.git
$ cd sl
$ make
gcc -O -o sl sl.c -lncurses
$ mkdir -p ~/local/bin
$ cp sl ~/local/bin/
$ echo "export PATH=$HOME/local/bin:$PATH" >> ~/.bashrc
$ source ~/.bashrc
$ whereis sl
sl: /home/dobc/local/bin/sl
$ sl
$ grep --version
grep (GNU grep) 2.20
$ which grep
alias grep='grep --color=auto'
/usr/bin/grep
$ wget http://mirrors.kernel.org/gnu/grep/grep-3.3.tar.xz
$ tar -Jxvf grep-3.3.tar.xz
$ cd grep-3.3
$ ./configure --prefix=$HOME/local/
$ make
$ make install
$ hash -r
$ grep --version
grep (GNU grep) 3.3
$ which grep
alias grep='grep --color=auto'
~/local/bin/grep