2012-08-10 23:32:19 +04:00
|
|
|
{
|
|
|
|
'variables': {
|
|
|
|
'pkg-config': 'pkg-config',
|
|
|
|
'chromium_code': 1,
|
2012-08-11 01:54:28 +04:00
|
|
|
'use_aura%': 0,
|
|
|
|
'conditions': [
|
|
|
|
['OS=="win"', {
|
|
|
|
'os_posix': 0,
|
|
|
|
}, {
|
|
|
|
'os_posix': 1,
|
|
|
|
}],
|
|
|
|
# Set toolkit_uses_gtk for the Chromium browser on Linux.
|
|
|
|
['(OS=="linux" or OS=="freebsd" or OS=="openbsd" or OS=="solaris") and use_aura==0', {
|
|
|
|
'toolkit_uses_gtk%': 1,
|
|
|
|
}, {
|
|
|
|
'toolkit_uses_gtk%': 0,
|
|
|
|
}],
|
|
|
|
],
|
2013-02-28 22:55:48 +04:00
|
|
|
'fix_framework_link_command': [
|
|
|
|
'install_name_tool',
|
|
|
|
'-change',
|
|
|
|
'@executable_path/libcef.dylib',
|
|
|
|
'@rpath/Chromium Embedded Framework.framework/Libraries/libcef.dylib',
|
|
|
|
'-change',
|
|
|
|
'@executable_path/../Frameworks/CocoaOniguruma.framework/Versions/A/CocoaOniguruma',
|
|
|
|
'@rpath/CocoaOniguruma.framework/Versions/A/CocoaOniguruma',
|
|
|
|
'-change',
|
|
|
|
'@loader_path/../Frameworks/Sparkle.framework/Versions/A/Sparkle',
|
|
|
|
'@rpath/Sparkle.framework/Versions/A/Sparkle',
|
|
|
|
'-change',
|
|
|
|
'@executable_path/libgit2.0.17.0.dylib',
|
|
|
|
'@rpath/libgit2.framework/Libraries/libgit2.0.17.0.dylib',
|
|
|
|
'${BUILT_PRODUCTS_DIR}/${EXECUTABLE_PATH}'
|
|
|
|
],
|
2012-08-10 23:32:19 +04:00
|
|
|
},
|
|
|
|
'includes': [
|
2012-08-22 00:06:40 +04:00
|
|
|
'cef/cef_paths2.gypi',
|
2012-10-26 03:58:24 +04:00
|
|
|
'git2/libgit2.gypi',
|
2012-08-10 23:32:19 +04:00
|
|
|
],
|
2012-08-21 20:49:38 +04:00
|
|
|
'target_defaults': {
|
2012-08-27 21:22:43 +04:00
|
|
|
'default_configuration': 'Debug',
|
|
|
|
'configurations': {
|
|
|
|
'Debug': {
|
2013-02-14 01:09:35 +04:00
|
|
|
'defines': ['DEBUG=1'],
|
2012-09-21 02:13:25 +04:00
|
|
|
'xcode_settings': { 'GCC_OPTIMIZATION_LEVEL' : '0' },
|
2012-08-27 21:22:43 +04:00
|
|
|
},
|
|
|
|
'Release': {
|
|
|
|
},
|
|
|
|
},
|
2012-08-21 20:49:38 +04:00
|
|
|
'xcode_settings': {
|
|
|
|
'CLANG_CXX_LANGUAGE_STANDARD' : 'c++0x',
|
|
|
|
'GCC_VERSION': 'com.apple.compilers.llvm.clang.1_0',
|
|
|
|
'COMBINE_HIDPI_IMAGES': 'YES', # Removes 'Validate Project Settings' warning
|
|
|
|
'GCC_SYMBOLS_PRIVATE_EXTERN': 'YES' # Removes 'Reference to global weak symbol vtable' warning
|
|
|
|
},
|
|
|
|
},
|
2012-08-10 23:32:19 +04:00
|
|
|
'targets': [
|
|
|
|
{
|
|
|
|
'target_name': 'Atom',
|
|
|
|
'type': 'executable',
|
|
|
|
'mac_bundle': 1,
|
|
|
|
'msvs_guid': 'D22C6F51-AA2D-457C-B579-6C97A96C724D',
|
|
|
|
'dependencies': [
|
2013-02-28 22:55:48 +04:00
|
|
|
'atom_framework',
|
2012-08-10 23:32:19 +04:00
|
|
|
],
|
2012-08-28 02:00:38 +04:00
|
|
|
'mac_framework_dirs': [ 'native/frameworks' ],
|
2012-08-10 23:32:19 +04:00
|
|
|
'sources': [
|
2013-02-28 22:55:48 +04:00
|
|
|
'native/main.cpp',
|
2012-08-10 23:32:19 +04:00
|
|
|
],
|
|
|
|
'mac_bundle_resources': [
|
2012-08-28 00:21:59 +04:00
|
|
|
'native/mac/atom.icns',
|
2012-12-29 03:38:58 +04:00
|
|
|
'native/mac/file.icns',
|
2013-01-24 03:09:58 +04:00
|
|
|
'native/mac/speakeasy.pem',
|
2012-08-10 23:32:19 +04:00
|
|
|
],
|
|
|
|
'xcode_settings': {
|
2012-08-28 00:21:59 +04:00
|
|
|
'INFOPLIST_FILE': 'native/mac/info.plist',
|
2013-02-28 22:55:48 +04:00
|
|
|
'LD_RUNPATH_SEARCH_PATHS': '@executable_path/../Frameworks',
|
2012-08-10 23:32:19 +04:00
|
|
|
},
|
|
|
|
'conditions': [
|
2013-02-27 04:43:15 +04:00
|
|
|
['CODE_SIGN' , {
|
|
|
|
'xcode_settings': {'CODE_SIGN_IDENTITY': "<(CODE_SIGN)"},
|
|
|
|
}],
|
2012-08-10 23:32:19 +04:00
|
|
|
['OS=="win" and win_use_allocator_shim==1', {
|
|
|
|
'dependencies': [
|
|
|
|
'<(DEPTH)/base/allocator/allocator.gyp:allocator',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
['OS=="win"', {
|
|
|
|
'configurations': {
|
|
|
|
'Debug_Base': {
|
|
|
|
'msvs_settings': {
|
|
|
|
'VCLinkerTool': {
|
|
|
|
'LinkIncremental': '<(msvs_large_module_debug_link_mode)',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
'msvs_settings': {
|
|
|
|
'VCLinkerTool': {
|
|
|
|
# Set /SUBSYSTEM:WINDOWS.
|
|
|
|
'SubSystem': '2',
|
|
|
|
'EntryPointSymbol' : 'wWinMainCRTStartup',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
|
|
|
'-lcomctl32.lib',
|
|
|
|
'-lshlwapi.lib',
|
|
|
|
'-lrpcrt4.lib',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
'sources': [
|
|
|
|
'<@(includes_win)',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
['OS == "win" or (toolkit_uses_gtk == 1 and selinux == 0)', {
|
|
|
|
'dependencies': [
|
|
|
|
'<(DEPTH)/sandbox/sandbox.gyp:sandbox',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
['toolkit_uses_gtk == 1', {
|
|
|
|
'dependencies': [
|
|
|
|
'<(DEPTH)/build/linux/system.gyp:gtk',
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
[ 'OS=="mac"', {
|
|
|
|
'product_name': 'Atom',
|
|
|
|
'dependencies': [
|
|
|
|
'AtomHelperApp',
|
|
|
|
],
|
|
|
|
'copies': [
|
|
|
|
{
|
|
|
|
'destination': '<(PRODUCT_DIR)/Atom.app/Contents/Frameworks/Chromium Embedded Framework.framework/Libraries/',
|
|
|
|
'files': [
|
2013-02-17 20:56:27 +04:00
|
|
|
'cef/Release/libcef.dylib',
|
|
|
|
'cef/Release/ffmpegsumo.so',
|
2012-08-10 23:32:19 +04:00
|
|
|
],
|
|
|
|
},
|
2012-08-28 02:00:38 +04:00
|
|
|
{
|
|
|
|
'destination': '<(PRODUCT_DIR)/Atom.app/Contents/Frameworks',
|
|
|
|
'files': [
|
2013-03-02 01:26:57 +04:00
|
|
|
'<(PRODUCT_DIR)/Atom Helper.app',
|
2013-02-28 22:55:48 +04:00
|
|
|
'<(PRODUCT_DIR)/Atom.framework',
|
2012-08-28 02:00:38 +04:00
|
|
|
'native/frameworks/CocoaOniguruma.framework',
|
2013-01-24 03:09:58 +04:00
|
|
|
'native/frameworks/Sparkle.framework',
|
2012-08-28 02:00:38 +04:00
|
|
|
],
|
|
|
|
},
|
2012-10-30 20:01:30 +04:00
|
|
|
{
|
|
|
|
'destination': '<(PRODUCT_DIR)/Atom.app/Contents/Frameworks/libgit2.framework/Libraries',
|
|
|
|
'files': [
|
|
|
|
'git2/frameworks/libgit2.0.17.0.dylib',
|
|
|
|
],
|
|
|
|
},
|
2012-08-10 23:32:19 +04:00
|
|
|
{
|
2013-03-02 01:26:57 +04:00
|
|
|
'destination': '<(PRODUCT_DIR)/Atom.app/Contents/Frameworks/Chromium Embedded Framework.framework',
|
|
|
|
'files': [
|
|
|
|
'cef/Resources',
|
2012-08-10 23:32:19 +04:00
|
|
|
],
|
|
|
|
},
|
2013-03-02 01:26:57 +04:00
|
|
|
],
|
|
|
|
'postbuilds': [
|
2012-08-10 23:32:19 +04:00
|
|
|
{
|
|
|
|
'postbuild_name': 'Fix Framework Link',
|
|
|
|
'action': [
|
2013-02-28 22:55:48 +04:00
|
|
|
'<@(fix_framework_link_command)',
|
2012-08-10 23:32:19 +04:00
|
|
|
],
|
|
|
|
},
|
|
|
|
{
|
|
|
|
# This postbuid step is responsible for creating the following
|
|
|
|
# helpers:
|
|
|
|
#
|
2012-08-21 22:02:49 +04:00
|
|
|
# Atom Helper EH.app and Atom Helper NP.app are created
|
|
|
|
# from Atom Helper.app.
|
2012-08-10 23:32:19 +04:00
|
|
|
#
|
|
|
|
# The EH helper is marked for an executable heap. The NP helper
|
|
|
|
# is marked for no PIE (ASLR).
|
|
|
|
'postbuild_name': 'Make More Helpers',
|
|
|
|
'action': [
|
2012-08-11 02:11:09 +04:00
|
|
|
'tools/mac/make_more_helpers.sh',
|
2012-08-10 23:32:19 +04:00
|
|
|
'Frameworks',
|
|
|
|
'Atom',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
],
|
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
|
|
|
'$(SDKROOT)/System/Library/Frameworks/AppKit.framework',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
'sources': [
|
2012-08-22 00:06:40 +04:00
|
|
|
'cef/include/cef_application_mac.h',
|
|
|
|
'cef/include/internal/cef_mac.h',
|
|
|
|
'cef/include/internal/cef_types_mac.h',
|
2012-08-10 23:32:19 +04:00
|
|
|
],
|
|
|
|
}],
|
|
|
|
[ 'OS=="linux" or OS=="freebsd" or OS=="openbsd"', {
|
|
|
|
'sources': [
|
|
|
|
'<@(includes_linux)',
|
|
|
|
],
|
|
|
|
'copies': [
|
|
|
|
{
|
|
|
|
'destination': '<(PRODUCT_DIR)/files',
|
|
|
|
'files': [
|
|
|
|
'<@(cefclient_bundle_resources_linux)',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
],
|
|
|
|
}],
|
|
|
|
],
|
|
|
|
},
|
2013-02-28 22:55:48 +04:00
|
|
|
{
|
|
|
|
'target_name': 'atom_framework',
|
|
|
|
'product_name': 'Atom',
|
|
|
|
'type': 'shared_library',
|
|
|
|
'mac_bundle': 1,
|
|
|
|
'dependencies': [
|
|
|
|
'libcef_dll_wrapper',
|
|
|
|
],
|
|
|
|
'defines': [
|
|
|
|
'USING_CEF_SHARED',
|
|
|
|
],
|
|
|
|
'xcode_settings': {
|
|
|
|
'INFOPLIST_FILE': 'native/mac/framework-info.plist',
|
|
|
|
'LD_DYLIB_INSTALL_NAME': '@rpath/Atom.framework/Atom',
|
|
|
|
},
|
|
|
|
'include_dirs': [ '.', 'cef', 'git2' ],
|
|
|
|
'mac_framework_dirs': [ 'native/frameworks' ],
|
|
|
|
'sources': [
|
|
|
|
'<@(includes_common)',
|
|
|
|
'<@(includes_wrapper)',
|
|
|
|
'native/atom_application.h',
|
|
|
|
'native/atom_application.mm',
|
|
|
|
'native/atom_cef_app.h',
|
|
|
|
'native/atom_cef_app.h',
|
|
|
|
'native/atom_cef_client.cpp',
|
|
|
|
'native/atom_cef_client.h',
|
|
|
|
'native/atom_cef_client_mac.mm',
|
|
|
|
'native/atom_cef_render_process_handler.h',
|
|
|
|
'native/atom_cef_render_process_handler.mm',
|
|
|
|
'native/atom_window_controller.h',
|
|
|
|
'native/atom_window_controller.mm',
|
|
|
|
'native/atom_main.h',
|
|
|
|
'native/atom_main_mac.mm',
|
|
|
|
'native/message_translation.cpp',
|
|
|
|
'native/message_translation.cpp',
|
|
|
|
'native/message_translation.h',
|
|
|
|
'native/message_translation.h',
|
|
|
|
'native/path_watcher.h',
|
|
|
|
'native/path_watcher.mm',
|
|
|
|
'native/v8_extensions/atom.h',
|
|
|
|
'native/v8_extensions/atom.mm',
|
|
|
|
'native/v8_extensions/git.h',
|
|
|
|
'native/v8_extensions/git.mm',
|
|
|
|
'native/v8_extensions/native.h',
|
|
|
|
'native/v8_extensions/native.mm',
|
|
|
|
'native/v8_extensions/onig_reg_exp.h',
|
|
|
|
'native/v8_extensions/onig_reg_exp.mm',
|
|
|
|
'native/v8_extensions/onig_scanner.h',
|
|
|
|
'native/v8_extensions/onig_scanner.mm',
|
|
|
|
'native/v8_extensions/readtags.c',
|
|
|
|
'native/v8_extensions/readtags.h',
|
|
|
|
'native/v8_extensions/tags.h',
|
|
|
|
'native/v8_extensions/tags.mm',
|
|
|
|
],
|
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
|
|
|
'$(SDKROOT)/System/Library/Frameworks/AppKit.framework',
|
|
|
|
'git2/frameworks/libgit2.0.17.0.dylib',
|
|
|
|
'native/frameworks/CocoaOniguruma.framework',
|
|
|
|
'native/frameworks/Sparkle.framework',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
'mac_bundle_resources': [
|
|
|
|
'native/mac/English.lproj/AtomWindow.xib',
|
|
|
|
'native/mac/English.lproj/MainMenu.xib',
|
|
|
|
],
|
|
|
|
'postbuilds': [
|
|
|
|
{
|
|
|
|
'postbuild_name': 'Copy and Compile Static Files',
|
|
|
|
'action': [
|
|
|
|
'script/copy-files-to-bundle'
|
|
|
|
],
|
|
|
|
},
|
|
|
|
{
|
|
|
|
'postbuild_name': 'Fix Framework Link',
|
|
|
|
'action': [
|
|
|
|
'<@(fix_framework_link_command)',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
],
|
|
|
|
},
|
2012-08-10 23:32:19 +04:00
|
|
|
{
|
|
|
|
'target_name': 'libcef_dll_wrapper',
|
|
|
|
'type': 'static_library',
|
|
|
|
'msvs_guid': 'A9D6DC71-C0DC-4549-AEA0-3B15B44E86A9',
|
2012-08-11 01:54:28 +04:00
|
|
|
'dependencies': [
|
|
|
|
],
|
2012-08-10 23:32:19 +04:00
|
|
|
'defines': [
|
|
|
|
'USING_CEF_SHARED',
|
|
|
|
],
|
2012-08-22 00:06:40 +04:00
|
|
|
'include_dirs': [ '.', 'cef' ],
|
2012-08-10 23:32:19 +04:00
|
|
|
'sources': [
|
|
|
|
'<@(includes_common)',
|
|
|
|
'<@(includes_capi)',
|
|
|
|
'<@(includes_wrapper)',
|
|
|
|
'<@(libcef_dll_wrapper_sources_common)',
|
|
|
|
],
|
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
2013-02-17 20:56:27 +04:00
|
|
|
'cef/Release/libcef.dylib',
|
2012-08-10 23:32:19 +04:00
|
|
|
],
|
2012-08-11 01:54:28 +04:00
|
|
|
}
|
2012-08-10 23:32:19 +04:00
|
|
|
},
|
|
|
|
],
|
|
|
|
'conditions': [
|
|
|
|
['os_posix==1 and OS!="mac" and OS!="android" and gcc_version==46', {
|
|
|
|
'target_defaults': {
|
|
|
|
# Disable warnings about c++0x compatibility, as some names (such
|
|
|
|
# as nullptr) conflict with upcoming c++0x types.
|
|
|
|
'cflags_cc': ['-Wno-c++0x-compat'],
|
|
|
|
},
|
|
|
|
}],
|
|
|
|
['OS=="mac"', {
|
|
|
|
'targets': [
|
|
|
|
{
|
|
|
|
'target_name': 'AtomHelperApp',
|
|
|
|
'type': 'executable',
|
|
|
|
'variables': { 'enable_wexit_time_destructors': 1, },
|
|
|
|
'product_name': 'Atom Helper',
|
|
|
|
'mac_bundle': 1,
|
|
|
|
'dependencies': [
|
2013-02-28 22:55:48 +04:00
|
|
|
'atom_framework',
|
2012-08-10 23:32:19 +04:00
|
|
|
],
|
|
|
|
'defines': [
|
|
|
|
'USING_CEF_SHARED',
|
2012-08-21 00:33:31 +04:00
|
|
|
'PROCESS_HELPER_APP',
|
2012-08-10 23:32:19 +04:00
|
|
|
],
|
2012-08-28 02:00:38 +04:00
|
|
|
'mac_framework_dirs': [ 'native/frameworks' ],
|
2012-08-10 23:32:19 +04:00
|
|
|
'sources': [
|
2013-02-28 22:55:48 +04:00
|
|
|
'native/main.cpp',
|
2012-08-10 23:32:19 +04:00
|
|
|
],
|
|
|
|
# TODO(mark): For now, don't put any resources into this app. Its
|
|
|
|
# resources directory will be a symbolic link to the browser app's
|
|
|
|
# resources directory.
|
|
|
|
'mac_bundle_resources/': [
|
|
|
|
['exclude', '.*'],
|
|
|
|
],
|
|
|
|
'xcode_settings': {
|
2012-08-28 00:21:59 +04:00
|
|
|
'INFOPLIST_FILE': 'native/mac/helper-info.plist',
|
2013-02-28 22:55:48 +04:00
|
|
|
'LD_RUNPATH_SEARCH_PATHS': '@executable_path/../../..',
|
2012-08-10 23:32:19 +04:00
|
|
|
},
|
|
|
|
'postbuilds': [
|
|
|
|
{
|
2013-02-28 22:55:48 +04:00
|
|
|
'postbuild_name': 'Fix Framework Link',
|
2012-08-28 01:02:05 +04:00
|
|
|
'action': [
|
2013-02-28 22:55:48 +04:00
|
|
|
'<@(fix_framework_link_command)',
|
2012-08-28 01:02:05 +04:00
|
|
|
],
|
|
|
|
},
|
2012-08-10 23:32:19 +04:00
|
|
|
],
|
|
|
|
}, # target cefclient_helper_app
|
|
|
|
],
|
|
|
|
}], # OS=="mac"
|
|
|
|
],
|
|
|
|
}
|