Last active
June 26, 2017 13:58
-
-
Save chooaya/50e7b0ae3eefa341fbba651f23eba938 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# インストールのやり方はこちらのサイトを参考にしました。 | |
# http://blog.csdn.net/shile/article/details/54602768 | |
### まずはbashdbのインストール | |
# osのバージョンを確認 | |
[vagrant@daily bashdb-code]$ cat /etc/redhat-release | |
CentOS release 6.7 (Final) | |
# アーキテクチャ(OSが32bit, 64bitどちらなのか)を確認 | |
[vagrant@daily bashdb-code]$ arch | |
x86_64 | |
# bashのバージョンを確認 | |
[vagrant@daily bashdb-code]$ bash --version | |
GNU bash, version 4.1.2(1)-release (x86_64-redhat-linux-gnu) | |
Copyright (C) 2009 Free Software Foundation, Inc. | |
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> | |
This is free software; you are free to change and redistribute it. | |
There is NO WARRANTY, to the extent permitted by law. | |
# yumが壊れた場合の再インストール | |
# http://takeshiyako.blogspot.jp/2015/06/centosyum.html | |
# sudo rpm -Uhv --force http://vault.centos.org/6.7/os/x86_64/Packages/python-2.6.6-64.el6.x86_64.rpm | |
# sudo rpm -Uhv --force http://vault.centos.org/6.7/os/x86_64/Packages/yum-3.2.29-69.el6.centos.noarch.rpm | |
# bashdbの依存パッケージのインストール(必要の場合のみ) | |
# sudo yum -y install rpm-build texinfo bison | |
# bashのソースコードをダウンロード | |
wget http://vault.centos.org/6.7/os/Source/SPackages/bash-4.1.2-33.el6.src.rpm | |
# 解凍 | |
sudo rpm -ivh bash-4.1.2-33.el6.src.rpm | |
sudo su - | |
cd /root/rpmbuild/SPECS | |
# bashのソースコードのビルド | |
rpmbuild -bp bash.spec | |
# bashのソースコードを移動 | |
cd /root/rpmbuild/BUILD | |
mv bash-4.1 bash-4.1.2-33 | |
mv bash-4.1.2-33 /usr/src | |
cd /usr/src | |
cd bash-4.1.2-33 | |
./configure && make | |
# autoconfのインストール(必要の場合) | |
# http://huzhifeng.github.io/2014/10/08/upgrade-autoconf-on-centos/ | |
# wget http://ftp.gnu.org/gnu/autoconf/autoconf-latest.tar.xz | |
# tar -xf autoconf-latest.tar.xz | |
# cd autoconf-2.69 | |
# ./configure --prefix=/usr | |
# make && make install | |
# libtoolのインストール(必要の場合) http://d.hatena.ne.jp/IT7C/20100815/1281864245 | |
# cd /usr/src | |
# wget http://ftp.gnu.org/gnu/libtool/libtool-2.4.6.tar.gz | |
# tar xvzf libtool-2.4.6.tar.gz | |
# cd libtool-2.4.6 | |
# ./configure --prefix=/usr | |
# make | |
# make install | |
# readlineのインストール(必要の場合) | |
# sudo yum install readline-devel | |
# texi2htmlのインストール(必要の場合) | |
# sudo yum install texi2html | |
# bashdbのダウンロード https://sourceforge.net/projects/bashdb/files/bashdb/4.1-0.5/ | |
cd /usr/src/ | |
tar xvzf bashdb-4.1-0.5.tar.gz | |
cd bashdb-4.1-0.5 | |
# bashdbのインストール | |
touch /usr/missing | |
touch libtoolT | |
###autoreconf -fvi | |
./configure --prefix=/usr --with-bash-src=/usr/src/bash-4.1.2-33 --enable-maintainer-mode | |
make CFLAGS="-O3 -fPIC" | |
make install | |
mkdir /usr/share/bashdb/ | |
ln -s /usr/share/share/bashdb/bashdb-main.inc /usr/share/bashdb/ | |
vi ~/.bash_profile | |
---------------------------------------- | |
MANPATH=/usr/share/man:$MANPATH | |
export MANPATH | |
INFOPATH=/usr/share/info | |
export INFOPATH | |
---------------------------------------- | |
# 使い方 http://d.hatena.ne.jp/ksaito11/20111107/1320679125 | |
bash --debugger yourscript.sh var1 var2 | |
### vscode のインストール http://qiita.com/y-takasuka/items/ad2348bff2c768cf1d1d | |
http://msyksphinz.hatenablog.com/entry/2016/03/26/060000 | |
# | |
### つぎは、bash-support.vimのインストール https://mag.osdn.jp/07/06/13/0134239 | |
# cd /usr/src | |
# git clone https://github.com/vim-scripts/bash-support.vim | |
# cd bash-support.vim | |
The mode has failed while tokenizing the input | |
http://msyksphinz.hatenablog.com/entry/2016/03/26/060000 | |
{ | |
"version": "0.2.0", | |
"configurations": [ | |
{ | |
"name": "Bash-Debug (select script from list of sh files)", | |
"type": "bashdb", | |
"request": "launch", | |
"scriptPath": "${command:SelectScriptName}", | |
"commandLineArguments": "", | |
"windows": { | |
"bashPath": "C:\\Windows\\sysnative\\bash.exe" | |
}, | |
"linux": { | |
"bashPath": "bash" | |
}, | |
"osx": { | |
"bashPath": "bash" | |
} | |
} | |
] | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment