mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
element-maker: Clean up directory
This commit is contained in:
parent
c8d9cc5770
commit
7ae4aaaee6
23 changed files with 80 additions and 54 deletions
|
@ -1,24 +1,28 @@
|
|||
|
||||
templatefiles=\
|
||||
element-templates/audiofilter \
|
||||
element-templates/audiosink \
|
||||
element-templates/audiosrc \
|
||||
element-templates/base \
|
||||
element-templates/baseaudiosink \
|
||||
element-templates/baseaudiosrc \
|
||||
element-templates/basertpdepayload \
|
||||
element-templates/basertppayload \
|
||||
element-templates/basesink \
|
||||
element-templates/basesrc \
|
||||
element-templates/basetransform \
|
||||
element-templates/cddabasesrc \
|
||||
element-templates/element \
|
||||
element-templates/gobject \
|
||||
element-templates/pushsrc \
|
||||
element-templates/sinkpad \
|
||||
element-templates/sinkpad-simple \
|
||||
element-templates/srcpad \
|
||||
element-templates/srcpad-simple \
|
||||
element-templates/tagdemux \
|
||||
element-templates/videosink
|
||||
|
||||
EXTRA_DIST = \
|
||||
element-maker \
|
||||
base.c \
|
||||
gobject.c \
|
||||
gstaudiofilter.c \
|
||||
gstaudiosink.c \
|
||||
gstaudiosrc.c \
|
||||
gstbaseaudiosink.c \
|
||||
gstbaseaudiosrc.c \
|
||||
gstbasertpdepayload.c \
|
||||
gstbasertppayload.c \
|
||||
gstbasesink.c \
|
||||
gstbasesrc.c \
|
||||
gstbasetransform.c \
|
||||
gstcddabasesrc.c \
|
||||
gstelement.c \
|
||||
gstpushsrc.c \
|
||||
gsttagdemux.c \
|
||||
gstvideosink.c \
|
||||
sinkpad.c \
|
||||
sinkpad-simple.c \
|
||||
srcpad.c \
|
||||
srcpad-simple.c
|
||||
gst-element-maker \
|
||||
$(templatefiles)
|
||||
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstAudioFilter
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstAudioSink
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstAudioSrc
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
|
||||
% copyright
|
||||
/* GStreamer
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstBaseAudioSink
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstBaseAudioSrc
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstBaseRTPDepayload
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstBaseRTPPayload
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstBaseSink
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstBaseSrc
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstBaseTransform
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstCddaBaseSrc
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstElement
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
|
||||
% includes
|
||||
% prototypes
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstPushSrc
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
|
||||
% instance-members
|
||||
GstPad *sinkpad;
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
|
||||
% instance-members
|
||||
GstPad *sinkpad;
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
|
||||
% instance-members
|
||||
GstPad *srcpad;
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
|
||||
% instance-members
|
||||
GstPad *srcpad;
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstTagDemux
|
||||
% TYPE_CLASS_NAME
|
|
@ -1,3 +1,4 @@
|
|||
/* vim: set filetype=c: */
|
||||
% ClassName
|
||||
GstVideoSink
|
||||
% TYPE_CLASS_NAME
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
|
||||
prefix=gst
|
||||
templatedir=element-templates
|
||||
|
||||
while [ "$1" ] ; do
|
||||
case $1 in
|
||||
|
@ -43,7 +44,7 @@ if [ "$name" = "" -o "$class" = "" ] ; then
|
|||
exit 1
|
||||
fi
|
||||
|
||||
if [ ! -f "gst$class.c" ] ; then
|
||||
if [ ! -f "element-templates/$class" ] ; then
|
||||
echo "Template file for $class not found."
|
||||
exit 1
|
||||
fi
|
||||
|
@ -69,11 +70,11 @@ if [ "$EMAIL_ADDRESS" = "" ] ; then
|
|||
EMAIL_ADDRESS=fixme@example.com
|
||||
fi
|
||||
|
||||
source=gst$class.c
|
||||
pkg=`grep -A 10000 '^% pkg-config' $source | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1`
|
||||
GST_TYPE_BASE_REPLACE=`grep -A 10000 '^% TYPE_CLASS_NAME' $source | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1`
|
||||
GstBaseReplace=`grep -A 10000 '^% ClassName' $source | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1`
|
||||
pads=`grep -A 10000 '^% pads' $source | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1`
|
||||
|
||||
pkg=`grep -A 10000 '^% pkg-config' $templatedir/$class | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1`
|
||||
GST_TYPE_BASE_REPLACE=`grep -A 10000 '^% TYPE_CLASS_NAME' $templatedir/$class | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1`
|
||||
GstBaseReplace=`grep -A 10000 '^% ClassName' $templatedir/$class | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1`
|
||||
pads=`grep -A 10000 '^% pads' $templatedir/$class | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1`
|
||||
|
||||
generate ()
|
||||
{
|
||||
|
@ -115,7 +116,7 @@ cat <<-EOF
|
|||
*/
|
||||
EOF
|
||||
|
||||
#grep -A 10000 '^% copyright' base.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
#grep -A 10000 '^% copyright' $templatedir/base | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
|
||||
cat <<EOF
|
||||
|
||||
|
@ -125,9 +126,9 @@ cat <<EOF
|
|||
|
||||
EOF
|
||||
|
||||
grep -A 10000 '^% includes' base.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% includes' gobject.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% includes' $source | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% includes' $templatedir/base | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% includes' $templatedir/gobject | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% includes' $templatedir/$class | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
|
||||
cat <<EOF
|
||||
#include "gstreplace.h"
|
||||
|
@ -136,12 +137,12 @@ cat <<EOF
|
|||
|
||||
EOF
|
||||
|
||||
grep -A 10000 '^% prototypes' base.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% prototypes' gobject.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% prototypes' $source | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% prototypes' $templatedir/base | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% prototypes' $templatedir/gobject | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% prototypes' $templatedir/$class | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
for each in $pads
|
||||
do
|
||||
grep -A 10000 '^% prototypes' $each.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% prototypes' $templatedir/$each | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
done
|
||||
|
||||
cat <<EOF
|
||||
|
@ -157,7 +158,7 @@ EOF
|
|||
|
||||
for each in $pads
|
||||
do
|
||||
grep -A 10000 '^% pad-template' $each.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% pad-template' $templatedir/$each | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
done
|
||||
|
||||
cat <<EOF
|
||||
|
@ -176,7 +177,7 @@ EOF
|
|||
|
||||
for each in $pads
|
||||
do
|
||||
grep -A 10000 '^% base-init' $each.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% base-init' $templatedir/$each | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
done
|
||||
|
||||
cat <<EOF
|
||||
|
@ -189,15 +190,15 @@ static void
|
|||
gst_replace_class_init (GstReplaceClass * klass)
|
||||
{
|
||||
EOF
|
||||
grep -A 10000 '^% declare-class' base.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% declare-class' gobject.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% declare-class' $source | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% declare-class' $templatedir/base | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% declare-class' $templatedir/gobject | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% declare-class' $templatedir/$class | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
|
||||
echo
|
||||
|
||||
grep -A 10000 '^% set-methods' base.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% set-methods' gobject.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% set-methods' $source | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% set-methods' $templatedir/base | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% set-methods' $templatedir/gobject | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% set-methods' $templatedir/$class | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
|
||||
cat <<EOF
|
||||
|
||||
|
@ -210,7 +211,7 @@ EOF
|
|||
|
||||
for each in $pads
|
||||
do
|
||||
grep -A 10000 '^% instance-init' $each.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% instance-init' $templatedir/$each | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
done
|
||||
|
||||
|
||||
|
@ -219,12 +220,12 @@ cat <<EOF
|
|||
EOF
|
||||
|
||||
|
||||
grep -A 10000 '^% methods' base.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% methods' gobject.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% methods' $source | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% methods' $templatedir/base | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% methods' $templatedir/gobject | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% methods' $templatedir/$class | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
for each in $pads
|
||||
do
|
||||
grep -A 10000 '^% methods' $each.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% methods' $templatedir/$each | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
done
|
||||
|
||||
|
||||
|
@ -267,7 +268,7 @@ EOF
|
|||
generate_header ()
|
||||
{
|
||||
|
||||
grep -A 10000 '^% copyright' base.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% copyright' $templatedir/base | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
|
||||
cat <<EOF
|
||||
#ifndef _GST_REPLACE_H_
|
||||
|
@ -275,9 +276,9 @@ cat <<EOF
|
|||
|
||||
EOF
|
||||
|
||||
grep -A 10000 '^% includes' base.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% includes' gobject.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% includes' $source | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% includes' $templatedir/base | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% includes' $templatedir/gobject | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% includes' $templatedir/$class | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
|
||||
cat <<EOF
|
||||
|
||||
|
@ -305,7 +306,7 @@ EOF
|
|||
|
||||
for each in $pads
|
||||
do
|
||||
grep -A 10000 '^% instance-members' $each.c | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
grep -A 10000 '^% instance-members' $templatedir/$each | tail -n +2|grep -m 1 -B 10000 '^%'|head -n -1
|
||||
done
|
||||
|
||||
cat <<EOF
|
Loading…
Reference in a new issue