diff options
Diffstat (limited to 'meta-gnome/recipes-gnome/abiword/abiword/autogen-common.sh')
-rwxr-xr-x | meta-gnome/recipes-gnome/abiword/abiword/autogen-common.sh | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/meta-gnome/recipes-gnome/abiword/abiword/autogen-common.sh b/meta-gnome/recipes-gnome/abiword/abiword/autogen-common.sh new file mode 100755 index 000000000..c1f10e1a4 --- /dev/null +++ b/meta-gnome/recipes-gnome/abiword/abiword/autogen-common.sh | |||
@@ -0,0 +1,28 @@ | |||
1 | #!/bin/sh | ||
2 | |||
3 | # find plugins Makefile templates | ||
4 | find plugins -name Makefile.am | sed 's|.am$||g' > plugin-makefiles.m4 | ||
5 | |||
6 | # create plugin list | ||
7 | (cd plugins && find . -maxdepth 1 -type d | grep -v '^\.$' | grep -v '\./\.' | sed 's|\./||g' | xargs echo) > plugin-list.m4 | ||
8 | |||
9 | # create conditionals for builtin plugins | ||
10 | (for plugin in `cat plugin-list.m4`; do | ||
11 | u=`echo $plugin | tr '[:lower:]' '[:upper:]'` | ||
12 | echo 'AM_CONDITIONAL(['$u'_BUILTIN], test "$enable_'$plugin'_builtin" == "yes")' | ||
13 | done) > plugin-builtin.m4 | ||
14 | |||
15 | # create plugin configuration | ||
16 | find plugins -name plugin.m4 | xargs cat > plugin-configure.m4 | ||
17 | #to debug if plugin configuration code misbehaves (instead of the above line): | ||
18 | #rm plugin-configure.m4 | ||
19 | #for f in $(find plugins -name plugin.m4); do | ||
20 | # echo "AC_MSG_RESULT([plugin: $f])" >> plugin-configure.m4 | ||
21 | # cat $f >> plugin-configure.m4 | ||
22 | #done | ||
23 | |||
24 | # find extra m4 files provided by plugins and symlink them | ||
25 | for f in ` find ./plugins -name '*.m4' | grep -v 'plugin\.m4'`; do | ||
26 | ln -sf $f | ||
27 | done | ||
28 | |||