Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 42 lines (30 sloc) 0.659 kb
a793fea Do we really want to depend on Perl? Shell scripts are handy and run on
Sascha Schumann authored
1 #! /bin/sh
2
8460074 - Partial revert: It does not matter if awk works or not but helps if it...
foobar authored
3 # $Id: genif.sh,v 1.6 2005-06-21 13:47:38 sniper Exp $
a793fea Do we really want to depend on Perl? Shell scripts are handy and run on
Sascha Schumann authored
4 # replacement for genif.pl
5
f93e3ab de-overquotation
Sascha Schumann authored
6 infile=$1
a793fea Do we really want to depend on Perl? Shell scripts are handy and run on
Sascha Schumann authored
7 shift
f93e3ab de-overquotation
Sascha Schumann authored
8 srcdir=$1
a793fea Do we really want to depend on Perl? Shell scripts are handy and run on
Sascha Schumann authored
9 shift
f93e3ab de-overquotation
Sascha Schumann authored
10 extra_module_ptrs=$1
a2d4241 Revamp session's config.m4 and reenable support for mm. The shared memor...
Sascha Schumann authored
11 shift
f93e3ab de-overquotation
Sascha Schumann authored
12 awk=$1
060e647 Speed up the genif.sh script a little bit. Whereas it took three second...
Sascha Schumann authored
13 shift
a793fea Do we really want to depend on Perl? Shell scripts are handy and run on
Sascha Schumann authored
14
f93e3ab de-overquotation
Sascha Schumann authored
15 if test -z "$infile" || test -z "$srcdir"; then
a793fea Do we really want to depend on Perl? Shell scripts are handy and run on
Sascha Schumann authored
16 echo "please supply infile and srcdir"
17 exit 1
18 fi
19
f93e3ab de-overquotation
Sascha Schumann authored
20 header_list=
5b293ec - add global startup/shutdown handlers
Sascha Schumann authored
21 olddir=`pwd`
22 cd $srcdir
23
8460074 - Partial revert: It does not matter if awk works or not but helps if it...
foobar authored
24 module_ptrs="$extra_module_ptrs`echo $@ | $awk -f ./build/order_by_dep.awk`"
25
91cf2e5 get rid of the binary character, execute sed only once
Sascha Schumann authored
26 for ext in ${1+"$@"} ; do
0c83631 Fix building of pure C++ extensions as static
Scott MacVicar authored
27 header_list="$header_list ext/$ext/*.h*"
17a36c3 this is faster than parsing the file line by line
Sascha Schumann authored
28 done
29
7f96af8 Stop automatically passing vars to AC_SUBST through PHP_SUBST.
Sascha Schumann authored
30 includes=`$awk -f ./build/print_include.awk $header_list`
060e647 Speed up the genif.sh script a little bit. Whereas it took three second...
Sascha Schumann authored
31
5b293ec - add global startup/shutdown handlers
Sascha Schumann authored
32 cd $olddir
33
17a36c3 this is faster than parsing the file line by line
Sascha Schumann authored
34 cat $infile | \
91cf2e5 get rid of the binary character, execute sed only once
Sascha Schumann authored
35 sed \
36 -e "s'@EXT_INCLUDE_CODE@'$includes'" \
37 -e "s'@EXT_MODULE_PTRS@'$module_ptrs'" \
8d5af8c Replace the incomprehensible newline escaping with @NEWLINE@
Sascha Schumann authored
38 -e 's/@NEWLINE@/\
91cf2e5 get rid of the binary character, execute sed only once
Sascha Schumann authored
39 /g'
40
17a36c3 this is faster than parsing the file line by line
Sascha Schumann authored
41
Something went wrong with that request. Please try again.