aMule Forum
English => Compilation problems => Topic started by: alantang888 on June 13, 2008, 01:07:11 PM
-
HI,
when i use make after "./configure --prefix=/usr/local/aMule --enable-amule-daemon --enable-amulecmd --enable-webserver --enable-amule-gui --with-wxdir=/usr/local/wxWidgets/bin" got error, any can help???
Thank you
error:
Compiling Scanner.cpp
./Scanner.l: In function 'void LexFree()':
./Scanner.l:191: error: 'yylex_destroy' was not declared in this scope
make[3]: *** [libmuleappcore_a-Scanner.o] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
-
Hi,
do you have flex installed?
-
I also had this problem when I compiled 2.2.1 on my FC4 machine. I solved this by including "Scanner.h.in" in Scanner.l Hope this help.
-
flex installed
rpm -qa |grep flex
flex-2.5.4a-41.fc6
-
wcliao, your way is work!!!! but got anther problem:
Linking amule
./libmuleappcore.a(libmuleappcore_a-Scanner.o): In function `LexFree()':
/root/aMule/aMule-2.2.1/src/./Scanner.l:191: undefined reference to `yylex_destroy()'
collect2: ld returned 1 exit status
make[3]: *** [amule] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
thank yoy ;D
-
Hi wcliao,
thanks for the hint. Worked for me too.
EDIT:
Well, looks like i now have the same problem like alantang888. Compilation worked with adding the include but linking fails for the same reason.
-
I had the same problem on a Mandriva system.
I thus checked the version of Flex that I had and it was 2.5.4a
I upgraded it to 2.5.35 and the error did not go away while compiling. I thus edited the Scanner.l file and applied the suggested patch.
It compiled just fine and the link worked like a charm.
Thus I would suggest upgrading the requirements in configure to force having a version post 2.5.4a and add the fix in Scanner.l
Regards
EDIT: this was trying to compile the aMule 2.2.1 tgz archive content, no source repository content at all.
-
yeah!!! youpla's way is WORK!!!!! update flex to 2.5.35+ wcliao 's way "including "Scanner.h.in" in Scanner.l" is success to make & install!!
flex 2.5.35 rpm: ftp://ftp.uni-bayreuth.de/pub/redhat.com/fedora/linux/releases/9/Everything/i386/os/Packages/flex-2.5.35-1.fc9.i386.rpm
-
I had this same problem too, except on Suse 9.3.
Like the others above I added the following line to ../src/Scanner.l
#include <Scanner.h.in>
and that fixed it for me too ..