xref: /aosp_15_r20/external/libopus/doc/build_oggdraft.sh (revision a58d3d2adb790c104798cd88c8a3aff4fa8b82cc)
1*a58d3d2aSXin Li#!/bin/sh
2*a58d3d2aSXin Li
3*a58d3d2aSXin Li# Copyright (c) 2012 Xiph.Org Foundation and Mozilla Corporation
4*a58d3d2aSXin Li#
5*a58d3d2aSXin Li#  This file is extracted from RFC6716. Please see that RFC for additional
6*a58d3d2aSXin Li#  information.
7*a58d3d2aSXin Li#
8*a58d3d2aSXin Li#  Redistribution and use in source and binary forms, with or without
9*a58d3d2aSXin Li#  modification, are permitted provided that the following conditions
10*a58d3d2aSXin Li#  are met:
11*a58d3d2aSXin Li#
12*a58d3d2aSXin Li#  - Redistributions of source code must retain the above copyright
13*a58d3d2aSXin Li#  notice, this list of conditions and the following disclaimer.
14*a58d3d2aSXin Li#
15*a58d3d2aSXin Li#  - Redistributions in binary form must reproduce the above copyright
16*a58d3d2aSXin Li#  notice, this list of conditions and the following disclaimer in the
17*a58d3d2aSXin Li#  documentation and/or other materials provided with the distribution.
18*a58d3d2aSXin Li#
19*a58d3d2aSXin Li#  - Neither the name of Internet Society, IETF or IETF Trust, nor the
20*a58d3d2aSXin Li#  names of specific contributors, may be used to endorse or promote
21*a58d3d2aSXin Li#  products derived from this software without specific prior written
22*a58d3d2aSXin Li#  permission.
23*a58d3d2aSXin Li#
24*a58d3d2aSXin Li#  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
25*a58d3d2aSXin Li#  ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
26*a58d3d2aSXin Li#  LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
27*a58d3d2aSXin Li#  A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER
28*a58d3d2aSXin Li#  OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
29*a58d3d2aSXin Li#  EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
30*a58d3d2aSXin Li#  PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
31*a58d3d2aSXin Li#  PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
32*a58d3d2aSXin Li#  LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
33*a58d3d2aSXin Li#  NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
34*a58d3d2aSXin Li#  SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
35*a58d3d2aSXin Li
36*a58d3d2aSXin Li#Stop on errors
37*a58d3d2aSXin Liset -e
38*a58d3d2aSXin Li#Set the CWD to the location of this script
39*a58d3d2aSXin Li[ -n "${0%/*}" ] && cd "${0%/*}"
40*a58d3d2aSXin Li
41*a58d3d2aSXin Liif test -z `which xml2rfc 2> /dev/null`; then
42*a58d3d2aSXin Li  echo "Error: couldn't find xml2rfc."
43*a58d3d2aSXin Li  echo
44*a58d3d2aSXin Li  echo "Please install xml2rfc version 2 or later."
45*a58d3d2aSXin Li  echo "E.g. 'pip install xml2rfc' or follow the instructions"
46*a58d3d2aSXin Li  echo "on http://pypi.python.org/pypi/xml2rfc/ or tools.ietf.org."
47*a58d3d2aSXin Li  exit 1
48*a58d3d2aSXin Lifi
49*a58d3d2aSXin Li
50*a58d3d2aSXin Liecho running xml2rfc
51*a58d3d2aSXin Li# version 2 syntax
52*a58d3d2aSXin Lixml2rfc draft-ietf-codec-oggopus.xml --text --html
53