Td: Builds for android, ios, windows, linux, etc

Created on 7 Jan 2018  路  14Comments  路  Source: tdlib/td

Very cool work!

But...I do not have time to build a library through cmake and view the required dependencies(i'am sorry).
The documentation is good, but there are few practical examples of applying methods and necessary chains of methods. There are a lot of methods.

I have a few questions

  • Where there are ready assemblies for android, ios, windows, linux, etc?
    Will there be documentation in each pre-assembly? What for? (long unpacking)
    I managed to find a pre-build only for android. It is not known how relevant this is. You can render the documentation in a separate section for each pre-assembly (if there is an additional interface used, such as Java).
  • Python, C++ and C# the last languages where I would like to use tdlib(i'am sorry).
    How does this thing behave with javascript and is it possible? (I want an interface;))
    https://nodejs.org/api/addons.html may be for json interface, but need example.
  • Is there a test environment where can test the build?
question

Most helpful comment

You can use my lib on node js https://github.com/k-egor-smirnov/node-tg-native

All 14 comments

  1. The library has a minimum number of dependencies and supposed to be easily built on any of the supported architectures. There are too many supported operating systems, platforms and compilers to prebuilt all usable variants. We provide for now only prebuilt shared library for Android with corresponding Java interface, which is documented via Javadoc, because it is slightly harder to build the library for Java and Android.

  2. TDLib can be used virtually from any modern programming language including Javascript. Moreover TDLib JSON interface can be treated as a native interface for Javascript. For Node.JS the usage of library is mostly the same as from Python: you just need to load tdjson shared library. To use TDLib in browsers you need to compile it using Emscripten compiler. It is harder to use TDLib from browsers because of sandboxing, so we will publish our browser Javascript wrapper later.

  3. What do you mean by "where can test the build"?

Suppose we have built an application using tdlib.
Then it is necessary to check the correctness of displaying information in the lists and other interface elements.
I think this is allowed by a "mega-bot" on a specific phone number in one of the data centers. But here I can be wrong. I do not know the architecture on the backend. In one of the competitions on tdlib there was something like this. "It looks like it's gone".
Now testing applications with such a crazy speed is unrealistic on the bare channel.
I would like it to come to life :)

You can use my lib on node js https://github.com/k-egor-smirnov/node-tg-native

Sorry, but there is no such mega-bot. It was a usual user account and it is now unavailable, because someone has tested deletion of all chats. You can test everything using self-created accounts in the test DC.

Alexey, I would say, at the moment there are too many problems for the average user of the library.
It is completely unclear what for it is needed without a backend (if only for the soul).

@k-egor-smirnov thanks, but that's not what I need 馃憤
node -v
v8.9.1

But I think, if you send this thing to the heart of all sorts of angular, reactjs, it can make it easier for people to organize their communication systems. The truth is that the infa will be in the cloud somewhere.(there is a need for a cloud-based message viewer and other features)
A little humor :) "Scientists have created a preporat, which allows you to lose weight without dieting"
But the implementation of the interface will still be difficult. Too many features..

Thanks for the tips
The library code is cool!
Regards

@isopen i took an mistake when wrote that my module is incompatible with node.js >=7. You can run module with node.js < 9
due the bug in ffi module https://github.com/node-ffi/node-ffi/pull/439

@k-egor-smirnov
"ffi" module doesn't compile on node <= 9 (see https://github.com/node-ffi/node-ffi/pull/439)
node -v
v8.9.1
I'll try a little later :)

@k-egor-smirnov tried :)

I do not know where to write this. I'll leave it here.)

My OpenSSL 1.1.0f 25 May 2017

nodejs index.js

fs.js:646
  return binding.open(pathModule._makeLong(path), stringToFlags(flags), mode);
                 ^
Error: ENOENT: no such file or directory, open 'libssl.so.1.0.0'
    at Object.fs.openSync (fs.js:646:18)
    at fs.readFileSync (fs.js:551:33)
    at new DynamicLibrary (/home/mrmakss/prog/tdlib/npm/node_modules/ffi/lib/dynamic_library.js:67:21)
    at Object.Library (/home/mrmakss/prog/tdlib/npm/node_modules/ffi/lib/library.js:45:12)
    at Object.<anonymous> (/home/mrmakss/prog/tdlib/npm/node_modules/node-tg-native/lib/TD.js:15:19)
    at Module._compile (module.js:635:30)
    at Object.Module._extensions..js (module.js:646:10)
    at Module.load (module.js:554:32)
    at tryModuleLoad (module.js:497:12)
    at Function.Module._load (module.js:489:3)

Then the next bike starts, which I will not do ;)

@isopen Can you open issue in my repository with information about your system and close this thread?

@k-egor-smirnov More information about the system can be found on this site.
https://www.debian.org/index.en.html

There is probably not even a problem in the system. Just asks tsl1.0.0
By the way trying to solve this problem, I lost one virtual machine.
In a certain year there were disturbing news about version 1.0.0

You can add this yourself to your repository and ask @levlam about when this report will be closed.

@isopen https://github.com/nodegin/tglib is working with latest node version.

@seiya-git Thanks. But that's not what I need.
Too much dependence on third-party module ffi-napi.
If @levlam will include your source code in the examples, then I will take great pleasure in using it.

So back to this report. He alone can replace everything.
@levlam of all this is really lacking and no one seems to want to really help, except @isopen
What is the use of these gross interfaces on top, if there is no implementation for javascript.

@levlam In which patch can I build it myself for android? According to instructions

Was this page helpful?
0 / 5 - 0 ratings

Related issues

hameda169 picture hameda169  路  3Comments

liaoyu1992 picture liaoyu1992  路  4Comments

sh-a-v picture sh-a-v  路  3Comments

kossnocorp picture kossnocorp  路  3Comments

mbj2007 picture mbj2007  路  4Comments