xgfone / go-bt

Another pure golang implementation of BitTorrent library.
Apache License 2.0
52 stars 13 forks source link

Proposal #2

Open VuzzyM opened 2 years ago

VuzzyM commented 2 years ago

Hello.

Sorry for the inconvenience, but I want to propose an idea to implement your own Libtorrent-go repository, built for android applications. I know it sounds weird to propose this, but no one has implemented Libtorrent go for android apps yet.

What do you think?

VuzzyM commented 2 years ago

?

xgfone commented 2 years ago

LGTM

VuzzyM commented 2 years ago

LGTM

Interesting. If I saw something like this in practice, it would be very surprising :).

xgfone commented 2 years ago

Fine. Welcome to give me a PR if you have a good idea.

VuzzyM commented 2 years ago

Fine. Welcome to give me a PR if you have a good idea.

I don't deal with go language, I can only give ideas and advice.

There is this repository: https://github.com/i96751414/libtorrent-go https://github.com/ElementumOrg/libtorrent-go https://github.com/ElementumOrg/cross-compiler

Works with kodi, with the elementum plugin: https://github.com/elgatito/plugin.video.elementum

But with android applications, as far as I understand, it doesn't work. That's why I proposed this idea.

VuzzyM commented 2 years ago

@xgfone What you say?

xgfone commented 2 years ago

Sorry for the late reply.

I‘m a noob for the android development, and works on the server side, not mobile. So I can give no more about the android.

The bt library only uses the go stdlib, no any third-party dependencies. So, in theory, it should be compiled by gomobile.

VuzzyM commented 2 years ago

Sorry for the late reply.

I‘m a noob for the android development, and works on the server side, not mobile. So I can give no more about the android.

The bt library only uses the go stdlib, no any third-party dependencies. So, in theory, it should be compiled by gomobile.

Thanks, I just came up with the proposal to implement a separate library based on Libtorrent: https://www.libtorrent.org/

VuzzyM commented 2 years ago

@xgfone Hello, sorry for the inconvenience. You can create your repository on the libtorrent engine? Following the example of this repository https://github.com/anacrolix/torrent. Thanks. I think many are interested in libtorrent on the go language.

xgfone commented 2 years ago

The module bt is a basic core BT library without any denpendencies. For the examples or tools, refer to the repository bttools.

bttools functions:

VuzzyM commented 2 years ago

The module bt is a basic core BT library without any denpendencies. For the examples or tools, refer to the repository bttools.

bttools functions:

  • [ ] dht: Start and run a DHT server.
  • [ ] peer: Start and run a peer to serve the torrent files or the real files.
  • [ ] tracker: Start and run a http/udp tracker.
  • [ ] torrent:

    • [x] create: Generate a .torrent file from a file or directory.
    • [ ] download: Download a .torrent file or real file from the remote peers.
    • [x] dumpinfo: Print the metainfo of the torrent file.
    • [x] getpeers: Get the peers of the torrent from the given tracker.

I mean libtorrent.org