| Revision: | 1.2 |
| Committed: | Sat Jan 25 00:15:52 2014 UTC (12 years, 9 months ago) by root |
| Branch: | MAIN |
| CVS Tags: | rel-4_4, rel-4_5, rel-4_6, rel-4_7, rel-4_2, rel-4_3, rel-4_52, rel-4_53, rel-4_51, rel-4_54, rel-4_71, rel-4_72, rel-4_73, rel-4_31, rel-4_32, rel-4_33, rel-4_34 |
| Changes since 1.1: | +5 -0 lines |
| Log Message: | 4.2 |
| # | User | Rev | Content |
|---|---|---|---|
| 1 | root | 1.1 | #!/usr/bin/perl |
| 2 | |||
| 3 | open STDIN, "<AIO.xs" | ||
| 4 | or die "AIO.xs: $!"; | ||
| 5 | |||
| 6 | open STDOUT, ">def0.h" | ||
| 7 | or die "def0.h: $!"; | ||
| 8 | |||
| 9 | root | 1.2 | print <<EOF; |
| 10 | /* GENERATED FILE */ | ||
| 11 | /* use ./gendef0 to regenerate this file */ | ||
| 12 | EOF | ||
| 13 | |||
| 14 | root | 1.1 | while (<>) { |
| 15 | if (/^\s*const_iv\s*\((\S+)\)\s*$/ || /^\s*const_niv\s*\([^,]+,\s*(\S+)\)\s*$/) { | ||
| 16 | print "#ifndef $1\n", | ||
| 17 | "#define $1 0\n", | ||
| 18 | "#endif\n"; | ||
| 19 | } | ||
| 20 | } |