First success with DESTDIR

So, I have good results, my DESTDIR implementation has proven to work with the simplest ports. I mean ports without USE_* that don’t install files via [pre|do|post]-install target and have a standard configure and/or make script, e.g. net/csup or security/chroot_safe. I haven’t tested ports with dependencies, but that will be the next step. Here’s an example log:

[root@spitfire /usr/ports/net/csup]# make DESTDIR=/bla install

[snip]

===> Installing for csup-20060313
===> Generating temporary packing list
===> Checking if net/csup already installed
install -s -o root -g wheel -m 555 csup /bla/usr/local/bin
install -o root -g wheel -m 444 csup.1.gz /bla/usr/local/man/man1
===> Registering installation for csup-20060313
pkg_info: can’t find package ‘csup-20060313′ installed or in a file!
[root@spitfire /usr/ports/net/csup]# ls /bla/usr/local/bin/
csup
[root@spitfire /usr/ports/net/csup]# ls /bla/var/db/pkg/csup-20060313/
+COMMENT +CONTENTS +DESC +MTREE_DIRS
[root@spitfire /usr/ports/net/csup]# cat /bla/var/db/pkg/csup-20060313/+CONTENTS
@comment PKG_FORMAT_REVISION:1.1
@name csup-20060313
@comment ORIGIN:net/csup
@cwd /usr/local
bin/csup
man/man1/csup.1.gz

If you want a patch, here it is, but note that this is very-very-very experimental, use it for your own risk! Any feedback appreciated.

One Response to “First success with DESTDIR”

  1. krion says:

    And the crowd goes wild…
    Great job!

Leave a Reply

It sounds like SK2 has recently been updated on this blog. But not fully configured. You MUST visit Spam Karma's admin page at least once before letting it filter your comments (chaos may ensue otherwise).