vysheng / tg

telegram-cli
GNU General Public License v2.0
6.46k stars 1.53k forks source link

can't compile on debian stretch #1547

Open simbalion opened 6 years ago

simbalion commented 6 years ago

followed the instructions but got the following error:

g -fno-omit-frame-pointer -ggdb -Wno-unused-parameter -fPIC -iquote ./tgl -c -MP -MD -MF dep/crypto/rsa_pem_openssl.d -MQ objs/crypto/rsa_pem_openssl.o -o objs/crypto/rsa_pem_openssl.o tgl/crypto/rsa_pem_openssl.c tgl/crypto/rsa_pem_openssl.c: In function ‘TGLC_rsa_new’: tgl/crypto/rsa_pem_openssl.c:41:6: error: dereferencing pointer to incomplete type ‘RSA {aka struct rsa_st}’ ret->e = unwrap_bn (TGLC_bn_new ()); ^~ tgl/crypto/rsa_pem_openssl.c: In function ‘TGLC_rsa_n’: tgl/crypto/rsa_pem_openssl.c:52:1: error: control reaches end of non-void function [-Werror=return-type] RSA_GETTER(n); ^~~~~~ tgl/crypto/rsa_pem_openssl.c: In function ‘TGLC_rsa_e’: tgl/crypto/rsa_pem_openssl.c:53:1: error: control reaches end of non-void function [-Werror=return-type] RSA_GETTER(e); ^~~~~~ cc1: all warnings being treated as errors Makefile.tgl:20: recipe for target 'objs/crypto/rsa_pem_openssl.o' failed make: *** [objs/crypto/rsa_pem_openssl.o] Error 1

ichbestimmtnicht commented 6 years ago

I just did it and refferring to another issue that i just read you can fix this bug (i stumbled with it too) with installing sudo apt install libssl1.0-devand or passing ./configure --disalbe-openssl instead of the plain variant of ./configure.

melonius commented 5 years ago

Thanks, It works for me, but I need to install also sudo apt install libgcrypt20 libgcrypt20-dev

./configure --disable-openssl

x4x commented 5 years ago

Thanks for the helpful info. I just needed to install libssl1.0-devand libgcrypt20 libgcrypt20-dev then it compiled normal with openssl.

LorenzoAncora commented 5 years ago

I just did it and refferring to another issue that i just read you can fix this bug (i stumbled with it too) with installing sudo apt install libssl1.0-devand or passing ./configure --disalbe-openssl instead of the plain variant of ./configure.

@ichbestimmtnicht this solution works, telegram-cli was compiled correctly with OpenSSL.

quantitative-technologies commented 5 years ago

Just installed libssl1.0-dev and then plain .configure worked.