aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Pages: [1] 2

Author Topic: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error  (Read 19888 times)

peerstudio

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 17
amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« on: December 30, 2011, 01:14:11 PM »

Hi all,

i am trying to compile amule 2.3.1 on a solaris 11/11 system with the oracle solaris studio compiler 12.3.

I have installed succesfully the following dependencies
-wxwidgets 2.8.12 (included in the official oracle repository and compiled with sun compilers)
-cryptopp (compiled without error using 'gmake CXX=CC')

after untarring amule 2.3.1, i run without errors:

./configure --disable-monolithic  --enable-amule-daemon --disable-amulecmd --disable-webserver --disable-amule-gui --disable-cas --disable-wxcas --disable-alc --disable-alcc --disable-xas --disable-fileview --disable-plasmamule --disable-geoip --disable-upnp --disable-debug --disable-nls --with-zlib=/usr/lib --disable-ed2k --enable-optimize --enable-mmap

Code: [Select]
  Configure script has finished system check.

  Configured aMule 2.3.1 for 'i386-pc-solaris2.11'.

  aMule enabled options:

  **** aMule Core ****
  Prefix where aMule should be installed?                    /usr/local
  Should aMule be compiled with i18n support?                no
  Should aMule be compiled in debug mode?                    no
  Should aMule be compiled with profiling?                   no
  Should aMule be compiled with optimizations?               no
  Should aMule be compiled with UPnP support?                no
  Should aMule be compiled with IP2country support?          no
  Should aMule monolithic application be built?              no
  Should aMule daemon version be built?                      yes
  Should aMule remote gui be built?                          no
  Crypto++ library/headers style?                            installed

  **** aMule TextClient ****
  Should aMule Command Line Client be built?                 no

  **** aMule WebServer ****
  Should aMule WebServer be built?                           no

  **** aMule ED2K Links Handler ****
  Should aMule ED2K Links Handler be built?                  no

  **** aMuleLinkCreator ****
  Should aMuleLinkCreator GUI version (alc) be built?        no
  Should aMuleLinkCreator for console (alcc) be built?       no

  **** aMule Statistics ****
  Should C aMule Statistics (CAS) be built?                  no
  Should aMule GUI Statistics (wxCas) be built?              no
  Should xas XChat2 plugin be installed?                     no
  Should plasmaMule plasma-applet be build?                  no

  **** General Libraries and Tools ****
  Should ccache support be enabled?                          no
  Libraries aMule will use to build:
                             wxWidgets             2.8.12 (gtk2,shared)
                             crypto++              5.6.1 (installed, in /usr)
                             zlib                  1.2.3


 *** Warnings during configuration ***

* bfd.h not found or unusable, please install binutils development package if
  you are a developer or want to help testing aMule

i do not know what bfd.h is needed for. i simply ignore this warning.

now i run :  gmake -j2 CXX=CC

Quote
        source='strerror_r.c' object='strerror_r.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../../../depcomp \
        cc -DHAVE_CONFIG_H -I. -I../../..  -DUSE_WX_EXTENSIONS  -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0 -I/usr/local/include   -c strerror_r.c
"/usr/include/sys/feature_tests.h", line 358: #error: "Compiler or options invalid; UNIX 03 and POSIX.1-2001 applications       require the use of c99"
cc: acomp failed for strerror_r.c
gmake[4]: *** [strerror_r.o] Error 2
gmake[4]: Leaving directory `/usr/local/aMule-2.3.1/src/libs/common'
gmake[3]: *** [all-recursive] Error 1
gmake[3]: Leaving directory `/usr/local/aMule-2.3.1/src/libs'
gmake[2]: *** [all-recursive] Error 1
gmake[2]: Leaving directory `/usr/local/aMule-2.3.1/src'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/usr/local/aMule-2.3.1'
gmake: *** [all] Error 2

i am able to solve this first error by adding the '-xc99' flag to 'cc -DHAVE_CONFIG_H -I. -I../../..  -DUSE_WX_EXTENSIONS  -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0 -I/usr/local/include   -c strerror_r.c'

after compiling strerror_r.c, i go on.

i cannot solve the following problem. i think a patch is needed:

Code: [Select]
gmake[3]: Entering directory `/usr/local/aMule-2.3.1/src'
\
        source='GapList.cpp' object='libmuleappcommon_a-GapList.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0 -I./libs -I./include -I/usr/include -D__WEAK_CRYPTO__  -I/usr/local/include  -I/usr/local/include -c -o libmuleappcommon_a-GapList.o `test -f 'GapList.cpp' || echo './'`GapList.cpp
"./include/common/Macros.h", line 33: Warning (Anachronism): Attempt to redefine SEC without using #undef.
"GapList.cpp", line 108: Error: Could not find a match for std::map<unsigned long long,unsigned long long>::insert(__rwstd::__rb_tree<unsigned long long, std::pair<const unsigned long long, unsigned long long>, __rwstd::__select1st<std::pair<const unsigned long long, unsigned long long>, unsigned long long>, std::less<unsigned long long>, std::allocator<std::pair<const unsigned long long, unsigned long long>>>::iterator, std::pair<unsigned long long, unsigned long long>) needed in CGapList::AddGap(unsigned long long, unsigned long long).
"GapList.cpp", line 173: Error: Could not find a match for std::map<unsigned long long,unsigned long long>::insert(__rwstd::__rb_tree<unsigned long long, std::pair<const unsigned long long, unsigned long long>, __rwstd::__select1st<std::pair<const unsigned long long, unsigned long long>, unsigned long long>, std::less<unsigned long long>, std::allocator<std::pair<const unsigned long long, unsigned long long>>>::iterator, std::pair<unsigned long long, unsigned long long>) needed in CGapList::FillGap(unsigned long long, unsigned long long).
"GapList.cpp", line 183: Error: Could not find a match for std::map<unsigned long long,unsigned long long>::insert(__rwstd::__rb_tree<unsigned long long, std::pair<const unsigned long long, unsigned long long>, __rwstd::__select1st<std::pair<const unsigned long long, unsigned long long>, unsigned long long>, std::less<unsigned long long>, std::allocator<std::pair<const unsigned long long, unsigned long long>>>::iterator, std::pair<unsigned long long, unsigned long long>) needed in CGapList::FillGap(unsigned long long, unsigned long long).
3 Error(s) and 1 Warning(s) detected.
gmake[3]: *** [libmuleappcommon_a-GapList.o] Error 2
gmake[3]: Leaving directory `/usr/local/aMule-2.3.1/src'
gmake[2]: *** [all-recursive] Error 1
gmake[2]: Leaving directory `/usr/local/aMule-2.3.1/src'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/usr/local/aMule-2.3.1'
gmake: *** [all] Error 2

i have tried, as suggested in many guides, to append the -library=stlport4 option to CXXFLAGS.
using this flags it generates errors even before GapList.cpp in the compile process.

i really do not know how to fix these lines:
Code: [Select]
m_gaplist.insert(it, std::pair<uint64,uint64>(gapend, gapstart));
-----
m_gaplist.insert(it3, std::pair<uint64,uint64>(partstart - 1, curGapStart));
-----
m_gaplist.insert(it3, std::pair<uint64,uint64>(partstart - 1, curGapStart));

if i do gmake -k, i see many other errors related to std::vector and  and other standard library functions

another one:

Code: [Select]
        source='MagnetURI.cpp' object='libmuleappcommon_a-MagnetURI.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0 -I./libs -I./include -I/usr/include -D__WEAK_CRYPTO__  -I/usr/local/include  -I/usr/local/include -c -o libmuleappcommon_a-MagnetURI.o `test -f 'MagnetURI.cpp' || echo './'`MagnetURI.cpp
"MagnetURI.cpp", line 40: Warning (Anachronism): Attempt to redefine _C without using #undef.
"MagnetURI.cpp", line 46: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 64: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 98: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 102: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 103: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 104: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 120: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 120: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 122: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 128: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 130: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 133: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 136: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
20 Error(s) and 1 Warning(s) detected.
make[3]: *** [libmuleappcommon_a-MagnetURI.o] Error 2


i am really committed on making it work on this version of solaris and with this compiler.
after an entire day of work, trying with gcc, i realized that is much easier using the sun compiler for building amule and its dependencies.
since the whole user level libraries are compiled with sun studio in solaris, amule will have to use libraries both compiled with gcc (eventually wxwidgets and cryptopp) and with sun compiler (all the others system libraries). The results are uglier than above.

if we succeed i can update this guide http://wiki.amule.org/index.php/HowTo_compile_on_Solaris

thank you in advance for your support.

enrico.
Logged

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #1 on: December 30, 2011, 01:33:09 PM »

I think you should pass your compiler option "CC=CXX -xc99" right to configure. And check if configure is already using the compiler you want to use for building.
Logged
The image of mother goddess, lying dormant in the eyes of the dead, the sheaf of the corn is broken, end the harvest, throw the dead on the pyre -- Iron Maiden, Isle of Avalon

peerstudio

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 17
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #2 on: December 30, 2011, 02:25:59 PM »

hello,
yes, the configure is always using the cc compiler
Code: [Select]
checking for g++... no
checking for c++... no
checking for gpp... no
checking for aCC... no
checking for CC... CC
checking whether the C++ compiler works... yes
checking for C++ compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... no
checking whether CC accepts -g... yes
checking for style of include used by make... GNU
checking dependency style of CC... none
checking how to run the C++ preprocessor... CC -E
checking for gcc... no
checking for cc... cc
checking whether we are using the GNU C compiler... no
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking dependency style of cc... none
no packages related to gcc are installed in the system.


i try again what you say.
i have added to CPPFLAGS:

CXXFLAGS='CXX=CC -xlang=c99 -I/usr/local/include'

http://docs.oracle.com/cd/E19205-01/819-5267/bkbcv/index.html

i get immediately:
Code: [Select]
checking whether the C++ compiler works... no
configure: error: in `/usr/local/aMule-2.3.1':
configure: error: C++ compiler cannot create executables

i change the flags to
CXXFLAGS='-xlang=c99 -I/usr/local/include'

i configure correclty.
but i get the same error:
Code: [Select]
\
        source='Path.cpp' object='Path.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../../../depcomp \
        CC -DHAVE_CONFIG_H -I. -I../../..  -DUSE_WX_EXTENSIONS  -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0  -O2 -mt -D_REENTRANT  -xlang=c99 -I/usr/local/include -c -o Path.o Path.cpp
\
        source='strerror_r.c' object='strerror_r.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../../../depcomp \
        cc -DHAVE_CONFIG_H -I. -I../../..  -DUSE_WX_EXTENSIONS  -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0    -c strerror_r.c
"/usr/include/sys/feature_tests.h", line 358: #error: "Compiler or options invalid; UNIX 03 and POSIX.1-2001 applications       require the use of c99"
cc: acomp failed for strerror_r.c
make[4]: *** [strerror_r.o] Error 2
make[4]: Leaving directory `/usr/local/aMule-2.3.1/src/libs/common'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/usr/local/aMule-2.3.1/src/libs'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/usr/local/aMule-2.3.1/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/local/aMule-2.3.1'
make: *** [all] Error 2

not that the files compiled with CC (capitals), have the -xlang flag. and the others not!... sorry but i do not know what causes this difference.

i change the flags to
CXXFLAGS='-xc99 -I/usr/local/include'

i get immediately:
Code: [Select]
checking whether the C++ compiler works... no
configure: error: in `/usr/local/aMule-2.3.1':
configure: error: C++ compiler cannot create executables

my env variables:
Code: [Select]
LDFLAGS=-L/usr/local/lib -R/usr/local/lib -L/usr/local/sunstudio/lib -R/usr/local/sunstudio/lib
LD_LIBRARY_PATH=/usr/local/lib:/usr/local/sunstudio/lib:/usr/lib
CXXFLAGS=-xc99 -I/usr/local/include
PATH=/usr/gnu/bin:/usr/bin:/usr/sbin:/usr/local/sunstudio/bin
Logged

peerstudio

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 17
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #3 on: December 30, 2011, 02:46:17 PM »

i have also UNSET these variables
Code: [Select]
CXX=CC
CXXFLAGS="-xlang=c99"

and tried passing them directly to configure

./configure CXX=CC CXXFLAGS=-xlang=c99 --disable-monolithic  --enable-amule-daemon --disable-amulecmd --disable-webserver --disable-amule-gui --disable-cas --disable-wxcas --disable-alc --disable-alcc --disable-xas --disable-fileview --disable-plasmamule --disable-geoip --disable-upnp --disable-debug --disable-nls --with-zlib=sys --disable-ed2k --enable-optimize --enable-mmap

same issue. stderror is compiled with cc and not CC, the flag is ignored
Code: [Select]
gmake[4]: Entering directory `/usr/local/aMule-2.3.1/src/libs/common'
\
        source='FileFunctions.cpp' object='FileFunctions.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../../../depcomp \
        CC -DHAVE_CONFIG_H -I. -I../../..  -DUSE_WX_EXTENSIONS  -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0  -O2 -mt -D_REENTRANT  -xlang=c99 -c -o FileFunctions.o FileFunctions.cpp
\
        source='Format.cpp' object='Format.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../../../depcomp \
        CC -DHAVE_CONFIG_H -I. -I../../..  -DUSE_WX_EXTENSIONS  -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0  -O2 -mt -D_REENTRANT  -xlang=c99 -c -o Format.o Format.cpp
\
        source='MD5Sum.cpp' object='MD5Sum.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../../../depcomp \
        CC -DHAVE_CONFIG_H -I. -I../../..  -DUSE_WX_EXTENSIONS  -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0  -O2 -mt -D_REENTRANT  -xlang=c99 -c -o MD5Sum.o MD5Sum.cpp
\
        source='MuleDebug.cpp' object='MuleDebug.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../../../depcomp \
        CC -DHAVE_CONFIG_H -I. -I../../..  -DUSE_WX_EXTENSIONS  -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0  -O2 -mt -D_REENTRANT  -xlang=c99 -c -o MuleDebug.o MuleDebug.cpp
"MuleDebug.cpp", line 67: Warning (Anachronism): Formal argument 1 of type void(*)() in call to std::set_terminate(void(*)()) is being passed extern "C" void(*)().
1 Warning(s) detected.
\
        source='Path.cpp' object='Path.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../../../depcomp \
        CC -DHAVE_CONFIG_H -I. -I../../..  -DUSE_WX_EXTENSIONS  -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0  -O2 -mt -D_REENTRANT  -xlang=c99 -c -o Path.o Path.cpp
\
        source='strerror_r.c' object='strerror_r.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../../../depcomp \
        cc -DHAVE_CONFIG_H -I. -I../../..  -DUSE_WX_EXTENSIONS  -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0    -c strerror_r.c
"/usr/include/sys/feature_tests.h", line 358: #error: "Compiler or options invalid; UNIX 03 and POSIX.1-2001 applications       require the use of c99"
cc: acomp failed for strerror_r.c
gmake[4]: *** [strerror_r.o] Error 2
gmake[4]: Leaving directory `/usr/local/aMule-2.3.1/src/libs/common'
gmake[3]: *** [all-recursive] Error 1
gmake[3]: Leaving directory `/usr/local/aMule-2.3.1/src/libs'
gmake[2]: *** [all-recursive] Error 1
gmake[2]: Leaving directory `/usr/local/aMule-2.3.1/src'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/usr/local/aMule-2.3.1'
gmake: *** [all] Error 2


i want to report that ALL the times that ./configure ends i get also these messages
(they have been already reported in another topic)

Code: [Select]
config.status: creating po/Makefile
config.status: executing denoiser commands
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9
Unrecognized command:   /^MULEC\(XX\)\?FLAGS/! b 9


  Configure script has finished system check.


....so still nothing
Logged

peerstudio

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 17
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #4 on: December 30, 2011, 03:17:12 PM »

i compiled manually stderror like before and carried on with -xlang=c99

Code: [Select]
        source='GapList.cpp' object='libmuleappcommon_a-GapList.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0 -I./libs -I./include -I/usr/include -D__WEAK_CRYPTO__   -O2 -xlang=c99 -c -o libmuleappcommon_a-GapList.o `test -f 'GapList.cpp' || echo './'`GapList.cpp
"./include/common/Macros.h", line 33: Warning (Anachronism): Attempt to redefine SEC without using #undef.
"GapList.cpp", line 108: Error: Could not find a match for std::map<unsigned long long,unsigned long long>::insert(__rwstd::__rb_tree<unsigned long long, std::pair<const unsigned long long, unsigned long long>, __rwstd::__select1st<std::pair<const unsigned long long, unsigned long long>, unsigned long long>, std::less<unsigned long long>, std::allocator<std::pair<const unsigned long long, unsigned long long>>>::iterator, std::pair<unsigned long long, unsigned long long>) needed in CGapList::AddGap(unsigned long long, unsigned long long).
"GapList.cpp", line 173: Error: Could not find a match for std::map<unsigned long long,unsigned long long>::insert(__rwstd::__rb_tree<unsigned long long, std::pair<const unsigned long long, unsigned long long>, __rwstd::__select1st<std::pair<const unsigned long long, unsigned long long>, unsigned long long>, std::less<unsigned long long>, std::allocator<std::pair<const unsigned long long, unsigned long long>>>::iterator, std::pair<unsigned long long, unsigned long long>) needed in CGapList::FillGap(unsigned long long, unsigned long long).
"GapList.cpp", line 183: Error: Could not find a match for std::map<unsigned long long,unsigned long long>::insert(__rwstd::__rb_tree<unsigned long long, std::pair<const unsigned long long, unsigned long long>, __rwstd::__select1st<std::pair<const unsigned long long, unsigned long long>, unsigned long long>, std::less<unsigned long long>, std::allocator<std::pair<const unsigned long long, unsigned long long>>>::iterator, std::pair<unsigned long long, unsigned long long>) needed in CGapList::FillGap(unsigned long long, unsigned long long).
3 Error(s) and 1 Warning(s) detected.
make[3]: *** [libmuleappcommon_a-GapList.o] Error 2
make[3]: Leaving directory `/usr/local/aMule-2.3.1/src'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/usr/local/aMule-2.3.1/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/local/aMule-2.3.1'
make: *** [all] Error 2

again gaplist.cpp

it looks like that with the c99 flag we are going nowhere...
Logged

peerstudio

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 17
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #5 on: December 30, 2011, 03:28:38 PM »

not knowing what to do i tried this flag:

Code: [Select]
  -compat=g
(x86 Only) enables recognition of g++ language
extensions and causes the compiler to generate
code that is binary-compatible with g++ on x86
Oracle Solaris and  Linux platforms.

The binary compatibility extends only to shared
(dynamic or .so) libraries, not to individual .o
files or archive (.a) libraries.



from http://docs.oracle.com/cd/E24457_01/html/E22003/cplusplus.1.html

but at the first source file

Code: [Select]
\
        source='FileFunctions.cpp' object='FileFunctions.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../../../depcomp \
        CC -DHAVE_CONFIG_H -I. -I../../..  -DUSE_WX_EXTENSIONS  -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0  -O2 -mt -D_REENTRANT  -compat=g -c -o FileFunctions.o FileFunctions.cpp
CC: Warning: Can not determine include paths to compile with -library=stdcpp, please, consult documentation
"/usr/include/wx-2.8/wx/string.h", line 176: Error: Could not open include file<string>.
"/usr/include/wx-2.8/wx/string.h", line 181: Error: wstring is not a member of std.

Logged

peerstudio

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 17
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #6 on: December 30, 2011, 03:43:45 PM »

now i am using oracle solaris studio 12.2, installed from the official repository with the ips pkg.

Code: [Select]
\
        source='GapList.cpp' object='libmuleappcommon_a-GapList.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0 -I./libs -I./include -I/usr/include -D__WEAK_CRYPTO__   -O2 -I/usr/local/include -c -o libmuleappcommon_a-GapList.o `test -f 'GapList.cpp' || echo './'`GapList.cpp
"./include/common/Macros.h", line 33: Warning (Anachronism): Attempt to redefine SEC without using #undef.
"GapList.cpp", line 108: Error: Could not find a match for std::map<unsigned long long,unsigned long long>::insert(__rwstd::__rb_tree<unsigned long long, std::pair<const unsigned long long, unsigned long long>, __rwstd::__select1st<std::pair<const unsigned long long, unsigned long long>, unsigned long long>, std::less<unsigned long long>, std::allocator<std::pair<const unsigned long long, unsigned long long>>>::iterator, std::pair<unsigned long long, unsigned long long>) needed in CGapList::AddGap(unsigned long long, unsigned long long).
"GapList.cpp", line 173: Error: Could not find a match for std::map<unsigned long long,unsigned long long>::insert(__rwstd::__rb_tree<unsigned long long, std::pair<const unsigned long long, unsigned long long>, __rwstd::__select1st<std::pair<const unsigned long long, unsigned long long>, unsigned long long>, std::less<unsigned long long>, std::allocator<std::pair<const unsigned long long, unsigned long long>>>::iterator, std::pair<unsigned long long, unsigned long long>) needed in CGapList::FillGap(unsigned long long, unsigned long long).
"GapList.cpp", line 183: Error: Could not find a match for std::map<unsigned long long,unsigned long long>::insert(__rwstd::__rb_tree<unsigned long long, std::pair<const unsigned long long, unsigned long long>, __rwstd::__select1st<std::pair<const unsigned long long, unsigned long long>, unsigned long long>, std::less<unsigned long long>, std::allocator<std::pair<const unsigned long long, unsigned long long>>>::iterator, std::pair<unsigned long long, unsigned long long>) needed in CGapList::FillGap(unsigned long long, unsigned long long).
3 Error(s) and 1 Warning(s) detected.
gmake[3]: *** [libmuleappcommon_a-GapList.o] Error 2
gmake[3]: Leaving directory `/usr/local/aMule-2.3.1/src'
gmake[2]: *** [all-recursive] Error 1
gmake[2]: Leaving directory `/usr/local/aMule-2.3.1/src'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/usr/local/aMule-2.3.1'
gmake: *** [all] Error 2

this time i have used no flags.
Logged

peerstudio

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 17
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #7 on: December 30, 2011, 03:49:41 PM »

the packages that are currently installed are:

Code: [Select]
#pkg search -l -o pkg.name "*devel*" | grep devel
developer/solarisstudio-122/cc
developer/solarisstudio-122/c++
developer/solarisstudio-122/library/c++-libs
developer/solarisstudio-122/library/math-libs
developer/solarisstudio-122/backend
developer/solarisstudio-122/studio-legal
developer/solarisstudio-122/studio-common
developer/documentation-tool/opensp
developer/build/make
developer/build/automake-110
developer/build/makedepend
developer/versioning/git
developer/base-developer-utilities
developer/versioning/sccs
developer/debug/mdb
developer/build/autoconf
developer/build/libtool
developer/library/xprofile
developer/documentation-tool/openjade
developer/build/autoconf/xorg-macros
developer/assembler
developer/gnome/gettext
developer/macro/cpp
developer/build/gnu-make
developer/macro/gnu-m4
developer/library/lint
Logged

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #8 on: December 30, 2011, 05:35:06 PM »

Looks like your STL doesn't support map::insert with an iterator (which is a performance optimization).
Just remove the iterators like this:

Code: [Select]
Index: GapList.cpp
===================================================================
--- GapList.cpp (revision 10704)
+++ GapList.cpp (working copy)
@@ -105,7 +105,7 @@
  if (it != m_gaplist.begin()) {
  --it;
  }
- m_gaplist.insert(it, std::pair<uint64,uint64>(gapend, gapstart));
+ m_gaplist.insert(std::pair<uint64,uint64>(gapend, gapstart));
 }
 
 void CGapList::AddGap(uint16 part)
@@ -170,7 +170,7 @@
  if (it3 != m_gaplist.begin()) {
  --it3;
  }
- m_gaplist.insert(it3, std::pair<uint64,uint64>(partstart - 1, curGapStart));
+ m_gaplist.insert(std::pair<uint64,uint64>(partstart - 1, curGapStart));
  // we're done
  break;
  } else if (curGapEnd >= partstart) {
@@ -180,7 +180,7 @@
  if (it3 != m_gaplist.begin()) {
  --it3;
  }
- m_gaplist.insert(it3, std::pair<uint64,uint64>(partstart - 1, curGapStart));
+ m_gaplist.insert(std::pair<uint64,uint64>(partstart - 1, curGapStart));
  // and delete the old one
  m_gaplist.erase(it2);
  }
Logged
The image of mother goddess, lying dormant in the eyes of the dead, the sheaf of the corn is broken, end the harvest, throw the dead on the pyre -- Iron Maiden, Isle of Avalon

peerstudio

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 17
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #9 on: December 30, 2011, 05:47:24 PM »

you are right. the iterators are deleted
now that file compiles correctly.

the next (MagnetURI.cpp) is MagnetURI.cpp

Code: [Select]
\
        source='GapList.cpp' object='libmuleappcommon_a-GapList.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0 -I./libs -I./include -I/usr/include -D__WEAK_CRYPTO__   -O2 -I/usr/local/include -c -o libmuleappcommon_a-GapList.o `test -f 'GapList.cpp' || echo './'`GapList.cpp
\
        source='MagnetURI.cpp' object='libmuleappcommon_a-MagnetURI.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0 -I./libs -I./include -I/usr/include -D__WEAK_CRYPTO__   -O2 -I/usr/local/include -c -o libmuleappcommon_a-MagnetURI.o `test -f 'MagnetURI.cpp' || echo './'`MagnetURI.cpp
"./include/common/Macros.h", line 33: Warning (Anachronism): Attempt to redefine SEC without using #undef.
1 Warning(s) detected.
"MagnetURI.cpp", line 40: Warning (Anachronism): Attempt to redefine _C without using #undef.
"MagnetURI.cpp", line 46: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 64: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 98: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 102: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 103: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 104: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 120: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 120: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 122: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 128: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 130: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 133: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 136: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
"MagnetURI.cpp", line 141: Error: The function "_T" must have a prototype.
20 Error(s) and 1 Warning(s) detected.
gmake[3]: *** [libmuleappcommon_a-MagnetURI.o] Error 2
gmake[3]: *** Waiting for unfinished jobs....
gmake[3]: Leaving directory `/usr/local/aMule-2.3.1/src'
gmake[2]: *** [all-recursive] Error 1
gmake[2]: Leaving directory `/usr/local/aMule-2.3.1/src'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/usr/local/aMule-2.3.1'
gmake: *** [all] Error 2

with gmake -k i have many other errors:
Code: [Select]
\
        source='amuled.cpp' object='amuled-amuled.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0   -I./libs -Ilibs -I./include -I/usr/include -D__WEAK_CRYPTO__ -DAMULE_DAEMON   -O2 -mt -D_REENTRANT  -I/usr/local/include -c -o amuled-amuled.o `test -f 'amuled.cpp' || echo './'`amuled.cpp
"amuleIPV4Address.h", line 58: Warning: amuleIPV4Address::Hostname hides the virtual function wxIPV4address::Hostname() const.
"Proxy.h", line 509: Warning: CSocketClientProxy::Connect hides the virtual function wxSocketClient::Connect(wxSockAddress&, bool).
"./include/common/Macros.h", line 33: Warning (Anachronism): Attempt to redefine SEC without using #undef.
"amuled.cpp", line 523: Error: Strings of differing character types cannot be catenated.
"amuled.cpp", line 575: Warning (Anachronism): Assigning void(*)(int,siginfo*,void*) to extern "C" void(*)(int,siginfo*,void*).
1 Error(s) and 4 Warning(s) detected.
gmake[3]: *** [amuled-amuled.o] Error 2
\
        source='amule.cpp' object='amuled-amule.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0   -I./libs -Ilibs -I./include -I/usr/include -D__WEAK_CRYPTO__ -DAMULE_DAEMON   -O2 -mt -D_REENTRANT  -I/usr/local/include -c -o amuled-amule.o `test -f 'amule.cpp' || echo './'`amule.cpp
"kademlia/kademlia/../../amuleIPV4Address.h", line 58: Warning: amuleIPV4Address::Hostname hides the virtual function wxIPV4address::Hostname() const.
"kademlia/kademlia/../../Proxy.h", line 509: Warning: CSocketClientProxy::Connect hides the virtual function wxSocketClient::Connect(wxSockAddress&, bool).
"./include/common/Macros.h", line 33: Warning (Anachronism): Attempt to redefine SEC without using #undef.
"StatTree.h", line 243: Error: Could not find a match for std::list<CStatTreeItemBase*>::sort(bool(const CStatTreeItemBase*,const CStatTreeItemBase*)) needed in CStatTreeItemBase::ReSortChildren().
"UserEvents.h", line 124: Warning: Identifier expected instead of "}".
"amule.cpp", line 390: Warning (Anachronism): Formal argument 2 of type extern "C" void(*)(int) in call to std::signal(int, extern "C" void(*)(int)) is being passed void(*)(int).
"amule.cpp", line 391: Warning (Anachronism): Formal argument 2 of type extern "C" void(*)(int) in call to std::signal(int, extern "C" void(*)(int)) is being passed void(*)(int).
1 Error(s) and 6 Warning(s) detected.
gmake[3]: *** [amuled-amule.o] Error 2

looking at the following errors the are all pretty the same, for example:
Code: [Select]
"UploadQueue.cpp", line 273: Error: The function "_T" must have a prototype.

Code: [Select]
"StatTree.h", line 243: Error: Could not find a match for std::list<CStatTreeItemBase*>::sort(bool(const CStatTreeItemBase*,const CStatTreeItemBase*)) needed in CStatTreeItemBase::ReSortChildren().

a more radical approach is needed?
Logged

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #10 on: December 30, 2011, 06:16:15 PM »

Looks like you have to add -DwxNEEDS__T to your compiler options.

The _T in MagnetURI.cpp exists for a reason, because it is also used in non-wx programs.
In other places like UploadQueue.cpp it is just an oversight.

Code: (wxchar.h) [Select]
/*
    We define _T() as a synonym of wxT() for backwards compatibility and also
    for the benefit of Windows programmers used to it. But this identifier is a
    reserved one and this does create problems in practice, notably with Sun CC
    which uses it in the recent versions of its standard headers. So avoid
    defining it for this compiler at all, unless it was explicitly requested by
    predefining wxNEEDS__T macro before including this header or if we're
    building wx itself which does need and compiles fine thanks to the special
    workarounds for Sun CC in wx/{before,after}std.h.
 */
#ifndef wxNEEDS__T
    #if defined(WXBUILDING) || !(defined (__SUNPRO_C) || defined(__SUNPRO_CC))
        #define wxNEEDS__T
    #endif
#endif

#ifdef wxNEEDS__T
    /* BSDs define _T() to be something different in ctype.h, override it */
    #if defined(__FreeBSD__) || defined(__DARWIN__)
        #include <ctype.h>
    #endif
    #undef _T

    #define _T(x) wxT(x)
#endif /* wxNEEDS__T */

amuled:523:
Code: [Select]
*msg << wxT("Error: waitpid() call returned 0 but "
"WNOHANG was not specified in options.");
Ah, like Windows.  :) Just use
Code: [Select]
*msg << wxT("Error: waitpid() call returned 0 but WNOHANG was not specified in options.");

StatTree.h:243:
Code: [Select]
void ReSortChildren() { wxMutexLocker lock(m_lock); m_children.sort(ValueSort); }
So much for Standard Template Library. Apparently it has no sort. Just live with an unsorted stat tree for now (I believe it's not used in amuled anyway):
Code: [Select]
void ReSortChildren() {}
Logged
The image of mother goddess, lying dormant in the eyes of the dead, the sheaf of the corn is broken, end the harvest, throw the dead on the pyre -- Iron Maiden, Isle of Avalon

peerstudio

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 17
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #11 on: December 30, 2011, 06:27:09 PM »

thank you.
i will try these changes ASAP, and let you all know.

note also that i have not listed all the source files that has these errors.

anyway, since in these threads they suggest to use stdcxx from Apache,
https://forums.oracle.com/forums/thread.jspa?threadID=2214485
https://forums.oracle.com/forums/thread.jspa?threadID=2218424

and solaris studio 12.3 supports it.

i will try to add this flag:  -library=stdcxx
Logged

peerstudio

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 17
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #12 on: December 30, 2011, 07:08:25 PM »

OK,
now i'm with oss 12.3

after changing:

amuled.cpp:523
StatTree.h:243

and configuring with:

./configure CFLAGS=-xc99 CXXFLAGS=-DwxNEEDS_T --disable-monolithic  --enable-amule-daemon --disable-amulecmd --disable-webserver --disable-amule-gui --disable-cas --disable-wxcas --disable-alc --disable-alcc --disable-xas --disable-fileview --disable-plasmamule --disable-geoip --disable-upnp --disable-debug --disable-nls --with-zlib=sys --disable-ed2k --enable-optimize --enable-mmap

the first errors is here:
Code: [Select]
\
        source='ClientList.cpp' object='amuled-ClientList.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0   -I./libs -Ilibs -I./include -I/usr/include -D__WEAK_CRYPTO__ -DAMULE_DAEMON   -O2 -mt -D_REENTRANT  -DwxNEEDS_T -c -o amuled-ClientList.o `test -f 'ClientList.cpp' || echo './'`ClientList.cpp
"./include/common/Macros.h", line 33: Warning (Anachronism): Attempt to redefine SEC without using #undef.
"amuleIPV4Address.h", line 58: Warning: amuleIPV4Address::Hostname hides the virtual function wxIPV4address::Hostname() const.
"Proxy.h", line 509: Warning: CSocketClientProxy::Connect hides the virtual function wxSocketClient::Connect(wxSockAddress&, bool).
"ClientList.cpp", line 114: Error: Could not find a match for std::multimap<unsigned, CClientRef, std::less<unsigned>, std::allocator<std::pair<const unsigned, CClientRef>>>::insert(std::pair<unsigned, CClientRef>) needed in CClientList::AddClient(CUpDownClient*).
"ClientList.cpp", line 118: Error: Could not find a match for std::multimap<unsigned, CClientRef, std::less<unsigned>, std::allocator<std::pair<const unsigned, CClientRef>>>::insert(std::pair<unsigned, CClientRef>) needed in CClientList::AddClient(CUpDownClient*).
"ClientList.cpp", line 123: Error: Could not find a match for std::multimap<CMD4Hash, CClientRef, std::less<CMD4Hash>, std::allocator<std::pair<const CMD4Hash, CClientRef>>>::insert(std::pair<CMD4Hash, CClientRef>) needed in CClientList::AddClient(CUpDownClient*).
"ClientList.cpp", line 154: Error: Could not find a match for std::multimap<unsigned, CClientRef, std::less<unsigned>, std::allocator<std::pair<const unsigned, CClientRef>>>::insert(std::pair<unsigned, CClientRef>) needed in CClientList::UpdateClientID(CUpDownClient*, unsigned).
"ClientList.cpp", line 168: Error: Could not find a match for std::multimap<unsigned, CClientRef, std::less<unsigned>, std::allocator<std::pair<const unsigned, CClientRef>>>::insert(std::pair<unsigned, CClientRef>) needed in CClientList::UpdateClientIP(CUpDownClient*, unsigned).
"ClientList.cpp", line 185: Error: Could not find a match for std::multimap<CMD4Hash, CClientRef, std::less<CMD4Hash>, std::allocator<std::pair<const CMD4Hash, CClientRef>>>::insert(std::pair<CMD4Hash, CClientRef>) needed in CClientList::UpdateClientHash(CUpDownClient*, const CMD4Hash&).
"ClientList.cpp", line 268: Error: Cannot use std::pair<__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CClientRef>, __rwstd::__select1st<std::pair<const unsigned, CClientRef>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CClientRef>>>::iterator, __rwstd::__rb_tree<unsigned, std::pair<const unsigned, CClientRef>, __rwstd::__select1st<std::pair<const unsigned, CClientRef>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CClientRef>>>::iterator> to initialize std::pair<__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CClientRef>, __rwstd::__select1st<std::pair<const unsigned, CClientRef>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CClientRef>>>::const_iterator, __rwstd::__rb_tree<unsigned, std::pair<const unsigned, CClientRef>, __rwstd::__select1st<std::pair<const unsigned, CClientRef>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CClientRef>>>::const_iterator>.
"ClientList.cpp", line 285: Error: Cannot use std::pair<__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CClientRef>, __rwstd::__select1st<std::pair<const unsigned, CClientRef>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CClientRef>>>::iterator, __rwstd::__rb_tree<unsigned, std::pair<const unsigned, CClientRef>, __rwstd::__select1st<std::pair<const unsigned, CClientRef>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CClientRef>>>::iterator> to initialize std::pair<__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CClientRef>, __rwstd::__select1st<std::pair<const unsigned, CClientRef>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CClientRef>>>::const_iterator, __rwstd::__rb_tree<unsigned, std::pair<const unsigned, CClientRef>, __rwstd::__select1st<std::pair<const unsigned, CClientRef>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CClientRef>>>::const_iterator>.
"ClientList.cpp", line 301: Warning: A class with a reference member lacks a user-defined constructor, which can lead to errors.
8 Error(s) and 4 Warning(s) detected.
gmake[3]: *** [amuled-ClientList.o] Error 2
gmake[3]: Leaving directory `/usr/local/aMule-2.3.1/src'
gmake[2]: *** [all-recursive] Error 1
gmake[2]: Leaving directory `/usr/local/aMule-2.3.1/src'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/usr/local/aMule-2.3.1'
gmake: *** [all] Error 2


here we go again with std::vector
Code: [Select]
\
        source='DownloadQueue.cpp' object='amuled-DownloadQueue.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0   -I./libs -Ilibs -I./include -I/usr/include -D__WEAK_CRYPTO__ -DAMULE_DAEMON   -O2 -mt -D_REENTRANT  -DwxNEEDS_T -c -o amuled-DownloadQueue.o `test -f 'DownloadQueue.cpp' || echo './'`DownloadQueue.cpp
"amuleIPV4Address.h", line 58: Warning: amuleIPV4Address::Hostname hides the virtual function wxIPV4address::Hostname() const.
"Proxy.h", line 509: Warning: CSocketClientProxy::Connect hides the virtual function wxSocketClient::Connect(wxSockAddress&, bool).
"./include/common/Macros.h", line 33: Warning (Anachronism): Attempt to redefine SEC without using #undef.
"UserEvents.h", line 124: Warning: Identifier expected instead of "}".
"DownloadQueue.cpp", line 1535: Error: Could not find a match for std::vector<CPartFile*>::insert(CPartFile**, std::deque<CPartFile*>::iterator, std::deque<CPartFile*>::iterator) needed in CDownloadQueue::ObserverAdded(CObserver<CQueueEvent<CPartFile*>>*).
1 Error(s) and 4 Warning(s) detected.
gmake[3]: *** [amuled-DownloadQueue.o] Error 2

the next is:
Code: [Select]
\
        source='IPFilter.cpp' object='amuled-IPFilter.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0   -I./libs -Ilibs -I./include -I/usr/include -D__WEAK_CRYPTO__ -DAMULE_DAEMON   -O2 -mt -D_REENTRANT  -DwxNEEDS_T -c -o amuled-IPFilter.o `test -f 'IPFilter.cpp' || echo './'`IPFilter.cpp
"amuleIPV4Address.h", line 58: Warning: amuleIPV4Address::Hostname hides the virtual function wxIPV4address::Hostname() const.
"Proxy.h", line 509: Warning: CSocketClientProxy::Connect hides the virtual function wxSocketClient::Connect(wxSockAddress&, bool).
"./include/common/Macros.h", line 33: Warning (Anachronism): Attempt to redefine SEC without using #undef.
"RangeMap.h", line 492: Error: Could not find a match for std::map<unsigned,CRangeMapHelper<CIPFilterTask::rangeObject, unsigned> >::insert(__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CRangeMapHelper<CIPFilterTask::rangeObject, unsigned>>, __rwstd::__select1st<std::pair<const unsigned, CRangeMapHelper<CIPFilterTask::rangeObject, unsigned>>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CRangeMapHelper<CIPFilterTask::rangeObject, unsigned>>>>::iterator, std::pair<unsigned, CRangeMapHelper<CIPFilterTask::rangeObject, unsigned>>) needed in CRangeMap<CIPFilterTask::rangeObject, unsigned>::do_insert(unsigned, CRangeMapHelper<CIPFilterTask::rangeObject, unsigned>, bool).
"RangeMap.h", line 424:     Where: While instantiating "CRangeMap<CIPFilterTask::rangeObject, unsigned>::do_insert(unsigned, CRangeMapHelper<CIPFilterTask::rangeObject, unsigned>, bool)".
"RangeMap.h", line 424:     Where: Instantiated from CRangeMap<CIPFilterTask::rangeObject, unsigned>::insert<CIPFilterTask::rangeObject>(unsigned, unsigned, const CIPFilterTask::rangeObject&).
"IPFilter.cpp", line 262:     Where: Instantiated from non-template code.
"RangeMap.h", line 526: Error: Could not find a match for std::map<unsigned,CRangeMapHelper<CIPFilterTask::rangeObject, unsigned> >::insert(__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CRangeMapHelper<CIPFilterTask::rangeObject, unsigned>>, __rwstd::__select1st<std::pair<const unsigned, CRangeMapHelper<CIPFilterTask::rangeObject, unsigned>>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CRangeMapHelper<CIPFilterTask::rangeObject, unsigned>>>>::iterator, std::pair<unsigned, CRangeMapHelper<CIPFilterTask::rangeObject, unsigned>>) needed in CRangeMap<CIPFilterTask::rangeObject, unsigned>::do_insert(unsigned, CRangeMapHelper<CIPFilterTask::rangeObject, unsigned>, bool).
"RangeMap.h", line 424:     Where: While instantiating "CRangeMap<CIPFilterTask::rangeObject, unsigned>::do_insert(unsigned, CRangeMapHelper<CIPFilterTask::rangeObject, unsigned>, bool)".
"RangeMap.h", line 424:     Where: Instantiated from CRangeMap<CIPFilterTask::rangeObject, unsigned>::insert<CIPFilterTask::rangeObject>(unsigned, unsigned, const CIPFilterTask::rangeObject&).
"IPFilter.cpp", line 262:     Where: Instantiated from non-template code.
2 Error(s) and 3 Warning(s) detected.
gmake[3]: *** [amuled-IPFilter.o] Error 2

Code: [Select]
        source='KnownFileList.cpp' object='amuled-KnownFileList.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0   -I./libs -Ilibs -I./include -I/usr/include -D__WEAK_CRYPTO__ -DAMULE_DAEMON   -O2 -mt -D_REENTRANT  -DwxNEEDS_T -c -o amuled-KnownFileList.o `test -f 'KnownFileList.cpp' || echo './'`KnownFileList.cpp
"./include/common/Macros.h", line 33: Warning (Anachronism): Attempt to redefine SEC without using #undef.
"kademlia/kademlia/../../amuleIPV4Address.h", line 58: Warning: amuleIPV4Address::Hostname hides the virtual function wxIPV4address::Hostname() const.
"kademlia/kademlia/../../Proxy.h", line 509: Warning: CSocketClientProxy::Connect hides the virtual function wxSocketClient::Connect(wxSockAddress&, bool).
"KnownFileList.cpp", line 189: Warning (Anachronism): Assigning std::pair<__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::iterator, __rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::iterator> to std::pair<__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::const_iterator, __rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::const_iterator>.
"KnownFileList.cpp", line 189: Error: Cannot cast from std::pair<__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::iterator, __rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::iterator> to std::pair<__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::const_iterator, __rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::const_iterator>.
"KnownFileList.cpp", line 217: Warning (Anachronism): Assigning std::pair<__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::iterator, __rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::iterator> to std::pair<__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::const_iterator, __rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::const_iterator>.
"KnownFileList.cpp", line 217: Error: Cannot cast from std::pair<__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::iterator, __rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::iterator> to std::pair<__rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::const_iterator, __rwstd::__rb_tree<unsigned, std::pair<const unsigned, CKnownFile*>, __rwstd::__select1st<std::pair<const unsigned, CKnownFile*>, unsigned>, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::const_iterator>.
"KnownFileList.cpp", line 327: Error: Could not find a match for std::multimap<unsigned, CKnownFile*, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::insert(std::pair<unsigned, CKnownFile*>) needed in CKnownFileList::PrepareIndex().
"KnownFileList.cpp", line 331: Error: Could not find a match for std::multimap<unsigned, CKnownFile*, std::less<unsigned>, std::allocator<std::pair<const unsigned, CKnownFile*>>>::insert(std::pair<unsigned, CKnownFile*>) needed in CKnownFileList::PrepareIndex().
4 Error(s) and 5 Warning(s) detected.
gmake[3]: *** [amuled-KnownFileList.o] Error 2

Code: [Select]
        source='ServerList.cpp' object='amuled-ServerList.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0   -I./libs -Ilibs -I./include -I/usr/include -D__WEAK_CRYPTO__ -DAMULE_DAEMON   -O2 -mt -D_REENTRANT  -DwxNEEDS_T -c -o amuled-ServerList.o `test -f 'ServerList.cpp' || echo './'`ServerList.cpp
"amuleIPV4Address.h", line 58: Warning: amuleIPV4Address::Hostname hides the virtual function wxIPV4address::Hostname() const.
"Proxy.h", line 509: Warning: CSocketClientProxy::Connect hides the virtual function wxSocketClient::Connect(wxSockAddress&, bool).
"./include/common/Macros.h", line 33: Warning (Anachronism): Attempt to redefine SEC without using #undef.
"ServerList.cpp", line 560: Error: Could not find a match for std::list<CServer*>::sort(ServerPriorityComparator) needed in CServerList::Sort().
"ServerList.cpp", line 929: Error: Could not find a match for std::vector<CServer*>::assign(std::list<CServer*>::iterator, std::list<CServer*>::iterator) needed in CServerList::ObserverAdded(CObserver<CQueueEvent<CServer*>>*).
"ServerList.cpp", line 968: Error: Could not find a match for std::vector<const CServer*>::assign(std::list<CServer*>::const_iterator, std::list<CServer*>::const_iterator) needed in CServerList::CopySnapshot() const.
3 Error(s) and 3 Warning(s) detected.
gmake[3]: *** [amuled-ServerList.o] Error 2

and that's it.
a lot of warnings follows all the source files.
most are due to:
Code: [Select]
Warning (Anachronism): Attempt to redefine SEC without using #undef.
Warning: amuleIPV4Address::Hostname hides the virtual function wxIPV4address::Hostname() const.
Warning:CSocketClientProxy::Connect hides the virtual function wxSocketClient::Connect(wxSockAddress&, bool).

i tried with -library=stdcxx4 after installing the library but no luck...
Logged

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #13 on: December 30, 2011, 09:37:57 PM »

I think you need a fully implemented STL. With this thing here we are getting nowhere.

What was the "no luck" with -library=stdcxx4 ?

Maybe Skolnick has an idea, he used to be our Solaris guru until he abandoned it.
Logged
The image of mother goddess, lying dormant in the eyes of the dead, the sheaf of the corn is broken, end the harvest, throw the dead on the pyre -- Iron Maiden, Isle of Avalon

peerstudio

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 17
Re: amule 2.3.1 - solaris 11/11 - sun compiler 12.3 : libCstd error
« Reply #14 on: December 30, 2011, 09:51:18 PM »

with the original source code
and with
/configure CFLAGS=-xc99 CXXFLAGS="-library=stdcxx4 -DwxNEEDS_T" --disable-monolithic  --enable-amule-daemon --disable-amulecmd --disable-webserver --disable-amule-gui --disable-cas --disable-wxcas --disable-alc --disable-alcc --disable-xas --disable-fileview --disable-plasmamule --disable-geoip --disable-upnp --disable-debug --disable-nls --with-zlib=sys --disable-ed2k --enable-optimize --enable-mmap

Code: [Select]
\
        source='ClientCredits.cpp' object='libmuleappcommon_a-ClientCredits.o' libtool=no \
        DEPDIR=.deps depmode=none /bin/sh ../depcomp \
        CC -DHAVE_CONFIG_H -I. -I..  -DUSE_WX_EXTENSIONS -I/usr/lib/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -DwxUSE_GUI=0 -I./libs -I./include -I/usr/include -D__WEAK_CRYPTO__   -O2 -library=stdcxx4 -DwxNEEDS_T -c -o libmuleappcommon_a-ClientCredits.o `test -f 'ClientCredits.cpp' || echo './'`ClientCredits.cpp
"ClientCredits.cpp", line 150: Error: The function "sqrt" must have a prototype.
1 Error(s) detected.
gmake[3]: *** [libmuleappcommon_a-ClientCredits.o] Error 2
gmake[3]: Leaving directory `/usr/local/aMule-2.3.1/src'
gmake[2]: *** [all-recursive] Error 1
gmake[2]: Leaving directory `/usr/local/aMule-2.3.1/src'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/usr/local/aMule-2.3.1'
gmake: *** [all] Error 2

the library that the stdcxx4 flag should use is:
Code: [Select]
pkg info stdcxx
          Name: library/c++/stdcxx
       Summary: The Apache C++ Standard Library
   Description: An Open Source ISO/IEC:14882:2003 Compliant Implementation of
                the C++ Standard Library
      Category: Development/C++
         State: Installed
     Publisher: solaris
       Version: 4.2.1
 Build Release: 5.11
        Branch: 0.175.0.0.0.2.537
Packaging Date: Wed Oct 19 10:31:48 2011
          Size: 77.40 MB
          FMRI: pkg://solaris/library/c++/stdcxx@4.2.1,5.11-0.175.0.0.0.2.537:20111019T103148Z

i have attached also the entire compile output
Logged
Pages: [1] 2