Re: [問題] 一包open source code如何compile

作者: qrtt1 (有些事,有時候。。。)   2015-09-26 20:48:53
※ 引述《psylove5566 (甜小蜜)》之銘言:
: Hi各位大大:
: 不好意思,我是新新手,我在網路上載了一包jar檔的open source code,解壓縮看過裡
: 面的java code,已經在eclipse的project->java build path->add external jars加入
: 了open source的jar檔
: 並開了一個new project,也有看到左側視窗有剛剛加入的很多jar檔
: 但我不清楚的地方是如何把open source的.java檔一次全部加入project,讓我能夠埋deb
: ug message,並compile?
: 另外想問的是java有如同c code有make file可以在不用用eclipse開project的情況下就
: 能compile嗎?
: 麻煩各位高手的提點,感激
如果你有同一版的 JAR 的 source code。
在你引用了之後,JAR 的 context menu(俗稱右鍵選單)內的 properties
設定中有一頁是『Java Source Attachment』,
這個能讓你指定 Source JAR 的位置
(其實就是一個含 Source Code 的 JAR 或 Zip 檔)
當你設定 breakpoint 後,以 debug 模式追 code 時,
就能追進 source code 了,不用自己埋 code 那麼費力
作者: jtorngl (Pedrosa go!)   2015-09-26 21:07:00
有裝decompiler plugin,debug也可以直接追jar的code吧
作者: qrtt1 (有些事,有時候。。。)   2015-09-26 21:42:00
都用 open source 了,還搞什麼 decompiler xd
作者: jtorngl (Pedrosa go!)   2015-09-27 09:21:00
應該說在沒有source code的情況下通常會裝decompiler

Links booklink

Contact Us: admin [ a t ] ucptt.com