<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>3344</bug_id>
          
          <creation_ts>2005-06-08 04:17:04 -0700</creation_ts>
          <short_desc>10.3.9 Build Failure: isnan failure in kjs_window.cpp</short_desc>
          <delta_ts>2006-01-30 03:18:11 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>JavaScriptCore</component>
          <version>412</version>
          <rep_platform>Mac</rep_platform>
          <op_sys>OS X 10.3</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>WORKSFORME</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          <blocked>3354</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Christopher Schmidt">crschmidt</reporter>
          <assigned_to name="Maciej Stachowiak">mjs</assigned_to>
          <cc>snu</cc>
    
    <cc>yibinlu</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>11068</commentid>
    <comment_count>0</comment_count>
    <who name="Christopher Schmidt">crschmidt</who>
    <bug_when>2005-06-08 04:17:06 -0700</bug_when>
    <thetext>Another build error: in file:
/Users/crschmidt/webkit/WebCore/khtml/ecma/kjs_window.cpp

/Users/crschmidt/webkit/WebCore/khtml/ecma/kjs_window.cpp:93: error: `isnan&apos; not
declared
/Users/crschmidt/webkit/WebCore/khtml/ecma/kjs_window.cpp: In function `int
KJS::intFeature(const QMap&lt;QString, QString&gt;&amp;, const char*, int, int, int)&apos;:
/Users/crschmidt/webkit/WebCore/khtml/ecma/kjs_window.cpp:557: error: `isnan&apos;
undeclared (first use this function)
/Users/crschmidt/webkit/WebCore/khtml/ecma/kjs_window.cpp:557: error: (Each
undeclared identifier is reported only once for each function it appears in.)

Interestingly enough, there seems to be some kind of indication in the file of
why this might happen: 

// Must include &lt;cmath&gt; instead of &lt;math.h&gt; because of a bug in the
// gcc 3.3 library version of &lt;math.h&gt; where if you include both
// &lt;cmath&gt; and &lt;math.h&gt; the macros necessary for functions like
// isnan are not defined.

But &lt;cmath&gt; is being included. Not sure why exactly this is/isn&apos;t working, but I
do know that Panther is using gcc-3.3, whereas building on Tiger used gcc-4.0.

This one is an error, rather than a warning, so it can&apos;t be just skipped over.

I was able to continue building by pulling the isnan calls out (as well as the
using std::isnan), although obviously the code in this file will suffer as a
result. (Not sure what the end result of this really is, just trying to get it
to build to find where things which need to change are).

(Brought over from Bug 3331).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>11116</commentid>
    <comment_count>1</comment_count>
    <who name="Robin Lu">yibinlu</who>
    <bug_when>2005-06-08 20:08:02 -0700</bug_when>
    <thetext>I worked it around by applying this:

-using std::isnan;
+extern &quot;C&quot; int isnan(double);
</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>11118</commentid>
    <comment_count>2</comment_count>
    <who name="Christopher Schmidt">crschmidt</who>
    <bug_when>2005-06-08 20:20:20 -0700</bug_when>
    <thetext>Confirmed: Robin&apos;s fix allows the file to build correctly.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>11831</commentid>
    <comment_count>3</comment_count>
      <attachid>2308</attachid>
    <who name="Finlay Dobbie">snu</who>
    <bug_when>2005-06-13 18:41:04 -0700</bug_when>
    <thetext>Created attachment 2308
proposed fix</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12283</commentid>
    <comment_count>4</comment_count>
    <who name="Harri Porten">porten</who>
    <bug_when>2005-06-16 14:47:17 -0700</bug_when>
    <thetext>FWIW, the KDE version already uses an easy fix for this problem. The code is 
#ifdefed with HAVE_FLOAT_H. It&apos;s just that it&apos;s also protected 
by !APPLE_CHANGES so I think all that&apos;s needed is to apply the same change to 
operations.h. </thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12549</commentid>
    <comment_count>5</comment_count>
      <attachid>2308</attachid>
    <who name="Darin Adler">darin</who>
    <bug_when>2005-06-18 16:53:21 -0700</bug_when>
    <thetext>Comment on attachment 2308
proposed fix

I don&apos;t like solutions that involve changing the project file, because it makes
it likely that we&apos;ll never remember to remove the hack. Also, setting the
internal _GLIBCPP flag in the project file is not how the library&apos;s intended to
be used.

There must be some other solution to compiling this on Panther. I&apos;d prefer
another approach.

If we search and can&apos;t come up with anything, then feel free to set the review
flag on this patch again and I&apos;ll reconsider.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12553</commentid>
    <comment_count>6</comment_count>
    <who name="Finlay Dobbie">snu</who>
    <bug_when>2005-06-18 16:57:10 -0700</bug_when>
    <thetext>This solution is the one that the Xcode Tools team suggested, fwiw.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12556</commentid>
    <comment_count>7</comment_count>
    <who name="Finlay Dobbie">snu</who>
    <bug_when>2005-06-18 17:04:05 -0700</bug_when>
    <thetext>(In reply to comment #6)
&gt; This solution is the one that the Xcode Tools team suggested, fwiw.

Just to clarify: this suggestion was made by Chris Espinosa and seemingly endorsed by Scott Tooker on 
the xcode-users mailing list, and not necessarily the position of the Xcode Tools team. See http://
lists.apple.com/archives/xcode-users/2005/May/msg00765.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>19432</commentid>
    <comment_count>8</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2005-09-11 22:05:51 -0700</bug_when>
    <thetext>I think this is fixed in TOT.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30618</commentid>
    <comment_count>9</comment_count>
    <who name="Maciej Stachowiak">mjs</who>
    <bug_when>2006-01-30 03:18:11 -0800</bug_when>
    <thetext>Seems to work ok on TOT.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>2308</attachid>
            <date>2005-06-13 18:41:04 -0700</date>
            <delta_ts>2005-06-18 16:53:21 -0700</delta_ts>
            <desc>proposed fix</desc>
            <filename>3344.patch</filename>
            <type>text/plain</type>
            <size>785</size>
            <attacher name="Finlay Dobbie">snu</attacher>
            
              <data encoding="base64">SW5kZXg6IFdlYkNvcmUucGJwcm9qL3Byb2plY3QucGJ4cHJvago9PT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09ClJDUyBmaWxl
OiAvY3ZzL3Jvb3QvV2ViQ29yZS9XZWJDb3JlLnBicHJvai9wcm9qZWN0LnBieHByb2osdgpyZXRy
aWV2aW5nIHJldmlzaW9uIDEuNTUyCmRpZmYgLXUgLXIxLjU1MiBwcm9qZWN0LnBieHByb2oKLS0t
IHByb2plY3QucGJ4cHJvagkyMDA1LzA2LzA4IDA5OjU1OjEyCTEuNTUyCisrKyBwcm9qZWN0LnBi
eHByb2oJMjAwNS8wNi8xNCAwMTo0MDoxNQpAQCAtMjMwNyw3ICsyMzA3LDcgQEAKIAkJCQlHQ0Nf
T1BUSU1JWkFUSU9OX0xFVkVMID0gczsKIAkJCQlHQ0NfUFJFQ09NUElMRV9QUkVGSVhfSEVBREVS
ID0gWUVTOwogCQkJCUdDQ19QUkVGSVhfSEVBREVSID0gV2ViQ29yZVByZWZpeC5oOwotCQkJCUdD
Q19QUkVQUk9DRVNTT1JfREVGSU5JVElPTlMgPSAiJChERUJVR19ERUZJTkVTKSBBUFBMRV9DSEFO
R0VTIEtIVE1MX05PX0NQTFVTUExVU19ET00iOworCQkJCUdDQ19QUkVQUk9DRVNTT1JfREVGSU5J
VElPTlMgPSAiX0dMSUJDUFBfVVNFX0M5OT0xICQoREVCVUdfREVGSU5FUykgQVBQTEVfQ0hBTkdF
UyBLSFRNTF9OT19DUExVU1BMVVNfRE9NIjsKIAkJCQlHQ0NfVFJFQVRfV0FSTklOR1NfQVNfRVJS
T1JTID0gWUVTOwogCQkJCUdDQ19XQVJOX0FCT1VUX01JU1NJTkdfUFJPVE9UWVBFUyA9IFlFUzsK
IAkJCQlHQ0NfV0FSTl9OT05fVklSVFVBTF9ERVNUUlVDVE9SID0gWUVTOwo=
</data>
<flag name="review"
          id="6"
          type_id="1"
          status="-"
          setter="darin"
    />
          </attachment>
      

    </bug>

</bugzilla>