From 38527b4c59d966cbf546f86253c5b1fa2a8857d2 Mon Sep 17 00:00:00 2001 From: Bruce Mitchener Date: Wed, 1 Jan 2014 16:19:22 +0700 Subject: [PATCH 1/2] [win32] Rely on requiring full CRT. * Remove fullcrt build option. * Cease building minvcrt. * Add $(libcmt) to $(rtlibs) in Jam. * Stop linking in a libc anywhere other than via $(rtlibs). --- .gitignore | 2 -- admin/builds/build-release.bat | 13 --------- sources/common-dylan/win32-common-dylan.lid | 1 - sources/jamfiles/x86-win32-vc6-build.jam | 6 ++-- sources/jamfiles/x86-win32-vc8-build.jam | 6 ++-- sources/lib/c-ffi/test/c-ffi-test.lid | 1 - sources/lib/run-time/Makefile.win32 | 26 +----------------- sources/lib/run-time/minvcrt.def | 13 --------- sources/lib/run-time/rtsyms.obj | Bin 366 -> 0 bytes sources/lib/run-time/rtsyms.s | 7 ----- .../access-path/win32-access-path.lid | 1 - .../debugger-nub/server/remote-nub.hdp | 1 - 12 files changed, 7 insertions(+), 70 deletions(-) delete mode 100644 sources/lib/run-time/minvcrt.def delete mode 100644 sources/lib/run-time/rtsyms.obj delete mode 100644 sources/lib/run-time/rtsyms.s diff --git a/.gitignore b/.gitignore index 426496cf05..f9fd325376 100644 --- a/.gitignore +++ b/.gitignore @@ -22,8 +22,6 @@ Makefile /sources/lib/run-time/dylan-plinth.lib /sources/lib/run-time/dylan-support.lib /sources/lib/run-time/heap-*.obj -/sources/lib/run-time/minvcrt.exp -/sources/lib/run-time/minvcrt.lib /sources/lib/run-time/mpsiowin32.obj /sources/lib/run-time/obj-* /sources/lib/run-time/pentium-run-time.lib diff --git a/admin/builds/build-release.bat b/admin/builds/build-release.bat index eaaaff30d4..e9ee51f8af 100644 --- a/admin/builds/build-release.bat +++ b/admin/builds/build-release.bat @@ -43,8 +43,6 @@ echo - /statistics echo - Turns on a reasonable default set of statistics [default: none] echo - /debugger echo - Runs the builds under batch-debug [default: no debugging] -echo - /fullcrt -echo - will build the pentium run time using full version of the C runtime echo - /verbose echo - Show more information during building echo - @@ -122,7 +120,6 @@ set STRIP_RUNTIME=no set OLD_RUNTIME_PREFIX=D3 set RUNTIME_PREFIX=Dx set USE_ENVIRONMENT=yes -set USE_FULL_C_RUNTIME=no set VERBOSE=no set OPEN_DYLAN_USER_SOURCES= @@ -181,8 +178,6 @@ if "%1"=="-internal" GOTO SET_INTERNAL if "%1"=="/internal" GOTO SET_INTERNAL if "%1"=="-external" GOTO SET_EXTERNAL if "%1"=="/external" GOTO SET_EXTERNAL -if "%1"=="-fullcrt" GOTO SET_FULLCRT -if "%1"=="/fullcrt" GOTO SET_FULLCRT if "%1%"=="/verbose" GOTO SET_VERBOSE if "%1%"=="-verbose" GOTO SET_VERBOSE set ERROR_MESSAGE=Invalid command line argument %1 @@ -322,11 +317,6 @@ set WARNINGS=yes shift goto PARAM_LOOP -:SET_FULLCRT -set USE_FULL_C_RUNTIME=yes -shift -goto PARAM_LOOP - :SET_VERBOSE set VERBOSE=yes shift @@ -366,9 +356,6 @@ set OPEN_DYLAN_TARGET_PLATFORM=x86-win32 REM // Pentium runtime build options set PENTIUM_RUNTIME_OPTIONS= set QUOTED_PENTIUM_RUNTIME_OPTIONS= -if "%USE_FULL_C_RUNTIME%"=="no" goto setup_build_options -set PENTIUM_RUNTIME_OPTIONS=%PENTIUM_RUNTIME_OPTIONS% fullcrt=yes -set QUOTED_PENTIUM_RUNTIME_OPTIONS=PENTIUM_RUNTIME_OPTIONS="%PENTIUM_RUNTIME_OPTIONS%" REM // Build options :SETUP_BUILD_OPTIONS diff --git a/sources/common-dylan/win32-common-dylan.lid b/sources/common-dylan/win32-common-dylan.lid index ad6c7a5f53..b4129af2f4 100644 --- a/sources/common-dylan/win32-common-dylan.lid +++ b/sources/common-dylan/win32-common-dylan.lid @@ -29,7 +29,6 @@ Files: library machine-words/double machine-words/unsigned-double C-Source-Files: timer_helpers.c -C-Libraries: $(libcmt) Copyright: Original Code is Copyright (c) 1995-2004 Functional Objects, Inc. All rights reserved. License: See License.txt in this distribution for details. diff --git a/sources/jamfiles/x86-win32-vc6-build.jam b/sources/jamfiles/x86-win32-vc6-build.jam index 7eca6c16d9..df070a84da 100644 --- a/sources/jamfiles/x86-win32-vc6-build.jam +++ b/sources/jamfiles/x86-win32-vc6-build.jam @@ -47,17 +47,17 @@ LINKFLAGS ?= /NODEFAULTLIB # Runtime # +libcmt ?= libcmt.lib ; + # External libraries linked with the dylan library # (via the Linker-Options: keyword in Sources/dylan/dylan.lid) rtlibs ?= kernel32.lib pentium-run-time.lib mmdw.lib mpsplinth.lib - minvcrt.lib ; + $(libcmt) ; # External libraries linked with libraries other than the dylan library # (via the DylanLibrary function defined below) suplibs ?= kernel32.lib dylan-support.lib ; -libcmt ?= libcmt.lib ; - # Linker flags and libraries for GUI applications # Used in the Linker-Options: LID keyword of DUIM applications. guilflags ?= /RELEASE /subsystem:windows,4.0 ; diff --git a/sources/jamfiles/x86-win32-vc8-build.jam b/sources/jamfiles/x86-win32-vc8-build.jam index c4546fa195..f37e1b0c8e 100644 --- a/sources/jamfiles/x86-win32-vc8-build.jam +++ b/sources/jamfiles/x86-win32-vc8-build.jam @@ -47,17 +47,17 @@ LINKFLAGS ?= /NODEFAULTLIB /INCREMENTAL:NO /DEBUG /MANIFEST ; # Runtime # +libcmt ?= libcmt.lib ; + # External libraries linked with the dylan library # (via the Linker-Options: keyword in Sources/dylan/dylan.lid) rtlibs ?= kernel32.lib pentium-run-time.lib mmdw.lib mpsplinth.lib - minvcrt.lib ; + $(libcmt) ; # External libraries linked with libraries other than the dylan library # (via the DylanLibrary function defined below) suplibs ?= kernel32.lib dylan-support.lib ; -libcmt ?= libcmt.lib ; - # Linker flags and libraries for GUI applications # Used in the Linker-Options: LID keyword of DUIM applications. guilflags ?= /RELEASE /subsystem:windows,4.0 ; diff --git a/sources/lib/c-ffi/test/c-ffi-test.lid b/sources/lib/c-ffi/test/c-ffi-test.lid index 6474d3b3da..138c3d503a 100644 --- a/sources/lib/c-ffi/test/c-ffi-test.lid +++ b/sources/lib/c-ffi/test/c-ffi-test.lid @@ -4,7 +4,6 @@ Files: c-ffi-test-library tests C-Source-Files: main.c C-Header-Files: main.h -C-Libraries: $(libcmt) Copyright: Original Code is Copyright (c) 1995-2004 Functional Objects, Inc. All rights reserved. License: See License.txt in this distribution for details. diff --git a/sources/lib/run-time/Makefile.win32 b/sources/lib/run-time/Makefile.win32 index 1ad3d0e18f..14815f67d0 100644 --- a/sources/lib/run-time/Makefile.win32 +++ b/sources/lib/run-time/Makefile.win32 @@ -40,12 +40,10 @@ OBJS = collector.obj break.obj $(HEAPOBJS) harp-support\x86-windows\runtime.obj LIBFILE = pentium-run-time.lib USEROBJ = harp-support\x86-windows\dylan-support.obj USERLIB = dylan-support.lib -MINCRT = minvcrt.lib RUNTIMELIBDEST = $(LIBDEST)\pentium-run-time.lib MMDWDEST = $(LIBDEST)\mmdw.lib PLINTHDEST = $(LIBDEST)\mpsplinth.lib -MINCRTDEST = $(LIBDEST)\minvcrt.lib RELEASEMMDW = $(SDK4MEMORY_POOL_SYSTEM)\code\w3i3mv\hi\mmdw.lib RELEASEPLINTH = $(SDK4MEMORY_POOL_SYSTEM)\code\w3i3mv\hi\mpsplan.lib @@ -59,17 +57,6 @@ SYMBOLICPLINTH = mpsplan.lib PLINTHOBJS = plinth.obj mpsiowin32.obj DYLANPLINTH = dylan-plinth.lib -!if defined(fullcrt) -$(MINCRT): -!else -$(MINCRT): minvcrt.def rtsyms.obj - $(LINKLIB)$(MINCRT) /def:minvcrt.def /machine:ix86 - $(LINKLIB)$(MINCRT) $(MINCRT) rtsyms.obj - -rtsyms.obj: rtsyms.s - as -n -o rtsyms.obj rtsyms.s -!endif - $(DYLANPLINTH): $(PLINTHOBJS) $(LINKLIB)$(DYLANPLINTH) $(PLINTHOBJS) @@ -119,16 +106,6 @@ install-plinth: install-dylan-plinth echo Building pentium run time: install-plinth -!if defined(fullcrt) -install-mincrt: - echo Building pentium run time: install-mincrt (fullcrt) -!else -install-mincrt: $(MINCRT) - echo Building pentium run time: install-mincrt - if exist $(MINCRTDEST) del /q /f $(MINCRTDEST) - copy $(MINCRT) $(MINCRTDEST) -!endif - install-mmdw: echo Building pentium run time: install-mmdw if exist $(MMDWDEST) del /q /f $(MMDWDEST) @@ -148,7 +125,7 @@ install-debug-mmdw: $(DEBUGMMDW) copy $(DEBUGMMDW) $(MMDWDEST) -install-common-libs: ensure-dirs install-plinth install-userlib install-mincrt +install-common-libs: ensure-dirs install-plinth install-userlib install-stripped: ensure-dirs install-mmdw install-runtime install-common-libs @@ -165,6 +142,5 @@ install: ensure-dirs install-stripped install-build clean: pushd . & (del /f /q *collector.obj break.obj $(HEAPOBJS) windows-threads-primitives.obj windows-spy-interfaces.obj) & popd pushd . & (del /f /q *pentium-run-time.lib $(USERLIB)) & popd - pushd . & (del /f /q $(MINCRT) mincrt.def) & popd pushd . & (del /f /q $(DYLANPLINTH) $(PLINTHOBJS)) & popd diff --git a/sources/lib/run-time/minvcrt.def b/sources/lib/run-time/minvcrt.def deleted file mode 100644 index 04b91faa7e..0000000000 --- a/sources/lib/run-time/minvcrt.def +++ /dev/null @@ -1,13 +0,0 @@ -LIBRARY MSVCRT.dll -EXPORTS - _except_handler3 - _ftol - strcpy - strlen - memcpy - memset - free - realloc - strtod - strtoul - clock diff --git a/sources/lib/run-time/rtsyms.obj b/sources/lib/run-time/rtsyms.obj deleted file mode 100644 index fd42c8ab14c39059a97ca939ede90f9d93deb830..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 366 zcmeZaWM%+?9w6ohvsfARN>VFIz--)v0s}*WUP@v~B5oyM83zW21A0lt#RQZwG=S8l zW#*(p75@9rz>vy=nDJ@P-L5P6V@PP;*fT)oHvf|^@a!No7fvnVu Date: Wed, 1 Jan 2014 16:50:01 +0700 Subject: [PATCH 2/2] [win32] Spaces to tabs for some Makefile stuff. --- sources/lib/run-time/Makefile.win32 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sources/lib/run-time/Makefile.win32 b/sources/lib/run-time/Makefile.win32 index 14815f67d0..d46582a1ee 100644 --- a/sources/lib/run-time/Makefile.win32 +++ b/sources/lib/run-time/Makefile.win32 @@ -107,12 +107,12 @@ install-plinth: install-dylan-plinth install-mmdw: - echo Building pentium run time: install-mmdw + echo Building pentium run time: install-mmdw if exist $(MMDWDEST) del /q /f $(MMDWDEST) if not exist $(RELEASEMMDW) pushd $(SDK4MEMORY_POOL_SYSTEM)\code \ & $(MAKE) /k /f w3i3mv.nmk mmdw.lib > $(BUILD_LOGS)\make-mmdw.log \ & popd - copy $(RELEASEMMDW) $(MMDWDEST) + copy $(RELEASEMMDW) $(MMDWDEST) install-symbolic-mmdw: $(SYMBOLICMMDW) echo Building pentium run time: install-symbolic-mmdw @@ -141,6 +141,6 @@ install: ensure-dirs install-stripped install-build # (The files runtime.obj & dylan-support.obj are checked out from HOPE) clean: pushd . & (del /f /q *collector.obj break.obj $(HEAPOBJS) windows-threads-primitives.obj windows-spy-interfaces.obj) & popd - pushd . & (del /f /q *pentium-run-time.lib $(USERLIB)) & popd - pushd . & (del /f /q $(DYLANPLINTH) $(PLINTHOBJS)) & popd + pushd . & (del /f /q *pentium-run-time.lib $(USERLIB)) & popd + pushd . & (del /f /q $(DYLANPLINTH) $(PLINTHOBJS)) & popd