]> granicus.if.org Git - postgresql/commitdiff
Warn when MinGW fails to create symlinks during configure. Report
authorBruce Momjian <bruce@momjian.us>
Thu, 13 May 2004 01:45:02 +0000 (01:45 +0000)
committerBruce Momjian <bruce@momjian.us>
Thu, 13 May 2004 01:45:02 +0000 (01:45 +0000)
already made to MinGW maintainers.

Andrew Dunstan

configure
configure.in

index 9deb026c4a3ff1786006fec60ce145cbf1986db0..742bbabfc4116743bf5213cfebed26a7f17fba3f 100755 (executable)
--- a/configure
+++ b/configure
@@ -17974,6 +17974,25 @@ ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
 ac_config_links="$ac_config_links src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION} src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION} src/include/dynloader.h:src/backend/port/dynloader/${template}.h src/include/pg_config_os.h:src/include/port/${template}.h src/Makefile.port:src/makefiles/Makefile.${template}"
 
 
+# Links sometimes fail undetected on Mingw -
+# so here we detect it and warn the user
+case $host_os in mingw*)
+ for linktarget in \
+       src/backend/port/tas.s \
+       src/backend/port/dynloader.c \
+       src/backend/port/pg_sema.c \
+       src/backend/port/pg_shmem.c \
+       src/include/dynloader.h \
+       src/include/pg_config_os.h \
+       src/Makefile.port
+ do
+       # test -e works for symlinks in the MinGW console
+       test -e $linktarget || { echo "$as_me:$LINENO: WARNING: *** link for $linktarget failed - please fix by hand" >&5
+echo "$as_me: WARNING: *** link for $linktarget failed - please fix by hand" >&2;}
+ done
+       ;;
+esac
+
 ac_config_headers="$ac_config_headers src/include/pg_config.h"
 
 
index 8947a815830f5f32baca99fd09c0e6913a6f7893..b198162ede4459fdf5d90ffad27f85a72e8e0bbf 100644 (file)
@@ -1,5 +1,5 @@
 dnl Process this file with autoconf to produce a configure script.
-dnl $PostgreSQL: pgsql/configure.in,v 1.346 2004/05/11 21:57:13 momjian Exp $
+dnl $PostgreSQL: pgsql/configure.in,v 1.347 2004/05/13 01:45:02 momjian Exp $
 dnl
 dnl Developers, please strive to achieve this order:
 dnl
@@ -1236,6 +1236,24 @@ AC_CONFIG_LINKS([
   src/Makefile.port:src/makefiles/Makefile.${template}
 ])
 
+# Links sometimes fail undetected on Mingw - 
+# so here we detect it and warn the user
+case $host_os in mingw*)
+ for linktarget in \
+       src/backend/port/tas.s \
+       src/backend/port/dynloader.c \
+       src/backend/port/pg_sema.c \
+       src/backend/port/pg_shmem.c \
+       src/include/dynloader.h \
+       src/include/pg_config_os.h \
+       src/Makefile.port
+ do
+       # test -e works for symlinks in the MinGW console
+       test -e $linktarget || AC_MSG_WARN([*** link for $linktarget failed - please fix by hand])
+ done
+       ;;
+esac
+
 AC_CONFIG_HEADERS([src/include/pg_config.h],
 [
 # Update timestamp for pg_config.h (see Makefile.global)