Closed loguntsov closed 7 years ago
Gosh, seems like they changed erl_types API again in 19.3... I will take a look ASAP.
Hi. What progress for this ? How i can help you to fix this bug ?
I'm a bit busy on another tasks. If you absolutely need to compile the spec, you can install 19.2 and compile it there. The generated code will work in 19.3 anyway.
do you have spare time to this task ? I also have the bug with erlang 19.3,wish you take some time to fix the bug .
Compiling Erlang 19.2 is easy:
cd /tmp
curl -LO http://erlang.org/download/otp_src_19.2.tar.gz
tar -xzf otp_src_19.2.tar.gz
cd otp_src_19.2
./configure --without-termcap --disable-hipe --prefix=/opt/erlang-19.2
make
sudo make install
export PATH=/opt/erlang-19.2/bin ;# Before compiling the xmpp spec.
So I don't think this issue is urgent.
See my comment: https://github.com/processone/xmpp/issues/9#issuecomment-301870026 to automate building of extensions for xmpp
I tried compile specs again for erlang 19.3.5
I made:
$ git clone https://github.com/processone/xmpp.git
$ make
$ make spec
And got this:
erl -noinput +B -pa ebin -pa deps/*/ebin -eval \
'case fxml_gen:compile("specs/xmpp_codec.spec", [{add_type_specs, xmpp_element}, {erl_dir, "src"}, {hrl_dir, "include"}]) of ok -> halt(0); _ -> halt(1) end.'
failed to compile "specs/xmpp_codec.spec": {'EXIT',
{{badmap,
{dict,1,16,16,8,80,48,
{[],[],[],[],[],[],[],[],[],[],
[],[],[],[],[],[]},
{{[],[],[],[],[],[],[],[],[],
[[{opaque,xmlel,[]}|
{{fxml,1,2,[]},type}]],
[],[],[],[],[],[]}}}},
[{maps,filter,
[#Fun<erl_types.11.61440706>,
{dict,1,16,16,8,80,48,
{[],[],[],[],[],[],[],[],[],
[],[],[],[],[],[],[]},
{{[],[],[],[],[],[],[],[],[],
[[{opaque,xmlel,[]}|
{{fxml,1,2,[]},type}]],
[],[],[],[],[],[]}}}],
[{file,"maps.erl"},{line,205}]},
{erl_types,
t_opaque_from_records,1,
[{file,"erl_types.erl"},
{line,770}]},
{fxml_gen,t_remote,2,
[{file,"src/fxml_gen.erl"},
{line,2827}]},
{fxml_gen,get_label_type,5,
[{file,"src/fxml_gen.erl"},
{line,2275}]},
{fxml_gen,
'-get_types/3-fun-0-',5,
[{file,"src/fxml_gen.erl"},
{line,2243}]},
{lists,map,2,
[{file,"lists.erl"},
{line,1239}]},
{fxml_gen,
'-get_types/3-fun-1-',5,
[{file,"src/fxml_gen.erl"},
{line,2241}]},
{lists,foldl,3,
[{file,"lists.erl"},
{line,1263}]}]}}
So isse still not fixed for master. So pls reopen it.
Erlang is:
$erl
Erlang/OTP 19 [erts-8.3.5] [source] [64-bit] [smp:8:8] [async-threads:10] [hipe] [kernel-poll:false]
Works for me on 19.3
So how i can localize problem ? any ideas ?
Could you use same version of Erlang as me ?
Install newer Erlang? Also, I'm not sure why you constantly recompile the spec: the generated code wouldn't be different.
i have my own custom tags so i forced to recompile xmpp every time.
i have my own custom tags so i forced to recompile xmpp every time.
What for? The result will be the same.
It's supposed that you compile your spec only once, then forget about it for several years or so.
you uses standard tags from XMPP, but i have my own tags. So i need recompile code every time when i adds new tags for specification.
by the way it works for Erlang/OTP 20 [erts-9.2] [source] [64-bit] [smp:8:8] [ds:8:8:10] [async-threads:10] [hipe] [kernel-poll:false]
So compile it on Erlang 20 and use the generated code on 19.3, what's the problem?
I'm really not going to install all possible Erlang versions to check every minor release (the API breaks even between minor releases) any time soon, I have more important tasks.
I used esl-erlang installation named as 19.3.6, don't know why it showed as 19.3.5. Could you check it with this version of erlang ?
We do not recommend using Erlang from Erlang Solutions, there are already 2 other issues detected when using it.
Could you point me on some articles for this ? what issues detected ?
I tries compile xmpp_codec.spec manually. So i just changed this file to add one new empty line. After that i ran: make spec And got:
Erlang is: Erlang/OTP 19 [erts-8.3] [source-d5c06c6] [64-bit] [smp:8:8] [async-threads:10] [hipe] [kernel-poll:false]
What is wrong ?