stumpwm-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [STUMP] [PATCH] Make install-info configurable


From: Teemu Likonen
Subject: Re: [STUMP] [PATCH] Make install-info configurable
Date: Mon, 13 Jul 2009 11:10:41 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux)

On 2009-07-12 18:38 (-0700), Shawn Betts wrote:

> If it's useful to choose a different install-info, should it maybe be
> a --with-install-info option? When I run your patch (on ubuntu 8) I
> get:
>
> checking for install-info... /usr/sbin/install-info
> checking for install-info... (cached) /usr/sbin/install-info
> checking for install-info... (cached) /usr/sbin/install-info
>
> Which makes me wonder: why are there 3 checks?

I copied the idea from GNU Emacs' configure.in. Obviously the idea is to
check from different paths.

    AC_PATH_PROG(INSTALL_INFO,install-info)
    AC_PATH_PROG(INSTALL_INFO,install-info,,/usr/sbin)
    AC_PATH_PROG(INSTALL_INFO,install-info,,/sbin)

The first check without a path will just search from $PATH. If user is
running configure as a normal user (non-root) in Debian systems it won't
normally find anything because the program is /usr/sbin/install-info
(notice the sbin/). I think it's still a good idea to search from $PATH
first.

Again, if configure is executed as a normal user the second line will
find Debian's install-info. Actually running Debian's install-info needs
root access because it writes something to /var directories. But root
access is possibly needed only at "make install" time so we still want
to find /usr/sbin/install-info even when it's not in normal user's
$PATH. I think it's quite common that system admins configure and build
programs as a normal user and only the "make install" stage is executed
as root.

About the third check, I don't know any systems which have
/sbin/install-info so I can't say where or if the third check is useful.
As far as I'm concerned it just came from GNU Emacs.

In your Ubuntu system configure script seems to have found
/usr/sbin/install-info first. It's the Debian's custom install-info in
"dpkg" package. You probably ran configure as root user (so that
/usr/sbin/ is in $PATH), or maybe you ran it as a normal user and have
INSTALL_INFO variable pointing to /usr/sbin/install-info?

(I hope you tried the PATCH version 2.)

> I checked ratpoison's automake generated make files and it seems to
> use a hardcoded install-info. If it's good enough for automake, isn't
> it good enough for us? :)

Then "us" doesn't include Debian users who want to install StumpWM in
their home directory.

As I said, in Debian systems there is this custom /usr/sbin/install-info
which does not work at all with normal user's access. It tries to write
something to /var directories. So, a Debian user who wants to install
StumpWM under her $HOME must either

  - leave the info manual uninstalled (my patch gives only a warning and
    does not stop with error on "make install"), or

  - use GNU install-info which is in "texinfo" package. The executable
    is named /usr/bin/ginstall-info (notice the path and "g").

If install-info is hard-coded in Makefile a normal user can't "make
install" StumpWM's info manual without editing the Makefile first (to
use ginstall-info) or perhaps making a symlink ~/bin/install-info ->
/usr/bin/ginstall-info. Or perhaps downloading and installing her own
GNU install-info under $HOME. I'll repeat: Debian's custom
/usr/sbin/install-info doesn't work at all with normal user's access.

These are the reasons why I'm proposing making install-info
configurable. What comes to implementation using AC_PATH_PROG is good
because user can set INSTALL_INFO variable before-hand and configure
script will use that. Having a couple of different checks for different
paths is more automatic than a requirement for an option like
--with-install-info. That said, I'm fine with the option and I'm fine
with only the first AC_PATH_PROG check without explicit path name (see
above). My patch also makes the install-info non-essential. Only a
warning is given at configure time if it's not found; "make install"
won't complain anymore.

Thanks.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]