aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBruce Momjian <bruce@momjian.us>2009-01-06 02:25:29 +0000
committerBruce Momjian <bruce@momjian.us>2009-01-06 02:25:29 +0000
commiteaa088e8ee624d691bfce6179a049078d321d34c (patch)
tree8472ba1940b4821b01d65500bc514f85e76c8ca4
parent9f910a3b9aeab5a79142860eea53747c1f321aa3 (diff)
downloadpostgresql-eaa088e8ee624d691bfce6179a049078d321d34c.tar.gz
postgresql-eaa088e8ee624d691bfce6179a049078d321d34c.zip
Fix new timezone cross-compile rule to avoid a bug in gmake 3.78.1;
document change.
-rw-r--r--src/timezone/Makefile12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/timezone/Makefile b/src/timezone/Makefile
index 1a5fc06d446..3171eb40979 100644
--- a/src/timezone/Makefile
+++ b/src/timezone/Makefile
@@ -4,7 +4,7 @@
# Makefile for the timezone library
# IDENTIFICATION
-# $PostgreSQL: pgsql/src/timezone/Makefile,v 1.30 2009/01/05 10:25:59 petere Exp $
+# $PostgreSQL: pgsql/src/timezone/Makefile,v 1.31 2009/01/06 02:25:29 momjian Exp $
#
#-------------------------------------------------------------------------
@@ -38,12 +38,20 @@ ifeq (,$(with_system_tzdata))
all: submake-libpgport zic
endif
+# We could do this test in the action section:
+# $(if $(ZIC),$(ZIC),./zic)
+# but gmake versions <= 3.78.1 or perhaps later have a bug
+# that causes a segfault; gmake 3.81 or later fixes this.
+ifeq (,$(ZIC))
+ZIC= ./zic
+endif
+
zic: $(ZICOBJS)
$(CC) $(CFLAGS) $(ZICOBJS) $(LDFLAGS) $(LIBS) -o $@$(X)
install: all installdirs
ifeq (,$(with_system_tzdata))
- $(if $(ZIC),$(ZIC),./zic) -d '$(DESTDIR)$(datadir)/timezone' -p '$(POSIXRULES)' $(TZDATAFILES)
+ $(ZIC) -d '$(DESTDIR)$(datadir)/timezone' -p '$(POSIXRULES)' $(TZDATAFILES)
endif
$(MAKE) -C tznames $@