Go to file
Tom Finegan ae2fbfe0cf parser_tests: Silence sign compare warning.
Change-Id: I5286cf99129cc8fd5336e792990886f43332b720
2016-02-26 08:57:43 -08:00
build Add CMakeLists.txt and msvc_runtime.cmake. 2015-02-13 16:07:01 -08:00
common libwebm_utils: Silence sign compare warning. 2016-02-26 08:57:43 -08:00
testing parser_tests: Silence sign compare warning. 2016-02-26 08:57:43 -08:00
.clang-format clang-format re-run 2015-06-04 16:48:48 -07:00
.gitattributes Enable auto CRLF for visual studio project and solution files. 2012-05-29 10:45:59 -04:00
.gitignore Update .gitignore to include some new binaries 2016-02-05 09:21:33 -08:00
Android.mk libwebm: Update Android build 2013-04-15 09:13:07 -07:00
AUTHORS.TXT Initial version 2010-06-02 10:25:33 -04:00
CMakeLists.txt Add C++11 detection to cmake file. 2016-02-25 09:09:24 -08:00
dumpvtt.cc clang-format on dumpvtt.cc 2014-04-14 12:15:04 -07:00
hdr_util.cpp Set the mastering metadata on the muxers colour 2016-02-22 10:54:58 -08:00
hdr_util.hpp Add hdr_util. 2016-02-18 13:13:54 -08:00
iosbuild.sh add bitcode embedding support for ios 2016-01-23 19:24:52 +09:00
LICENSE.TXT added new license files 2010-06-15 17:45:08 -04:00
Makefile.unix Add hdr_util. 2016-02-18 13:13:54 -08:00
mkvmuxer.cpp mkvmuxer: Fix GCC build. 2016-02-22 09:25:19 -08:00
mkvmuxer.hpp mkvmuxer: Use kValueNotPresent in Colour/MasteringMetadata. 2016-02-18 12:11:53 -08:00
mkvmuxertypes.hpp clang-format on mkvmuxertypes.hpp and webmids.hpp 2014-04-15 11:39:44 -07:00
mkvmuxerutil.cpp clang-format re-run 2015-06-04 16:48:48 -07:00
mkvmuxerutil.hpp mkvmuxer: Write Block key frames correctly. 2015-06-01 11:04:12 -07:00
mkvparser.cpp Colour element: TransferFunction renamed to TransferCharacteristics. 2016-02-18 12:03:41 -08:00
mkvparser.hpp Colour element: TransferFunction renamed to TransferCharacteristics. 2016-02-18 12:03:41 -08:00
mkvreader.cpp clang-format on mkvreader.[ch]pp 2014-04-15 12:05:58 -07:00
mkvreader.hpp make Mkv(Reader|Writer)(FILE*) explicit 2014-05-02 11:47:44 -07:00
mkvwriter.cpp clang-format on mkvwriter.[ch]pp 2014-04-14 10:30:33 -07:00
mkvwriter.hpp make Mkv(Reader|Writer)(FILE*) explicit 2014-05-02 11:47:44 -07:00
PATENTS.TXT PATENTS: fix a typo: constitutes -> constitute 2015-04-30 15:40:13 -07:00
README.libwebm webm2pes/ts: Fix gcc build. 2016-01-25 12:18:56 -08:00
sample_muxer_metadata.cc sample_muxer: Use AddGenericFrame to add frames. 2015-06-01 10:32:07 -07:00
sample_muxer_metadata.h clang-format on sample_muxer_metadata.(cc|h) 2014-04-14 12:09:20 -07:00
sample_muxer.cpp Add hdr_util. 2016-02-18 13:13:54 -08:00
sample.cpp Colour element: TransferFunction renamed to TransferCharacteristics. 2016-02-18 12:03:41 -08:00
vpxpes2ts_main.cc webm2ts: Converts WebM VPx video to a MPEG TS. 2016-01-22 20:28:04 +00:00
vpxpes2ts.cc webm2ts: Converts WebM VPx video to a MPEG TS. 2016-01-22 20:28:04 +00:00
vpxpes2ts.h webm2ts: Converts WebM VPx video to a MPEG TS. 2016-01-22 20:28:04 +00:00
vttdemux.cc Revert change from auto_ptr to unique_ptr in sample code. 2016-02-17 11:22:40 -08:00
vttreader.cc clang-format on vttreader.cc 2014-04-14 12:11:27 -07:00
vttreader.h added dumpvtt app 2012-08-23 14:00:57 -07:00
webm2pes_main.cc webm2pes: Rename Convert to ConvertToFile(). 2015-12-17 08:50:23 -08:00
webm2pes.cc webm2ts: Converts WebM VPx video to a MPEG TS. 2016-01-22 20:28:04 +00:00
webm2pes.h webm2ts: Converts WebM VPx video to a MPEG TS. 2016-01-22 20:28:04 +00:00
webmids.hpp Colour element: TransferFunction renamed to TransferCharacteristics. 2016-02-18 12:03:41 -08:00
webvttparser.cc clang-format re-run. 2014-04-29 11:27:31 -07:00
webvttparser.h clang-format on webvttparser.(cc|h) 2014-04-25 22:18:40 -07:00

Building Libwebm

To build libwebm you must first create project files. To do this run cmake
and pass it the path to your libwebm repo.

Makefile.unix can be used as a fallback on systems that cmake does not
support.


CMake Basics

To generate project/make files for the default toolchain on your system simply
run cmake with the path to the libwebm repo:

$ cmake path/to/libwebm

On Windows the above command will produce Visual Studio project files for the
newest Visual Studio detected on the system. On Mac OS X and Linux systems, the
above command will produce a makefile.

To control what types of projects are generated the -G parameter is added to
the cmake command line. This argument must be followed by the name of a
generator. Running cmake with the --help argument will list the available
generators for your system.

On Mac OS X you would run the following command to generate Xcode projects:

$ cmake path/to/libwebm -G Xcode

On a Windows box you would run the following command to generate Visual Studio
2013 projects:

$ cmake path/to/libwebm -G "Visual Studio 12"

To generate 64-bit Windows Visual Studio 2013 projects:

$ cmake path/to/libwebm "Visual Studio 12 Win64"


CMake Makefiles: Debugging and Optimization

Unlike Visual Studio and Xcode projects, the build configuration for make builds
is controlled when you run cmake. The following examples demonstrate various
build configurations.

Omitting the build type produces makefiles that use build flags containing
neither optimization nor debug flags:
$ cmake path/to/libwebm

A makefile using release (optimized) flags is produced like this:
$ cmake path/to/libwebm -DCMAKE_BUILD_TYPE=release

A release build with debug info can be produced as well:
$ cmake path/to/libwebm -DCMAKE_BUILD_TYPE=relwithdebinfo

And your standard debug build will be produced using:
$ cmake path/to/libwebm -DCMAKE_BUILD_TYPE=debug


Tests

To enable libwebm tests add -DENABLE_TESTS=ON CMake generation command line. For
example:

$ cmake path/to/libwebm -G Xcode -DENABLE_TESTS=ON

Libwebm tests depend on googletest. By default googletest is expected to be a
sibling directory of the Libwebm repository. To change that, update your CMake
command to be similar to the following:

$ cmake path/to/libwebm -G Xcode -DENABLE_TESTS=ON \
  -DGTEST_SRC_DIR=/path/to/googletest

The tests rely upon the LIBWEBM_TEST_DATA_PATH environment variable to locate
test input. The following example demonstrates running the muxer tests from the
build directory:

$ LIBWEBM_TEST_DATA_PATH=path/to/libwebm/testing/testdata ./muxer_tests

Note: Libwebm Googletest integration was built with googletest from
      https://github.com/google/googletest.git at git revision
      ddb8012eb48bc203aa93dcc2b22c1db516302b29.