2 # A simple script to build all parts of GnuPG from the git repos.
4 # Copyright 2011 Free Software Foundation, Inc.
6 # This file is free software; as a special exception the author gives
7 # unlimited permission to copy and/or distribute it, with or without
8 # modifications, as long as this notice is preserved.
10 # This file is distributed in the hope that it will be useful, but
11 # WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
12 # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
14 # Run this in another window:
15 #tail -n0 -F ~/tmp/gpg-tmp/b/{libgpg-error,libksba,libassuan,libgcrypt,gnupg}.log &
18 parts="libgpg-error libassuan libksba libgcrypt gnupg"
22 # Reject unsafe characters in $PWD and $HOME. We consider spaces as
23 # unsafe because it is too easy to get scripts wrong in this regard.
27 *[\;\\\"\#\$\&\'\`$am_lf\ \ ]*)
28 echo "unsafe working directory: \`$here'"; die=yes;;
31 *[\;\\\"\#\$\&\'\`$am_lf\ \ ]*)
32 echo "unsafe home directory: \`$HOME'"; die=yes;;
34 test $die = yes && exit 1
36 # Check that all components are available
42 echo "component $i missing"
45 test $die = yes && exit 1
50 mkdir $p/b/$i || exit 1
53 export PATH=$p/bin:$PATH
54 export LD_LIBRARY_PATH=$p/lib
57 cfg="configure --enable-maintainer-mode --prefix=$p"
60 test -n "$prev" && cfg="$cfg --with-$prev-prefix=$p"
61 (cd $p/b/$i && eval $here/$i/$cfg && make && make check && make install) \
63 || { echo FAIL; break; }