<?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>76476</bug_id>
          
          <creation_ts>2012-01-17 13:09:31 -0800</creation_ts>
          <short_desc>Build failure on Snow Leopard i386: implicit conversion warnings</short_desc>
          <delta_ts>2014-09-01 11:41:02 -0700</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>528+ (Nightly build)</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>WONTFIX</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>109834</blocked>
          <everconfirmed>0</everconfirmed>
          <reporter name="Jeff Johnson">opendarwin</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>aroben</cc>
    
    <cc>barraclough</cc>
    
    <cc>burg</cc>
    
    <cc>ggaren</cc>
    
    <cc>mrowe</cc>
    
    <cc>oliver</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>537318</commentid>
    <comment_count>0</comment_count>
    <who name="Jeff Johnson">opendarwin</who>
    <bug_when>2012-01-17 13:09:31 -0800</bug_when>
    <thetext>I&apos;m trying to build WebKit trunk at git commit 790c9d7dc9ceed0e8283c70013d273be222e7a24, git-svn-id: http://svn.webkit.org/repository/webkit/trunk@105183 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Building the Debug configuration fails on Snow Leopard, arch i386, Xcode 3.2.6. Here&apos;s where it fails in the build transcript:

CompileC /Users/Shared/source/WebKit/WebKitBuild/JavaScriptCore.build/Debug/JavaScriptCore.build/Objects-normal/i386/DatePrototype.o runtime/DatePrototype.cpp normal i386 c++ com.apple.compilers.gcc.4_2
    cd /Users/Shared/source/WebKit/Source/JavaScriptCore
    setenv LANG en_US.US-ASCII
    /Developer/usr/bin/gcc-4.2 -x c++ -arch i386 -fmessage-length=0 -pipe -Wno-trigraphs -fno-exceptions -fno-rtti -fpascal-strings -fasm-blocks -O0 -Werror -Wmissing-prototypes -Wnon-virtual-dtor -Wnewline-eof -DHAVE_DTRACE=1 -DWEBKIT_VERSION_MIN_REQUIRED=WEBKIT_VERSION_LATEST -DHAVE_HEADER_DETECTION_H -fstrict-aliasing -fvisibility-inlines-hidden -fno-threadsafe-statics -mmacosx-version-min=10.6 -gdwarf-2 -I/Users/Shared/source/WebKit/WebKitBuild/JavaScriptCore.build/Debug/JavaScriptCore.build/JavaScriptCore.hmap -Wall -Wextra -Wcast-qual -Wchar-subscripts -Wextra-tokens -Wformat=2 -Winit-self -Wmissing-format-attribute -Wmissing-noreturn -Wpacked -Wpointer-arith -Wredundant-decls -Wundef -Wwrite-strings -Wshorten-64-to-32 -F/Users/Shared/source/WebKit/WebKitBuild/Debug -I/Users/Shared/source/WebKit/WebKitBuild/Debug/include -I/Users/Shared/source/WebKit/WebKitBuild/Debug/DerivedSources/JavaScriptCore -I. -Iicu -I/Users/Shared/source/WebKit/WebKitBuild/JavaScriptCore.build/Debug/JavaScriptCore.build/DerivedSources/i386 -I/Users/Shared/source/WebKit/WebKitBuild/JavaScriptCore.build/Debug/JavaScriptCore.build/DerivedSources -include /var/folders/YN/YN5rYxFcFny7MbZuKAQAw++++TI/-Caches-/com.apple.Xcode.501/SharedPrecompiledHeaders/JavaScriptCorePrefix-fqfopdxsbxxzoagbayqcsvgxdjft/JavaScriptCorePrefix.h -c /Users/Shared/source/WebKit/Source/JavaScriptCore/runtime/DatePrototype.cpp -o /Users/Shared/source/WebKit/WebKitBuild/JavaScriptCore.build/Debug/JavaScriptCore.build/Objects-normal/i386/DatePrototype.o

cc1plus: warnings being treated as errors
/Users/Shared/source/WebKit/Source/JavaScriptCore/runtime/DatePrototype.cpp: In function &apos;JSC::EncodedJSValue JSC::dateProtoFuncToISOString(JSC::ExecState*)&apos;:
/Users/Shared/source/WebKit/Source/JavaScriptCore/runtime/DatePrototype.cpp:513: warning: implicit conversion shortens 64-bit value into a 32-bit value</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>537342</commentid>
    <comment_count>1</comment_count>
    <who name="Jeff Johnson">opendarwin</who>
    <bug_when>2012-01-17 14:06:49 -0800</bug_when>
    <thetext>I built WebKit with GCC_TREAT_WARNINGS_AS_ERRORS=NO and found implicit conversion warnings in a bunch of other files too. Otherwise the build seemed to be fine though.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>658738</commentid>
    <comment_count>2</comment_count>
    <who name="Mark Rowe (bdash)">mrowe</who>
    <bug_when>2012-06-27 11:35:16 -0700</bug_when>
    <thetext>Very few people actively build WebKit with such an old version of Xcode. Patches are welcome to address the issues you run in to though.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>658797</commentid>
    <comment_count>3</comment_count>
    <who name="Jeff Johnson">opendarwin</who>
    <bug_when>2012-06-27 12:51:59 -0700</bug_when>
    <thetext>I found something interesting. If I build i386 with Xcode 4.2 on Snow Leopard instead of Xcode 3.2.6, it succeeds, but I can see in the build transcript that it&apos;s using &quot;-Wno-shorten-64-to-32&quot;, whereas you can see in my transcript above that it used -Wshorten-64-to-32 with Xcode 3.2.6.

I did a search of the WebKit project and found the xcconfig file:

https://trac.webkit.org/browser/trunk/Source/JavaScriptCore/Configurations/Base.xcconfig

67	WARNING_CFLAGS_macosx = $(WARNING_CFLAGS_macosx_$(CURRENT_ARCH));
68	WARNING_CFLAGS_macosx_ = $(WARNING_CFLAGS_BASE) -Wshorten-64-to-32;
69	WARNING_CFLAGS_macosx_i386 = $(WARNING_CFLAGS_BASE) -Wshorten-64-to-32;
70	WARNING_CFLAGS_macosx_ppc = $(WARNING_CFLAGS_BASE) -Wshorten-64-to-32;
71	// FIXME: JavaScriptCore 64-bit builds should build with -Wshorten-64-to-32
72	WARNING_CFLAGS_macosx_ppc64 = $(WARNING_CFLAGS_BASE);
73	WARNING_CFLAGS_macosx_x86_64 = $(WARNING_CFLAGS_BASE);

Notice the FIXME comment. If I add -Wshorten-64-to-32 to line 73, then the build fails even with Xcode 4.2.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>658799</commentid>
    <comment_count>4</comment_count>
    <who name="Jeff Johnson">opendarwin</who>
    <bug_when>2012-06-27 12:53:54 -0700</bug_when>
    <thetext>I should note that I usually do build-webkit ONLY_ACTIVE_ARCH=NO ARCHS=&quot;i386 x86_64&quot;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>658804</commentid>
    <comment_count>5</comment_count>
    <who name="Mark Rowe (bdash)">mrowe</who>
    <bug_when>2012-06-27 12:56:16 -0700</bug_when>
    <thetext>I don&apos;t think any of that is all that interesting. When building 32-bit we&apos;ve always built with -Wshorten-64-to-32 and we&apos;ve never built with it enabled for 64-bit. I think the difference you&apos;re seeing between Xcode 3.2.6 and Xcode 4.2 is actually the difference between building for i386 and x86_64.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>658855</commentid>
    <comment_count>6</comment_count>
    <who name="Jeff Johnson">opendarwin</who>
    <bug_when>2012-06-27 14:02:38 -0700</bug_when>
    <thetext>Ok, you&apos;re right, I saw the -Wno-shorten-64-to-32 in the transcript for x86_64 and also for i386, but I didn&apos;t notice the second -Wshorten-64-to-32 for i386 that overrides the first.

There are probably way too many warnings here to fix in patches.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>