# warn about a file type
#format is
# tag (unique) ~~ type regex (x) [~~ name regex (x) optional empty means .* ~~ missing source transform regex separated by && or map or nothing do not check]
# note that map is not evaluated but check with regex so please use correct form:
# map { 's/SOMEREGEXP/'.$_.'/'} qw(LIST)
#
# File should match both "type regex" and "name regex"
#
source-contains-prebuilt-binary             ~~ \bELF\b                                                                   ~~                                   ~~ map { 's/(?i)(?:[\.-](?:bin|elf|hs|linux\d+|oo?|out|so(?:\.\d+)*)|static)?$/'.$_.'/'} qw(.asm .c .cc .cpp .cxx .f .F .ml .S)
source-contains-prebuilt-flash-object       ~~ ^Macromedia \s Flash                                                      ~~                                   ~~ s/(?i)\.swf$/.as/
source-contains-prebuilt-flash-project      ~~ ^Composite \s Document \s File                                            ~~ (?i)\.fla$                        ~~ s/(?i)\.fla$/.as/
source-contains-prebuilt-java-object        ~~ (?: Java [ ] (?:Jar [ ] file|archive [ ] data) | Zip [ ] archive | JAR)   ~~ (?i)\.jar$
# do not forget to change also $JS_EXT in file.pm
source-contains-prebuilt-javascript-object  ~~ .*                                                                        ~~ (?i)[-._](?:compiled|compressed|lite|min|pack(?:ed)?|yc)\.js$ ~~ map{'s/(?i)(?:[-._](?:compiled|compressed|lite|min|pack(?:ed)?|yc))?\.js$/'.$_.'/'} qw(.js _orig.js .js.orig .src.js .debug.js -debug.js)
# ok chm could be created from docbook or texi
source-contains-prebuilt-ms-help-file       ~~ ^MS \s Windows \s Html \s? Help \s Data ~~  (?i)\.chm$
source-contains-prebuilt-python-object      ~~ ^python \s \d(\.\d+)? \s byte-compiled                                    ~~ .*                                ~~ s/(?i)(?:\.cpython-\d{2}|\.pypy)?\.py[co]$/.py/
source-contains-prebuilt-silverlight-object ~~ ^Zip \s archive \s data                                                   ~~ (?i)\.xac$
source-contains-prebuilt-windows-binary     ~~ \b(?:PE(?:32|64)|(?:MS-DOS|COFF)\s executable)\b
