summaryrefslogtreecommitdiffstats
path: root/build/SConscript.main
diff options
context:
space:
mode:
authorsgk@google.com <sgk@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-24 18:26:24 +0000
committersgk@google.com <sgk@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-24 18:26:24 +0000
commitc7848cc2522c8057fe0c54a3485a98cd309c551f (patch)
tree7bc96c92ac98bb96cf427059a188ca6685aabcbd /build/SConscript.main
parent8c1445388c4f9cdf1f2214d7924935b5891150ca (diff)
downloadchromium_src-c7848cc2522c8057fe0c54a3485a98cd309c551f.zip
chromium_src-c7848cc2522c8057fe0c54a3485a98cd309c551f.tar.gz
chromium_src-c7848cc2522c8057fe0c54a3485a98cd309c551f.tar.bz2
Get libevent building and linking in base_unittests in the Mac SCons build:
* Call the $LIBEVENT_DIR/SConscript file on both Linux and Mac. * Add generation of the config.h file. * Modify the libevent_prebuild.sh script so SCons can pass in the input file name (because SCons executes things from top of tree) but the script still defaults to what XCode wants. * Only build epoll.c and epoll_sub.c on Linux. * Only build kqueue.c on Mac. * Add -framework AppKit to the link lines. * Add -fobjc-gc to Objective C compilation. * Add message_pump_mac.mm to the base input file list on Mac. * Build message_pump_libevent.cc on for base on both Linux and Mac. * Link against -levent on both Linux and Mac. Review URL: http://codereview.chromium.org/4254 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2555 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'build/SConscript.main')
-rw-r--r--build/SConscript.main4
1 files changed, 3 insertions, 1 deletions
diff --git a/build/SConscript.main b/build/SConscript.main
index 8807cbd..80c1052 100644
--- a/build/SConscript.main
+++ b/build/SConscript.main
@@ -368,6 +368,7 @@ elif env['PLATFORM'] == 'darwin':
],
CXXFLAGS = [
'-fvisibility-inlines-hidden',
+ '${str(SOURCE).endswith(".mm") and "-fobjc-gc" or ""}',
],
CCFLAGS = [
'-fmessage-length=0',
@@ -392,6 +393,7 @@ elif env['PLATFORM'] == 'darwin':
'/System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks',
],
FRAMEWORKS = [
+ 'AppKit',
'ApplicationServices',
'Foundation',
],
@@ -507,7 +509,7 @@ if LoadComponent('third_party'):
'$LIBXML_DIR/SConscript',
'$LIBXSLT_DIR/SConscript',
])
- if env['PLATFORM'] == 'posix':
+ if env['PLATFORM'] in ('posix', 'darwin'):
sconscripts.extend([
'$LIBEVENT_DIR/SConscript',
])