Re: [HACKERS] make install fails in perl5 ...

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: The Hermit Hacker <scrappy(at)hub(dot)org>
Cc: pgsql-hackers(at)postgreSQL(dot)org
Subject: Re: [HACKERS] make install fails in perl5 ...
Date: 1998-10-27 16:27:24
Message-ID: 6030.909505644@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

The Hermit Hacker <scrappy(at)hub(dot)org> writes:
> So, who took the root check out, and when, and why?

Well, I didn't do it, but I agree with whoever took it out. You cannot
test at *configure* time to see whether the invoker of configure is
root. It is not reasonable to expect people to do the configure and
build as root, even if they su to root for the install step (which
is surely the WRONG thing for a Postgres install anyway!)

I wouldn't care for a test on rootness even if it were done at the right
time, ie, install step. That's an entirely unwarranted assumption about
how people set up their file ownership. (For example, on my machine the
Perl5 tree belongs to user "gnu", not root.) A more useful test would
be whether you have write permission on the Perl5 install tree top-level
directory, but that seems to require knowing where the Perl5 install
tree *is*, a fact that's buried inside the Perl-generated makefile.

Maybe we could modify src/interfaces/Makefile along this line:

install-perl5:
$(MAKE) -C perl5 clean
cd perl5 && POSTGRES_HOME="$(POSTGRESDIR)" perl Makefile.PL
if test -w `PERL-LIB` then
$(MAKE) -C perl5 install
rm -f perl5/Makefile
else
echo "Postponing Perl install, don't have permissions."
echo "To install, cd into interfaces/perl5, su to Perl"
echo "file owner, and do 'make install'."
fi

where PERL-LIB is some sed hackery to extract the PERL_LIB
definition from the just-built perl5/Makefile.

If you like this I will see what I can do with the idea.

We'll also need to discuss this whole business in the INSTALL
directions.

regards, tom lane

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 1998-10-27 16:39:19 Re: [HACKERS] Last call?
Previous Message Tom Lane 1998-10-27 16:04:47 Re: [HACKERS] Last call?