diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2013-11-18 15:37:44 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2013-11-18 15:37:44 (GMT) |
commit | 48494f66c267f103ed95d01c2b56fc4f140d9913 (patch) | |
tree | 70064bf1cfdd18f31955dae35ec3204b6d640c71 | |
parent | ff32dfae22846c7a5e3e85b77309a9c186a3b56f (diff) | |
parent | 0af1f3e468baaf1b8cf6bc13452d1fc8f0a265f5 (diff) | |
download | tk-48494f66c267f103ed95d01c2b56fc4f140d9913.zip tk-48494f66c267f103ed95d01c2b56fc4f140d9913.tar.gz tk-48494f66c267f103ed95d01c2b56fc4f140d9913.tar.bz2 |
Cygwin: In stead of checking whether the win32 part is configured properly, just configure it when needed.
Always build the stub library first (and - on Cygwin - configure win32 properly just before building the stub library)
-rw-r--r-- | unix/Makefile.in | 16 | ||||
-rwxr-xr-x | unix/configure | 13 | ||||
-rw-r--r-- | unix/tcl.m4 | 11 |
3 files changed, 26 insertions, 14 deletions
diff --git a/unix/Makefile.in b/unix/Makefile.in index 3914940..f21fdbb 100644 --- a/unix/Makefile.in +++ b/unix/Makefile.in @@ -570,7 +570,7 @@ SHELL_ENV = \ all: binaries libraries doc -binaries: ${LIB_FILE} ${STUB_LIB_FILE} ${WISH_EXE} +binaries: ${LIB_FILE} ${WISH_EXE} libraries: @@ -581,11 +581,15 @@ doc: $(TOP_DIR)/doc/man.macros # The following target is configured by autoconf to generate either # a shared library or non-shared library for Tk. -${LIB_FILE}: ${OBJS} ${STUB_LIB_FILE} @LIB_RSRC_FILE@ +${LIB_FILE}: ${STUB_LIB_FILE} @LIB_RSRC_FILE@ ${OBJS} rm -f $@ @MAKE_LIB@ ${STUB_LIB_FILE}: ${STUB_LIB_OBJS} + @if test "x${LIB_FILE}" = "xlibtk${MAJOR_VERSION}.${MINOR_VERSION}.dll"; then \ + (cd ${TOP_DIR}/win; ${MAKE} tk${MAJOR_VERSION}${MINOR_VERSION}.dll); \ + cp "${TOP_DIR}/win/tk${MAJOR_VERSION}${MINOR_VERSION}.dll" .; \ + fi rm -f $@ @MAKE_STUB_LIB@ @@ -610,11 +614,7 @@ tkLibObjs: objs: ${OBJS} -${WISH_EXE}: $(WISH_OBJS) $(TK_LIB_FILE) $(TK_STUB_LIB_FILE) @APP_RSRC_FILE@ - @if test "x$(TK_SHARED_BUILD)" = "x1" -a \ - -f "${TOP_DIR}/win/tk${MAJOR_VERSION}${MINOR_VERSION}.dll"; then \ - cp "${TOP_DIR}/win/tk${MAJOR_VERSION}${MINOR_VERSION}.dll" .; \ - fi +${WISH_EXE}: $(TK_STUB_LIB_FILE) $(WISH_OBJS) $(TK_LIB_FILE) @APP_RSRC_FILE@ ${CC} ${CFLAGS} ${LDFLAGS} $(WISH_OBJS) @TK_BUILD_LIB_SPEC@ \ $(WISH_LIBS) $(CC_SEARCH_FLAGS) -o ${WISH_EXE} @@ -713,7 +713,7 @@ install-strip: # some ranlibs write to current directory, and this might not always be # possible (e.g. if installing as root). -install-binaries: $(TK_LIB_FILE) $(TK_STUB_LIB_FILE) ${WISH_EXE} +install-binaries: $(TK_STUB_LIB_FILE) $(TK_LIB_FILE) ${WISH_EXE} @for i in "$(LIB_INSTALL_DIR)" "$(BIN_INSTALL_DIR)" \ "$(PKG_INSTALL_DIR)" "$(CONFIG_INSTALL_DIR)" ; \ do \ diff --git a/unix/configure b/unix/configure index 485b70a..a3888e3 100755 --- a/unix/configure +++ b/unix/configure @@ -4995,10 +4995,15 @@ echo "$as_me: error: ${CC} is not a cygwin compiler." >&2;} echo "$as_me: error: CYGWIN compile is only supported with --enable-threads" >&2;} { (exit 1); exit 1; }; } fi - if test "x${SHARED_BUILD}" = "x1" -a ! -f "../win/tcldde14.dll" -a ! -f "../win/tk86.dll"; then - { { echo "$as_me:$LINENO: error: Please configure and make the ../win directory first." >&5 -echo "$as_me: error: Please configure and make the ../win directory first." >&2;} - { (exit 1); exit 1; }; } + do64bit_ok=yes + if test "x${SHARED_BUILD}" = "x1"; then + echo "running cd ../win; ${CONFIG_SHELL-/bin/sh} ./configure $ac_configure_args" + # The eval makes quoting arguments work. + if cd ../win; eval ${CONFIG_SHELL-/bin/sh} ./configure $ac_configure_args; cd ../unix + then : + else + { echo "configure: error: configure failed for ../win" 1>&2; exit 1; } + fi fi ;; dgux*) diff --git a/unix/tcl.m4 b/unix/tcl.m4 index 194cf90..070946a 100644 --- a/unix/tcl.m4 +++ b/unix/tcl.m4 @@ -1253,8 +1253,15 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ if test "x${TCL_THREADS}" = "x0"; then AC_MSG_ERROR([CYGWIN compile is only supported with --enable-threads]) fi - if test "x${SHARED_BUILD}" = "x1" -a ! -f "../win/tcldde14.dll" -a ! -f "../win/tk86.dll"; then - AC_MSG_ERROR([Please configure and make the ../win directory first.]) + do64bit_ok=yes + if test "x${SHARED_BUILD}" = "x1"; then + echo "running cd ../win; ${CONFIG_SHELL-/bin/sh} ./configure $ac_configure_args" + # The eval makes quoting arguments work. + if cd ../win; eval ${CONFIG_SHELL-/bin/sh} ./configure $ac_configure_args; cd ../unix + then : + else + { echo "configure: error: configure failed for ../win" 1>&2; exit 1; } + fi fi ;; dgux*) |