Small Patch

Vernon Schryver
Wed Apr 14 03:08:54 UTC 2004

> From: Martin Helas 

> as i am trying to package dcc for the debian project, 

Given errors that seem to be in the FreeBSD DCC "port" or "package",
that threat is disconcerting.

>                                                      i got some
> problems installing dcc in a changeroot enviroment. To fix that problem
> i use attached patch, initialy written by Bas Zoetekouw from the Debian
> project. I modified the his patch to got it running with dcc version
> 1.2.39.
> I would be happy if you could apply this patch to upstream as it only 
> gives the posibility to install dcc in a changeroot. To use it man 
> has to run the installation the following way:
> $ DESTDIR=/path/to/changeroot make install

Your changes to the Makefiles are not enormous, but neither are they
small.  Before I could include them I would need to spend time testing
them to ensure that they are necessary and sufficient.  For example,
it seems odd to install the man pages in the chroot filesystem.  Then
there are the `cdcc` and `chown` commands in homedire/Makefile that
don't seem to be working with your $(DESTDIR).
Since the only Linux system I've access to is an old Redhat 5.1
test drive and since I've no experience building RPMs, my testing
an RPM would not be a trivial effort.

How do you intend to use chroot()?

Why not use simpler tactics for building software for a chroot() environment?

    One classic tactic is to
      build with ./configure --homedir=/chroot/var/dcc ...
      install as usual in /chroot/var/dcc 
      create a symbolic link `ln -s . /chroot`

    The result is that whenever one of the dcc programs refers to 
    a DCC file in /chroot/var/dcc, it gets the right thing.

  A second tactic would be to 
      build with ./configure --homedir=/chroot/var/dcc ...
      install as usual in /chroot/var/dcc 
      change HOMEDIR in /chroot/var/dcc/dcc_conf

Or if I have misunderstood what is intended by "changeroot" and the idea
is to use "changeroot" only for building binaries, then why use the
HINSTALL and DCC_PROTO_HOMEDIR mechanism that is already in the Makefile?

Vernon Schryver

More information about the DCC mailing list

Contact by mail or use the form.