|
|
230118 |
#!/bin/sh
|
|
|
230118 |
#
|
|
|
230118 |
# usage: sanitize-tarball.sh [tarball]
|
|
|
230118 |
|
|
|
230118 |
if [ "x$1" = "x" ]; then
|
|
|
230118 |
echo "Usage: sanitize-tarball.sh [tarball]"
|
|
|
230118 |
exit 1
|
|
|
230118 |
fi
|
|
|
230118 |
|
|
|
230118 |
if [ -e /usr/bin/pxz ]; then
|
|
|
230118 |
XZ=/usr/bin/pxz
|
|
|
230118 |
else
|
|
|
230118 |
XZ=/usr/bin/xz
|
|
|
230118 |
fi
|
|
|
230118 |
|
|
|
230118 |
dirname=$(basename $(basename "$1" .tar.bz2) .tar.xz)
|
|
|
230118 |
|
|
|
230118 |
tar xf "$1"
|
|
|
230118 |
pushd $dirname
|
|
|
230118 |
|
|
|
230118 |
cat > src/gallium/auxiliary/vl/vl_mpeg12_decoder.c << EOF
|
|
|
230118 |
#include "vl_mpeg12_decoder.h"
|
|
|
230118 |
struct pipe_video_decoder *
|
|
|
230118 |
vl_create_mpeg12_decoder(struct pipe_context *context,
|
|
|
230118 |
enum pipe_video_profile profile,
|
|
|
230118 |
enum pipe_video_entrypoint entrypoint,
|
|
|
230118 |
enum pipe_video_chroma_format chroma_format,
|
|
|
230118 |
unsigned width, unsigned height,
|
|
|
230118 |
unsigned max_references,
|
|
|
230118 |
bool expect_chunked_decode)
|
|
|
230118 |
{
|
|
|
230118 |
return NULL;
|
|
|
230118 |
}
|
|
|
230118 |
EOF
|
|
|
230118 |
|
|
|
230118 |
cat > src/gallium/auxiliary/vl/vl_decoder.c << EOF
|
|
|
230118 |
#include "vl_decoder.h"
|
|
|
230118 |
bool vl_profile_supported(struct pipe_screen *screen,
|
|
|
230118 |
enum pipe_video_profile profile)
|
|
|
230118 |
{
|
|
|
230118 |
return false;
|
|
|
230118 |
}
|
|
|
230118 |
struct pipe_video_decoder *
|
|
|
230118 |
vl_create_decoder(struct pipe_context *pipe,
|
|
|
230118 |
enum pipe_video_profile profile,
|
|
|
230118 |
enum pipe_video_entrypoint entrypoint,
|
|
|
230118 |
enum pipe_video_chroma_format chroma_format,
|
|
|
230118 |
unsigned width, unsigned height, unsigned max_references,
|
|
|
230118 |
bool expect_chunked_decode)
|
|
|
230118 |
{
|
|
|
230118 |
return NULL;
|
|
|
230118 |
}
|
|
|
230118 |
EOF
|
|
|
230118 |
|
|
|
230118 |
popd
|
|
|
230118 |
tar cf - $dirname | $XZ > $dirname.tar.xz
|