Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(114)

Side by Side Diff: generate_gypi.sh

Issue 1339033002: generate_gypi.sh: --disable-avx and --only-config flags (Closed) Base URL: https://chromium.googlesource.com/chromium/deps/libvpx@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #
11 # For example: 11 # Usage:
12 # $ ./generate_gypi.sh 12 # $ ./generate_gypi.sh [--disable-avx] [--only-configs]
13 # 13 #
14 # And this will update all the .gypi, .gni and config files needed. 14 # The following optional flags are supported:
15 # --disable-avx : AVX+AVX2 support is disabled.
16 # --only-configs: Excludes generation of GN and GYP files (i.e. only
17 # configuration headers are generated).
15 # 18 #
16 # !!! It's highly recommended to install yasm before running this script. 19 # !!! It's highly recommended to install yasm before running this script.
17 20
18 export LC_ALL=C 21 export LC_ALL=C
19 BASE_DIR=$(pwd) 22 BASE_DIR=$(pwd)
20 LIBVPX_SRC_DIR="source/libvpx" 23 LIBVPX_SRC_DIR="source/libvpx"
21 LIBVPX_CONFIG_DIR="source/config" 24 LIBVPX_CONFIG_DIR="source/config"
22 25
Johann 2015/09/14 17:24:04 maybe unset DISABLE_AVX?
kjellander_chromium 2015/09/14 18:38:21 Done.
26 for i in "$@"
27 do
28 case $i in
29 --disable-avx)
30 DISABLE_AVX=true
Johann 2015/09/14 17:24:04 DISABLE_AVX="--disable-avx --disable-avx2"
kjellander_chromium 2015/09/14 18:38:21 Done.
31 shift
32 ;;
33 --only-configs)
34 ONLY_CONFIGS=true
35 shift
36 ;;
37 *)
38 # Unknown option.
Johann 2015/09/14 17:24:04 fail/error on unknown option
kjellander_chromium 2015/09/14 18:38:21 Good idea, done.
39 ;;
40 esac
41 done
42
23 # Print license header. 43 # Print license header.
24 # $1 - Output base name 44 # $1 - Output base name
25 function write_license { 45 function write_license {
26 echo "# This file is generated. Do not edit." >> $1 46 echo "# This file is generated. Do not edit." >> $1
27 echo "# Copyright (c) 2014 The Chromium Authors. All rights reserved." >> $1 47 echo "# Copyright (c) 2014 The Chromium Authors. All rights reserved." >> $1
28 echo "# Use of this source code is governed by a BSD-style license that can be " >> $1 48 echo "# Use of this source code is governed by a BSD-style license that can be " >> $1
29 echo "# found in the LICENSE file." >> $1 49 echo "# found in the LICENSE file." >> $1
30 echo "" >> $1 50 echo "" >> $1
31 } 51 }
32 52
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 echo " ['clang==0 and use_lto==1', {" >> "$2" 131 echo " ['clang==0 and use_lto==1', {" >> "$2"
112 echo " 'cflags!': [" >> "$2" 132 echo " 'cflags!': [" >> "$2"
113 echo " '-flto'," >> "$2" 133 echo " '-flto'," >> "$2"
114 echo " '-ffat-lto-objects'," >> "$2" 134 echo " '-ffat-lto-objects'," >> "$2"
115 echo " ]," >> "$2" 135 echo " ]," >> "$2"
116 echo " }]," >> "$2" 136 echo " }]," >> "$2"
117 echo " ]," >> "$2" 137 echo " ]," >> "$2"
118 fi 138 fi
119 echo " 'cflags': [ '-m$4', ]," >> "$2" 139 echo " 'cflags': [ '-m$4', ]," >> "$2"
120 echo " 'xcode_settings': { 'OTHER_CFLAGS': [ '-m$4' ] }," >> "$2" 140 echo " 'xcode_settings': { 'OTHER_CFLAGS': [ '-m$4' ] }," >> "$2"
121 if [[ $4 == avx2 ]]; then 141 if [[ ! $DISABLE_AVX && $4 == avx2 ]]; then
Johann 2015/09/14 17:24:03 -nz or -ne or whatever "not set"
kjellander_chromium 2015/09/14 18:38:21 Done.
122 echo " 'msvs_settings': {" >> "$2" 142 echo " 'msvs_settings': {" >> "$2"
123 echo " 'VCCLCompilerTool': {" >> "$2" 143 echo " 'VCCLCompilerTool': {" >> "$2"
124 echo " 'EnableEnhancedInstructionSet': '5', # /arch:AVX2" >> "$2" 144 echo " 'EnableEnhancedInstructionSet': '5', # /arch:AVX2" >> "$2"
125 echo " }," >> "$2" 145 echo " }," >> "$2"
126 echo " }," >> "$2" 146 echo " }," >> "$2"
127 elif [[ $4 == ssse3 || $4 == sse4.1 ]]; then 147 elif [[ $4 == ssse3 || $4 == sse4.1 ]]; then
128 echo " 'conditions': [" >> "$2" 148 echo " 'conditions': [" >> "$2"
129 echo " ['OS==\"win\" and clang==1', {" >> "$2" 149 echo " ['OS==\"win\" and clang==1', {" >> "$2"
130 echo " # cl.exe's /arch flag doesn't have a setting for SSSE3/4, and cl.exe" >> "$2" 150 echo " # cl.exe's /arch flag doesn't have a setting for SSSE3/4, and cl.exe" >> "$2"
131 echo " # doesn't need it for intrinsics. clang-cl does need it, thoug h." >> "$2" 151 echo " # doesn't need it for intrinsics. clang-cl does need it, thoug h." >> "$2"
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
176 #write_target_definition sse3_sources[@] "$2" libvpx_intrinsics_sse3 sse3 196 #write_target_definition sse3_sources[@] "$2" libvpx_intrinsics_sse3 sse3
177 echo "ERROR: Uncomment sse3 sections in libvpx.gyp" 197 echo "ERROR: Uncomment sse3 sections in libvpx.gyp"
178 exit 1 198 exit 1
179 fi 199 fi
180 if [ 0 -ne ${#ssse3_sources} ]; then 200 if [ 0 -ne ${#ssse3_sources} ]; then
181 write_target_definition ssse3_sources[@] "$2" libvpx_intrinsics_ssse3 ssse3 201 write_target_definition ssse3_sources[@] "$2" libvpx_intrinsics_ssse3 ssse3
182 fi 202 fi
183 if [ 0 -ne ${#sse4_1_sources} ]; then 203 if [ 0 -ne ${#sse4_1_sources} ]; then
184 write_target_definition sse4_1_sources[@] "$2" libvpx_intrinsics_sse4_1 sse4 .1 204 write_target_definition sse4_1_sources[@] "$2" libvpx_intrinsics_sse4_1 sse4 .1
185 fi 205 fi
186 if [ 0 -ne ${#avx_sources} ]; then 206 if [[ ! $DISABLE_AVX && 0 -ne ${#avx_sources} ]]; then
187 #write_target_definition avx_sources[@] "$2" libvpx_intrinsics_avx avx 207 #write_target_definition avx_sources[@] "$2" libvpx_intrinsics_avx avx
188 echo "ERROR: Uncomment avx sections in libvpx.gyp" 208 echo "ERROR: Uncomment avx sections in libvpx.gyp"
189 exit 1 209 exit 1
190 fi 210 fi
191 if [ 0 -ne ${#avx2_sources} ]; then 211 if [[ ! $DISABLE_AVX && 0 -ne ${#avx2_sources} ]]; then
192 write_target_definition avx2_sources[@] "$2" libvpx_intrinsics_avx2 avx2 212 write_target_definition avx2_sources[@] "$2" libvpx_intrinsics_avx2 avx2
193 fi 213 fi
194 214
195 # arm neon 215 # arm neon
196 if [ 0 -ne ${#neon_sources} ]; then 216 if [ 0 -ne ${#neon_sources} ]; then
197 write_target_definition neon_sources[@] "$2" libvpx_intrinsics_neon fpu=neon 217 write_target_definition neon_sources[@] "$2" libvpx_intrinsics_neon fpu=neon
198 fi 218 fi
199 219
200 echo " ]," >> "$2" 220 echo " ]," >> "$2"
201 221
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
260 local avx_sources=$(echo "$intrinsic_list" | grep '_avx\.c$') 280 local avx_sources=$(echo "$intrinsic_list" | grep '_avx\.c$')
261 local avx2_sources=$(echo "$intrinsic_list" | grep '_avx2\.c$') 281 local avx2_sources=$(echo "$intrinsic_list" | grep '_avx2\.c$')
262 282
263 write_gni c_sources $2 "$BASE_DIR/libvpx_srcs.gni" 283 write_gni c_sources $2 "$BASE_DIR/libvpx_srcs.gni"
264 write_gni assembly_sources $2_assembly "$BASE_DIR/libvpx_srcs.gni" 284 write_gni assembly_sources $2_assembly "$BASE_DIR/libvpx_srcs.gni"
265 write_gni mmx_sources $2_mmx "$BASE_DIR/libvpx_srcs.gni" 285 write_gni mmx_sources $2_mmx "$BASE_DIR/libvpx_srcs.gni"
266 write_gni sse2_sources $2_sse2 "$BASE_DIR/libvpx_srcs.gni" 286 write_gni sse2_sources $2_sse2 "$BASE_DIR/libvpx_srcs.gni"
267 write_gni sse3_sources $2_sse3 "$BASE_DIR/libvpx_srcs.gni" 287 write_gni sse3_sources $2_sse3 "$BASE_DIR/libvpx_srcs.gni"
268 write_gni ssse3_sources $2_ssse3 "$BASE_DIR/libvpx_srcs.gni" 288 write_gni ssse3_sources $2_ssse3 "$BASE_DIR/libvpx_srcs.gni"
269 write_gni sse4_1_sources $2_sse4_1 "$BASE_DIR/libvpx_srcs.gni" 289 write_gni sse4_1_sources $2_sse4_1 "$BASE_DIR/libvpx_srcs.gni"
270 write_gni avx_sources $2_avx "$BASE_DIR/libvpx_srcs.gni" 290 if [[ ! $DISABLE_AVX ]]; then
271 write_gni avx2_sources $2_avx2 "$BASE_DIR/libvpx_srcs.gni" 291 write_gni avx_sources $2_avx "$BASE_DIR/libvpx_srcs.gni"
292 write_gni avx2_sources $2_avx2 "$BASE_DIR/libvpx_srcs.gni"
293 fi
272 else 294 else
273 local c_sources=$(echo "$source_list" | egrep '.(c|h)$') 295 local c_sources=$(echo "$source_list" | egrep '.(c|h)$')
274 local assembly_sources=$(echo -e "$source_list\n$intrinsic_list" | \ 296 local assembly_sources=$(echo -e "$source_list\n$intrinsic_list" | \
275 egrep '.asm$') 297 egrep '.asm$')
276 local neon_sources=$(echo "$intrinsic_list" | grep '_neon\.c$') 298 local neon_sources=$(echo "$intrinsic_list" | grep '_neon\.c$')
277 write_gni c_sources $2 "$BASE_DIR/libvpx_srcs.gni" 299 write_gni c_sources $2 "$BASE_DIR/libvpx_srcs.gni"
278 write_gni assembly_sources $2_assembly "$BASE_DIR/libvpx_srcs.gni" 300 write_gni assembly_sources $2_assembly "$BASE_DIR/libvpx_srcs.gni"
279 if [ 0 -ne ${#neon_sources} ]; then 301 if [ 0 -ne ${#neon_sources} ]; then
280 write_gni neon_sources $2_neon "$BASE_DIR/libvpx_srcs.gni" 302 write_gni neon_sources $2_neon "$BASE_DIR/libvpx_srcs.gni"
281 fi 303 fi
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
334 print_config_basic $1 > $BASE_DIR/$TEMP_DIR/libvpx.config 356 print_config_basic $1 > $BASE_DIR/$TEMP_DIR/libvpx.config
335 else 357 else
336 $BASE_DIR/lint_config.sh -p \ 358 $BASE_DIR/lint_config.sh -p \
337 -h $BASE_DIR/$LIBVPX_CONFIG_DIR/$1/vpx_config.h \ 359 -h $BASE_DIR/$LIBVPX_CONFIG_DIR/$1/vpx_config.h \
338 -a $BASE_DIR/$LIBVPX_CONFIG_DIR/$1/vpx_config.asm \ 360 -a $BASE_DIR/$LIBVPX_CONFIG_DIR/$1/vpx_config.asm \
339 -o $BASE_DIR/$TEMP_DIR/libvpx.config 361 -o $BASE_DIR/$TEMP_DIR/libvpx.config
340 fi 362 fi
341 363
342 $BASE_DIR/$LIBVPX_SRC_DIR/build/make/rtcd.pl \ 364 $BASE_DIR/$LIBVPX_SRC_DIR/build/make/rtcd.pl \
343 --arch=$2 \ 365 --arch=$2 \
344 --sym=vp8_rtcd \ 366 --sym=vp8_rtcd \
Johann 2015/09/14 17:24:04 add a line like --sym=vp8_rtcd $DISABLE_AVX \
kjellander_chromium 2015/09/14 18:38:21 Done.
345 --config=$BASE_DIR/$TEMP_DIR/libvpx.config \ 367 --config=$BASE_DIR/$TEMP_DIR/libvpx.config \
346 $BASE_DIR/$LIBVPX_SRC_DIR/vp8/common/rtcd_defs.pl \ 368 $BASE_DIR/$LIBVPX_SRC_DIR/vp8/common/rtcd_defs.pl \
347 > $BASE_DIR/$LIBVPX_CONFIG_DIR/$1/vp8_rtcd.h 369 > $BASE_DIR/$LIBVPX_CONFIG_DIR/$1/vp8_rtcd.h
348 370
349 $BASE_DIR/$LIBVPX_SRC_DIR/build/make/rtcd.pl \ 371 $BASE_DIR/$LIBVPX_SRC_DIR/build/make/rtcd.pl \
350 --arch=$2 \ 372 --arch=$2 \
351 --sym=vp9_rtcd \ 373 --sym=vp9_rtcd \
Johann 2015/09/14 17:24:04 need to do it for all the rtcd targets
kjellander_chromium 2015/09/14 18:38:20 Done.
352 --config=$BASE_DIR/$TEMP_DIR/libvpx.config \ 374 --config=$BASE_DIR/$TEMP_DIR/libvpx.config \
353 $BASE_DIR/$LIBVPX_SRC_DIR/vp9/common/vp9_rtcd_defs.pl \ 375 $BASE_DIR/$LIBVPX_SRC_DIR/vp9/common/vp9_rtcd_defs.pl \
354 > $BASE_DIR/$LIBVPX_CONFIG_DIR/$1/vp9_rtcd.h 376 > $BASE_DIR/$LIBVPX_CONFIG_DIR/$1/vp9_rtcd.h
355 377
356 $BASE_DIR/$LIBVPX_SRC_DIR/build/make/rtcd.pl \ 378 $BASE_DIR/$LIBVPX_SRC_DIR/build/make/rtcd.pl \
357 --arch=$2 \ 379 --arch=$2 \
358 --sym=vpx_scale_rtcd \ 380 --sym=vpx_scale_rtcd \
359 --config=$BASE_DIR/$TEMP_DIR/libvpx.config \ 381 --config=$BASE_DIR/$TEMP_DIR/libvpx.config \
360 $BASE_DIR/$LIBVPX_SRC_DIR/vpx_scale/vpx_scale_rtcd.pl \ 382 $BASE_DIR/$LIBVPX_SRC_DIR/vpx_scale/vpx_scale_rtcd.pl \
361 > $BASE_DIR/$LIBVPX_CONFIG_DIR/$1/vpx_scale_rtcd.h 383 > $BASE_DIR/$LIBVPX_CONFIG_DIR/$1/vpx_scale_rtcd.h
362 384
363 $BASE_DIR/$LIBVPX_SRC_DIR/build/make/rtcd.pl \ 385 $BASE_DIR/$LIBVPX_SRC_DIR/build/make/rtcd.pl \
364 --arch=$2 \ 386 --arch=$2 \
365 --sym=vpx_dsp_rtcd \ 387 --sym=vpx_dsp_rtcd \
366 --config=$BASE_DIR/$TEMP_DIR/libvpx.config \ 388 --config=$BASE_DIR/$TEMP_DIR/libvpx.config \
367 $BASE_DIR/$LIBVPX_SRC_DIR/vpx_dsp/vpx_dsp_rtcd_defs.pl \ 389 $BASE_DIR/$LIBVPX_SRC_DIR/vpx_dsp/vpx_dsp_rtcd_defs.pl \
368 > $BASE_DIR/$LIBVPX_CONFIG_DIR/$1/vpx_dsp_rtcd.h 390 > $BASE_DIR/$LIBVPX_CONFIG_DIR/$1/vpx_dsp_rtcd.h
369 391
370 rm -rf $BASE_DIR/$TEMP_DIR/libvpx.config 392 rm -rf $BASE_DIR/$TEMP_DIR/libvpx.config
371 } 393 }
372 394
373 # Generate Config files. "--enable-external-build" must be set to skip 395 # Generate Config files. "--enable-external-build" must be set to skip
374 # detection of capabilities on specific targets. 396 # detection of capabilities on specific targets.
375 # $1 - Header file directory. 397 # $1 - Header file directory.
376 # $2 - Config command line. 398 # $2 - Config command line.
377 function gen_config_files { 399 function gen_config_files {
378 ./configure $2 > /dev/null 400 ./configure $2 > /dev/null
379 401
380 # Disable HAVE_UNISTD_H as it causes vp8 to try to detect how many cpus 402 # Disable HAVE_UNISTD_H as it causes vp8 to try to detect how many cpus
381 # available, which doesn't work from iniside a sandbox on linux. 403 # available, which doesn't work from iniside a sandbox on linux.
382 ( echo '/HAVE_UNISTD_H/s/[01]/0/' ; echo 'w' ; echo 'q' ) | ed -s vpx_config.h 404 ( echo '/HAVE_UNISTD_H/s/[01]/0/' ; echo 'w' ; echo 'q' ) | ed -s vpx_config.h
383 405
384 # Generate vpx_config.asm. Do not create one for mips. 406 # Generate vpx_config.asm. Do not create one for mips.
385 if [[ "$1" != *mipsel && "$1" != *mips64el ]]; then 407 if [[ "$1" != *mipsel && "$1" != *mips64el ]]; then
386 if [[ "$1" == *x64* ]] || [[ "$1" == *ia32* ]]; then 408 if [[ "$1" == *x64* ]] || [[ "$1" == *ia32* ]]; then
387 egrep "#define [A-Z0-9_]+ [01]" vpx_config.h | awk '{print "%define " $2 " " $3}' > vpx_config.asm 409 egrep "#define [A-Z0-9_]+ [01]" vpx_config.h | awk '{print "%define " $2 " " $3}' > vpx_config.asm
388 else 410 else
389 egrep "#define [A-Z0-9_]+ [01]" vpx_config.h | awk '{print $2 " EQU " $3}' | perl $BASE_DIR/$LIBVPX_SRC_DIR/build/make/ads2gas.pl > vpx_config.asm 411 egrep "#define [A-Z0-9_]+ [01]" vpx_config.h | awk '{print $2 " EQU " $3}' | perl $BASE_DIR/$LIBVPX_SRC_DIR/build/make/ads2gas.pl > vpx_config.asm
390 fi 412 fi
391 fi 413 fi
392 414
393 cp vpx_config.* $BASE_DIR/$LIBVPX_CONFIG_DIR/$1 415 cp vpx_config.* $BASE_DIR/$LIBVPX_CONFIG_DIR/$1
394 make_clean 416 make_clean
395 rm -rf vpx_config.* 417 rm -rf vpx_config.*
396 } 418 }
397 419
398 echo "Create temporary directory." 420 echo "Create temporary directory."
399 TEMP_DIR="$LIBVPX_SRC_DIR.temp" 421 TEMP_DIR="$LIBVPX_SRC_DIR.temp"
400 rm -rf $TEMP_DIR 422 rm -rf $TEMP_DIR
401 cp -R $LIBVPX_SRC_DIR $TEMP_DIR 423 cp -R $LIBVPX_SRC_DIR $TEMP_DIR
402 cd $TEMP_DIR 424 cd $TEMP_DIR
403 425
404 echo "Generate config files." 426 echo "Generate config files."
405 all_platforms="--enable-external-build --enable-postproc --disable-install-srcs --enable-multi-res-encoding --enable-temporal-denoising --disable-unit-tests --d isable-install-docs --disable-examples --enable-vp9-temporal-denoising --enable- vp9-postproc --size-limit=16384x16384" 427 all_platforms="--enable-external-build --enable-postproc --disable-install-srcs --enable-multi-res-encoding --enable-temporal-denoising --disable-unit-tests --d isable-install-docs --disable-examples --enable-vp9-temporal-denoising --enable- vp9-postproc --size-limit=16384x16384"
Johann 2015/09/14 17:24:04 add DISABLE_AVX to this line
kjellander_chromium 2015/09/14 18:38:20 Done.
428 if [[ $DISABLE_AVX ]]; then
429 all_platforms="${all_platforms} --disable-avx --disable-avx2"
430 fi
406 gen_config_files linux/ia32 "--target=x86-linux-gcc --disable-ccache --enable-pi c --enable-realtime-only ${all_platforms}" 431 gen_config_files linux/ia32 "--target=x86-linux-gcc --disable-ccache --enable-pi c --enable-realtime-only ${all_platforms}"
407 gen_config_files linux/x64 "--target=x86_64-linux-gcc --disable-ccache --enable- pic --enable-realtime-only ${all_platforms}" 432 gen_config_files linux/x64 "--target=x86_64-linux-gcc --disable-ccache --enable- pic --enable-realtime-only ${all_platforms}"
408 gen_config_files linux/arm "--target=armv6-linux-gcc --enable-pic --enable-realt ime-only --disable-install-bins --disable-install-libs --disable-edsp ${all_plat forms}" 433 gen_config_files linux/arm "--target=armv6-linux-gcc --enable-pic --enable-realt ime-only --disable-install-bins --disable-install-libs --disable-edsp ${all_plat forms}"
409 gen_config_files linux/arm-neon "--target=armv7-linux-gcc --enable-pic --enable- realtime-only --disable-edsp ${all_platforms}" 434 gen_config_files linux/arm-neon "--target=armv7-linux-gcc --enable-pic --enable- realtime-only --disable-edsp ${all_platforms}"
410 gen_config_files linux/arm-neon-cpu-detect "--target=armv7-linux-gcc --enable-pi c --enable-realtime-only --enable-runtime-cpu-detect --disable-edsp ${all_platfo rms}" 435 gen_config_files linux/arm-neon-cpu-detect "--target=armv7-linux-gcc --enable-pi c --enable-realtime-only --enable-runtime-cpu-detect --disable-edsp ${all_platfo rms}"
411 gen_config_files linux/arm64 "--force-target=armv8-linux-gcc --enable-pic --enab le-realtime-only --disable-edsp ${all_platforms}" 436 gen_config_files linux/arm64 "--force-target=armv8-linux-gcc --enable-pic --enab le-realtime-only --disable-edsp ${all_platforms}"
412 gen_config_files linux/mipsel "--target=mips32-linux-gcc ${all_platforms}" 437 gen_config_files linux/mipsel "--target=mips32-linux-gcc ${all_platforms}"
413 gen_config_files linux/mips64el "--target=mips64-linux-gcc ${all_platforms}" 438 gen_config_files linux/mips64el "--target=mips64-linux-gcc ${all_platforms}"
414 gen_config_files linux/generic "--target=generic-gnu --enable-pic --enable-realt ime-only ${all_platforms}" 439 gen_config_files linux/generic "--target=generic-gnu --enable-pic --enable-realt ime-only ${all_platforms}"
415 gen_config_files win/ia32 "--target=x86-win32-vs12 --enable-realtime-only ${all_ platforms}" 440 gen_config_files win/ia32 "--target=x86-win32-vs12 --enable-realtime-only ${all_ platforms}"
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
456 gen_rtcd_header win/ia32 x86 481 gen_rtcd_header win/ia32 x86
457 gen_rtcd_header win/x64 x86_64 482 gen_rtcd_header win/x64 x86_64
458 gen_rtcd_header mac/ia32 x86 483 gen_rtcd_header mac/ia32 x86
459 gen_rtcd_header mac/x64 x86_64 484 gen_rtcd_header mac/x64 x86_64
460 gen_rtcd_header nacl nacl 485 gen_rtcd_header nacl nacl
461 486
462 echo "Prepare Makefile." 487 echo "Prepare Makefile."
463 ./configure --target=generic-gnu > /dev/null 488 ./configure --target=generic-gnu > /dev/null
464 make_clean 489 make_clean
465 490
466 # Remove existing .gni file. 491 if [[ ! $ONLY_CONFIGS ]]; then
467 rm -rf $BASE_DIR/libvpx_srcs.gni 492 # Remove existing .gni file.
468 write_license $BASE_DIR/libvpx_srcs.gni 493 rm -rf $BASE_DIR/libvpx_srcs.gni
494 write_license $BASE_DIR/libvpx_srcs.gni
469 495
470 echo "Generate X86 source list." 496 echo "Generate X86 source list."
471 config=$(print_config linux/ia32) 497 config=$(print_config linux/ia32)
472 make_clean 498 make_clean
473 make libvpx_srcs.txt target=libs $config > /dev/null 499 make libvpx_srcs.txt target=libs $config > /dev/null
474 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_x86 500 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_x86
475 501
476 # Copy vpx_version.h. The file should be the same for all platforms. 502 # Copy vpx_version.h. The file should be the same for all platforms.
477 cp vpx_version.h $BASE_DIR/$LIBVPX_CONFIG_DIR 503 cp vpx_version.h $BASE_DIR/$LIBVPX_CONFIG_DIR
478 504
479 echo "Generate X86_64 source list." 505 echo "Generate X86_64 source list."
480 config=$(print_config linux/x64) 506 config=$(print_config linux/x64)
481 make_clean 507 make_clean
482 make libvpx_srcs.txt target=libs $config > /dev/null 508 make libvpx_srcs.txt target=libs $config > /dev/null
483 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_x86_64 509 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_x86_64
484 510
485 echo "Generate ARM source list." 511 echo "Generate ARM source list."
486 config=$(print_config linux/arm) 512 config=$(print_config linux/arm)
487 make_clean 513 make_clean
488 make libvpx_srcs.txt target=libs $config > /dev/null 514 make libvpx_srcs.txt target=libs $config > /dev/null
489 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_arm 515 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_arm
490 516
491 echo "Generate ARM NEON source list." 517 echo "Generate ARM NEON source list."
492 config=$(print_config linux/arm-neon) 518 config=$(print_config linux/arm-neon)
493 make_clean 519 make_clean
494 make libvpx_srcs.txt target=libs $config > /dev/null 520 make libvpx_srcs.txt target=libs $config > /dev/null
495 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_arm_neon 521 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_arm_neon
496 522
497 echo "Generate ARM NEON CPU DETECT source list." 523 echo "Generate ARM NEON CPU DETECT source list."
498 config=$(print_config linux/arm-neon-cpu-detect) 524 config=$(print_config linux/arm-neon-cpu-detect)
499 make_clean 525 make_clean
500 make libvpx_srcs.txt target=libs $config > /dev/null 526 make libvpx_srcs.txt target=libs $config > /dev/null
501 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_arm_neon_cpu_detect 527 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_arm_neon_cpu_detect
502 528
503 echo "Generate ARM64 source list." 529 echo "Generate ARM64 source list."
504 config=$(print_config linux/arm64) 530 config=$(print_config linux/arm64)
505 make_clean 531 make_clean
506 make libvpx_srcs.txt target=libs $config > /dev/null 532 make libvpx_srcs.txt target=libs $config > /dev/null
507 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_arm64 533 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_arm64
508 534
509 echo "Generate MIPS source list." 535 echo "Generate MIPS source list."
510 config=$(print_config_basic linux/mipsel) 536 config=$(print_config_basic linux/mipsel)
511 make_clean 537 make_clean
512 make libvpx_srcs.txt target=libs $config > /dev/null 538 make libvpx_srcs.txt target=libs $config > /dev/null
513 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_mips 539 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_mips
514 540
515 echo "MIPS64 source list is identical to MIPS source list. No need to generate i t." 541 echo "MIPS64 source list is identical to MIPS source list. No need to generate it."
516 542
517 echo "Generate NaCl source list." 543 echo "Generate NaCl source list."
518 config=$(print_config_basic nacl) 544 config=$(print_config_basic nacl)
519 make_clean 545 make_clean
520 make libvpx_srcs.txt target=libs $config > /dev/null 546 make libvpx_srcs.txt target=libs $config > /dev/null
521 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_nacl 547 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_nacl
522 548
523 echo "Generate GENERIC source list." 549 echo "Generate GENERIC source list."
524 config=$(print_config_basic linux/generic) 550 config=$(print_config_basic linux/generic)
525 make_clean 551 make_clean
526 make libvpx_srcs.txt target=libs $config > /dev/null 552 make libvpx_srcs.txt target=libs $config > /dev/null
527 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_generic 553 convert_srcs_to_project_files libvpx_srcs.txt libvpx_srcs_generic
554 fi
528 555
529 echo "Remove temporary directory." 556 echo "Remove temporary directory."
530 cd $BASE_DIR 557 cd $BASE_DIR
531 rm -rf $TEMP_DIR 558 rm -rf $TEMP_DIR
532 559
533 # TODO(fgalligan): Can we turn on "--enable-realtime-only" for mipsel? 560 # TODO(fgalligan): Can we turn on "--enable-realtime-only" for mipsel?
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698