Bug 111881

Summary: Build fix: guard macro test for MAC platform for a feature
Product: WebKit Reporter: Adenilson Cavalcanti Silva <savagobr>
Component: WebKit2Assignee: Adenilson Cavalcanti Silva <savagobr>
Status: RESOLVED FIXED    
Severity: Normal CC: ddkilzer, eric, sam, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
Only test for OSX version if the platform is Mac
ddkilzer: review+, ddkilzer: commit-queue-
Better use of macro conditionals as suggested by Reviewer ddkilzer: review+, webkit.review.bot: commit-queue-

Description Adenilson Cavalcanti Silva 2013-03-08 11:51:13 PST
Changeset 145235 broke WebKit2 build thanks to a not defined macro. Compilation fails with:

/home/adenilson/apps/webkit/Webkit/Source/WebKit2/UIProcess/WebInspectorProxy.cpp:69:5: error: "__MAC_OS_X_VERSION_MIN_REQUIRED" is not defined [-Werror=undef]
cc1plus: all warnings being treated as errors
Comment 1 Adenilson Cavalcanti Silva 2013-03-08 11:54:58 PST
Created attachment 192261 [details]
Only test for OSX version if the platform is Mac
Comment 2 David Kilzer (:ddkilzer) 2013-03-08 11:58:31 PST
Comment on attachment 192261 [details]
Only test for OSX version if the platform is Mac

View in context: https://bugs.webkit.org/attachment.cgi?id=192261&action=review

r=me with that change.

> Source/WebKit2/UIProcess/WebInspectorProxy.cpp:70
> +#if PLATFORM(MAC)
>  #if __MAC_OS_X_VERSION_MIN_REQUIRED >= 1080

Usually we just use:

#if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 1080
Comment 3 Adenilson Cavalcanti Silva 2013-03-08 12:02:45 PST
Created attachment 192262 [details]
Better use of macro conditionals as suggested by Reviewer
Comment 4 David Kilzer (:ddkilzer) 2013-03-08 12:09:42 PST
Comment on attachment 192262 [details]
Better use of macro conditionals as suggested by Reviewer

r=me
Comment 5 David Kilzer (:ddkilzer) 2013-03-08 12:11:03 PST
Comment on attachment 192262 [details]
Better use of macro conditionals as suggested by Reviewer

View in context: https://bugs.webkit.org/attachment.cgi?id=192262&action=review

> Source/WebKit2/UIProcess/WebInspectorProxy.cpp:69
> +#if PLATFORM(MAC) &&  __MAC_OS_X_VERSION_MIN_REQUIRED >= 1080

Nit: extra space after "&&".  I'll re-review if you want to fix.
Comment 6 WebKit Review Bot 2013-03-08 13:15:14 PST
Comment on attachment 192262 [details]
Better use of macro conditionals as suggested by Reviewer

Rejecting attachment 192262 [details] from commit-queue.

Failed to run "['/mnt/git/webkit-commit-queue/Tools/Scripts/webkit-patch', '--status-host=webkit-commit-queue.appspot.com', '--bot-id=gce-cq-02', 'land-attachment', '--force-clean', '--non-interactive', '--parent-command=commit-queue', 192262, '--port=chromium-xvfb']" exit_code: 2 cwd: /mnt/git/webkit-commit-queue

Last 500 characters of output:
rce/WebKit/chromium/webkit/media/crypto/ppapi/cdm --revision 181763 --non-interactive --force --accept theirs-conflict --ignore-externals' in '/mnt/git/webkit-commit-queue/Source/WebKit/chromium'
57>At revision 181763.

________ running '/usr/bin/python tools/clang/scripts/update.py --mac-only' in '/mnt/git/webkit-commit-queue/Source/WebKit/chromium'

________ running '/usr/bin/python gyp_webkit' in '/mnt/git/webkit-commit-queue/Source/WebKit/chromium'
Updating webkit projects from gyp files...

Full output: http://webkit-commit-queue.appspot.com/results/17050637
Comment 7 Adenilson Cavalcanti Silva 2013-03-08 14:10:42 PST
Fixed by 145256