From ba3d96c81985d987859f5fe57115de2736da6649 Mon Sep 17 00:00:00 2001 From: Yorick Peterse Date: Sat, 10 May 2014 00:28:23 +0200 Subject: [PATCH] Re-build lexers when base_lexer.rl changes. Thanks to @avdi for bringing up on how to do this when using rule() blocks. --- task/lexer.rake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/task/lexer.rake b/task/lexer.rake index 68338bb..d8eeec7 100644 --- a/task/lexer.rake +++ b/task/lexer.rake @@ -16,11 +16,11 @@ rule '.rb' => '.rl' do |task| end end -rule '.c' => '.rl' do |task| +rule '.c' => ['.rl', 'ext/ragel/base_lexer.rl'] do |task| sh "ragel -I ext/ragel -C -G2 #{task.source} -o #{task.name}" end -rule '.java' => '.rl' do |task| +rule '.java' => ['.rl', 'ext/ragel/base_lexer.rl'] do |task| sh "ragel -I ext/ragel -J #{task.source} -o #{task.name}" end