>>>>> OKUJI Yoshinori writes:

 >> I may end up putting them in datadir, once the architecture is
 >> wired into the filename (something like $(datadir)/grub/i386).
 >> Does that sound like a good idea?

 OY>   No. The Makefile Conventions says:

 OY> `datadir' The directory for installing read-only architecture
 OY> independent data files.  [...]

Yes.  Any reading of the standards depends on your definition of
architecture-independent.  Yours seems to be ``files that contain
non-native executable code.''  Mine is ``files that are the same on
every system where the package is installed, regardless of
architecture.''

I believe my definition is what the Makefile conventions find more
useful.  All I'm saying is that /share/grub/i386/stage2 will be the
same on every machine, regardless of architecture.  So will
/share/grub/m68k/stage2.

For the same reasons, /lib/grub/stage2 would differ from machine to
machine, so it belongs in libdir.

Don't forget that the Makefile conventions were invented to permit
sharing of certain directories between machines of different
architectures, *not* to arbitrarily distinguish between `text' and
`program' files.

The name `grub/i386/stage2' can be shared across architectures.  The
name `grub/stage2' cannot.  So, the first belongs in datadir, and the
second belongs in libdir.

 OY> Therefore, installing them in datadir is obviously strange. In my
 OY> opinion, they should be installed in bootdir as they were,
 OY> because there is no suitable standard directory for them.

bootdir is for boot files specific to the current machine (i.e. they
cannot be shared to any other machines).  It is a mistake to put files
there when they are useful for more than just booting.

My entire rationale depends on when we have a utility like grubinst or
the /sbin/grub I'm working on: we cannot assume that just because
somebody installs the GRUB package, they want to use it only to boot
the current system they have.

What is wrong with using an i386 machine to install an m68k GRUB to
floppy?  Nothing.  Where should those files (the m68k boot program
files) belong on the i386 machine?

I believe the answer is in $(datadir)/grub/$(arch).

Does that make more sense now?

-- 
 Gordon Matzigkeit <[EMAIL PROTECTED]>  //\ I'm a FIG (http://www.fig.org/)
Committed to freedom and diversity \// I use GNU (http://www.gnu.org/)

Reply via email to