Posted to tcl by patthoyts at Tue Apr 19 14:40:01 GMT 2011view raw

  1. ? win/starsh.c
  2. ? win/vercl.x
  3. ? win/versions.vc
  4. Index: win/makefile.vc
  5. ===================================================================
  6. RCS file: /cvsroot/tcl/tcl/win/makefile.vc,v
  7. retrieving revision 1.175.2.3
  8. diff -u -r1.175.2.3 makefile.vc
  9. --- win/makefile.vc 11 Aug 2008 21:57:17 -0000 1.175.2.3
  10. +++ win/makefile.vc 12 Aug 2008 08:35:23 -0000
  11. @@ -211,6 +211,14 @@
  12. TCLTEST = $(OUT_DIR)\$(PROJECT)test.exe
  13. CAT32 = $(OUT_DIR)\cat32.exe
  14.  
  15. +!ifndef TCLSH_NATIVE
  16. +!if "$(MACHINE)" == "$(NATIVE_ARCH)"
  17. +TCLSH_NATIVE = $(TCLSH)
  18. +!else
  19. +!error You must explicitly set TCLSH_NATIVE for cross-compilation
  20. +!endif
  21. +!endif
  22. +
  23. ### Make sure we use backslash only.
  24. LIB_INSTALL_DIR = $(_INSTALLDIR)\lib
  25. BIN_INSTALL_DIR = $(_INSTALLDIR)\bin
  26. @@ -407,7 +415,7 @@
  27. !if !$(DEBUG)
  28. !if $(OPTIMIZING)
  29. ### This cranks the optimization level to maximize speed
  30. -cdebug = -O2 $(OPTIMIZATIONS)
  31. +cdebug = -Zi -O2 $(OPTIMIZATIONS)
  32. !else
  33. cdebug =
  34. !endif
  35. @@ -1024,13 +1032,13 @@
  36. install-tzdata:
  37. @echo Installing time zone data
  38. @set TCL_LIBRARY=$(ROOT)/library
  39. - @$(TCLSH) "$(ROOT)/tools/installData.tcl" \
  40. + @$(TCLSH_NATIVE) "$(ROOT)/tools/installData.tcl" \
  41. "$(ROOT)/library/tzdata" "$(SCRIPT_INSTALL_DIR)/tzdata"
  42.  
  43. install-msgs:
  44. @echo Installing message catalogs
  45. @set TCL_LIBRARY=$(ROOT)/library
  46. - @$(TCLSH) "$(ROOT)/tools/installData.tcl" \
  47. + @$(TCLSH_NATIVE) "$(ROOT)/tools/installData.tcl" \
  48. "$(ROOT)/library/msgs" "$(SCRIPT_INSTALL_DIR)/msgs"
  49.  
  50. #---------------------------------------------------------------------
  51. Index: win/rules.vc
  52. ===================================================================
  53. RCS file: /cvsroot/tcl/tcl/win/rules.vc,v
  54. retrieving revision 1.35.2.1
  55. diff -u -r1.35.2.1 rules.vc
  56. --- win/rules.vc 25 Jun 2008 10:57:54 -0000 1.35.2.1
  57. +++ win/rules.vc 1 Jul 2008 10:25:03 -0000
  58. @@ -30,7 +30,12 @@
  59. _INSTALLDIR = $(INSTALLDIR:/=\)
  60. !endif
  61.  
  62. +# Test for cross-compilation environment.
  63. !ifndef MACHINE
  64. +NATIVE_ARCH=$(PROCESSOR_ARCHITECTURE)
  65. +!if "$(NATIVE_ARCH)" == "x86"
  66. +NATIVE_ARCH=IX86
  67. +!endif
  68. !if "$(CPU)" == "" || "$(CPU)" == "i386"
  69. MACHINE = IX86
  70. !else
  71. @@ -666,6 +671,7 @@
  72. !message *** Intermediate directory will be '$(TMP_DIR)'
  73. !message *** Output directory will be '$(OUT_DIR)'
  74. !message *** Suffix for binaries will be '$(SUFX)'
  75. +!message *** Build arch is $(NATIVE_ARCH). Target is $(MACHINE)
  76. !message *** Optional defines are '$(OPTDEFINES)'
  77. !message *** Compiler version $(VCVER). Target machine is $(MACHINE)
  78. !message *** Compiler options '$(COMPILERFLAGS) $(OPTIMIZATIONS) $(DEBUGFLAGS) $(WARNINGS)'
  79.