aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: Compilation error with arm4l arch  (Read 6111 times)

alhsu

  • Newbie
  • Karma: 0
  • Offline Offline
  • Posts: 3
Compilation error with arm4l arch
« on: January 15, 2009, 06:49:23 AM »

Hi all

1. I compilation cryptopp522 OK:
   JOBS=4
   PREFIX=/_install/usr/cryptopp
   env CC=$CC CXX=$CXX STRIP=$STRIP AR=$AR RANLIB=$RANLIB PREFIX=/_install/usr/cryptopp \
   make -f GNUmakefile -j${JOBS}

   mkdir -p ${PREFIX}
   mkdir -p ${PREFIX}/include/cryptopp
   mkdir -p ${PREFIX}/lib
   mkdir -p ${PREFIX}/bin

   cd /source/cryptopp552
   cp *.h ${PREFIX}/include/cryptopp
   cp *.a ${PREFIX}/lib
   cp *.exe ${PREFIX}/bin
   cd /

2. I compilation wxWidgets-2.8.9 OK(or i think?):
   env CC=/usr/local/920t_le/bin/arm_920t_le-gcc CXX=/usr/local/920t_le/bin/arm_920t_le-g++ STRIP=/usr/local/920t_le/bin/arm_920t_le-strip AR=/usr/local/920t_le/bin/arm_920t_le-ar RANLIB=/usr/local/920t_le/bin/arm_920t_le-ranlib \
      ./configure --host=armv4tl-hardhat-linux --target=armv4tl-hardhat-linux --build=i686-pc-linux \
      prefix=/_install/usr/wx \
      --enable-unicode --with-unicode \
      --with-gtk \
      && make

   make install

3. Then I compilation aMule-2.2.2 NG!!:
   env CC=/usr/local/920t_le/bin/arm_920t_le-gcc CXX=/usr/local/920t_le/bin/arm_920t_le-g++ STRIP=/usr/local/920t_le/bin/arm_920t_le-strip AR=/usr/local/920t_le/bin/arm_920t_le-ar RANLIB=/usr/local/920t_le/bin/arm_920t_le-ranlib \
      ./configure --host=armv4tl-hardhat-linux --target=armv4tl-hardhat-linux --build=i686-pc-linux \
      --disable-debug \
      --enable-optimize \
      --with-crypto-prefix=/_install/usr/cryptopp \
      --with-wx-prefix=/_install/usr/wx \
      --with-libupnp-prefix=/source/UPnP \
      --prefix=/_install/usr/aMule \
      && make

Code: [Select]
...
...

  Configure script has finished system check.

  Configured aMule 2.2.2 for 'armv4tl-hardhat-linux-gnu'.

  aMule enabled options:

  **** aMule Core ****
  Prefix where aMule should be installed?                    /_install/usr/aMule
  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?               yes
  Should aMule be compiled with UPnP support?                disabled
  Should aMule be compiled with IP2country support?          no
  Should aMule monolithic application be built?              yes
  Should aMule daemon version be built?                      no
  Should aMule remote gui be built? (EXPERIMENTAL)           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?                  yes

  **** 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

  **** General Libraries and Tools ****
  Should ccache support be enabled?                          no
  Libraries aMule will use to build:
                                       wxWidgets             2.8.9 (base,shared)
                                       crypto++              5.5.2 (installed, in /_install/usr/cryptopp)
                                       libintl               Not detected
                                       zlib                  1.2.1


WARNING! UPnP code has been disabled because cross compiling.

Generating ECVersion.h... created.
Compiling ECTag.cpp
Compiling ECPacket.cpp
Compiling ECSocket.cpp
Compiling ECMuleSocket.cpp
Compiling RemoteConnect.cpp
Compiling ECSpecialTags.cpp
Building libec.a
Compiling Format.cpp
Compiling MD5Sum.cpp
Compiling MuleDebug.cpp
Compiling StringFunctions.cpp
Compiling FileFunctions.cpp
Compiling TextFile.cpp
Compiling Path.cpp
Building libmulecommon.a
Compiling AsyncDNS.cpp
Compiling DeadSourceList.cpp
Compiling Scanner.cpp
Compiling Parser.cpp
Compiling PlatformSpecific.cpp
Compiling Entry.cpp
Compiling SearchManager.cpp
Compiling RoutingBin.cpp
Compiling StateMachine.cpp
Compiling ThreadScheduler.cpp
Building libmuleappcore.a
Compiling BarShader.cpp
BarShader.cpp:26:19: wx/dc.h: No such file or directory
BarShader.cpp: In member function `void CBarShader::BuildModifiers()':
BarShader.cpp:120: error: `sin' undeclared (first use this function)
BarShader.cpp:120: error: (Each undeclared identifier is reported only once for each function it appears in.)
BarShader.cpp: In member function `void CBarShader::Draw(wxDC*, int, int, bool)':
BarShader.cpp:201: error: aggregate `wxRect rectSpan' has incomplete type and cannot be defined
BarShader.cpp:208: error: invalid use of undefined type `struct wxDC'
BarShader.h:33: error: forward declaration of `struct wxDC'
BarShader.cpp:208: error: `wxTRANSPARENT_PEN' undeclared (first use this function)
BarShader.cpp:217: error: no matching function for call to `CBarShader::FillRect(wxDC*&, <type error>, uint32&, bool&)'
BarShader.h:147: note: candidates are: void CBarShader::FillRect(wxDC*, const wxRect&, uint32, bool)
BarShader.cpp:224: error: no matching function for call to `CBarShader::FillRect(wxDC*&, <type error>, uint32&, bool&)'
BarShader.h:147: note: candidates are: void CBarShader::FillRect(wxDC*, const wxRect&, uint32, bool)
BarShader.cpp: In member function `void CBarShader::FillRect(wxDC*, const wxRect&, uint32, bool)':
BarShader.cpp:233: error: `wxBrush' undeclared (first use this function)
BarShader.cpp:233: error: expected `;' before "brush"
BarShader.cpp:234: error: invalid use of undefined type `struct wxDC'
BarShader.h:33: error: forward declaration of `struct wxDC'
BarShader.cpp:234: error: `brush' undeclared (first use this function)
BarShader.cpp:235: error: invalid use of undefined type `struct wxDC'
BarShader.h:33: error: forward declaration of `struct wxDC'
BarShader.cpp:237: error: invalid use of undefined type `const struct wxRect'
BarShader.h:32: error: forward declaration of `const struct wxRect'
BarShader.cpp:238: error: invalid use of undefined type `const struct wxRect'
BarShader.h:32: error: forward declaration of `const struct wxRect'
BarShader.cpp:238: error: invalid use of undefined type `const struct wxRect'
BarShader.h:32: error: forward declaration of `const struct wxRect'
BarShader.cpp:239: error: invalid use of undefined type `const struct wxRect'
BarShader.h:32: error: forward declaration of `const struct wxRect'
BarShader.cpp:240: error: invalid use of undefined type `const struct wxRect'
BarShader.h:32: error: forward declaration of `const struct wxRect'
BarShader.cpp:248: error: `wxPen' undeclared (first use this function)
BarShader.cpp:248: error: expected `;' before "pen"
BarShader.cpp:249: error: invalid use of undefined type `struct wxDC'
BarShader.h:33: error: forward declaration of `struct wxDC'
BarShader.cpp:249: error: `pen' undeclared (first use this function)
BarShader.cpp:252: error: invalid use of undefined type `struct wxDC'
BarShader.h:33: error: forward declaration of `struct wxDC'
BarShader.cpp:255: error: invalid use of undefined type `struct wxDC'
BarShader.h:33: error: forward declaration of `struct wxDC'
BarShader.cpp:259: error: invalid use of undefined type `struct wxDC'
BarShader.h:33: error: forward declaration of `struct wxDC'
BarShader.cpp:259: error: `wxNullBrush' undeclared (first use this function)
make[3]: *** [libmuleappgui_a-BarShader.o] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2


Just like the aMule can not find the dc.h of wx.
That real!! I can not find any dc.h in my wx-prefix directory!!!
But there are a lot of dc.h in the wx source directory!!

Why?? Has any problem of the configure of wxWidgets-2.8.9 ???

Thanks.
« Last Edit: January 15, 2009, 07:10:14 AM by alhsu »
Logged

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: Compilation error with arm4l arch
« Reply #1 on: January 15, 2009, 09:54:02 PM »

You compiled wx --with-GTK, but amule's configure only found wxbase (which is not enough to build the monolith).
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

alhsu

  • Newbie
  • Karma: 0
  • Offline Offline
  • Posts: 3
Re: Compilation error with arm4l arch
« Reply #2 on: January 16, 2009, 03:28:23 AM »

You compiled wx --with-GTK, but amule's configure only found wxbase (which is not enough to build the monolith).

Hi Sir

What is your mean??
1. My system is not enough to build the wx ??
2. or my system is not enough to build the aMule ??
3. or the wx/aMule configure need some additional setup ??
3. or ....

Thinks,

AL
Logged

lfroen

  • Guest
Re: Compilation error with arm4l arch
« Reply #3 on: January 16, 2009, 07:50:06 AM »

Quote
1. My system is not enough to build the wx ??
Your system (which is embedded AFAIK) can't build GUI parts of wx

Quote
2. or my system is not enough to build the aMule ??
Without gui parts of wx, you obviously can't build gui part of aMule

Quote
3. or the wx/aMule configure need some additional setup ??
You should choose to compile non-gui version of amule: amuled (daemon), amuleweb (web server), etc

Quote
3. or ....
.... or provide more detailed explanation about your system and what you're trying to do.
Logged

alhsu

  • Newbie
  • Karma: 0
  • Offline Offline
  • Posts: 3
Re: Compilation error with arm4l arch
« Reply #4 on: January 16, 2009, 11:06:58 AM »

Quote
1. My system is not enough to build the wx ??
Your system (which is embedded AFAIK) can't build GUI parts of wx

Quote
2. or my system is not enough to build the aMule ??
Without gui parts of wx, you obviously can't build gui part of aMule

Quote
3. or the wx/aMule configure need some additional setup ??
You should choose to compile non-gui version of amule: amuled (daemon), amuleweb (web server), etc

Quote
3. or ....
.... or provide more detailed explanation about your system and what you're trying to do.



I try the amule-daemon that your reply,...

wxWidgets-2.8.9 -> ./configure --host=armv4tl-hardhat-linux --target=armv4tl-hardhat-linux --build=i686-pc-linux \
      prefix=/_install/usr/wx \
      --disable-gui --enable-unicode --without-subdirs --without-expat \
      && make
aMule-2.2.2 -> ./configure --host=armv4tl-hardhat-linux --target=armv4tl-hardhat-linux --build=i686-pc-linux \
         --disable-monolithic --with-toolkit=base --enable-amule-daemon --enable-amulecmd --enable-webserver \
         --disable-debug \
         --with-crypto-prefix=/_install/usr/cryptopp \
         --with-wx-prefix=/_install/usr/wx \
         --with-libupnp-prefix=/source/UPnP \
         --prefix=/_install/usr/aMule \
         && make

Then the aMule-2.2.2 just like make success, but Linking amuleweb have some problem...
Code: [Select]
...
  Configure script has finished system check.

  Configured aMule 2.2.2 for 'armv4tl-hardhat-linux-gnu'.

  aMule enabled options:

  **** aMule Core ****
  Prefix where aMule should be installed?                    /_install/usr/aMule
  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?                disabled
  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? (EXPERIMENTAL)           no
  Crypto++ library/headers style?                            installed

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

  **** aMule WebServer ****
  Should aMule WebServer be built?                           yes

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

  **** 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

  **** General Libraries and Tools ****
  Should ccache support be enabled?                          no
  Libraries aMule will use to build:
                                       wxWidgets             2.8.9 (,shared)
                                       crypto++              5.5.2 (installed, in /_install/usr/cryptopp)
                                       regex                 system
                                       libintl               Not detected
                                       libpng                Not detected
                                       zlib                  1.2.1


WARNING! libpng >= 1.2.0 not found.
amuleweb will be compiled but file download progress bar images will NOT be generated.



WARNING! UPnP code has been disabled because cross compiling.

Generating ECVersion.h... created.
Compiling ECTag.cpp
Compiling ECPacket.cpp
Compiling ECSocket.cpp
Compiling ECMuleSocket.cpp
Compiling RemoteConnect.cpp
Compiling ECSpecialTags.cpp
Building libec.a
Compiling Format.cpp
Compiling MD5Sum.cpp
Compiling MuleDebug.cpp
Compiling StringFunctions.cpp
Compiling FileFunctions.cpp
Compiling TextFile.cpp
Compiling Path.cpp
Building libmulecommon.a
Compiling WebServer.cpp
Compiling WebInterface.cpp
Compiling WebSocket.cpp
Compiling ExternalConnector.cpp
Compiling OtherFunctions.cpp
Compiling RLE.cpp
Compiling NetworkFunctions.cpp
Compiling php_parser.c
Compiling php_lexer.c
Compiling php_syntree.cpp
Compiling php_amule_lib.cpp
Compiling php_core_lib.cpp
Linking amuleweb
/usr/local/920t_le/bin/../lib/gcc/arm-linux/3.4.4/../../../../arm-linux/bin/ld: warning: libdl.so.2, needed by /_install/usr/wx/lib/libwx_baseu_net-2.8-armv4tl-hardhat-linux.so, not found (try using -rpath or -rpath-link)
/usr/local/920t_le/bin/../lib/gcc/arm-linux/3.4.4/../../../../arm-linux/bin/ld: warning: libiconv.so.2, needed by /_install/usr/wx/lib/libwx_baseu_net-2.8-armv4tl-hardhat-linux.so, not found (try using -rpath or -rpath-link)
/_install/usr/wx/lib/libwx_baseu-2.8-armv4tl-hardhat-linux.so: undefined reference to `dlclose@GLIBC_2.0'
/_install/usr/wx/lib/libwx_baseu-2.8-armv4tl-hardhat-linux.so: undefined reference to `dlerror@GLIBC_2.0'
/_install/usr/wx/lib/libwx_baseu-2.8-armv4tl-hardhat-linux.so: undefined reference to `dlopen@GLIBC_2.1'
/_install/usr/wx/lib/libwx_baseu-2.8-armv4tl-hardhat-linux.so: undefined reference to `dlsym@GLIBC_2.0'
/_install/usr/wx/lib/libwx_baseu-2.8-armv4tl-hardhat-linux.so: undefined reference to `libiconv_open'
/_install/usr/wx/lib/libwx_baseu-2.8-armv4tl-hardhat-linux.so: undefined reference to `libiconv_close'
/_install/usr/wx/lib/libwx_baseu-2.8-armv4tl-hardhat-linux.so: undefined reference to `libiconv'
collect2: ld returned 1 exit status
make[4]: *** [amuleweb] Error 1
make[3]: *** [all-recursive] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

I finded my "libdl.so.2" are in /lib, but the compilation can not find the libdl.so.2 !!
How do i lat the amule know where my libdl.so.2 ?
It said "try using -rpath or -rpath-link", how do i try -rpath or -rpath-link ??
Logged

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: Compilation error with arm4l arch
« Reply #5 on: January 16, 2009, 09:28:28 PM »

Hi Sir
"Stu" will do. We're on colloquial terms here.  :)
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

GonoszTopi

  • The current man in charge of most things.
  • Administrator
  • Hero Member
  • *****
  • Karma: 169
  • Offline Offline
  • Posts: 2685
Re: Compilation error with arm4l arch
« Reply #6 on: January 18, 2009, 01:46:55 PM »

I finded my "libdl.so.2" are in /lib, but the compilation can not find the libdl.so.2 !!
How do i lat the amule know where my libdl.so.2 ?

Because you're cross-compiling, host libraries in /lib and /usr/lib are not checked (they obviously wouldn't work on the target system). Check if the library is in the cross-linker's libraries (e.g. something like /usr/armv4tl-hardhat-linux/lib).
Logged
concordia cum veritate