Skip to content

Commit 461f80c

Browse files
committed
Add strerror to pg_version for sunos4.
1 parent 622af87 commit 461f80c

File tree

2 files changed

+43
-0
lines changed

2 files changed

+43
-0
lines changed

src/bin/pg_version/Makefile.in

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
#-------------------------------------------------------------------------
2+
#
3+
# Makefile.inc--
4+
# Makefile for bin/pg_version
5+
#
6+
# Copyright (c) 1994, Regents of the University of California
7+
#
8+
#
9+
# IDENTIFICATION
10+
# $Header: /cvsroot/pgsql/src/bin/pg_version/Attic/Makefile.in,v 1.1 1997/07/29 16:36:43 momjian Exp $
11+
#
12+
#-------------------------------------------------------------------------
13+
14+
SRCDIR= ../..
15+
include ../../Makefile.global
16+
17+
OBJS= pg_version.o ../../utils/version.o @STRERROR2@
18+
19+
CFLAGS+= -I$(SRCDIR)/include
20+
21+
all: pg_version
22+
23+
pg_version: submake $(OBJS)
24+
$(CC) -o pg_version $(OBJS) $(LDFLAGS)
25+
26+
.PHONY: submake
27+
submake:
28+
$(MAKE) -C ../../utils version.o
29+
30+
install: pg_version
31+
$(INSTALL) $(INSTL_EXE_OPTS) pg_version $(DESTDIR)$(BINDIR)/pg_version
32+
33+
depend dep:
34+
$(CC) -MM $(INCLUDE_OPT) *.c >depend
35+
36+
clean:
37+
rm -f pg_version pg_version.o
38+
39+
ifeq (depend,$(wildcard depend))
40+
include depend
41+
endif

src/configure.in

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -413,10 +413,12 @@ AC_CHECK_FUNCS(isinf tzset getrusage vfork memmove sigsetjmp kill sysconf)
413413
AC_CHECK_FUNCS(sigprocmask waitpid setsid random fcvt)
414414
AC_CHECK_FUNC(inet_aton, AC_DEFINE(HAVE_INET_ATON), INET_ATON='inet_aton.o')
415415
AC_CHECK_FUNC(strerror, AC_DEFINE(HAVE_STRERROR), STRERROR='strerror.o')
416+
eC_CHECK_FUNC(strerror, AC_DEFINE(HAVE_STRERROR), STRERROR2='../../backend/port/strerror.o')
416417
AC_CHECK_FUNC(strdup, AC_DEFINE(HAVE_STRDUP), STRDUP='../../utils/strdup.o')
417418
AC_SUBST(STRDUP)
418419
AC_SUBST(INET_ATON)
419420
AC_SUBST(STRERROR)
421+
AC_SUBST(STRERROR2)
420422
AC_CHECK_FUNC(cbrt, AC_DEFINE(HAVE_CBRT), AC_CHECK_LIB(m, cbrt, AC_DEFINE(HAVE_CBRT)))
421423
AC_CHECK_FUNC(rint, AC_DEFINE(HAVE_RINT), AC_CHECK_LIB(m, rint, AC_DEFINE(HAVE_RINT)))
422424

0 commit comments

Comments
 (0)