Add cmake as optional build system to Travis-CI configuration
[platform/upstream/libvorbis.git] / README.md
1 # Vorbis
2
3 [![Travis Build Status](https://travis-ci.org/xiph/vorbis.svg?branch=master)](https://travis-ci.org/xiph/vorbis)
4 [![Jenkins Build Status](https://mf4.xiph.org/jenkins/job/libvorbis/badge/icon)](https://mf4.xiph.org/jenkins/job/libvorbis/)
5
6 Vorbis is a general purpose audio and music encoding format
7 contemporary to MPEG-4's AAC and TwinVQ, the next generation beyond
8 MPEG audio layer 3. Unlike the MPEG sponsored formats (and other
9 proprietary formats such as RealAudio G2 and Windows' flavor of the
10 month), the Vorbis CODEC specification belongs to the public domain.
11 All the technical details are published and documented, and any
12 software entity may make full use of the format without license
13 fee, royalty or patent concerns.
14
15 This package contains:
16
17 - libvorbis, a BSD-style license software implementation of
18   the Vorbis specification by the Xiph.Org Foundation
19   (https://www.xiph.org/)
20
21 - libvorbisfile, a BSD-style license convenience library
22   built on Vorbis designed to simplify common uses
23
24 - libvorbisenc, a BSD-style license library that provides a simple,
25   programmatic encoding setup interface
26
27 - example code making use of libogg, libvorbis, libvorbisfile and
28   libvorbisenc
29
30 ## What's here ##
31
32 This source distribution includes libvorbis and an example
33 encoder/player to demonstrate use of libvorbis as well as
34 documentation on the Ogg Vorbis audio coding format.
35
36 You'll need libogg (distributed separately) to compile this library.
37 A more comprehensive set of utilities is available in the vorbis-tools
38 package.
39
40 Directory:
41
42 - `lib` The source for the libraries, a BSD-license implementation of the public domain Ogg Vorbis audio encoding format.
43
44 - `include` Library API headers
45
46 - `debian` Rules/spec files for building Debian .deb packages
47
48 - `doc` Vorbis documentation
49
50 - `examples` Example code illustrating programmatic use of libvorbis, libvorbisfile and libvorbisenc
51
52 - `macosx` Project files for MacOS X.
53
54 - `win32` Win32 projects files and build automation
55
56 - `vq` Internal utilities for training/building new LSP/residue and auxiliary codebooks.
57
58 ## Contact ##
59
60 The Ogg homepage is located at 'https://www.xiph.org/ogg/'.
61 Vorbis's homepage is located at 'https://www.xiph.org/vorbis/'.
62 Up to date technical documents, contact information, source code and
63 pre-built utilities may be found there.
64
65 The user website for Ogg Vorbis software and audio is http://vorbis.com/
66
67 ## Building ##
68
69 #### Building from master ####
70
71 Development source is under git revision control at
72 https://git.xiph.org/vorbis.git. You will also need the
73 newest versions of autoconf, automake, libtool and pkg-config in
74 order to compile Vorbis from development source. A configure script
75 is provided for you in the source tarball distributions.
76
77     ./autogen.sh
78     ./configure
79     make
80
81 and as root if desired:
82
83     make install
84
85 This will install the Vorbis libraries (static and shared) into
86 /usr/local/lib, includes into /usr/local/include and API manpages
87 (once we write some) into /usr/local/man.
88
89 Documentation building requires xsltproc and pdfxmltex.
90
91 #### Building from tarball distributions ####
92
93     ./configure
94     make
95
96 and optionally (as root):
97
98     make install
99
100 #### Building RPM packages ####
101
102 after normal configuring:
103
104     make dist
105     rpm -ta libvorbis-<version>.tar.gz
106
107 ## Building with CMake ##
108
109 Ogg supports building using [CMake](http://www.cmake.org/). CMake is a meta build system that generates native projects for each platform.
110 To generate projects just run cmake replacing `YOUR-PROJECT-GENERATOR` with a proper generator from a list [here](http://www.cmake.org/cmake/help/v3.2/manual/cmake-generators.7.html):
111
112     cmake -G YOUR-PROJECT-GENERATOR .
113
114 Note that by default cmake generates projects that will build static libraries.
115 To generate projects that will build dynamic library use `BUILD_SHARED_LIBS` option like this:
116
117     cmake -G YOUR-PROJECT-GENERATOR -DBUILD_SHARED_LIBS=1 .
118
119 After projects are generated use them as usual
120
121 #### Building on Windows ####
122
123 Use proper generator for your Visual Studio version like:
124
125     cmake -G "Visual Studio 12 2013" .
126
127 #### Building on Mac OS X ####
128
129 Use Xcode generator. To build framework run:
130
131     cmake -G Xcode -DBUILD_FRAMEWORK=1 .
132
133 #### Building on Linux ####
134
135 Use Makefile generator which is default one.
136
137     cmake .
138     make
139
140 ## License ##
141
142 THIS FILE IS PART OF THE OggVorbis SOFTWARE CODEC SOURCE CODE.
143 USE, DISTRIBUTION AND REPRODUCTION OF THIS LIBRARY SOURCE IS
144 GOVERNED BY A BSD-STYLE SOURCE LICENSE INCLUDED WITH THIS SOURCE
145 IN 'COPYING'. PLEASE READ THESE TERMS BEFORE DISTRIBUTING.
146
147 THE OggVorbis SOURCE CODE IS COPYRIGHT (C) 1994-2015
148 by the Xiph.Org Foundation https://www.xiph.org/