Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

crypto:rand_uniform/2 is deprecated #4

Closed
KarelWintersky opened this issue Jan 29, 2019 · 10 comments
Closed

crypto:rand_uniform/2 is deprecated #4

KarelWintersky opened this issue Jan 29, 2019 · 10 comments

Comments

@KarelWintersky
Copy link

===> Compiling mtproto_proxy
src/mtp_config.erl:49: Warning: crypto:rand_uniform/2 is deprecated and will be removed in a future release; use rand:uniform/1
src/mtp_config.erl:60: Warning: crypto:rand_uniform/2 is deprecated and will be removed in a future release; use rand:uniform/1
src/mtp_config.erl:123: Warning: erlang:get_stacktrace/0: deprecated; use the new try/catch syntax for retrieving the stack backtrace
src/mtp_config.erl:183: Warning: erlang:get_stacktrace/0: deprecated; use the new try/catch syntax for retrieving the stack backtrace

Erlang 21.2.4 , installed via deb-file

@KarelWintersky
Copy link
Author

also,

===> Compiling ranch
_build/default/lib/ranch/src/ranch_ssl.erl:131: Warning: ssl:ssl_accept/2: deprecated; use ssl:handshake/2 instead

@seriyps
Copy link
Owner

seriyps commented Jan 29, 2019

Yep. Those are just warnings. Shouldn't be a problem. But I will try to do something about that

@KarelWintersky
Copy link
Author

И еще: я не смог запустить собранный бинарник.

Что-то в духе "не удается запустить сервис e... , is blocked" (не помню вотпрямщас точный текст, что-то связанное с эрлангом). Вспоминать точно?)

@seriyps
Copy link
Owner

seriyps commented Jan 29, 2019

да, чем больше деталей тем лучше.
устанавливали через make install?

@KarelWintersky
Copy link
Author

KarelWintersky commented Jan 29, 2019

# cd /opt
# wget https://packages.erlang-solutions.com/erlang/esl-erlang/FLAVOUR_1_general/esl-erlang_21.2.4-1~ubuntu~xenial_amd64.deb 

# dpkg -i esl-erlang_21.2.4-1\~ubuntu\~xenial_amd64.deb

Selecting previously unselected package esl-erlang.
(Reading database ... 165794 files and directories currently installed.)
Preparing to unpack esl-erlang_21.2.4-1~ubuntu~xenial_amd64.deb ...
Unpacking esl-erlang (1:21.2.4-1) ...
dpkg: dependency problems prevent configuration of esl-erlang:
 esl-erlang depends on libwxbase2.8-0 | libwxbase3.0-0 | libwxbase3.0-0v5; however:
  Package libwxbase2.8-0 is not installed.
  Package libwxbase3.0-0 is not installed.
  Package libwxbase3.0-0v5 is not installed.
 esl-erlang depends on libwxgtk2.8-0 | libwxgtk3.0-0 | libwxgtk3.0-0v5; however:
  Package libwxgtk2.8-0 is not installed.
  Package libwxgtk3.0-0 is not installed.
  Package libwxgtk3.0-0v5 is not installed.
 esl-erlang depends on libsctp1; however:
  Package libsctp1 is not installed.

dpkg: error processing package esl-erlang (--install):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 esl-erlang

# apt install -f

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... Done
The following additional packages will be installed:
  libdrm-amdgpu1 libdrm-intel1 libdrm-nouveau2 libdrm-radeon1 libgl1-mesa-dri libgl1-mesa-glx libglapi-mesa libllvm6.0 libnotify4
  libpciaccess0 libsctp1 libsensors4 libwxbase3.0-0v5 libwxgtk3.0-0v5 libx11-xcb1 libxcb-dri2-0 libxcb-dri3-0 libxcb-glx0 libxcb-present0
  libxcb-sync1 libxshmfence1 libxxf86vm1
Suggested packages:
  lksctp-tools lm-sensors
Recommended packages:
  libtxc-dxtn-s2tc | libtxc-dxtn-s2tc0 | libtxc-dxtn0 notification-daemon
The following NEW packages will be installed:
  libdrm-amdgpu1 libdrm-intel1 libdrm-nouveau2 libdrm-radeon1 libgl1-mesa-dri libgl1-mesa-glx libglapi-mesa libllvm6.0 libnotify4
  libpciaccess0 libsctp1 libsensors4 libwxbase3.0-0v5 libwxgtk3.0-0v5 libx11-xcb1 libxcb-dri2-0 libxcb-dri3-0 libxcb-glx0 libxcb-present0
  libxcb-sync1 libxshmfence1 libxxf86vm1
0 upgraded, 22 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
Need to get 26.1 MB of archives.
After this operation, 226 MB of additional disk space will be used.
Do you want to continue? [Y/n] 
...

# dpkg -i esl-erlang_21.2.4-1\~ubuntu\~xenial_amd64.deb
(Reading database ... 170229 files and directories currently installed.)
Preparing to unpack esl-erlang_21.2.4-1~ubuntu~xenial_amd64.deb ...
Unpacking esl-erlang (1:21.2.4-1) over (1:21.2.4-1) ...
Setting up esl-erlang (1:21.2.4-1) ...

# erl --version
Erlang/OTP 21 [erts-10.2.3] [source] [64-bit] [smp:1:1] [ds:1:1:10] [async-threads:1] [hipe]

Eshell V10.2.3  (abort with ^G)

# git clone https://github.com/seriyps/mtproto_proxy.git
# cd mtproto_proxy/
# cp config/vm.args.example config/prod-vm.args
# cp config/sys.config.example config/prod-sys.config
# nano config/prod-sys.config 

# make && sudo make install

# sudo systemctl start mtproto-proxy

Failed to start mtproto-proxy.service: Unit epmd.service not found.

NB: Ubuntu 16.04
По умолчанию ставится какой-то 17-ый что ли Erlang.

@seriyps
Copy link
Owner

seriyps commented Jan 29, 2019

а... можно сделать sudo make uninstall, потом удалить эту сторочку

Requires=epmd.service

и установить снова

@seriyps
Copy link
Owner

seriyps commented Jan 29, 2019

Если не сложно, сделаешь отдельный таск насчет установки? Попозже это поправлю

@KarelWintersky
Copy link
Author

Сделаю попозже)

@KarelWintersky
Copy link
Author

Да, все отлично работает если удалить эту строчку :)

@seriyps
Copy link
Owner

seriyps commented Feb 16, 2019

Fixed by 84c18d4

@seriyps seriyps closed this as completed Feb 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants