1
0
Fork 0
forked from len0rd/rockbox

Lua: make sure action.h gets C preprocessed before processing it

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21123 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Maurus Cuelenaere 2009-05-28 22:02:53 +00:00
parent a96f2373db
commit acbbf93615
2 changed files with 2 additions and 8 deletions

View file

@ -18,13 +18,9 @@
# #
############################################################################ ############################################################################
$input = $ARGV[0] . "/../../action.h";
open(ACTION, "<$input") or die "Can't open $input!";
$i = 0; $i = 0;
$j = 0; $j = 0;
while(my $line = <ACTION>) while(my $line = <STDIN>)
{ {
chomp($line); chomp($line);
if($line =~ /^\s*(ACTION_[^\s]+)(\s*=.*)?,\s*$/) if($line =~ /^\s*(ACTION_[^\s]+)(\s*=.*)?,\s*$/)
@ -39,8 +35,6 @@ while(my $line = <ACTION>)
} }
} }
close(ACTION);
print "-- Don't change this file!\n"; print "-- Don't change this file!\n";
printf "-- It is automatically generated of action.h %s\n", '$Revision$'; printf "-- It is automatically generated of action.h %s\n", '$Revision$';

View file

@ -33,7 +33,7 @@ endif
$(LUA_BUILDDIR)/lua.rock: $(LUA_OBJ) $(LUA_BUILDDIR)/actions.lua $(LUA_BUILDDIR)/lua.rock: $(LUA_OBJ) $(LUA_BUILDDIR)/actions.lua
$(LUA_BUILDDIR)/actions.lua: $(LUA_OBJ) $(LUA_BUILDDIR)/actions.lua: $(LUA_OBJ)
$(call PRINTS,GEN $(@F))$(LUA_SRCDIR)/action_helper.pl $(LUA_SRCDIR) > $@ $(call PRINTS,GEN $(@F))$(CC) $(PLUGINFLAGS) -E $(APPSDIR)/action.h | $(LUA_SRCDIR)/action_helper.pl > $(LUA_BUILDDIR)/actions.lua
$(LUA_BUILDDIR)/lua.refmap: $(LUA_OBJ) $(LUA_BUILDDIR)/lua.refmap: $(LUA_OBJ)