On Apr 8, 2010, at 9:06, "Alban Mouton" <alban.mou...@univ-ubs.fr> wrote:

Hello,

I am trying to build Tika parsers using JCC. I build tika-core without
problem, but tika-parsers generates an error.

My command line:
sudo python __main__.py --jar jar/tika-parsers-0.7.jar --classpath
jar/tika-app-0.7.jar --python tika_parsers --build --install
[...]
In file included from build/_tika/__wrap__.cpp:18185:
build/_tika/org/apache/tika/parser/asm/ClassParser.h:17: error: expected
identifier before ‘asm’
build/_tika/org/apache/tika/parser/asm/ClassParser.h:17: error: expected
‘(’ before ‘{’ token
build/_tika/org/apache/tika/parser/asm/ClassParser.h:17: error: expected
unqualified-id before ‘{’ token
build/_tika/__wrap__.cpp:25573: error: expected ‘}’ at end of inp ut build/_tika/__wrap__.cpp:25573: error: expected ‘}’ at end of inp ut build/_tika/__wrap__.cpp:25573: error: expected ‘}’ at end of inp ut build/_tika/__wrap__.cpp:25573: error: expected ‘}’ at end of inp ut
error: command 'gcc' failed with exit status 1


The faulty line 27 in ClassParser.h is : "namespace asm {"

I don't known much about C, but I think asm is a language keyword that
can't be used as a namespace and that's what JCC tried to do.

A patch would be greatly appreciated ! Or a temporary hack to make it work..

Indeed, asm should be a reserved word. You can add it on the command line, via --reserved, until it gets added to the JCC list in source.
For other command line options see --help.

Andi..


Thanks,

Alban Mouton

Reply via email to