diff options
author | Tony Cook <tony@develop-help.com> | 2015-09-01 10:41:40 +1000 |
---|---|---|
committer | Steve Hay <steve.m.hay@googlemail.com> | 2015-10-21 08:27:27 +0100 |
commit | c38db1e0c8b9e8874f440f9d8856dbeb14bdfc7e (patch) | |
tree | 2a0ca7899decec9256ecc577ad426c960b0bff3d | |
parent | f2c3814ac5b4fedfd441efa352af3d6b4fe160c1 (diff) | |
download | perl-c38db1e0c8b9e8874f440f9d8856dbeb14bdfc7e.tar.gz |
[perl #125924] allow op/infnan.t to pass on Win32 gcc
(cherry picked from commit c0bf9074e4a1b56f9afe46591417297e6613d5ea)
-rw-r--r-- | win32/config_sh.PL | 25 |
1 files changed, 16 insertions, 9 deletions
diff --git a/win32/config_sh.PL b/win32/config_sh.PL index 98255a8eb2..74e5f0dd4b 100644 --- a/win32/config_sh.PL +++ b/win32/config_sh.PL @@ -198,6 +198,19 @@ else { $opt{uvxformat} = '"lx"'; } +unless ($opt{cc} =~ /\bcl/) { + if ($opt{WIN64} eq 'define') { + $opt{longdblsize} = 16; + $opt{longdblinfbytes} = '0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00'; + $opt{longdblnanbytes} = '0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00'; + } + else { + $opt{longdblsize} = 12; + $opt{longdblinfbytes} = '0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x7f, 0x00, 0x00'; + $opt{longdblnanbytes} = '0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00'; + } +} + # set long double options if ($opt{uselongdouble} eq 'define') { $opt{d_Gconvert} = 'sprintf((b),"%.*""Lg",(n),(x))'; @@ -214,14 +227,7 @@ if ($opt{uselongdouble} eq 'define') { $opt{d_PRIfldbl} = 'define'; $opt{d_PRIgldbl} = 'define'; $opt{d_SCNfldbl} = 'define'; - if ($opt{WIN64} eq 'define') { - $opt{longdblsize} = 16; - $opt{nvsize} = 16; - } - else { - $opt{longdblsize} = 12; - $opt{nvsize} = 12; - } + $opt{nvsize} = $opt{longdblsize}; $opt{nvtype} = 'long double'; $opt{nv_overflows_integers_at} = '256.0*256.0*256.0*256.0*256.0*256.0*256.0*2.0*2.0*2.0*2.0*2.0*2.0*2.0*2.0'; $opt{nvEUformat} = '"LE"'; @@ -230,6 +236,8 @@ if ($opt{uselongdouble} eq 'define') { $opt{nveformat} = '"Le"'; $opt{nvfformat} = '"Lf"'; $opt{nvgformat} = '"Lg"'; + $opt{longdblkind} = 3; + $opt{longdblmantbits} = 64; } else { $opt{d_Gconvert} = 'sprintf((b),"%.*g",(n),(x))'; @@ -246,7 +254,6 @@ else { $opt{d_PRIfldbl} = 'undef'; $opt{d_PRIgldbl} = 'undef'; $opt{d_SCNfldbl} = 'undef'; - $opt{longdblsize} = 8; $opt{nvsize} = 8; $opt{nvtype} = 'double'; $opt{nv_overflows_integers_at} = '256.0*256.0*256.0*256.0*256.0*256.0*2.0*2.0*2.0*2.0*2.0'; |