develooper Front page | perl.perl5.porters | Postings from January 2001

[PATCH: perl-5.6.1-TRIAL1] Win32 Makefile fixes

Thread Next
From:
Indy Singh
Date:
January 9, 2001 15:19
Subject:
[PATCH: perl-5.6.1-TRIAL1] Win32 Makefile fixes
Message ID:
008301c07a92$c03a8b50$00957018@roadhog
The enclosed patch contains the following changes to the Win32 Makefile

1) Changed default compiler options to release instead of debug.
2) Changed default compile flags to generate binary compatible code with
existiting Win32 module repositories.

Note 1:
The default compiler options were set to generate debug (-Od) code unless
one manually changed the Makefile to uncomment the #CCTYPE=MSVC60.  If you
were using MSVC50 then you were stuck with debug code.

I have tested this with MSVC50 (VisualStudio97)and MVSC60 (VisualStudio 98).

The DLL file size is 340KB smaller.

There was a comment in the make file to the effect that test would fail if
one did a release or optimized build with a compiler older than 60.  This
seems to be incorrect.  All tests run successfully with MSVC50 and MSVC60.

 Directory of C:\temp\perl-5.6.1-TRIAL1-release-build
01/08/2001  07:52p              16,384 perl.exe
01/08/2001  07:52p             614,400 perl56.dll

 Directory of C:\temp\perl-5.6.1-TRIAL1-original-build
01/08/2001  07:46p              16,384 perl.exe
01/08/2001  07:46p             962,560 perl56.dll


Note2:
The default options did not allow the use of pre-built binary modules from
several repositories including ActiveState.  This change also enables fork
emulation in Win32.

Indy Singh



--- Makefile.old Mon Dec 18 05:01:46 2000
+++ Makefile Mon Jan 08 20:32:58 2001
@@ -29,7 +29,7 @@
 # versioned installation can be obtained by setting INST_TOP above to a
 # path that includes an arbitrary version string.
 #
-INST_VER = \5.6.0
+#INST_VER = \5.6.0

 #
 # Comment this out if you DON'T want your perl installation to have
@@ -40,27 +40,27 @@
 # the same location.  Commenting it out gives you a simpler
 # installation that is easier to understand for beginners.
 #
-INST_ARCH = \$(ARCHNAME)
+#INST_ARCH = \$(ARCHNAME)

 #
 # uncomment to enable multiple interpreters.  This is need for fork()
 # emulation.
 #
-#USE_MULTI = define
+USE_MULTI = define

 #
 # Beginnings of interpreter cloning/threads; still very incomplete.
 # This should be enabled to get the fork() emulation.  This needs
 # USE_MULTI as well.
 #
-#USE_ITHREADS = define
+USE_ITHREADS = define

 #
 # uncomment to enable the implicit "host" layer for all system calls
 # made by perl.  This needs USE_MULTI above.  This is also needed to
 # get fork().
 #
-#USE_IMP_SYS = define
+USE_IMP_SYS = define

 #
 # WARNING! This option is deprecated and will eventually go away (enable
@@ -284,18 +284,12 @@

 # Visual Studio 98 specific
 !IF "$(CCTYPE)" == "MSVC60"
-
 # VC 6.0 can load the socket dll on demand.  Makes the test suite
 # run in about 10% less time.
 DELAYLOAD = -DELAYLOAD:wsock32.dll -DELAYLOAD:shell32.dll delayimp.lib
-
-# VC 6.0 seems capable of compiling perl correctly with optimizations
-# enabled.  Anything earlier fails tests.
-!IF "$(CFG)" == ""
-CFG  = Optimize
-!ENDIF
 !ENDIF

+
 ARCHDIR  = ..\lib\$(ARCHNAME)
 COREDIR  = ..\lib\CORE
 AUTODIR  = ..\lib\auto
@@ -350,13 +344,9 @@
 !  ENDIF
 LINK_DBG = -debug -pdb:none
 !ELSE
-!  IF  "$(CFG)" == "Optimize"
 # -O1 yields smaller code, which turns out to be faster than -O2
 #OPTIMIZE = -O2 -MD -DNDEBUG
 OPTIMIZE = -O1 -MD -DNDEBUG
-!  ELSE
-OPTIMIZE = -Od -MD -DNDEBUG
-!  ENDIF
 LINK_DBG = -release
 !ENDIF



Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About