rbenv で 2.0.0-p0 をインストールする際のエラー解決
問題のエラー
Inspect or clean up the working tree at /tmp/ruby-build.20170221141422.2681 Results logged to /tmp/ruby-build.20170221141422.2681.log Last 10 log lines: ^ ossl_pkey_ec.c:821:29: エラー: ‘EC_GROUP_new_curve_GF2m’ が宣言されていません (この関数内での最初の使用) new_curve = EC_GROUP_new_curve_GF2m; ^ ossl_pkey_ec.c:821:29: 備考: 未宣言の識別子は出現した各関数内で一回のみ報告されます make[2]: *** [ossl_pkey_ec.o] エラー 1 make[2]: ディレクトリ `/tmp/ruby-build.20170221141422.2681/ruby-2.0.0-p0/ext/openssl' から出ます make[1]: *** [ext/openssl/all] エラー 2 make[1]: ディレクトリ `/tmp/ruby-build.20170221141422.2681/ruby-2.0.0-p0' から出ます make: *** [build-ext] エラー 2
環境は CentOS7
Ruby 2.0.0-p247 以前のバージョンを RedHat系の OS にインストールする際に生じるエラーらしい。
解決方法
詳細は rbenv の Wiki に書いてあるけど、パッチを当てる必要があります。
パッチを当てるコマンドは以下の通り。
curl -fsSL "https://github.com/ruby/ruby/commit/0d58bb55985e787364b0235e5e69278d0f0ad4b0.patch" | \ filterdiff -x a/ChangeLog | rbenv install --patch 2.0.0-p0
わざわざブログに書くほどのことかと言われればそうかもしれないけど
Wiki 見る前にググったらあんまり情報なかったので書きました。
現代っ子は敬語を使えないというツイートを読んで、なぜ敬語を使うべきなのか考察してみた
はじめに
お久しぶりです。
最近またブログを書きたいと思っていたので衝動的に書きました。
はじめに書いておきたいのですが、これを書くことは個人を批判する目的ではなく、
あくまで、だから自分は敬語を使うという個人的意見です。
ということをご了承の上お読みください。
目次
問題提起
さて、今回の議題は見かけたこのツイート。
【悲報】現代っ子、敬語が使えない
— ゆきあちゃん@固定ツイ確認お願いします (@yuc1a) 2017年2月18日
【悲報】現代っ子、敬語が使えない
【悲報】現代っ子、敬語が使えない
【悲報】現代っ子、敬語が使えない
【悲報】現代っ子、敬語が使えない
【悲報】現代っ子、敬語が使えない
【悲報】現代っ子、敬語が使えない
【悲報】現代っ子、敬語が使えない pic.twitter.com/s3dzq74srJ
私はゆとり世代なので現代っ子に含まれると認識しています。
私は出身も田舎な上、民度が低い地域でしたので、確かに敬語が使えない(方言もきつい)人が多いと記憶しております(田舎+民度低+ゆとり世代というトリプルコンボ!!)。
そんな環境でおりましたので、前々からこういう問題があると思っていました。
良い機会なので、なぜ敬語を使うのかを考察してみます。
なぜ敬語を使うのか
理由は 2 つあると考えています。
1. これまで社会・会社を支えてきた先輩であるから
若いと、どうしても勝手に大きくなったと考えがちですが、今の社会や会社を作り、支えてきたのは紛れもなく先輩社員の方々です。
先輩社員のこれまでの功績や努力の上に日々の生活を享受している我々が、それを無視して大きな態度をとるべきではないでしょう。
尊敬と感謝の念を込めて敬語を使うべきだと思います。
2. あなたの社内での評価を上げやすくするため
1 の理由だけだと、社畜とか品行方正な奴だと判断されて届けたい人に意見が届かないので、1 の理由とは逆に個人のメリットについて考えてみます。
1 でも書きましたが、会社を作ってきたのは先輩達です。
我々のような新参者はその仲間に入れてもらわなければなりません。
仮に、敬語を使わなかったとします。よほどフラットな社風でもない限り良い顔はされないでしょう。
そんな態度を取っていると先輩と対立するなどして社内に軋轢を生みます。
もし、あなたが仕事ができる新人で、先輩より良い業績を残せたとしても、上司はあなたに高い評価をつけ昇進させることに頭を悩ませることになります。
なぜなら、あなたを昇進させると先輩達は良い顔をしません。社内の空気は悪くなり、ストレスを溜めやすい職場になるかもしれません(上司はそこまで考えて評価を下すものなのです)。
逆に、敬語を使い、仲間として認められていれば、上司は仕事に対して高い評価をつけやすくなります。
敬語を使うことだけで仲間として認められたり、人間関係に関する問題が起こらないとは考えていませんが、敬語を使わないことが社内に軋轢を生む原因の一つにはなり得るでしょう。
相対的に見れば、敬語を使うことで出世しやすくなるわけです。
もし、ここまで読んだ上でどうしても敬語を使いたくない、煩わしいという人は外資系の会社に行きましょう。
まとめ
これまで会社を支えてきた先輩達を敬うのは当然のこととして、敬語を使うことであなた自身も評価されやすくなります。
人間関係でストレスを抱えず、快適に業務を遂行するためにも礼儀正しくいることは、あなたや先輩、上司にとっても良いことだと考えます。
自戒の念も込めて。
上記でも書きましたがあくまで個人的意見なので悪しからず。
参考書籍
個人的に以下の書籍は仕事をする上でかなり参考になりました。
私自身、人間関係は得意ではないです(一人で黙々と仕事していたいタイプです)。
得意ではないからこそ、減点されないために社会人としてのマナーや仕事での正しい自己アピールの方法については知っておくべきだと思います。
ちょっと気をつける・実践すれば良いだけの単純なテクニックも結構あると感じています。
ぜひこの辺から始めましょう。
25歳からの社会人力 「会社から放り出されない人材」になる42カ条
- 作者: 大塚寿
- 出版社/メーカー: PHP研究所
- 発売日: 2014/03/14
- メディア: Kindle版
- この商品を含むブログを見る
Rails 4 で libv8, therubyracer のインストールにエラー発生
Rails 4 のチュートリアルを読んでいて、 libv8, therubyracer のインストール中にエラーが発生した。
実行環境は Ubuntu 12.04 LTS。
そもそも、チュートリアルの 1.2.5章で、javascript ランタイムがないから rails server がコケるという問題が前置きです。
gem install libv8 -v '3.16.14.7'
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
/home/ryu/.rvm/rubies/ruby-2.0.0-p598/bin/ruby -r ./siteconf20141212-26865-flicop.rb extconf.rb
creating Makefile
Compiling v8 for ia32
Using python 2.7.3
Using compiler: /usr/bin/c++ (GCC version 4.6)
/home/ryu/.rvm/gems/ruby-2.0.0-p598@railstutorial_rails_4_0/gems/libv8-3.16.14.7/ext/libv8/builder.rb:28:in `make_flags': undefined method `include?' for nil:NilClass (NoMethodError)
from /home/ryu/.rvm/gems/ruby-2.0.0-p598@railstutorial_rails_4_0/gems/libv8-3.16.14.7/ext/libv8/builder.rb:56:in `block in build_libv8!'
from /home/ryu/.rvm/gems/ruby-2.0.0-p598@railstutorial_rails_4_0/gems/libv8-3.16.14.7/ext/libv8/builder.rb:49:in `chdir'
from /home/ryu/.rvm/gems/ruby-2.0.0-p598@railstutorial_rails_4_0/gems/libv8-3.16.14.7/ext/libv8/builder.rb:49:in `build_libv8!'
from /home/ryu/.rvm/gems/ruby-2.0.0-p598@railstutorial_rails_4_0/gems/libv8-3.16.14.7/ext/libv8/location.rb:24:in `install!'
from extconf.rb:7:in `<main>'
extconf failed, exit code 1
Gem files will remain installed in /home/ryu/.rvm/gems/ruby-2.0.0-p598@railstutorial_rails_4_0/gems/libv8-3.16.14.7 for inspection.
Results logged to /home/ryu/.rvm/gems/ruby-2.0.0-p598@railstutorial_rails_4_0/extensions/x86-linux/2.0.0/libv8-3.16.14.7/gem_make.out
An error occurred while installing libv8 (3.16.14.7), and Bundler cannot continue.
Make sure that `gem install libv8 -v '3.16.14.7'` succeeds before bundling.
調べてみると、どうやら gcc,g++ のバージョンが低い事が問題らしい。
なので、バージョン 4.9 にアップグレードする。
以下アップグレード手順
1. ppa 登録
$ sudo add-apt-repository ppa:ubuntu-toolchain-r/test
2. gcc,g++ インストール
$ sudo apt-get update; sudo apt-get install gcc-4.9 g++-4.9
3. gcc,g++ コマンドのバージョンアップ
$ sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.9 20 $ sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.9 20
4. テスト
$ gcc --version $ g++ --version
バージョンが 4.9.2 になっていれば成功。(執筆時点)
そして再び、therubyracer と libv8 を gem でインストールすれば OK です。
rails server も無事起動しました。
しかし、チュートリアルなのにエラーの難易度が初学者が学ぶには高い気がする笑
参考 URI
Can't compile with gcc-4.9 on OSX · Issue #140 · cowboyd/libv8 · GitHub
金星☆ちゃんねる: C++11のためにGCCの最新版をインストールする
apt-get で 404 エラー発生
apt-get update を実行すると 404 エラーが発生した。
環境は Ubuntu 12.04 LTS
実行結果は以下
$ sudo apt-get update
ヒット http://jp.archive.ubuntu.com precise Release.gpg
ヒット http://jp.archive.ubuntu.com precise-updates Release.gpg
ヒット http://jp.archive.ubuntu.com precise Release
ヒット http://jp.archive.ubuntu.com precise-updates Release
ヒット http://jp.archive.ubuntu.com precise/main Sources
ヒット http://jp.archive.ubuntu.com precise/restricted Sources
ヒット http://jp.archive.ubuntu.com precise/universe Sources
ヒット http://jp.archive.ubuntu.com precise/multiverse Sources
ヒット http://jp.archive.ubuntu.com precise/main i386 Packages
ヒット http://jp.archive.ubuntu.com precise/restricted i386 Packages
ヒット http://jp.archive.ubuntu.com precise/universe i386 Packages
ヒット http://jp.archive.ubuntu.com precise/multiverse i386 Packages
ヒット http://jp.archive.ubuntu.com precise/main TranslationIndex
ヒット http://jp.archive.ubuntu.com precise/multiverse TranslationIndex
ヒット http://jp.archive.ubuntu.com precise/restricted TranslationIndex
ヒット http://jp.archive.ubuntu.com precise/universe TranslationIndex
ヒット http://jp.archive.ubuntu.com precise-updates/main Sources
ヒット http://jp.archive.ubuntu.com precise-updates/restricted Sources
ヒット http://jp.archive.ubuntu.com precise-updates/universe Sources
ヒット http://jp.archive.ubuntu.com precise-updates/multiverse Sources
ヒット http://jp.archive.ubuntu.com precise-updates/main i386 Packages
ヒット http://jp.archive.ubuntu.com precise-updates/restricted i386 Packages
ヒット http://jp.archive.ubuntu.com precise-updates/universe i386 Packages
ヒット http://jp.archive.ubuntu.com precise-updates/multiverse i386 Packages
ヒット http://jp.archive.ubuntu.com precise-updates/main TranslationIndex
ヒット http://jp.archive.ubuntu.com precise-updates/multiverse TranslationIndex
ヒット http://jp.archive.ubuntu.com precise-updates/restricted TranslationIndex
ヒット http://jp.archive.ubuntu.com precise-updates/universe TranslationIndex
ヒット http://jp.archive.ubuntu.com precise/main Translation-ja
ヒット http://jp.archive.ubuntu.com precise/main Translation-en
ヒット http://jp.archive.ubuntu.com precise/multiverse Translation-ja
ヒット http://jp.archive.ubuntu.com precise/multiverse Translation-en
ヒット http://jp.archive.ubuntu.com precise/restricted Translation-ja
ヒット http://jp.archive.ubuntu.com precise/restricted Translation-en
ヒット http://jp.archive.ubuntu.com precise/universe Translation-ja
ヒット http://jp.archive.ubuntu.com precise/universe Translation-en
ヒット http://jp.archive.ubuntu.com precise-updates/main Translation-ja
ヒット http://jp.archive.ubuntu.com precise-updates/main Translation-en
ヒット http://jp.archive.ubuntu.com precise-updates/multiverse Translation-ja
無視 http://ppa.launchpad.net precise Release.gpg
ヒット http://ppa.launchpad.net precise Release.gpg
ヒット http://ppa.launchpad.net precise Release.gpg
ヒット http://ppa.launchpad.net precise Release.gpg
ヒット http://jp.archive.ubuntu.com precise-updates/multiverse Translation-en
ヒット http://jp.archive.ubuntu.com precise-updates/restricted Translation-en
ヒット http://jp.archive.ubuntu.com precise-updates/universe Translation-ja
ヒット http://jp.archive.ubuntu.com precise-updates/universe Translation-en
無視 http://ppa.launchpad.net precise Release
ヒット http://ppa.launchpad.net precise Release
ヒット http://extras.ubuntu.com precise Release.gpg
ヒット http://ppa.launchpad.net precise Release
ヒット http://extras.ubuntu.com precise Release
ヒット http://ppa.launchpad.net precise Release
無視 http://ppa.launchpad.net precise/main Sources/DiffIndex
無視 http://ppa.launchpad.net precise/main i386 Packages/DiffIndex
無視 http://ppa.launchpad.net precise/main TranslationIndex
ヒット http://extras.ubuntu.com precise/main Sources
ヒット http://ppa.launchpad.net precise/main Sources
ヒット http://ppa.launchpad.net precise/main i386 Packages
ヒット http://ppa.launchpad.net precise/main TranslationIndex
ヒット http://extras.ubuntu.com precise/main i386 Packages
無視 http://extras.ubuntu.com precise/main TranslationIndex
ヒット http://ppa.launchpad.net precise/main Sources
ヒット http://ppa.launchpad.net precise/main i386 Packages
無視 http://ppa.launchpad.net precise/main TranslationIndex
ヒット http://ppa.launchpad.net precise/main Sources
ヒット http://ppa.launchpad.net precise/main i386 Packages
無視 http://ppa.launchpad.net precise/main TranslationIndex
ヒット http://ppa.launchpad.net precise/main Translation-en
エラー http://ppa.launchpad.net precise/main Sources
404 Not Found
エラー http://ppa.launchpad.net precise/main i386 Packages
404 Not Found
無視 http://ppa.launchpad.net precise/main Translation-ja_JP
無視 http://ppa.launchpad.net precise/main Translation-ja
無視 http://ppa.launchpad.net precise/main Translation-en
無視 http://ppa.launchpad.net precise/main Translation-ja_JP
無視 http://ppa.launchpad.net precise/main Translation-ja
無視 http://ppa.launchpad.net precise/main Translation-en
無視 http://extras.ubuntu.com precise/main Translation-ja_JP
無視 http://ppa.launchpad.net precise/main Translation-ja_JP
無視 http://extras.ubuntu.com precise/main Translation-ja
無視 http://ppa.launchpad.net precise/main Translation-ja
無視 http://ppa.launchpad.net precise/main Translation-en
無視 http://extras.ubuntu.com precise/main Translation-en
ヒット http://archive.canonical.com precise Release.gpg
ヒット http://archive.canonical.com precise Release
ヒット http://archive.canonical.com precise/partner i386 Packages
ヒット http://archive.canonical.com precise/partner TranslationIndex
ヒット http://archive.canonical.com precise/partner Translation-en
ヒット http://security.ubuntu.com precise-security Release.gpg
ヒット http://security.ubuntu.com precise-security Release
ヒット http://security.ubuntu.com precise-security/main Sources
ヒット http://security.ubuntu.com precise-security/restricted Sources
ヒット http://security.ubuntu.com precise-security/universe Sources
ヒット http://security.ubuntu.com precise-security/multiverse Sources
ヒット http://security.ubuntu.com precise-security/main i386 Packages
ヒット http://security.ubuntu.com precise-security/restricted i386 Packages
ヒット http://security.ubuntu.com precise-security/universe i386 Packages
ヒット http://security.ubuntu.com precise-security/multiverse i386 Packages
ヒット http://security.ubuntu.com precise-security/main TranslationIndex
ヒット http://security.ubuntu.com precise-security/multiverse TranslationIndex
ヒット http://security.ubuntu.com precise-security/restricted TranslationIndex
ヒット http://security.ubuntu.com precise-security/universe TranslationIndex
ヒット http://security.ubuntu.com precise-security/main Translation-en
ヒット http://security.ubuntu.com precise-security/multiverse Translation-en
ヒット http://security.ubuntu.com precise-security/restricted Translation-en
ヒット http://security.ubuntu.com precise-security/universe Translation-en
W: http://ppa.launchpad.net/bikooo/glippy/ubuntu/dists/precise/main/source/Sources の取得に失敗しました 404 Not Found
W: http://ppa.launchpad.net/bikooo/glippy/ubuntu/dists/precise/main/binary-i386/Packages の取得に失敗しました 404 Not Found
E: いくつかのインデックスファイルのダウンロードに失敗しました。これらは無視されるか、古いものが代わりに使われます
重要なのは以下の一文で、どうやらこのパッケージが見つからないらしい
W: http://ppa.launchpad.net/bikooo/glippy/ubuntu/dists/precise/main/binary-i386/Packages の取得に失敗しました 404 Not Found
ppa 関連のダウンロードリストは
/etc/apt/source.d/
配下にあるのでチェック
ls /etc/apt/source.d/
apt-build.list
bikooo-glippy-precise.list.save
ikoinoba-ppa-precise.list
oneiric-partner.list.save
apt-build.list.distUpgrade
clipgrab-team-ppa-precise.list
ikoinoba-ppa-precise.list.save
ubuntu-ja.list apt-build.list.save
clipgrab-team-ppa-precise.list.save
oneiric-partner.list
ubuntu-ja.list.distUpgrade
bikooo-glippy-precise.list
hotot-team-ppa-precise.list
oneiric-partner.list.distUpgrade
ubuntu-ja.list.save
404 のパッケージは bikoo-glippy-precise.list に書いてあるようだ
bikoo-glippy-precise.list を削除し update する
sudo rm bikoo-glippy-precise.list*
sudo apt-get update
すると解決できた
GUIのデスクトップにDesktopディレクトリを割り当てる
Ubuntu 12.04 LTS にて、Desktopディレクトリを誤って rm してしまった。
おかげで、モニターに home ディレクトリのファイルが表示されてしまっている。
モニター画面にDesktopディレクトリ内のファイルを表示させたい。
home 配下のディレクトリ(Desktop,Documents,Pictures,...,etc) は、以下のコンフィグにより設定されるらしい
/home/.config/user-dirs.dirs
このコンフィグファイルは以下のような記述になっている
#Default settings for user directories
#
# The values are relative pathnames from the home directory and
# will be translated on a per-path-element basis into the users locale
DESKTOP=Desktop
DOWNLOAD=Downloads
TEMPLATES=Templates
PUBLICSHARE=Public
DOCUMENTS=Documents
MUSIC=Music
PICTURES=Pictures
VIDEOS=Videos
# Another alternative is:
#MUSIC=Documents/Music
#PICTURES=Documents/Pictures
#VIDEOS=Documents/Videos
今回、DESKTOP=/home となっていたので、DESKTOP=Desktop に書き換えて再起動すると問題を解決できた。
デフォルトに戻したい時は、以下のパスのコンフィグファイルを ./config にコピーするとよい。
/etc/xdg/user-dirs.defaults
Flush Player ローカルストレージの許可ができない
ニコニコ生放送をみていて、 Flush Player設定ができない症状が発生した。
「ローカルストレージに保存する許可を要求しています。」と現れて、「許可」「拒否」のどちらも押せず消えない。
以下のサイトで1もしくは2の処理をすれば消せるみたいです。
- 「すべてのWEBサイトを削除」をクリックし、ローカルに保存されている情報を消す
- 「WEBサイト」の中にある「live.nikovideo.jp」をクリックし、上にあるシークバーを動かし、保存量を「制限なし」に設定する
Adobe - Flash Player:設定マネージャー - Web サイトの記憶領域設定パネル
http://www.macromedia.com/support/documentation/jp/flashplayer/help/settings_manager07.html
私は2の処理で解決しました。
2の方法を書いているブログを見つけられなかったため、解決に時間がかかりました(汗)
似た問題を抱えている人が解決する助けになればと思います。