On Thu, Sep 22, 2005, Simon J Mudd wrote:

> When doing a fresh install of openpkg from current I notice the following
>
> installing openpkg binary openpkg-20050920-20050920.powerpc-aix5.1-ope.sh
> OpenPKG CURRENT Binary Bootstrap Package, version 20050920
> Built for prefix /openpkg on target platform powerpc-aix5.1
> ++ hooking OpenPKG instance into system environment
> openpkg-20050920-20050920.powerpc-aix5.1-ope.sh[823]: /openpkg/bin/rpm: not
> found.
> ++ fixating OpenPKG instance root directory "/openpkg"
> ++ extracting OpenPKG binary distribution
> ++ installing OpenPKG binary distribution
> ++ fixating OpenPKG instance filesystem hierarchy
> ++ post-processing OpenPKG bootstrap installation
> +-----------------------------------------------------------------------------+
> | Congratulations!
> |
> [snip]
>
> /openpkg/bin/rpm was not on the system before as it was a clean install.
>
> This section in the openpkg...ope.sh script appears to be what is failing
>
>     #   remember what OpenPKG RPM version was installed, so we can
>     #   correctly upgrade the RPM database in the %post section (see below).
>     if [ -d ${prefix}/RPM/DB ]; then
>         if [ -x "${prefix}/bin/openpkg" -a -x
>         "${prefix}/libexec/openpkg/rpm" ]; then
>             #   OpenPKG 2.0
>             rpm="${prefix}/bin/openpkg rpm"
>         else
>             #   OpenPKG 1.x
>             rpm="${prefix}/bin/rpm"
>         fi
>         rm -f ${prefix}/RPM/DB/.version >/dev/null 2>&1 || true
>         $rpm --version |\
>             sed -e 's;^;X;' \
>                 -e
>                 's;^X[^0-9]*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*$;\1;' 
> \
>                 -e 's;^X[^0-9]*\([0-9][0-9]*\.[0-9][0-9]*\).*$;\1;' \
>                 -e 's;^X.*$;4.0;' \
>                 >${prefix}/RPM/DB/.version
>     fi
>
> (the $rpm --version line above)
>
> No harm seems to be done, but thought it wise to report this.

Well, seems like your "fresh" installation wasn't fresh enough. Seems
like you at least still had the <prefix>/RPM/DB directory staying around
which allowed this code execute (see the first "if" clause). In a fresh
installation this should not be the case.

                                       Ralf S. Engelschall
                                       [EMAIL PROTECTED]
                                       www.engelschall.com

______________________________________________________________________
The OpenPKG Project                                    www.openpkg.org
User Communication List                      openpkg-users@openpkg.org

Reply via email to