2 if [ "$1" = "--with" -a "$2" = "license_agreement" ]; then
4 SRPMDIR=`rpm --define "_topdir $tmp" --eval "%{_srcrpmdir}"`
5 BUILDDIR=`rpm --define "_topdir $tmp" --eval "%{_builddir}"`
6 RPMDIR=`rpm --define "_topdir $tmp" --eval "%{_rpmdir}"`
7 PACKAGEDIR="$tmp/packages/acroread"
8 mkdir -p $SRPMDIR $RPMDIR $SRPMDIR $BUILDDIR $PACKAGEDIR
10 if echo "$3" | grep '\.src\.rpm$' >/dev/null; then
12 if echo "$3" | grep '://' >/dev/null; then
14 wget --passive-ftp -t0 "$3"
18 rpm2cpio `basename "$3"` | ( cd $PACKAGEDIR; cpio -i @BASE_NAME@.spec )
19 if [ '@COPYSOURCES@' != '@'COPYSOURCES'@' ]; then
20 rpm2cpio `basename "$3"` | ( cd $PACKAGEDIR; cpio -i @COPYSOURCES@ )
24 cp -i "$3" $PACKAGEDIR || exit 1
25 if [ '@COPYSOURCES@' != '@'COPYSOURCES'@' ]; then
26 for i in @COPYSOURCES@; do
27 cp -i @DATADIR@/$i $PACKAGEDIR/$i || exit 1
33 if [ '@USE_DISTFILES@' = 'no' ]; then
36 /usr/bin/builder --define _topdir $tmp $nd -nm -nc -ncs --with license_agreement --target @TARGET_CPU@ @BASE_NAME@.spec
37 if [ "$?" -ne 0 ]; then
40 RPMNAMES="$RPMDIR/@BASE_NAME@-@VERSION@-@RELEASE@wla.@TARGET_CPU@.rpm"
41 rpm -Uhv $RPMNAMES || echo -e "Install manually the file(s):\n $RPMNAMES" )
43 if [ "@LICENSE@" != '@'LICENSE'@' ]; then
46 If you accept the above license rebuild the package using:
50 License issues made us not to include inherent files into
51 this package by default. If you want to create full working
52 package please build it with the following command:
55 echo "$0 --with license_agreement @SPECFILE@"