Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 { | 4 { |
| 5 'variables': { | |
| 6 'libsctp_target_type%': 'static_library', | |
| 7 }, | |
| 8 'target_defaults': { | |
| 9 'defines': [ | |
| 10 'INET', | |
| 11 'SCTP_PROCESS_LEVEL_LOCKS', | |
| 12 'SCTP_SIMPLE_ALLOCATOR', | |
| 13 '__Userspace__', | |
| 14 # 'SCTP_DEBUG', # Uncomment for SCTP debugging. | |
| 15 ], | |
| 16 'include_dirs': [ | |
| 17 'overrides/usrsctplib', | |
| 18 'overrides/usrsctplib/netinet', | |
| 19 'usrsctplib/', | |
| 20 'usrsctplib/netinet', | |
| 21 'usrsctplib/netinet6', | |
| 22 ], | |
| 23 'direct_dependent_settings': { | |
| 24 'include_dirs': [ | |
| 25 'overrides/usrsctplib', | |
| 26 'overrides/usrsctplib/netinet', | |
| 27 'usrsctplib/', | |
| 28 'usrsctplib/netinet', | |
| 29 'usrsctplib/netinet6', | |
| 30 ], | |
| 31 }, | |
| 32 'conditions': [ | |
| 33 ['use_openssl==1', { | |
| 34 'defines': [ | |
| 35 'SCTP_USE_OPENSSL_SHA1', | |
| 36 ], | |
| 37 'dependencies': [ | |
| 38 '../../third_party/openssl/openssl.gyp:openssl', | |
| 39 ], | |
| 40 }, | |
| 41 { # else use_openssl==0, use NSS. | |
| 42 'defines' : [ | |
| 43 'SCTP_USE_NSS_SHA1', | |
| 44 ], | |
| 45 'conditions': [ | |
| 46 ['os_posix == 1 and OS != "mac" and OS != "ios" and OS != "android"', { | |
| 47 'dependencies': [ | |
| 48 '<(DEPTH)/build/linux/system.gyp:ssl', | |
| 49 ], | |
| 50 }], | |
| 51 ['OS == "mac" or OS == "ios" or OS == "win"', { | |
| 52 'dependencies': [ | |
| 53 '<(DEPTH)/third_party/nss/nss.gyp:nspr', | |
| 54 '<(DEPTH)/third_party/nss/nss.gyp:nss', | |
| 55 ], | |
| 56 'conditions': [ | |
| 57 ['OS == "mac"', { | |
| 58 'link_settings': { | |
| 59 'libraries': [ | |
| 60 '$(SDKROOT)/System/Library/Frameworks/Foundation.framework', | |
| 61 '$(SDKROOT)/System/Library/Frameworks/Security.framework', | |
| 62 '$(SDKROOT)/System/Library/Frameworks/SystemConfiguration.fr amework', | |
| 63 '$(SDKROOT)/usr/lib/libresolv.dylib', | |
|
Ryan Sleevi
2013/06/10 18:53:47
Why is this necessary? You should only need a depd
Mallinath (Gone from Chromium)
2013/06/10 23:30:51
Done.
| |
| 64 ] | |
| 65 }, | |
| 66 }], | |
| 67 ], | |
| 68 }], | |
| 69 ], | |
| 70 }], | |
| 71 ], | |
| 72 }, | |
| 5 'targets': [ | 73 'targets': [ |
| 6 { | 74 { |
| 7 'target_name': 'usrsctplib', | 75 'target_name': 'usrsctplib', |
| 8 'type': 'static_library', | 76 'type': 'static_library', |
| 9 'direct_dependent_settings': { | |
| 10 'include_dirs': [ | |
| 11 '.', | |
| 12 ], | |
| 13 'defines': [ | |
| 14 'INET', | |
| 15 'SCTP_PROCESS_LEVEL_LOCKS', | |
| 16 'SCTP_SIMPLE_ALLOCATOR', | |
| 17 'STDC_HEADERS', | |
| 18 'USE_SCTP_SHA1', | |
| 19 '__Userspace__', | |
| 20 # 'SCTP_DEBUG', # Uncomment for SCTP debugging. | |
| 21 ], | |
| 22 }, | |
| 23 'include_dirs': [ | |
| 24 'usrsctplib/', | |
| 25 'usrsctplib/netinet', | |
| 26 'usrsctplib/netinet6', | |
| 27 ], | |
| 28 'sources': [ | 77 'sources': [ |
| 78 'overrides/usrsctplib/netinet/sctp_auth.h', | |
| 79 'overrides/usrsctplib/netinet/sctp_os.h', | |
| 80 'overrides/usrsctplib/netinet/sctp_os_userspace.h', | |
| 81 'overrides/usrsctplib/netinet/sctp_sha1.c', | |
| 82 'overrides/usrsctplib/netinet/sctp_sha1.h', | |
| 83 | |
| 84 'usrsctplib/usrsctp.h', | |
| 85 'usrsctplib/user_atomic.h', | |
| 29 'usrsctplib/user_environment.c', | 86 'usrsctplib/user_environment.c', |
| 87 'usrsctplib/user_environment.h', | |
| 88 'usrsctplib/user_inpcb.h', | |
| 89 'usrsctplib/user_ip6_var.h', | |
| 90 'usrsctplib/user_ip_icmp.h', | |
| 30 'usrsctplib/user_mbuf.c', | 91 'usrsctplib/user_mbuf.c', |
| 92 'usrsctplib/user_mbuf.h', | |
| 93 'usrsctplib/user_queue.h', | |
| 31 'usrsctplib/user_recv_thread.c', | 94 'usrsctplib/user_recv_thread.c', |
| 95 'usrsctplib/user_recv_thread.h', | |
| 96 'usrsctplib/user_route.h', | |
| 32 'usrsctplib/user_sctp_timer_iterate.c', | 97 'usrsctplib/user_sctp_timer_iterate.c', |
| 33 'usrsctplib/user_socket.c', | 98 'usrsctplib/user_socket.c', |
| 99 'usrsctplib/user_socketvar.h', | |
| 100 'usrsctplib/user_uma.h', | |
| 34 'usrsctplib/netinet/sctp_asconf.c', | 101 'usrsctplib/netinet/sctp_asconf.c', |
| 102 'usrsctplib/netinet/sctp_asconf.h', | |
| 35 'usrsctplib/netinet/sctp_auth.c', | 103 'usrsctplib/netinet/sctp_auth.c', |
| 36 'usrsctplib/netinet/sctp_bsd_addr.c', | 104 'usrsctplib/netinet/sctp_bsd_addr.c', |
| 105 'usrsctplib/netinet/sctp_bsd_addr.h', | |
| 37 'usrsctplib/netinet/sctp_callout.c', | 106 'usrsctplib/netinet/sctp_callout.c', |
| 107 'usrsctplib/netinet/sctp_callout.h', | |
| 38 'usrsctplib/netinet/sctp_cc_functions.c', | 108 'usrsctplib/netinet/sctp_cc_functions.c', |
| 109 'usrsctplib/netinet/sctp_constants.h', | |
| 39 'usrsctplib/netinet/sctp_crc32.c', | 110 'usrsctplib/netinet/sctp_crc32.c', |
| 111 'usrsctplib/netinet/sctp_crc32.h', | |
| 112 'usrsctplib/netinet/sctp_hashdriver.h', | |
| 40 'usrsctplib/netinet/sctp_hashdriver.c', | 113 'usrsctplib/netinet/sctp_hashdriver.c', |
| 114 'usrsctplib/netinet/sctp_header.h', | |
| 41 'usrsctplib/netinet/sctp_indata.c', | 115 'usrsctplib/netinet/sctp_indata.c', |
| 116 'usrsctplib/netinet/sctp_indata.h', | |
| 42 'usrsctplib/netinet/sctp_input.c', | 117 'usrsctplib/netinet/sctp_input.c', |
| 118 'usrsctplib/netinet/sctp_input.h', | |
| 119 'usrsctplib/netinet/sctp_lock_userspace.h', | |
| 43 'usrsctplib/netinet/sctp_output.c', | 120 'usrsctplib/netinet/sctp_output.c', |
| 121 'usrsctplib/netinet/sctp_output.h', | |
| 44 'usrsctplib/netinet/sctp_pcb.c', | 122 'usrsctplib/netinet/sctp_pcb.c', |
| 123 'usrsctplib/netinet/sctp_pcb.h', | |
| 45 'usrsctplib/netinet/sctp_peeloff.c', | 124 'usrsctplib/netinet/sctp_peeloff.c', |
| 46 'usrsctplib/netinet/sctp_sha1.c', | 125 'usrsctplib/netinet/sctp_peeloff.h', |
| 47 'usrsctplib/netinet/sctp_ss_functions.c', | 126 'usrsctplib/netinet/sctp_ss_functions.c', |
| 127 'usrsctplib/netinet/sctp_structs.h', | |
| 48 'usrsctplib/netinet/sctp_sysctl.c', | 128 'usrsctplib/netinet/sctp_sysctl.c', |
| 129 'usrsctplib/netinet/sctp_sysctl.h', | |
| 130 'usrsctplib/netinet/sctp_timer.c', | |
| 131 'usrsctplib/netinet/sctp_timer.h', | |
| 132 'usrsctplib/netinet/sctp_uio.h', | |
| 49 'usrsctplib/netinet/sctp_userspace.c', | 133 'usrsctplib/netinet/sctp_userspace.c', |
| 50 'usrsctplib/netinet/sctp_timer.c', | |
| 51 'usrsctplib/netinet/sctp_usrreq.c', | 134 'usrsctplib/netinet/sctp_usrreq.c', |
| 52 'usrsctplib/netinet/sctputil.c', | 135 'usrsctplib/netinet/sctputil.c', |
| 136 'usrsctplib/netinet/sctputil.h', | |
| 137 'usrsctplib/netinet/sctp_var.h', | |
| 53 'usrsctplib/netinet6/sctp6_usrreq.c', | 138 'usrsctplib/netinet6/sctp6_usrreq.c', |
| 139 'usrsctplib/netinet6/sctp6_var.h', | |
| 54 ], # sources | 140 ], # sources |
| 55 'conditions': [ | 141 'conditions': [ |
| 142 ['use_openssl==1', { | |
| 143 'sources!': [ | |
| 144 'overrides/usrsctplib/netinet/sctp_sha1.c', | |
| 145 'overrides/usrsctplib/netinet/sctp_sha1.h', | |
| 146 ], | |
| 147 }], | |
| 56 ['OS=="linux"', { | 148 ['OS=="linux"', { |
| 57 'defines': [ | 149 'defines': [ |
| 58 'HAVE_INET_ADDR', | 150 'HAVE_INET_ADDR', |
| 59 'HAVE_SOCKET', | 151 'HAVE_SOCKET', |
| 60 '__Userspace_os_Linux', | 152 '__Userspace_os_Linux', |
| 61 ], | 153 ], |
| 62 'ccflags!': [ '-Werror', '-Wall' ], | 154 'cflags!': [ '-Werror', '-Wall' ], |
| 63 'ccflags': [ '-w' ], | 155 'cflags': [ '-w' ], |
| 64 }], | 156 }], |
| 65 ['OS=="mac"', { | 157 ['OS=="mac"', { |
| 66 'defines': [ | 158 'defines': [ |
| 67 'HAVE_INET_ADDR', | 159 'HAVE_INET_ADDR', |
| 68 'HAVE_SA_LEN', | 160 'HAVE_SA_LEN', |
| 69 'HAVE_SCONN_LEN', | 161 'HAVE_SCONN_LEN', |
| 70 'HAVE_SIN6_LEN', | 162 'HAVE_SIN6_LEN', |
| 71 'HAVE_SIN_LEN', | 163 'HAVE_SIN_LEN', |
| 72 'HAVE_SOCKET', | 164 'HAVE_SOCKET', |
| 73 'INET6', | 165 'INET6', |
| 74 '__APPLE_USE_RFC_2292', | 166 '__APPLE_USE_RFC_2292', |
| 75 '__Userspace_os_Darwin', | 167 '__Userspace_os_Darwin', |
| 76 ], | 168 ], |
| 77 # TODO(ldixon): explore why gyp cflags here does not get picked up. | 169 # TODO(ldixon): explore why gyp cflags here does not get picked up. |
| 78 'xcode_settings': { | 170 'xcode_settings': { |
| 79 'OTHER_CFLAGS!': [ '-Werror', '-Wall' ], | 171 'OTHER_CFLAGS!': [ '-Werror', '-Wall' ], |
| 80 'OTHER_CFLAGS': [ '-U__APPLE__', '-w' ], | 172 'OTHER_CFLAGS': [ '-w' ], |
| 81 }, | 173 }, |
| 82 }], | 174 }], |
| 83 ['OS=="win"', { | 175 ['OS=="win"', { |
| 84 'defines': [ | 176 'defines': [ |
| 85 'INET6', | 177 'INET6', |
| 86 '__Userspace_os_Windows', | 178 '__Userspace_os_Windows', |
| 87 ], | 179 ], |
| 88 'ccflags!': [ '/W3', '/WX' ], | 180 'cflags!': [ '/W3', '/WX' ], |
| 89 'ccflags': [ '/w' ], | 181 'cflags': [ '/w' ], |
| 182 # TODO(ldixon) : Remove this disable. | |
| 183 'msvs_disabled_warnings': [ 4700, 4013, 4018, 4133 ], | |
| 90 }, { # OS != "win", | 184 }, { # OS != "win", |
| 91 'defines': [ | 185 'defines': [ |
| 92 'NON_WINDOWS_DEFINE', | 186 'NON_WINDOWS_DEFINE', |
| 93 ], | 187 ], |
| 94 }], | 188 }], |
| 95 ], # conditions | 189 ], # conditions |
| 96 }, # target usrsctp | 190 }, # target usrsctp |
| 97 ], # targets | 191 ], # targets |
| 98 } | 192 } |
| OLD | NEW |