]> git.saurik.com Git - apt.git/commitdiff
add framework code to run the installed aptitude with the current
authorDavid Kalnischkies <kalnischkies@gmail.com>
Tue, 30 Nov 2010 18:23:54 +0000 (19:23 +0100)
committerDavid Kalnischkies <kalnischkies@gmail.com>
Tue, 30 Nov 2010 18:23:54 +0000 (19:23 +0100)
build library in the test environment

test/integration/framework

index a0bad4170fb6a65f35c3ab1e8564e207297f1323..8abefc814abc358c582df95ffb36a9594bf1f76e 100644 (file)
@@ -78,6 +78,15 @@ aptkey() { runapt apt-key $*; }
 dpkg() {
        $(which dpkg) --root=${TMPWORKINGDIRECTORY}/rootdir --force-not-root --force-bad-path --log=${TMPWORKINGDIRECTORY}/rootdir/var/log/dpkg.log $*
 }
+aptitude() {
+       if [ -f ./aptconfig.conf ]; then
+               APT_CONFIG=aptconfig.conf LD_LIBRARY_PATH=${BUILDDIRECTORY}  $(which aptitude) $*
+       elif [ -f ../aptconfig.conf ]; then
+               APT_CONFIG=../aptconfig.conf LD_LIBRARY_PATH=${BUILDDIRECTORY} $(which aptitude) $*
+       else
+               LD_LIBRARY_PATH=${BUILDDIRECTORY}  $(which aptitude) $*
+       fi
+}
 
 setupenvironment() {
        TMPWORKINGDIRECTORY=$(mktemp -d)