OLD | NEW |
1 #!/bin/bash -e | 1 #!/bin/bash -e |
2 # | 2 # |
3 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 3 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
6 | 6 |
7 # This script is used to generate .gypi, .gni files and files in the | 7 # This script is used to generate .gypi, .gni files and files in the |
8 # config/platform directories needed to build libvpx. | 8 # config/platform directories needed to build libvpx. |
9 # Every time libvpx source code is updated just run this script. | 9 # Every time libvpx source code is updated just run this script. |
10 # | 10 # |
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
114 # regenerate the array locally. | 114 # regenerate the array locally. |
115 # $2 - GN variable name. | 115 # $2 - GN variable name. |
116 # $3 - Output file. | 116 # $3 - Output file. |
117 function write_gni { | 117 function write_gni { |
118 # Convert the first argument back in to an array. | 118 # Convert the first argument back in to an array. |
119 declare -a file_list=("${!1}") | 119 declare -a file_list=("${!1}") |
120 | 120 |
121 echo "$2 = [" >> "$3" | 121 echo "$2 = [" >> "$3" |
122 for f in $file_list | 122 for f in $file_list |
123 do | 123 do |
124 echo " \"//third_party/libvpx_new/source/libvpx/$f\"," >> "$3" | 124 echo " \"//third_party/libvpx/source/libvpx/$f\"," >> "$3" |
125 done | 125 done |
126 echo "]" >> "$3" | 126 echo "]" >> "$3" |
127 } | 127 } |
128 | 128 |
129 # Target template function | 129 # Target template function |
130 # $1 - Array name for file list. | 130 # $1 - Array name for file list. |
131 # $2 - Output file | 131 # $2 - Output file |
132 # $3 - Target name | 132 # $3 - Target name |
133 # $4 - Compiler flag | 133 # $4 - Compiler flag |
134 function write_target_definition { | 134 function write_target_definition { |
(...skipping 459 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
594 gn format --in-place $BASE_DIR/libvpx_srcs.gni | 594 gn format --in-place $BASE_DIR/libvpx_srcs.gni |
595 | 595 |
596 cd $BASE_DIR/$LIBVPX_SRC_DIR | 596 cd $BASE_DIR/$LIBVPX_SRC_DIR |
597 echo | 597 echo |
598 echo "Update README.chromium:" | 598 echo "Update README.chromium:" |
599 git log -1 --format="%cd%nCommit: %H" --date=format:"Date: %A %B %d %Y" | 599 git log -1 --format="%cd%nCommit: %H" --date=format:"Date: %A %B %d %Y" |
600 | 600 |
601 cd $BASE_DIR | 601 cd $BASE_DIR |
602 | 602 |
603 # TODO(fgalligan): Can we turn on "--enable-realtime-only" for mipsel? | 603 # TODO(fgalligan): Can we turn on "--enable-realtime-only" for mipsel? |
OLD | NEW |