pfalcon / ScratchABit

Easily retargetable and hackable interactive disassembler with IDAPython-compatible plugin API
GNU General Public License v3.0
393 stars 47 forks source link

Where's the setup.py #46

Closed radare closed 5 years ago

pfalcon commented 5 years ago

Well, there's none. So far, ScratchABit is "portable" software, which you don't install, but just git clone and run ;-). That of course mean you can't install it e.g. via pip, but such an installation wouldn't be much useful for majority of users, because the next immediate question is "how to use it?", etc. With git clone, there's README right there, sample .def files and binaries, etc.

That said, if you have specific usecase where having a classic Python "distribution package" with setup.py and stuff would be useful, feel free to elaborate.

radare commented 5 years ago

I was looking for this because i gave up after half an hour installing packages and trying different versions of python. And no. Nothing written in python can be considered portable.

On 19 Dec 2018, at 20:13, Paul Sokolovsky notifications@github.com wrote:

Well, there's none. So far, ScratchABit is "portable" software, which you don't install, but just git clone and run ;-). That of course mean you can't install it e.g. via pip, but such an installation wouldn't be much useful for majority of users, because the next immediate question is "how to use it?", etc. With git clone, there's README right there, sample .def files and binaries, etc.

That said, if you have specific usecase where having a classic Python "distribution package" with setup.py and stuff would be useful, feel free to elaborate.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

pfalcon commented 5 years ago

Installing packages which? Trying different version of python which? There's a README in this repository, it describes how to run it. If you failed somewhere, feel free to describe the steps you took and what exactly went wrong.

radare commented 5 years ago

I have tried py2.7, py3.7 installed picotui, capstone, pyelftools, elftools, numpy and tried many other unexistent ones because it was keeping complaining, also tried installing them in home, in system, in a clean virtualenv but didnt managed to get it to work at all.

In theory setup.py is suposed to ease that pain, and yes i followed the steps in the readme. but python apps never works out of the box, they depend on so many things from the system and the distribution that they all fail in some way or another. not providing standard dependency definitions or dockerfile/pyenv setup to get it to work is the main issue. Not to mention release builds.

I'm not really in a hurry or in the need to use this tool, but i was just curious to test it, and spending more than 1h to get something to work is outside of my current interests.

On 19 Dec 2018, at 20:51, Paul Sokolovsky notifications@github.com wrote:

Installing packages which? Trying different version of python which? There's a README in this repository, it describes how to run it. If you failed somewhere, feel free to describe the steps you took and what exactly went wrong.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/pfalcon/ScratchABit/issues/46#issuecomment-448722659, or mute the thread https://github.com/notifications/unsubscribe-auth/AA3-liwH3JMT2jzMqardUXNnSMBJbCVGks5u6pjXgaJpZM4Za1ke.

pfalcon commented 5 years ago

I have tried py2.7, py3.7

Why did you try py2.7, if the README clearly says "modern version, Python3"?

installed picotui, capstone, pyelftools, elftools, numpy and tried many other unexistent ones

Why did you do all that, if the README clearly says:

git clone --recursive https://github.com/pfalcon/ScratchABit

The only optional dependency is Capstone, it may be PITA to install indeed, because it's written in C. You can start very well without it.

because it was keeping complaining

Complaining what?

In theory setup.py is suposed to ease that pain, and yes i followed the steps in the readme.

Monorepos are known to ease the pain, and that's the approach followed here - all required dependencies included in the repo, as git submodules.

but python apps never works out of the box I'm not really in a hurry or in the need to use this tool, but i was just curious to test it

Sure, I feel the pain. And sure, I understand - holiday time, it's nice to relax, look around, and try that funny thing you heard about. Love that too.

But then, the only thing I can quote is the scripture, secion 3, verse 1:

Some of the worst bug reports I've ever seen come from programmers, and even from good programmers.

If you're interested, feel free to report the exact issue and way to reproduce it. But if all that was just for "I always knew that it sucks", then well, you won.

radare commented 5 years ago

Ok I managed to get it to work, and realized all the dependencies are a fork you did from the real projects, i had to tweak the pythonpath and then it worked.. bad practices all the way. but anyway my fault for not checking for the submodules. In fact capstone is the only dependency that should not be installed system wide because last release is pretty outdated and lacks several instructions, architectures and features.

I have already pointed a bunch of issues, and by running it i see a couple of more bugs like being unable to resize the terminal or reach the menu, no help available. And no, i'm not in holidays. But didn't knew about this project and was curious to test it and see if i can contribute or get ideas out of it in any way.

I'm not trying to won any war here, just got frustrated without even being able to run it. So i assume we can close this issue because you reject to add a setup.py, use the real dependencies instead of your forks, etc. those are just suggestions if you care about your project.

Sorry for reporting in the worst possible way.

radare commented 5 years ago

PD: "monorepo" implies 1 repository