aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/codec_names.sh
diff options
context:
space:
mode:
authorNicolas George <nicolas.george@normalesup.org>2011-10-22 10:55:44 +0200
committerMichael Niedermayer <michaelni@gmx.at>2011-10-22 16:49:49 +0200
commit0e138745f79f9da6a28b39dbd321354fd1159068 (patch)
tree3d9c94d3adc62525389b5c719a0cc5df6cb48857 /libavcodec/codec_names.sh
parent9ab5e64897b341044d3b39c6f941630e214a9766 (diff)
downloadffmpeg-0e138745f79f9da6a28b39dbd321354fd1159068.tar.gz
codec_names: invoke preprocessor on avcodec.h.
This fixes failures when codec IDs are defined conditionally, for example when scheduling for a major bump. Signed-off-by: Nicolas George <nicolas.george@normalesup.org> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/codec_names.sh')
-rwxr-xr-xlibavcodec/codec_names.sh7
1 files changed, 3 insertions, 4 deletions
diff --git a/libavcodec/codec_names.sh b/libavcodec/codec_names.sh
index 167d29771e..0e499c9c49 100755
--- a/libavcodec/codec_names.sh
+++ b/libavcodec/codec_names.sh
@@ -21,8 +21,7 @@
set -e
config="$1"
-codecs="$2"
-out="$3"
+out="$2"
test -n "$out"
outval=""
@@ -63,7 +62,7 @@ parse_enum_codecid () {
while read line; do
case "$line" in
"};") break;;
- *CODEC_ID_FIRST*///*dummy*) ;;
+ *CODEC_ID_FIRST*=*) ;;
CODEC_ID_*) define_codecid ${line%%[=,]*};;
esac
done
@@ -78,7 +77,7 @@ parse_avcodec_h () {
}
parse_config_h < "$config"
-parse_avcodec_h < "$codecs"
+parse_avcodec_h # use stdin
sed -e '/case.*:/!y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/' \
-e 's/extern avcodec /extern AVCodec /' > "$out" <<EOF
$outval