2016-12-08 3 views
0

私はgit(https://github.com/atom/atom)からAtomを入手していましたが、しばらく前にバージョン1.5.0-beta0をチェックアウトしました。私はUbuntu 14.04を使っています。ソースからAtomテキストエディタの旧バージョンをビルドしますか?

ここでは、64ビットdebとまったく同じバージョンを作りたいと思います。私はそれは簡単だろうと思ったので、私はちょうどGitのソースフォルダで発行:私/tmp/atom-build/atom-1.5.0-beta0-amd64.debを建て

script/build 
script/grunt mkdeb 

を、私はそれをインストールしたとき、それは私に言った:

/usr/share/atom/atom: error while loading shared libraries: libnotify.so.4: cannot open shared object file: No such file or directory 

...これは私の64ビットシステムであるため、変だった:

$ locate libnotify.so.4 
/usr/lib/x86_64-linux-gnu/libnotify.so.4 
/usr/lib/x86_64-linux-gnu/libnotify.so.4.0.0 

私はそれはおそらく​​のビルドシステムは、32〜64ビットのビルドを区別できないことを、することができない、と思いましたか?しかし、私はLD_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu atomを試したので、それは私にいくつかのエラー(EDIT:おそらくそれは "/usr/share/atom/atom: error while loading shared libraries: libnotify.so.4: wrong ELF class: ELFCLASS64")を教えてくれたので、それは正確にそれに変わりました...

すばらしいです。 [OK]を、今私が最初に掃除しようとした:

.... 
Installing build modules... 
npm ERR! fetch failed https://registry.npmjs.org/minimatch/-/minimatch-0.3.0.tgz 
npm ERR! fetch failed https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.5.0.tgz 
.... 

script/clean 
script/build 

、私は無線ネットワークを介して、ここでビルドをしていた一方で、npm(またはapm)をCOMPLETELY結局のようなメッセージを生成する、私のインターネット接続が詰まっているだろう

この時点で、Firefoxにページを読み込もうとすると、回転していてページが読み込まれなくなりました。

だから、私は、有線に無線から変更し、最終的にこれになった:

atom_git$ script/clean 
atom_git$ script/build 
Node: v4.0.0 
npm: v2.14.2 
Installing build modules... 
=> Took 94239ms. 

Installing apm... 
=> Took 67760ms. 

Deleting old packages... 
=> Took 418ms. 

Installing modules ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✓ 
Installing [email protected] ✗ 
Package version: 0.88.0 not found 

...そして今ここにビルドプロセスが停止します。私は気になると思った - どうやってソースからビルドできますか?インターネットから削除され続けるパッケージに依存するようになりました。しかし、その後、私は少しブラウザ、と発見したhttps://github.com/atom/tabs/releases/tag/v0.88.0 - 素晴らしい;

cd /tmp 
wget https://github.com/atom/tabs/archive/v0.88.0.zip 
unzip v0.88.0.zip 

cd /path/to/atom_git 
mv /tmp/tabs-0.88.0 ./node_modules/ 

...と再びビルドを試してみました:私はこれを試してみました

atom_git$ script/build 
Node: v4.0.0 
npm: v2.13.3 
Installing build modules... 
=> Took 3473ms. 

Installing apm... 
=> Took 1122ms. 

Deleting old packages... 
Removing tabs-0.88.0 ✓ 
=> Took 1290ms. 

Installing modules ✓ 
Installing [email protected] ✗ 
Package version: 0.88.0 not found 

は畜生 - それは[email protected]を見つけ、それを削除しました! [email protected]をオンラインで探すのではなく、私が提供しているものを使うようにビルドプロセスを説得するにはどうすればいいですか?

答えて

0

私はどこかにいると思います。

最初の問題は、v0.88.0.zipを解凍すると上のスニペットに示すようにtabs-0.88.0という名前のディレクトリが作成され、直接atom_git/node_modules/に移動します。しかし、./script/bootstrapは、「古いパッケージを削除しています...「apm cleanによるものであり、我々は助けを呼び出す場合:

atom_git$ ./apm/node_modules/atom-package-manager/bin/apm clean --help 
Usage: apm clean 
Deletes all packages in the node_modules folder that are not referenced 
as a dependency in the package.json file. 

ああ - 私の​​ソース用とpackage.jsonが含まれています。このように

atom_git$ grep tabs package.json 
    "tabs": "0.88.0", 

、それはフォルダがtabsを命名することが期待されます - そして、NOT tabs-0.88.0、そうする権利のことは次のようになります。

cd /tmp 
wget https://github.com/atom/tabs/archive/v0.88.0.zip 
unzip v0.88.0.zip 

cd /path/to/atom_git 
mv /tmp/tabs-0.88.0 ./node_modules/tabs 

それから私は同じ問題を抱えてtree-view;このため

Running "compile-packages-slug" task 
>> tabs: No README data 
Warning: Task "compile-packages-slug" failed. Use --force to continue. 

ソリューションをしていた:私は

cd /tmp 
wget https://github.com/atom/tree-view/archive/v0.198.1.zip 
unzip v0.198.1.zip 

cd /path/to/atom_git 
mv /tmp/tree-view-0.198.1 ./node_modules/tree-view 

をしましたこれは、まで、ビルドは継続なりNPM - How to fix "No readme data" - アドオンのpackage.jsonreadmeキーを含まなければならない今、判明したので、私は追加atom_git/node_modules/tabs/package.jsonにこのような何か:tree-view 1用

... 
    "dependencies": { 
    "temp": "~0.8.1", 
    "underscore-plus": "1.x" 
    }, 
    "readme": "# Tabs package", 
    "readmeFilename": "README.md", 
    "devDependencies": { 
... 

...と同じ - そして最後にビルドが完了し、script/grunt mkdebも働き、64ビットdebを作成しました。このデビットはインストール可能で、​​が最終的に私のために実行されています(それはまだ私が記録しなかった最初の起動時にエラーを吐き出しました(編集:おそらく "Uncaught TypeError: Cannot read property 'length' of undefined"です)。ので、私はそれが)今OKだと思います...

EDIT:いいえ、それはOKではない、それは私がキー...これは何時間の無駄

を入力Uncaught TypeError: Cannot read property 'length' of undefined毎回を与えます.. 。

関連する問題