Add a gyp target for producing a voice engine merged library.
This is based on webrtc/build/merge_libs.gyp, with a dependency on voice_engine.gyp instead and suitable name changes. Executing: $ rm -rf out/ $ ./webrtc/build/gyp_webrtc -Denable_video=0 -Denable_protobuf=0 -Drelease_optimize=s webrtc/build/merge_libs_voice.gyp $ ninja -C out/Release merged_lib_voice results in a minimially sized voice engine lib at: out/Release/librtc_voice_merged.a Linux: 6.4 MB Mac: 3.7 MB R=braveyao@webrtc.org Review URL: https://webrtc-codereview.appspot.com/23659004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@7199 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
parent
a6cefcaceb
commit
7351d4d698
@ -10,9 +10,6 @@
|
||||
'includes': ['common.gypi',],
|
||||
'variables': {
|
||||
'merge_libs_dependencies': [
|
||||
'../webrtc.gyp:webrtc',
|
||||
'../sound/sound.gyp:rtc_sound',
|
||||
'../libjingle/xmllite/xmllite.gyp:rtc_xmllite',
|
||||
],
|
||||
},
|
||||
'targets': [
|
||||
@ -21,6 +18,9 @@
|
||||
'type': 'executable',
|
||||
'dependencies': [
|
||||
'<@(merge_libs_dependencies)',
|
||||
'../webrtc.gyp:webrtc',
|
||||
'../sound/sound.gyp:rtc_sound',
|
||||
'../libjingle/xmllite/xmllite.gyp:rtc_xmllite',
|
||||
],
|
||||
'sources': ['no_op.cc',],
|
||||
},
|
||||
|
48
webrtc/build/merge_libs_voice.gyp
Normal file
48
webrtc/build/merge_libs_voice.gyp
Normal file
@ -0,0 +1,48 @@
|
||||
# Copyright (c) 2014 The WebRTC project authors. All Rights Reserved.
|
||||
#
|
||||
# Use of this source code is governed by a BSD-style license
|
||||
# that can be found in the LICENSE file in the root of the source
|
||||
# tree. An additional intellectual property rights grant can be found
|
||||
# in the file PATENTS. All contributing project authors may
|
||||
# be found in the AUTHORS file in the root of the source tree.
|
||||
|
||||
{
|
||||
'includes': ['common.gypi',],
|
||||
'variables': {
|
||||
'merge_libs_dependencies': [
|
||||
],
|
||||
},
|
||||
'targets': [
|
||||
{
|
||||
'target_name': 'no_op_voice',
|
||||
'type': 'executable',
|
||||
'dependencies': [
|
||||
'<@(merge_libs_dependencies)',
|
||||
'../voice_engine/voice_engine.gyp:voice_engine'
|
||||
],
|
||||
'sources': ['no_op.cc',],
|
||||
},
|
||||
{
|
||||
'target_name': 'merged_lib_voice',
|
||||
'type': 'none',
|
||||
'dependencies': [
|
||||
'no_op_voice',
|
||||
],
|
||||
'actions': [
|
||||
{
|
||||
'variables': {
|
||||
'output_lib_name': 'rtc_voice_merged',
|
||||
'output_lib': '<(PRODUCT_DIR)/<(STATIC_LIB_PREFIX)<(output_lib_name)<(STATIC_LIB_SUFFIX)',
|
||||
},
|
||||
'action_name': 'merge_libs_voice',
|
||||
'inputs': ['<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)no_op_voice<(EXECUTABLE_SUFFIX)'],
|
||||
'outputs': ['<(output_lib)'],
|
||||
'action': ['python',
|
||||
'merge_libs.py',
|
||||
'<(PRODUCT_DIR)',
|
||||
'<(output_lib)',],
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
}
|
Loading…
Reference in New Issue
Block a user