xref: /openbsd/usr.bin/lex/mkskel.sh (revision 09467b48)
1#! /bin/sh
2#	$OpenBSD: mkskel.sh,v 1.3 2015/11/19 19:43:40 tedu Exp $
3
4#  This file is part of flex.
5
6#  Redistribution and use in source and binary forms, with or without
7#  modification, are permitted provided that the following conditions
8#  are met:
9
10#  1. Redistributions of source code must retain the above copyright
11#     notice, this list of conditions and the following disclaimer.
12#  2. Redistributions in binary form must reproduce the above copyright
13#     notice, this list of conditions and the following disclaimer in the
14#     documentation and/or other materials provided with the distribution.
15
16#  Neither the name of the University nor the names of its contributors
17#  may be used to endorse or promote products derived from this software
18#  without specific prior written permission.
19
20#  THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
21#  IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
22#  WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
23#  PURPOSE.
24
25cat <<!
26/* File created from flex.skl via mkskel.sh */
27
28#include "flexdef.h"
29
30const char *skel[] = {
31!
32
33sed 's/\\/&&/g' | sed 's/"/\\"/g' | sed 's/.*/  "&",/'
34
35cat <<!
36  0
37};
38!
39