Hugin - Panorama Tools GUI

Mandriva: 2010.4 compilation fails

Reported by Alexander Rabtchevich on 2011-01-18

This bug report was converted into a question: question #146652: Mandriva: 2010.4 compilation fails.

12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Hugin
Undecided
Unassigned

Bug Description

Hugin compilation fails with the message:

/home/sasha/Install/hugin-2010.4.0/src/hugin1/icpfind/AutoCtrlPointCreator.cpp: In member function 'virtual HuginBase::CPVector AutoPanoSift::automatch(CPDetectorSetting&, PT::Panorama&, const HuginBase::UIntSet&, int, std::vector<wxString, std::allocator<wxString> >&, int&, wxWindow*)':
/home/sasha/Install/hugin-2010.4.0/src/hugin1/icpfind/AutoCtrlPointCreator.cpp:595: error: no matching function for call to 'wxString::wc_str()'
/usr/include/wx-2.8/wx/string.h:942: note: candidates are: const wxWCharBuffer wxString::wc_str(const wxMBConv&) const
make[2]: *** [src/hugin1/icpfind/CMakeFiles/icpfindlib.dir/AutoCtrlPointCreator.cpp.o] Error 1
make[1]: *** [src/hugin1/icpfind/CMakeFiles/icpfindlib.dir/all] Error 2
make: *** [all] Error 2

Mandriva 2010.2, wxgtk 2.8.10.

tduell (tduell-iinet) wrote :

Alexander,
Sorry if this is a silly question, but do you have wxGTK-devel installed?

Cheers,
Terry

Yuv (yuv) on 2011-01-23
Changed in hugin:
status: New → Incomplete

Yes, libwxgtk2.8-devel version 2.8.10 is installed. In the other case cmake would fail.

Yuv (yuv) wrote :

IIRC Mandriva is derived from Red Hat? so it may be similar to Fedora?

Does http://wiki.panotools.org/Hugin_Compiling_Fedora help?

Please set the status of this report to New when you add new information and need attention again.

Download full text (12.1 KiB)

No, the link haven't provided any new info. I have all required packages, at least the system reports they are installed.

When I try to replace in the string #595 of AutoCtrlPointCreator.cpp : matcherArgs.Replace(wxT("%k"), wxString (imgFiles.c_str(), HUGIN_CONV_FILENAME));

the part
imgFiles.wc_str()
with
imgFiles.c_str()

as it should be taken from string.h from wx include files
const wxChar* wc_str() const { return c_str(); }

compilation goes on. Could it be wxUSE_UNICODE isn't defined? How can I test it?

Now make stops at another point:

[ 64%] Built target icpfindlib
[ 64%] Building CXX object src/hugin1/icpfind/CMakeFiles/icpfind.dir/icpfind.cpp.o
/home/sasha/Install/hugin-2010.4.0/src/hugin1/icpfind/icpfind.cpp: In member function ‘virtual int iCPApp::OnRun()’:
/home/sasha/Install/hugin-2010.4.0/src/hugin1/icpfind/icpfind.cpp:108: error: ambiguous overload for ‘operator<<’ in ‘std::operator<< [with _Traits = std::char_traits<char>](((std::basic_ostream<char, std::char_traits<char> >&)(& std::cerr)), ((const char*)"could not open script : ")) << wxString::char_str(const wxMBConv&) const(((const wxMBConv&)((const wxMBConv*)wxConvLibc)))’
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/ostream:165: note: candidates are: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(long int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/ostream:169: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(long unsigned int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/ostream:173: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(bool) [with _CharT = char, _Traits = std::char_traits<char>]
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/bits/ostream.tcc:91: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(short int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/ostream:180: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(short unsigned int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/bits/ostream.tcc:105: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/ostream:191: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(unsigned int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/ostream:200: note: std::basic_ostream<_CharT, _Trai...

Changed in hugin:
status: Incomplete → New
Fessel (fefessel) wrote :

I have the same problem!

The solution, change in /etc/alternatives the links:

wx-config to /usr/lib64/wx/config/gtk2-unicode-release-2.8

wxrc to /usr/bin/wxrc-2.8-unicode

In mine both direct to the ansi versions.

I don't know if it change back when making a update of wxGTK.

After that, the compilation goes OK!!!

Download full text (11.6 KiB)

Thank you! The initial error has been passed. :)
But the afterwards compilation still fails:
...
Scanning dependencies of target icpfind
[ 64%] Building CXX object src/hugin1/icpfind/CMakeFiles/icpfind.dir/icpfind.cpp.o
/home/sasha/Install/hugin-2010.4.0/src/hugin1/icpfind/icpfind.cpp: In member function ‘virtual int iCPApp::OnRun()’:
/home/sasha/Install/hugin-2010.4.0/src/hugin1/icpfind/icpfind.cpp:108: error: ambiguous overload for ‘operator<<’ in ‘std::operator<< [with _Traits = std::char_traits<char>](((std::basic_ostream<char, std::char_traits<char> >&)(& std::cerr)), ((const char*)"could not open script : ")) << wxString::char_str(const wxMBConv&) const(((const wxMBConv&)((const wxMBConv*)wxConvLibc)))’
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/ostream:165: note: candidates are: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(long int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/ostream:169: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(long unsigned int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/ostream:173: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(bool) [with _CharT = char, _Traits = std::char_traits<char>]
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/bits/ostream.tcc:91: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(short int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/ostream:180: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(short unsigned int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/bits/ostream.tcc:105: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/ostream:191: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(unsigned int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/ostream:200: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(long long int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-gnu/4.4.3/../../../../include/c++/4.4.3/ostream:204: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(long long unsigned int) [with _CharT = char, _Traits = std::char_traits<char>] <near match>
/usr/lib/gcc/i586-manbo-linux-g...

Fessel (fefessel) wrote :

did you change the two links?

wxrc and wx-config?

Here is compiling without problems.
These error is related to the Unicode problem too.

He-he, I haven't cleaned previously compiled units. After clean install everything went OK. :) Many thanks for the help.

As the bug is common on Mandriva, should it be add to compilation notes or a workaround found?

Yuv (yuv) wrote :

It would be nice if you could write compilation notes for Mandriva - we don't have them yet.

Can you put your work at:
* http://wiki.panotools.org/Hugin_Compiling_Mandriva

A few examples:
* http://wiki.panotools.org/Hugin_Compiling_Ubuntu
* http://wiki.panotools.org/Hugin_Compiling_OpenSuse
* http://wiki.panotools.org/Hugin_Compiling_Fedora

Once you'll write it, it can be linked from the table of supported platforms at
* http://wiki.panotools.org/Development_of_Open_Source_tools#Build_your_Own_Test_Builds

And of course you get credited for that ;-)

Thanks
Yuv

Yuv (yuv) wrote :

As noted in the thread, the ANSI versions link must be replaced with the Unicode ones in /etc/alternatives
* wx-config to /usr/lib64/wx/config/gtk2-unicode-release-2.8
* wxrc to /usr/bin/wxrc-2.8-unicode

summary: - 2010.4 compilation fails
+ Mandriva: 2010.4 compilation fails
Changed in hugin:
status: New → Invalid
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Related questions