diff options
Diffstat (limited to 'wayland-build.sh')
-rwxr-xr-x | wayland-build.sh | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/wayland-build.sh b/wayland-build.sh index 9844e31..2b7c0ad 100755 --- a/wayland-build.sh +++ b/wayland-build.sh @@ -48,6 +48,9 @@ echo [ ! -d "$WLD/share/aclocal" ] && echo "$SUDO_PASSWD" | sudo -S mkdir -p "$WLD/share/aclocal" function build () { + if [ $FORCE_AUTOGEN -eq 1 -o ! -e Makefile ]; then + say " * autogen --prefix=$WLD $my_configure_opts" && ./autogen.sh --prefix=$WLD $my_configure_opts + fi if [ $FORCE_DISTCLEAN -eq 1 ]; then say " * make distclean" && make distclean >/dev/null fi @@ -55,15 +58,11 @@ function build () { say " * make" && make >$tmp && say " * install" && echo "$SUDO_PASSWD" | sudo -S -E make install } -function autogen () { - say " * autogen --prefix=$WLD $my_configure_opts" && ./autogen.sh --prefix=$WLD $my_configure_opts && build -} - function update () { SHA_PREV=$(git log --pretty="format:%H" HEAD~1..) say " * pull" && git pull || return 1 SHA_HEAD=$(git log --pretty="format:%H" HEAD~1..) - if [ $FORCE_AUTOGEN -eq 1 ]; then + if [ $FORCE_AUTOGEN -eq 1 -o $FORCE_DISTCLEAN -eq 1 ]; then autogen else [ "$SHA_PREV" = "$SHA_HEAD" ] && return 0 |