diff options
-rw-r--r-- | utils/perlcc.PL | 8 | ||||
-rw-r--r-- | win32/makefile.mk | 4 |
2 files changed, 9 insertions, 3 deletions
diff --git a/utils/perlcc.PL b/utils/perlcc.PL index 971923b68e..f0636f62bd 100644 --- a/utils/perlcc.PL +++ b/utils/perlcc.PL @@ -390,10 +390,16 @@ sub _ccharness @$libs = grep { !(/DynaLoader\.a$/ && ($dynaloader = $_)) } @$libs if($^O eq 'cygwin'); + my $args = "@args"; + if ($^O eq 'MSWin32' && $Config{cc} =~ /^bcc/i) { + # BC++ cmd line syntax does not allow space between -[oexz...] and arg + $args =~ s/(^|\s+)-([oe])\s+/$1-$2/g; + } + my $ccflags = $Config{ccflags}; $ccflags .= ' -DUSEIMPORTLIB' if $^O eq 'cygwin'; my $cccmd = "$Config{cc} $ccflags $optimize $incdir " - ."@args $dynaloader $linkargs @$libs"; + ."$args $dynaloader $linkargs @$libs"; _print ("$cccmd\n", 36); _run("$cccmd", 18 ); diff --git a/win32/makefile.mk b/win32/makefile.mk index 3d4f57e955..f2a19da7d9 100644 --- a/win32/makefile.mk +++ b/win32/makefile.mk @@ -838,9 +838,9 @@ CFG_VARS = \ d_crypt=$(D_CRYPT) ~ \ d_mymalloc=$(PERL_MALLOC) ~ \ libs=$(LIBFILES:f) ~ \ - incpath=$(CCINCDIR) ~ \ + incpath=$(CCINCDIR:s/\/\\/) ~ \ libperl=$(PERLIMPLIB:f) ~ \ - libpth=$(CCLIBDIR);$(EXTRALIBDIRS) ~ \ + libpth=$(CCLIBDIR:s/\/\\/);$(EXTRALIBDIRS:s/\/\\/) ~ \ libc=$(LIBC) ~ \ make=dmake ~ \ _o=$(o) obj_ext=$(o) ~ \ |