Add support for functions that return N values
[Funky.git] / bootstrap
blob3b15f00af17fb98b61b36d4fd671fbc63e478d04
1 #! /bin/bash -x
2 function get_version_info()
4 export PACKAGE="funky"
5 source project/gnu/version
6 echo VERSION=$VERSION
9 function gen_configure_ac()
11 cat > bootstrap.pl <<EOF
12 #! /usr/bin/perl -w
13 while (<>)
15 \$_ =~ s/\\\$\\\$__PACKAGE__\\\$\\\$/$PACKAGE/g;
16 \$_ =~ s/\\\$\\\$__VERSION__\\\$\\\$/$VERSION/g;
17 print \$_;
19 EOF
20 cat project/gnu/configure.ac.in | perl bootstrap.pl > configure.ac
23 function gen_makefile_in()
25 cat > bootstrap.pl <<EOF
26 #! /use/bin/perl -w
27 while (<>)
29 \$_ =~ s/\\\$\\\$__PACKAGE__\\\$\\\$/$PACKAGE/g;
30 \$_ =~ s/\\\$\\\$__VERSION__\\\$\\\$/$VERSION/g;
31 print \$_;
33 EOF
34 cat project/gnu/Makefile.in.in | perl bootstrap.pl > Makefile.in
37 get_version_info
38 gen_configure_ac
39 gen_makefile_in
41 libtoolize && \
42 aclocal && \
43 autoconf && \
44 cp project/gnu/install-sh .