Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit cfc0e01

Browse files
committed
Our test to see if we had permission to install into Perl5 install area
always failed if Perl makefile's INSTALLSITELIB variable was specified in terms of another variable. Fix by adding an echo-installdir target to the Perl makefile, which the upper-level Makefile can invoke.
1 parent 2ee858b commit cfc0e01

File tree

2 files changed

+13
-5
lines changed

2 files changed

+13
-5
lines changed

src/interfaces/Makefile

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
#
88
#
99
# IDENTIFICATION
10-
# $Header: /cvsroot/pgsql/src/interfaces/Makefile,v 1.35 2000/04/20 17:21:46 momjian Exp $
10+
# $Header: /cvsroot/pgsql/src/interfaces/Makefile,v 1.36 2000/04/23 04:26:31 tgl Exp $
1111
#
1212
#-------------------------------------------------------------------------
1313

@@ -53,7 +53,7 @@ install-perl5: perl5/Makefile
5353
$(MAKE) -C perl5 clean
5454
cd perl5 && POSTGRES_HOME="$(POSTGRESDIR)" $(PERL) Makefile.PL POLLUTE=1
5555
$(MAKE) -C perl5 all
56-
-@if [ -w `sed -n -e 's/^ *INSTALLSITELIB *= *//p' perl5/Makefile` ]; then \
56+
-@if [ -w `$(MAKE) --quiet -C perl5 echo-installdir` ]; then \
5757
$(MAKE) $(MFLAGS) -C perl5 install; \
5858
rm -f perl5/Makefile; \
5959
else \

src/interfaces/perl5/Makefile.PL

+11-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#-------------------------------------------------------
22
#
3-
# $Id: Makefile.PL,v 1.14 1998/10/18 02:36:48 tgl Exp $
3+
# $Id: Makefile.PL,v 1.15 2000/04/23 04:26:32 tgl Exp $
44
#
55
# Copyright (c) 1997, 1998 Edmund Mergl
66
#
@@ -53,6 +53,14 @@ where Postgres is installed (often /usr/local/pgsql).\n";
5353

5454
WriteMakefile(%opts);
5555

56-
exit(0);
5756

58-
# end of Makefile.PL
57+
sub MY::installbin {
58+
59+
q[
60+
# Create a target that interfaces/Makefile can use to
61+
# determine the Perl install directory.
62+
echo-installdir:
63+
@echo $(INSTALLSITELIB)
64+
];
65+
66+
}

0 commit comments

Comments
 (0)