Changeset 104835 in webkit


Ignore:
Timestamp:
Jan 12, 2012 10:20:05 AM (12 years ago)
Author:
mitz@apple.com
Message:

When generating derived sources, use the same compiler that is used to compile WebCore.

Fixes <http://webkit.org/b/76189>
[mac] When compiling WebCore with clang, llvm-gcc is used to generate derived sources

Reviewed by Mark Rowe.

  • DerivedSources.make: Changed to use the CC environment variable instead of hardcoded gcc.
  • WebCore.xcodeproj/project.pbxproj: Set the CC environment variable, if not already set,

according to TARGET_GCC_VERSION. CC is used by DerivedSources.make and some of the perl
scripts it invokes.

Location:
trunk/Source/WebCore
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r104834 r104835  
     12012-01-12  Dan Bernstein  <mitz@apple.com>
     2
     3        When generating derived sources, use the same compiler that is used to compile WebCore.
     4
     5        Fixes <http://webkit.org/b/76189>
     6        [mac] When compiling WebCore with clang, llvm-gcc is used to generate derived sources
     7
     8        Reviewed by Mark Rowe.
     9
     10        * DerivedSources.make: Changed to use the CC environment variable instead of hardcoded gcc.
     11        * WebCore.xcodeproj/project.pbxproj: Set the CC environment variable, if not already set,
     12        according to TARGET_GCC_VERSION. CC is used by DerivedSources.make and some of the perl
     13        scripts it invokes.
     14
    1152012-01-12  Pierre Rossi  <pierre.rossi@gmail.com>
    216
  • trunk/Source/WebCore/DerivedSources.make

    r104654 r104835  
    624624FRAMEWORK_FLAGS = $(shell echo $(BUILT_PRODUCTS_DIR) $(FRAMEWORK_SEARCH_PATHS) | perl -e 'print "-F " . join(" -F ", split(" ", <>));')
    625625
    626 ifeq ($(shell gcc -E -P -dM $(FRAMEWORK_FLAGS) WebCore/ForwardingHeaders/wtf/Platform.h | grep ENABLE_DASHBOARD_SUPPORT | cut -d' ' -f3), 1)
     626ifeq ($(shell $(CC) -E -P -dM $(FRAMEWORK_FLAGS) WebCore/ForwardingHeaders/wtf/Platform.h | grep ENABLE_DASHBOARD_SUPPORT | cut -d' ' -f3), 1)
    627627    ENABLE_DASHBOARD_SUPPORT = 1
    628628else
     
    630630endif
    631631
    632 ifeq ($(shell gcc -E -P -dM $(FRAMEWORK_FLAGS) WebCore/ForwardingHeaders/wtf/Platform.h | grep ENABLE_ORIENTATION_EVENTS | cut -d' ' -f3), 1)
     632ifeq ($(shell $(CC) -E -P -dM $(FRAMEWORK_FLAGS) WebCore/ForwardingHeaders/wtf/Platform.h | grep ENABLE_ORIENTATION_EVENTS | cut -d' ' -f3), 1)
    633633    ENABLE_ORIENTATION_EVENTS = 1
    634634else
  • trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj

    r104827 r104835  
    2526125261                        runOnlyForDeploymentPostprocessing = 0;
    2526225262                        shellPath = /bin/sh;
    25263                         shellScript = "mkdir -p \"${BUILT_PRODUCTS_DIR}/DerivedSources/WebCore\"\ncd \"${BUILT_PRODUCTS_DIR}/DerivedSources/WebCore\"\n\n/bin/ln -sfh \"${SRCROOT}\" WebCore\nexport WebCore=\"WebCore\"\n\nif [ \"${ACTION}\" = \"build\" -o \"${ACTION}\" = \"install\" -o \"${ACTION}\" = \"installhdrs\" ]; then\n    make  --no-builtin-rules -f \"WebCore/DerivedSources.make\" -j `/usr/sbin/sysctl -n hw.availcpu`\nfi\n";
     25263                        shellScript = "mkdir -p \"${BUILT_PRODUCTS_DIR}/DerivedSources/WebCore\"\ncd \"${BUILT_PRODUCTS_DIR}/DerivedSources/WebCore\"\n\n/bin/ln -sfh \"${SRCROOT}\" WebCore\nexport WebCore=\"WebCore\"\n\nif [ ! $CC ]; then\n    case $TARGET_GCC_VERSION in\n        (GCC_42)\n            export CC=\"${DT_TOOLCHAIN_DIR}/usr/bin/gcc-4.2\";;\n        (LLVM_GCC_42)\n            export CC=\"${DT_TOOLCHAIN_DIR}/usr/bin/llvm-gcc-4.2\";;\n        (LLVM_COMPILER)\n            export CC=\"${DT_TOOLCHAIN_DIR}/usr/bin/clang\";;\n    esac\nfi\n\nif [ \"${ACTION}\" = \"build\" -o \"${ACTION}\" = \"install\" -o \"${ACTION}\" = \"installhdrs\" ]; then\n    make  --no-builtin-rules -f \"WebCore/DerivedSources.make\" -j `/usr/sbin/sysctl -n hw.availcpu`\nfi\n";
    2526425264                };
    2526525265/* End PBXShellScriptBuildPhase section */
Note: See TracChangeset for help on using the changeset viewer.