On 07/12/2012 09:43 PM, Ken Moffat wrote:
> On Thu, Jul 12, 2012 at 09:11:45PM -0400, Baho Utot wrote:
>> I compile and install to DESTDIR all as non-root.  That way if the
>> package has not built correctly it will error out as it can not
>> install/modify files into the root file system (Houston we have a problem).
>>
>> This also lets me have a look before I copy to the working system.
>>
>> Just need to chown -R 0:0 DESTDIR then make a tarball.  Just extract it
>> into the root filesystem and water ;)
>   There are a *few* packages which have errors when using a DESTDIR,
> unless you are root.  For the moment, I don't recall any names, but
> they try to chown or chgrp some of the files.
>
>   And then there are the variant packages that use INSTALLROOT (from
> memory - spelling might be wrong), particularly QT and its users.
>
>   Yes, checking new packages before installing is sensible.  ISTR
> that a few need packages further action if installed in a DESTDIR
> and then copied to a system, but I don't recall which packages, nor
> what action : hopefully, all such packages in the book have already
> been noted.
>
>   Out of interest, what do you do for perl and python2 packages - do
> they generally respect DESTDIR ?
>
> ĸen

Here is a snippet for perl

     cd "$srcdir/$pkgname-$pkgver"
     sed -i -e "s|BUILD_ZLIB\s*= True|BUILD_ZLIB = False|" \
         -e "s|INCLUDE\s*= ./zlib-src|INCLUDE    = /usr/include|" \
         -e "s|LIB\s*= ./zlib-src|LIB        = /usr/lib|"         \
         cpan/Compress-Raw-Zlib/config.in
     sh Configure -des -Dprefix=/usr \
                   -Dvendorprefix=/usr           \
                   -Dman1dir=/usr/share/man/man1 \
                   -Dman3dir=/usr/share/man/man3 \
                   -Dpager="/usr/bin/less -isR"  \
                   -Duseshrplib
     make -j6

     cd $srcdir/$pkgname-$pkgver
     make DESTDIR=$pkgdir/ install -j1
     rm -rf ${pkgdir}/usr/share/info || true

-- 
http://linuxfromscratch.org/mailman/listinfo/blfs-dev
FAQ: http://www.linuxfromscratch.org/blfs/faq.html
Unsubscribe: See the above information page

Reply via email to