Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#40851 closed defect (fixed)

GiNaC 1.6.2 does not build with clang on 10.9

Reported by: david.seery@… Owned by: gwright@…
Priority: Normal Milestone:
Component: ports Version: 2.2.0
Keywords: mavericks Cc: michaelld (Michael Dickens)
Port: GiNaC

Description

After updating to 10.9 I have not been able to build GiNaC 1.6.2 with the default clang provided by Xcode 5.0.1. I was using this configuration (with Xcode 5.0) on 10.8 without problems.

Attempting to build gives:

:info:build libtool: compile:  /usr/bin/clang++ -DHAVE_CONFIG_H -I. -I../config -I/opt/local/include -I/opt/local/include -pipe -Os -arch x86_64 -MT inifcns.lo -MD -MP -MF .deps/inifcns.Tpo -c inifcns.cpp -o inifcns.o >/dev/null 2>&1
:info:build inifcns_nstdsums.cpp:2604:18: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                 return e * (-H(lst(0),1/arg).hold());
:info:build                                ^~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2635:16: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                 return e * H(lst(1),1-arg).hold();
:info:build                              ^~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2667:34: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                 ex addzeta = convert_H_to_zeta(lst(-1));
:info:build                                                ^~~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2668:28: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                 return (e * (addzeta - H(lst(-1),1/arg).hold())).expand();
:info:build                                          ^~~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2699:17: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                 return (e * H(lst(-1),(1-arg)/(1+arg)).hold()).expand();
:info:build                               ^~~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2730:17: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                 return (e * H(lst(1),(1-arg)/(1+arg)).hold()).expand();
:info:build                               ^~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2809:17: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                                         ex res = H(lst(1), arg).hold() * H(newparameter, arg).hold();
:info:build                                                    ^~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2873:27: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                                                 return unify((pow(H(lst(-1),1/arg).hold() - H(lst(0),1/arg).hold(), parameter.nops())
:info:build                                                                     ^~~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2873:53: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                                                 return unify((pow(H(lst(-1),1/arg).hold() - H(lst(0),1/arg).hold(), parameter.nops())
:info:build                                                                                               ^~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2885:27: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                                                 return unify((pow(H(lst(1),1/arg).hold() + H(lst(0),1/arg).hold() + H_polesign, parameter.nops())
:info:build                                                                     ^~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2885:52: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                                                 return unify((pow(H(lst(1),1/arg).hold() + H(lst(0),1/arg).hold() + H_polesign, parameter.nops())
:info:build                                                                                              ^~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2928:17: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                                         ex res = H(lst(1), arg).hold() * H(newparameter, arg).hold();
:info:build                                                    ^~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2984:28: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                                                 return unify((pow(-H(lst(1),(1-arg)/(1+arg)).hold() - H(lst(-1),(1-arg)/(1+arg)).hold(), parameter.nops())
:info:build                                                                      ^~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2984:63: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                                                 return unify((pow(-H(lst(1),(1-arg)/(1+arg)).hold() - H(lst(-1),(1-arg)/(1+arg)).hold(), parameter.nops())
:info:build                                                                                                         ^~~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:2996:36: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                                                 return unify((pow(log(2) - H(lst(-1),(1-arg)/(1+arg)).hold(), parameter.nops())
:info:build                                                                              ^~~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:3008:37: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                                                 return unify((pow(-log(2) - H(lst(0),(1-arg)/(1+arg)).hold() + H(lst(-1),(1-arg)/(1+arg)).hold(), parameter.nops())
:info:build                                                                               ^~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:3008:72: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                                                 return unify((pow(-log(2) - H(lst(0),(1-arg)/(1+arg)).hold() + H(lst(-1),(1-arg)/(1+arg)).hold(), parameter.nops())
:info:build                                                                                                                  ^~~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^
:info:build inifcns_nstdsums.cpp:3051:17: error: ambiguous conversion for functional-style cast from 'int' to 'lst' (aka 'container<std::list>')
:info:build                                         ex res = H(lst(1), arg).hold() * H(newparameter, arg).hold();
:info:build                                                    ^~~~~
:info:build ./container.h:145:2: note: candidate constructor
:info:build         container(STLT const & s, bool discardable = false)
:info:build         ^
:info:build ./container.h:167:11: note: candidate constructor
:info:build         explicit container(const ex & p1)
:info:build                  ^

Forcing a build with gcc 4.8 (via 'configure.compiler macports-gcc-4.8') completes correctly (although the result isn't usable, apparently because of mixing different C++ runtime environments).

Change History (4)

comment:1 Changed 8 years ago by mf2k (Frank Schima)

Cc: gwright@… removed
Keywords: mavericks added
Owner: changed from macports-tickets@… to gwright@…

As always, please attach the complete main.log file after cleaning the port.

comment:2 Changed 8 years ago by david.seery@…

I have reverted to 10.8 so cannot immediately provide a main.log. However I will try another 10.9 installation over the next few days for comparison purposes, and at that point I will try to build GiNaC again.

Initially I assumed this was just a build environment issue. However the same problem seems to have been reported on the GiNaC mailing lists, with a proposed patch:

http://www.cebix.net/pipermail/ginac-list/2013-October/001973.html

http://www.cebix.net/pipermail/ginac-list/2013-October/001974.html

Last edited 8 years ago by david.seery@… (previous) (diff)

comment:3 Changed 8 years ago by michaelld (Michael Dickens)

Resolution: fixed
Status: newclosed

Those links provide the idea for the necessary patch. Clang++ is just being annoying; it should be clear which container is to be selected for use in those cases

Maintainer timeout: fixed in r114209.

comment:4 Changed 8 years ago by michaelld (Michael Dickens)

Cc: michaelld@… added

Cc Me!

Note: See TracTickets for help on using tickets.