ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/OpenCL/h_extract
(Generate patch)

Comparing OpenCL/h_extract (file contents):
Revision 1.8 by root, Sat May 5 14:17:39 2012 UTC vs.
Revision 1.9 by root, Sat May 5 14:49:52 2012 UTC

8# constants 8# constants
9( 9(
10 echo '// autogenerated by h_extract' 10 echo '// autogenerated by h_extract'
11 cat $ALL_H | 11 cat $ALL_H |
12 perl -ne 'print "const_iv($1)\n" if /^#define CL_(\S+)/' 12 perl -ne 'print "const_iv($1)\n" if /^#define CL_(\S+)/'
13 cat CL/cl_platform.h |
14 perl -ne 'print "const_iv($1)\n" if /^#define CL_(\S+)\s+[^.]+\s*$/' |
15 sort | uniq |
16 perl -ne 'print unless /const_iv\((?:MAXFLOAT|INFINITY|NAN|HUGE_VALF?)\)/'
13) >constiv.h 17) >constiv.h
18
19# fp constants
20(
21 echo '// autogenerated by h_extract'
22 cat CL/cl_platform.h |
23 perl -ne 'print "const_nv($1)\n" if /^#define\s+CL_(\S+)\s+.*\..*\s*$/'
24 echo "const_nv(MAXFLOAT)"
25 echo "const_nv(INFINITY)"
26 echo "const_nv(HUGE_VAL)"
27 echo "const_nv(HUGE_VALF)"
28) >constnv.h
14 29
15# constants that look like enum values 30# constants that look like enum values
16( 31(
17 echo '// autogenerated by h_extract' 32 echo '// autogenerated by h_extract'
18 cat $ALL_H | 33 cat $ALL_H |
30# default constant values to -1 45# default constant values to -1
31( 46(
32 echo '// autogenerated by h_extract' 47 echo '// autogenerated by h_extract'
33 cat constiv.h | 48 cat constiv.h |
34 perl -ne '/const_iv\((.*)\)/ or next; print "#ifndef CL_$1\n#define CL_$1 -1\n#endif\n"' 49 perl -ne '/const_iv\((.*)\)/ or next; print "#ifndef CL_$1\n#define CL_$1 -1\n#endif\n"'
35) | sort >default.h 50) >default.h
36 51
37# *glGet*Info 52# *glGet*Info
38( 53(
39 <CL/cl.hpp perl -ne 'print "$1\n" if /^\s*F\((.*)\)\s*\\?\s*$/' 54 <CL/cl.hpp perl -ne 'print "$1\n" if /^\s*F\((.*)\)\s*\\?\s*$/'
40 # DEVICE_DOUBLE_FP_CONFIG 55 # DEVICE_DOUBLE_FP_CONFIG

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines