[ragel] "include" does not check same directory in ragel 7? (trying to build rspamd)
Adrian Thurston
thurston at colm.net
Sun Aug 27 20:35:51 UTC 2017
Hi Felix, I just checked in some changes which should allow rspamd to
compile with ragel 7. Also fixes the duplicate include. Let me know if
you have further problems.
On 2017-08-19 17:30, Felix Schwarz wrote:
> Hey,
>
> I try to get rspamd (https://github.com/vstakhov/rspamd/) to build
> while using
> ragel 7 [1]. As documented in various bug reports this is not possible
> right
> now and I'd like to find out why this is (knowning next to nothing
> about ragel).
>
> This is the error I'm getting (CentOS 7) with the latest
> colm/ragel/rspamd git
> versions:
>
> [ 43%] [RAGEL][ragel_smtp_addr] Compiling state machine with Ragel
> 7.0.0.10
> error: could not open smtp_address.rl
> /bin/sh: line 1: 9721 Segmentation fault /usr/local/bin/ragel -T1
> -o/foo/rspamd/src/smtp_addr_parser.rl.c
> /foo/rspamd/src/ragel/smtp_addr_parser.rl
> make[2]: *** [src/smtp_addr_parser.rl.c] Error 139
>
>
> "smtp_addr_parser.rl" contains these lines (and some more):
> %%{
>
> machine smtp_date_parser;
> include smtp_date "smtp_date.rl";
>
> main := date_time;
> }%%
>
> "smtp_date.rl" is located in the same directory as "smtp_date.rl". The
> script
> can be compiled with ragel 6 without any problems.
>
> If I add the full patch in the include statement everything works as
> expected.
> Also when I manually "cd" into the directory everything is fine.
>
> The "ragel guide" (PDF) for 6.10 says:
> "Ragel searches for included files from the location of the current
> file.
> Additional directories can be added to the search path using the -I
> option."
>
>
> I seems that this behavior did change in 0.7 but I'm not sure if that
> is a bug
> or a conscious decision. Also adding "-I /foo/rspamd/src/ragel/" to the
> call
> did not help.
>
> thank you very much
> Felix
>
>
> [1] Background:
> Somehow the Fedora maintainer for ragel decided to use development
> releases of
> colm/ragel in Fedora (and even EPEL/CentOS). This unfortunate decision
> was
> maybe facilitated by the odd/even version numbering schema of ragel.
>
> _______________________________________________
> ragel mailing list
> ragel at colm.net
> http://www.colm.net/cgi-bin/mailman/listinfo/ragel
More information about the ragel-users
mailing list