Use Linux-style EOL for non Windows specific files

This commit is contained in:
Cristian Morales Vega 2013-04-14 16:34:22 +01:00
parent a8f9a28def
commit e23d29d21b
13 changed files with 2234 additions and 2234 deletions

File diff suppressed because it is too large Load Diff

View File

@ -1,211 +1,211 @@
# Doxyfile 1.3
#---------------------------------------------------------------------------
# General configuration options
#---------------------------------------------------------------------------
PROJECT_NAME = libmatroska
PROJECT_NUMBER = 0.5.0
OUTPUT_DIRECTORY = ../../doc/src
OUTPUT_LANGUAGE = English
USE_WINDOWS_ENCODING = YES
EXTRACT_ALL = YES
EXTRACT_PRIVATE = NO
EXTRACT_STATIC = YES
EXTRACT_LOCAL_CLASSES = YES
HIDE_UNDOC_MEMBERS = NO
HIDE_UNDOC_CLASSES = NO
HIDE_FRIEND_COMPOUNDS = NO
HIDE_IN_BODY_DOCS = NO
BRIEF_MEMBER_DESC = YES
REPEAT_BRIEF = YES
ALWAYS_DETAILED_SEC = NO
INLINE_INHERITED_MEMB = YES
FULL_PATH_NAMES = NO
STRIP_FROM_PATH =
INTERNAL_DOCS = NO
CASE_SENSE_NAMES = YES
SHORT_NAMES = NO
HIDE_SCOPE_NAMES = NO
VERBATIM_HEADERS = YES
SHOW_INCLUDE_FILES = NO
JAVADOC_AUTOBRIEF = YES
MULTILINE_CPP_IS_BRIEF = NO
DETAILS_AT_TOP = YES
INHERIT_DOCS = YES
INLINE_INFO = YES
SORT_MEMBER_DOCS = NO
DISTRIBUTE_GROUP_DOC = NO
TAB_SIZE = 2
GENERATE_TODOLIST = YES
GENERATE_TESTLIST = YES
GENERATE_BUGLIST = YES
GENERATE_DEPRECATEDLIST= YES
ALIASES =
ENABLED_SECTIONS =
MAX_INITIALIZER_LINES = 30
OPTIMIZE_OUTPUT_FOR_C = NO
OPTIMIZE_OUTPUT_JAVA = NO
SHOW_USED_FILES = YES
#---------------------------------------------------------------------------
# configuration options related to warning and progress messages
#---------------------------------------------------------------------------
QUIET = NO
WARNINGS = YES
WARN_IF_UNDOCUMENTED = YES
WARN_IF_DOC_ERROR = YES
WARN_FORMAT = "$file:$line: $text"
WARN_LOGFILE =
#---------------------------------------------------------------------------
# configuration options related to the input files
#---------------------------------------------------------------------------
INPUT = ../../libebml/src \
../../libebml/src/platform/win32 \
../../libebml/ebml \
../../libebml/ebml/c \
../src \
../matroska \
../matroska/c
FILE_PATTERNS = *.cpp \
*.h
RECURSIVE = NO
EXCLUDE =
EXCLUDE_SYMLINKS = NO
EXCLUDE_PATTERNS =
EXAMPLE_PATH =
EXAMPLE_PATTERNS =
EXAMPLE_RECURSIVE = NO
IMAGE_PATH =
INPUT_FILTER =
FILTER_SOURCE_FILES = NO
#---------------------------------------------------------------------------
# configuration options related to source browsing
#---------------------------------------------------------------------------
SOURCE_BROWSER = YES
INLINE_SOURCES = NO
STRIP_CODE_COMMENTS = YES
REFERENCED_BY_RELATION = NO
REFERENCES_RELATION = YES
#---------------------------------------------------------------------------
# configuration options related to the alphabetical class index
#---------------------------------------------------------------------------
ALPHABETICAL_INDEX = NO
COLS_IN_ALPHA_INDEX = 5
IGNORE_PREFIX =
#---------------------------------------------------------------------------
# configuration options related to the HTML output
#---------------------------------------------------------------------------
GENERATE_HTML = YES
HTML_OUTPUT = html
HTML_FILE_EXTENSION = .html
HTML_HEADER =
HTML_FOOTER =
HTML_STYLESHEET = libmatroska.css
HTML_ALIGN_MEMBERS = YES
GENERATE_HTMLHELP = NO
CHM_FILE =
HHC_LOCATION =
GENERATE_CHI = NO
BINARY_TOC = NO
TOC_EXPAND = NO
DISABLE_INDEX = NO
ENUM_VALUES_PER_LINE = 4
GENERATE_TREEVIEW = NO
TREEVIEW_WIDTH = 250
#---------------------------------------------------------------------------
# configuration options related to the LaTeX output
#---------------------------------------------------------------------------
GENERATE_LATEX = YES
LATEX_OUTPUT = latex
LATEX_CMD_NAME = latex
MAKEINDEX_CMD_NAME = makeindex
COMPACT_LATEX = YES
PAPER_TYPE = a4wide
EXTRA_PACKAGES =
LATEX_HEADER =
PDF_HYPERLINKS = YES
USE_PDFLATEX = YES
LATEX_BATCHMODE = NO
LATEX_HIDE_INDICES = NO
#---------------------------------------------------------------------------
# configuration options related to the RTF output
#---------------------------------------------------------------------------
GENERATE_RTF = YES
RTF_OUTPUT = rtf
COMPACT_RTF = NO
RTF_HYPERLINKS = YES
RTF_STYLESHEET_FILE =
RTF_EXTENSIONS_FILE =
#---------------------------------------------------------------------------
# configuration options related to the man page output
#---------------------------------------------------------------------------
GENERATE_MAN = NO
MAN_OUTPUT = man
MAN_EXTENSION = .3
MAN_LINKS = YES
#---------------------------------------------------------------------------
# configuration options related to the XML output
#---------------------------------------------------------------------------
GENERATE_XML = NO
XML_SCHEMA =
XML_DTD =
#---------------------------------------------------------------------------
# configuration options for the AutoGen Definitions output
#---------------------------------------------------------------------------
GENERATE_AUTOGEN_DEF = NO
#---------------------------------------------------------------------------
# configuration options related to the Perl module output
#---------------------------------------------------------------------------
GENERATE_PERLMOD = NO
PERLMOD_LATEX = NO
PERLMOD_PRETTY = YES
PERLMOD_MAKEVAR_PREFIX =
#---------------------------------------------------------------------------
# Configuration options related to the preprocessor
#---------------------------------------------------------------------------
ENABLE_PREPROCESSING = YES
MACRO_EXPANSION = NO
EXPAND_ONLY_PREDEF = NO
SEARCH_INCLUDES = YES
INCLUDE_PATH =
INCLUDE_FILE_PATTERNS =
PREDEFINED =
EXPAND_AS_DEFINED =
SKIP_FUNCTION_MACROS = YES
#---------------------------------------------------------------------------
# Configuration::addtions related to external references
#---------------------------------------------------------------------------
TAGFILES =
GENERATE_TAGFILE =
ALLEXTERNALS = NO
EXTERNAL_GROUPS = YES
PERL_PATH = /usr/bin/perl
#---------------------------------------------------------------------------
# Configuration options related to the dot tool
#---------------------------------------------------------------------------
CLASS_DIAGRAMS = YES
HIDE_UNDOC_RELATIONS = YES
HAVE_DOT = NO
CLASS_GRAPH = YES
COLLABORATION_GRAPH = YES
TEMPLATE_RELATIONS = YES
INCLUDE_GRAPH = YES
INCLUDED_BY_GRAPH = YES
GRAPHICAL_HIERARCHY = YES
DOT_IMAGE_FORMAT = png
DOT_PATH =
DOTFILE_DIRS =
MAX_DOT_GRAPH_WIDTH = 1024
MAX_DOT_GRAPH_HEIGHT = 1024
MAX_DOT_GRAPH_DEPTH = 0
GENERATE_LEGEND = YES
DOT_CLEANUP = YES
#---------------------------------------------------------------------------
# Configuration::addtions related to the search engine
#---------------------------------------------------------------------------
SEARCHENGINE = NO
CGI_NAME = search.cgi
CGI_URL =
DOC_URL =
DOC_ABSPATH =
BIN_ABSPATH = /usr/local/bin/
EXT_DOC_PATHS =
# Doxyfile 1.3
#---------------------------------------------------------------------------
# General configuration options
#---------------------------------------------------------------------------
PROJECT_NAME = libmatroska
PROJECT_NUMBER = 0.5.0
OUTPUT_DIRECTORY = ../../doc/src
OUTPUT_LANGUAGE = English
USE_WINDOWS_ENCODING = YES
EXTRACT_ALL = YES
EXTRACT_PRIVATE = NO
EXTRACT_STATIC = YES
EXTRACT_LOCAL_CLASSES = YES
HIDE_UNDOC_MEMBERS = NO
HIDE_UNDOC_CLASSES = NO
HIDE_FRIEND_COMPOUNDS = NO
HIDE_IN_BODY_DOCS = NO
BRIEF_MEMBER_DESC = YES
REPEAT_BRIEF = YES
ALWAYS_DETAILED_SEC = NO
INLINE_INHERITED_MEMB = YES
FULL_PATH_NAMES = NO
STRIP_FROM_PATH =
INTERNAL_DOCS = NO
CASE_SENSE_NAMES = YES
SHORT_NAMES = NO
HIDE_SCOPE_NAMES = NO
VERBATIM_HEADERS = YES
SHOW_INCLUDE_FILES = NO
JAVADOC_AUTOBRIEF = YES
MULTILINE_CPP_IS_BRIEF = NO
DETAILS_AT_TOP = YES
INHERIT_DOCS = YES
INLINE_INFO = YES
SORT_MEMBER_DOCS = NO
DISTRIBUTE_GROUP_DOC = NO
TAB_SIZE = 2
GENERATE_TODOLIST = YES
GENERATE_TESTLIST = YES
GENERATE_BUGLIST = YES
GENERATE_DEPRECATEDLIST= YES
ALIASES =
ENABLED_SECTIONS =
MAX_INITIALIZER_LINES = 30
OPTIMIZE_OUTPUT_FOR_C = NO
OPTIMIZE_OUTPUT_JAVA = NO
SHOW_USED_FILES = YES
#---------------------------------------------------------------------------
# configuration options related to warning and progress messages
#---------------------------------------------------------------------------
QUIET = NO
WARNINGS = YES
WARN_IF_UNDOCUMENTED = YES
WARN_IF_DOC_ERROR = YES
WARN_FORMAT = "$file:$line: $text"
WARN_LOGFILE =
#---------------------------------------------------------------------------
# configuration options related to the input files
#---------------------------------------------------------------------------
INPUT = ../../libebml/src \
../../libebml/src/platform/win32 \
../../libebml/ebml \
../../libebml/ebml/c \
../src \
../matroska \
../matroska/c
FILE_PATTERNS = *.cpp \
*.h
RECURSIVE = NO
EXCLUDE =
EXCLUDE_SYMLINKS = NO
EXCLUDE_PATTERNS =
EXAMPLE_PATH =
EXAMPLE_PATTERNS =
EXAMPLE_RECURSIVE = NO
IMAGE_PATH =
INPUT_FILTER =
FILTER_SOURCE_FILES = NO
#---------------------------------------------------------------------------
# configuration options related to source browsing
#---------------------------------------------------------------------------
SOURCE_BROWSER = YES
INLINE_SOURCES = NO
STRIP_CODE_COMMENTS = YES
REFERENCED_BY_RELATION = NO
REFERENCES_RELATION = YES
#---------------------------------------------------------------------------
# configuration options related to the alphabetical class index
#---------------------------------------------------------------------------
ALPHABETICAL_INDEX = NO
COLS_IN_ALPHA_INDEX = 5
IGNORE_PREFIX =
#---------------------------------------------------------------------------
# configuration options related to the HTML output
#---------------------------------------------------------------------------
GENERATE_HTML = YES
HTML_OUTPUT = html
HTML_FILE_EXTENSION = .html
HTML_HEADER =
HTML_FOOTER =
HTML_STYLESHEET = libmatroska.css
HTML_ALIGN_MEMBERS = YES
GENERATE_HTMLHELP = NO
CHM_FILE =
HHC_LOCATION =
GENERATE_CHI = NO
BINARY_TOC = NO
TOC_EXPAND = NO
DISABLE_INDEX = NO
ENUM_VALUES_PER_LINE = 4
GENERATE_TREEVIEW = NO
TREEVIEW_WIDTH = 250
#---------------------------------------------------------------------------
# configuration options related to the LaTeX output
#---------------------------------------------------------------------------
GENERATE_LATEX = YES
LATEX_OUTPUT = latex
LATEX_CMD_NAME = latex
MAKEINDEX_CMD_NAME = makeindex
COMPACT_LATEX = YES
PAPER_TYPE = a4wide
EXTRA_PACKAGES =
LATEX_HEADER =
PDF_HYPERLINKS = YES
USE_PDFLATEX = YES
LATEX_BATCHMODE = NO
LATEX_HIDE_INDICES = NO
#---------------------------------------------------------------------------
# configuration options related to the RTF output
#---------------------------------------------------------------------------
GENERATE_RTF = YES
RTF_OUTPUT = rtf
COMPACT_RTF = NO
RTF_HYPERLINKS = YES
RTF_STYLESHEET_FILE =
RTF_EXTENSIONS_FILE =
#---------------------------------------------------------------------------
# configuration options related to the man page output
#---------------------------------------------------------------------------
GENERATE_MAN = NO
MAN_OUTPUT = man
MAN_EXTENSION = .3
MAN_LINKS = YES
#---------------------------------------------------------------------------
# configuration options related to the XML output
#---------------------------------------------------------------------------
GENERATE_XML = NO
XML_SCHEMA =
XML_DTD =
#---------------------------------------------------------------------------
# configuration options for the AutoGen Definitions output
#---------------------------------------------------------------------------
GENERATE_AUTOGEN_DEF = NO
#---------------------------------------------------------------------------
# configuration options related to the Perl module output
#---------------------------------------------------------------------------
GENERATE_PERLMOD = NO
PERLMOD_LATEX = NO
PERLMOD_PRETTY = YES
PERLMOD_MAKEVAR_PREFIX =
#---------------------------------------------------------------------------
# Configuration options related to the preprocessor
#---------------------------------------------------------------------------
ENABLE_PREPROCESSING = YES
MACRO_EXPANSION = NO
EXPAND_ONLY_PREDEF = NO
SEARCH_INCLUDES = YES
INCLUDE_PATH =
INCLUDE_FILE_PATTERNS =
PREDEFINED =
EXPAND_AS_DEFINED =
SKIP_FUNCTION_MACROS = YES
#---------------------------------------------------------------------------
# Configuration::addtions related to external references
#---------------------------------------------------------------------------
TAGFILES =
GENERATE_TAGFILE =
ALLEXTERNALS = NO
EXTERNAL_GROUPS = YES
PERL_PATH = /usr/bin/perl
#---------------------------------------------------------------------------
# Configuration options related to the dot tool
#---------------------------------------------------------------------------
CLASS_DIAGRAMS = YES
HIDE_UNDOC_RELATIONS = YES
HAVE_DOT = NO
CLASS_GRAPH = YES
COLLABORATION_GRAPH = YES
TEMPLATE_RELATIONS = YES
INCLUDE_GRAPH = YES
INCLUDED_BY_GRAPH = YES
GRAPHICAL_HIERARCHY = YES
DOT_IMAGE_FORMAT = png
DOT_PATH =
DOTFILE_DIRS =
MAX_DOT_GRAPH_WIDTH = 1024
MAX_DOT_GRAPH_HEIGHT = 1024
MAX_DOT_GRAPH_DEPTH = 0
GENERATE_LEGEND = YES
DOT_CLEANUP = YES
#---------------------------------------------------------------------------
# Configuration::addtions related to the search engine
#---------------------------------------------------------------------------
SEARCHENGINE = NO
CGI_NAME = search.cgi
CGI_URL =
DOC_URL =
DOC_ABSPATH =
BIN_ABSPATH = /usr/local/bin/
EXT_DOC_PATHS =

View File

@ -1,179 +1,179 @@
# libmatroska core Makefile (used in cygwin)
# $Id: Makefile 1254 2006-06-02 14:32:52Z mosu $
# Author: Steve Lhomme <robux4 @ users.sf.net>
# Author: Moritz Bunkus <moritz @ bunkus.org>
#
# The library is built without debug information. If you want
# debug information to be included then compile with
# 'make DEBUG=yes'.
#
# Paths
# BeOS wants the libs and headers in /boot/home/config
ifeq (BeOS,$(shell uname -s))
prefix=/boot/home/config
else
prefix=/usr/local
endif
libdir=$(prefix)/lib
includedir=$(prefix)/include/matroska
# Programs
CROSS =
CXX = $(CROSS)g++
LD = $(CXX)
AR = $(CROSS)ar
RANLIB = $(CROSS)ranlib
INSTALL = install
INSTALL_OPTS = -m 644
INSTALL_OPTS_LIB = -m 644
INSTALL_DIR_OPTS = -m 755
CWD=$(shell pwd)
# Options
LIBEBML_INCLUDE_DIR=$(CWD)/../../../libebml
LIBEBML_LIB_DIR=$(CWD)/../../../libebml/make/linux
EXTENSION=.cpp
ifeq (yes,$(DEBUG))
DEBUGFLAGS=-g -DDEBUG
endif
ifeq (Darwin,$(shell uname -s))
link=static
else
link=both
endif
targets_both = staticlib sharedlib
targets_shared = sharedlib
targets_static = staticlib
SRC_DIR=$(CWD)/../../src/
INCLUDE_DIR=$(CWD)/../../matroska
MUX_SRC_DIR=$(CWD)/../../test/mux/
TAG_SRC_DIR=$(CWD)/../../test/tags/
# Libraries
INCLUDE=-I$(CWD)/../.. -I$(LIBEBML_INCLUDE_DIR)
LIBS=
MUX_LIBS=-lmatroska -lebml $(LIBICONV)
# Names
LIBRARY=libmatroska.a
LIBRARY_SO=libmatroska.so
LIBRARY_SO_VER=libmatroska.so.6
# source-files
sources:=$(wildcard ${SRC_DIR}*$(EXTENSION))
# header files; replace .cxx extension with .h
headers:=$(patsubst %$(EXTENSION),%.h,$(sources))
# object files; replace .cxx extension with .o
objects:=$(patsubst %$(EXTENSION),%.o,$(sources))
objects_so:=$(patsubst %$(EXTENSION),%.lo,$(sources))
WARNINGFLAGS=-Wall -Wextra -Wno-unknown-pragmas -D_GNU_SOURCE -Wshadow
COMPILEFLAGS=$(DEBUGFLAGS) $(CXXFLAGS) $(CPPFLAGS) $(WARNINGFLAGS) $(INCLUDE)
LINKFLAGS=-L. -L$(LIBEBML_LIB_DIR) $(LDFLAGS)
DEPENDFLAGS = $(CXXFLAGS) $(INCLUDE)
all: $(targets_$(link))
staticlib: $(LIBRARY)
sharedlib: $(LIBRARY_SO)
lib:
@echo "Use the 'staticlib', 'sharedlib' or 'all' targets."
@false
# Build rules
%.o: %$(EXTENSION)
$(CXX) -c $(COMPILEFLAGS) -o $@ $<
%.lo: %$(EXTENSION)
$(CXX) -c $(COMPILEFLAGS) -fPIC -o $@ $<
$(LIBRARY): $(objects)
$(AR) rcvu $@ $(objects)
$(RANLIB) $@
$(LIBRARY_SO): $(objects_so)
$(CXX) -shared -Wl,-soname,$(LIBRARY_SO_VER) -o $(LIBRARY_SO_VER) $(objects_so) -lebml
rm -f $(LIBRARY_SO)
ln -s $(LIBRARY_SO_VER) $(LIBRARY_SO)
clean: cleantest
rm -f $(objects) $(objects_so)
rm -f $(LIBRARY)
rm -f $(LIBRARY_SO)
rm -f $(LIBRARY_SO_VER)
rm -f CORE
cleantest:
rm -f test6 test8 test9 test6.o test8.o test9.o
distclean dist-clean: clean
rm -f .depend
depend:
@echo Calculating dependecies:
@rm -f .depend
@touch .depend
@for i in $(sources); do \
o="`echo $$i | sed -e 's/\.c$$/.o/' -e 's/\.cpp$$/.o/'`" ; \
echo ' ' $$i: $$o ; \
$(CXX) $(DEPENDFLAGS) -MM -MT $$o $$i >> .depend ; \
done
test: test6 test9
test6: test6.o $(LIBRARY) $(LIBRARY_SO)
$(LD) -o $@ $(LINKFLAGS) $< $(MUX_LIBS)
test6.o: $(MUX_SRC_DIR)test6.cpp
$(CXX) -c $(COMPILEFLAGS) -o $@ $<
test8: test8.o $(LIBRARY) $(LIBRARY_SO)
$(LD) -o $@ $(LINKFLAGS) $< $(MUX_LIBS)
test8.o: $(MUX_SRC_DIR)test8.cpp
$(CXX) -c $(COMPILEFLAGS) -o $@ $<
test9: test9.o $(LIBRARY) $(LIBRARY_SO)
$(LD) -o $@ $(LINKFLAGS) $< $(MUX_LIBS)
test9.o: $(TAG_SRC_DIR)test9.cpp
$(CXX) -c $(COMPILEFLAGS) -o $@ $<
install: $(targets_$(link):%=install_%) install_headers
install_headers:
$(INSTALL) $(INSTALL_DIR_OPTS) -d $(DESTDIR)$(includedir)
for i in $(INCLUDE_DIR)/*.h; do \
$(INSTALL) $(INSTALL_OPTS) $$i $(DESTDIR)$(includedir) ; \
done
$(INSTALL) $(INSTALL_DIR_OPTS) -d $(DESTDIR)$(includedir)/c
for i in $(INCLUDE_DIR)/c/*.h; do \
$(INSTALL) $(INSTALL_OPTS) $$i $(DESTDIR)$(includedir)/c ; \
done
install_staticlib: $(LIBRARY)
$(INSTALL) $(INSTALL_DIR_OPTS) -d $(DESTDIR)$(libdir)
$(INSTALL) $(INSTALL_OPTS_LIB) $(LIBRARY) $(DESTDIR)$(libdir)
install_sharedlib: $(LIBRARY_SO)
$(INSTALL) $(INSTALL_DIR_OPTS) -d $(DESTDIR)$(libdir)
$(INSTALL) $(INSTALL_OPTS_LIB) $(LIBRARY_SO_VER) $(DESTDIR)$(libdir)
ln -fs $(LIBRARY_SO_VER) $(DESTDIR)$(libdir)/$(LIBRARY_SO)
ifneq ($(wildcard .depend),)
include .depend
endif
# DO NOT DELETE
# libmatroska core Makefile (used in cygwin)
# $Id: Makefile 1254 2006-06-02 14:32:52Z mosu $
# Author: Steve Lhomme <robux4 @ users.sf.net>
# Author: Moritz Bunkus <moritz @ bunkus.org>
#
# The library is built without debug information. If you want
# debug information to be included then compile with
# 'make DEBUG=yes'.
#
# Paths
# BeOS wants the libs and headers in /boot/home/config
ifeq (BeOS,$(shell uname -s))
prefix=/boot/home/config
else
prefix=/usr/local
endif
libdir=$(prefix)/lib
includedir=$(prefix)/include/matroska
# Programs
CROSS =
CXX = $(CROSS)g++
LD = $(CXX)
AR = $(CROSS)ar
RANLIB = $(CROSS)ranlib
INSTALL = install
INSTALL_OPTS = -m 644
INSTALL_OPTS_LIB = -m 644
INSTALL_DIR_OPTS = -m 755
CWD=$(shell pwd)
# Options
LIBEBML_INCLUDE_DIR=$(CWD)/../../../libebml
LIBEBML_LIB_DIR=$(CWD)/../../../libebml/make/linux
EXTENSION=.cpp
ifeq (yes,$(DEBUG))
DEBUGFLAGS=-g -DDEBUG
endif
ifeq (Darwin,$(shell uname -s))
link=static
else
link=both
endif
targets_both = staticlib sharedlib
targets_shared = sharedlib
targets_static = staticlib
SRC_DIR=$(CWD)/../../src/
INCLUDE_DIR=$(CWD)/../../matroska
MUX_SRC_DIR=$(CWD)/../../test/mux/
TAG_SRC_DIR=$(CWD)/../../test/tags/
# Libraries
INCLUDE=-I$(CWD)/../.. -I$(LIBEBML_INCLUDE_DIR)
LIBS=
MUX_LIBS=-lmatroska -lebml $(LIBICONV)
# Names
LIBRARY=libmatroska.a
LIBRARY_SO=libmatroska.so
LIBRARY_SO_VER=libmatroska.so.6
# source-files
sources:=$(wildcard ${SRC_DIR}*$(EXTENSION))
# header files; replace .cxx extension with .h
headers:=$(patsubst %$(EXTENSION),%.h,$(sources))
# object files; replace .cxx extension with .o
objects:=$(patsubst %$(EXTENSION),%.o,$(sources))
objects_so:=$(patsubst %$(EXTENSION),%.lo,$(sources))
WARNINGFLAGS=-Wall -Wextra -Wno-unknown-pragmas -D_GNU_SOURCE -Wshadow
COMPILEFLAGS=$(DEBUGFLAGS) $(CXXFLAGS) $(CPPFLAGS) $(WARNINGFLAGS) $(INCLUDE)
LINKFLAGS=-L. -L$(LIBEBML_LIB_DIR) $(LDFLAGS)
DEPENDFLAGS = $(CXXFLAGS) $(INCLUDE)
all: $(targets_$(link))
staticlib: $(LIBRARY)
sharedlib: $(LIBRARY_SO)
lib:
@echo "Use the 'staticlib', 'sharedlib' or 'all' targets."
@false
# Build rules
%.o: %$(EXTENSION)
$(CXX) -c $(COMPILEFLAGS) -o $@ $<
%.lo: %$(EXTENSION)
$(CXX) -c $(COMPILEFLAGS) -fPIC -o $@ $<
$(LIBRARY): $(objects)
$(AR) rcvu $@ $(objects)
$(RANLIB) $@
$(LIBRARY_SO): $(objects_so)
$(CXX) -shared -Wl,-soname,$(LIBRARY_SO_VER) -o $(LIBRARY_SO_VER) $(objects_so) -lebml
rm -f $(LIBRARY_SO)
ln -s $(LIBRARY_SO_VER) $(LIBRARY_SO)
clean: cleantest
rm -f $(objects) $(objects_so)
rm -f $(LIBRARY)
rm -f $(LIBRARY_SO)
rm -f $(LIBRARY_SO_VER)
rm -f CORE
cleantest:
rm -f test6 test8 test9 test6.o test8.o test9.o
distclean dist-clean: clean
rm -f .depend
depend:
@echo Calculating dependecies:
@rm -f .depend
@touch .depend
@for i in $(sources); do \
o="`echo $$i | sed -e 's/\.c$$/.o/' -e 's/\.cpp$$/.o/'`" ; \
echo ' ' $$i: $$o ; \
$(CXX) $(DEPENDFLAGS) -MM -MT $$o $$i >> .depend ; \
done
test: test6 test9
test6: test6.o $(LIBRARY) $(LIBRARY_SO)
$(LD) -o $@ $(LINKFLAGS) $< $(MUX_LIBS)
test6.o: $(MUX_SRC_DIR)test6.cpp
$(CXX) -c $(COMPILEFLAGS) -o $@ $<
test8: test8.o $(LIBRARY) $(LIBRARY_SO)
$(LD) -o $@ $(LINKFLAGS) $< $(MUX_LIBS)
test8.o: $(MUX_SRC_DIR)test8.cpp
$(CXX) -c $(COMPILEFLAGS) -o $@ $<
test9: test9.o $(LIBRARY) $(LIBRARY_SO)
$(LD) -o $@ $(LINKFLAGS) $< $(MUX_LIBS)
test9.o: $(TAG_SRC_DIR)test9.cpp
$(CXX) -c $(COMPILEFLAGS) -o $@ $<
install: $(targets_$(link):%=install_%) install_headers
install_headers:
$(INSTALL) $(INSTALL_DIR_OPTS) -d $(DESTDIR)$(includedir)
for i in $(INCLUDE_DIR)/*.h; do \
$(INSTALL) $(INSTALL_OPTS) $$i $(DESTDIR)$(includedir) ; \
done
$(INSTALL) $(INSTALL_DIR_OPTS) -d $(DESTDIR)$(includedir)/c
for i in $(INCLUDE_DIR)/c/*.h; do \
$(INSTALL) $(INSTALL_OPTS) $$i $(DESTDIR)$(includedir)/c ; \
done
install_staticlib: $(LIBRARY)
$(INSTALL) $(INSTALL_DIR_OPTS) -d $(DESTDIR)$(libdir)
$(INSTALL) $(INSTALL_OPTS_LIB) $(LIBRARY) $(DESTDIR)$(libdir)
install_sharedlib: $(LIBRARY_SO)
$(INSTALL) $(INSTALL_DIR_OPTS) -d $(DESTDIR)$(libdir)
$(INSTALL) $(INSTALL_OPTS_LIB) $(LIBRARY_SO_VER) $(DESTDIR)$(libdir)
ln -fs $(LIBRARY_SO_VER) $(DESTDIR)$(libdir)/$(LIBRARY_SO)
ifneq ($(wildcard .depend),)
include .depend
endif
# DO NOT DELETE

View File

@ -1,98 +1,98 @@
##
## This Makefile is made for cygwin, but might probably work on any standard UNIX too
##
#****************************************************************************
# DEBUG can be set to YES to include debugging info, or NO otherwise
DEBUG = YES
# PROFILE can be set to YES to include profiling info, or NO otherwise
PROFILE = NO
#****************************************************************************
CC = gcc
CXX = g++
LD = gcc
AR = ar rcvu
RANLIB = ranlib
DEPEND = makedepend
INDENT =indent --gnu-style -ut -ts6 -br -npsl -npcs
DELETE =rm -f
GLOBAL_CFLAGS = -Wall -Wno-unknown-pragmas -Wno-format
DEBUG_CFLAGS = -g -O0 -DDEBUG ${GLOBAL_CFLAGS}
RELEASE_CFLAGS = -O2 ${GLOBAL_CFLAGS}
P_OPTIONS = -pedantic
LIBS =
DEBUG_CXXFLAGS = ${DEBUG_CFLAGS}
RELEASE_CXXFLAGS = ${RELEASE_CFLAGS}
DEBUG_LDFLAGS = -g
RELEASE_LDFLAGS =
ifeq (YES, ${DEBUG})
CFLAGS = ${DEBUG_CFLAGS} ${INCS} ${P_OPTIONS}
CXXFLAGS = ${DEBUG_CXXFLAGS} ${INCS} ${P_OPTIONS}
LDFLAGS = ${DEBUG_LDFLAGS}
DEPENDFLAGS = ${DEBUG_CFLAGS} ${INCS}
else
CFLAGS = ${RELEASE_CFLAGS} ${INCS} ${P_OPTIONS}
CXXFLAGS = ${RELEASE_CXXFLAGS} ${INCS} ${P_OPTIONS}
LDFLAGS = ${RELEASE_LDFLAGS}
DEPENDFLAGS = ${RELEASE_CFLAGS} ${INCS}
endif
ifeq (YES, ${PROFILE})
CFLAGS := ${CFLAGS} -pg
CXXFLAGS := ${CXXFLAGS} -pg
LDFLAGS := ${LDFLAGS} -pg
endif
#****************************************************************************
# Preprocessor directives
#****************************************************************************
ifeq (YES, ${PROFILE})
DEFS =
else
DEFS =
endif
#****************************************************************************
# Include paths
#****************************************************************************
#INCS := -I/usr/include/g++-2 -I/usr/local/include
#INCS =
#****************************************************************************
# Makefile code common to all platforms
#****************************************************************************
CFLAGS := ${CFLAGS} ${DEFS}
CXXFLAGS := ${CXXFLAGS} ${DEFS}
#****************************************************************************
# General rules
#****************************************************************************
indent:
$(INDENT) --line-length 100 ${SRCS} ${SRCS_HEADERS}
$(DELETE) *.*~
indent80:
$(INDENT) --line-length 80 ${SRCS} ${SRCS_HEADERS}
$(DELETE) *.*~
clean:
rm -f core *.o *.so *.a *.exe
# what are the source dependencies
depend: $(SRCS)
$(DEPEND) $(DEPENDFLAGS) $(SRCS)
##
## This Makefile is made for cygwin, but might probably work on any standard UNIX too
##
#****************************************************************************
# DEBUG can be set to YES to include debugging info, or NO otherwise
DEBUG = YES
# PROFILE can be set to YES to include profiling info, or NO otherwise
PROFILE = NO
#****************************************************************************
CC = gcc
CXX = g++
LD = gcc
AR = ar rcvu
RANLIB = ranlib
DEPEND = makedepend
INDENT =indent --gnu-style -ut -ts6 -br -npsl -npcs
DELETE =rm -f
GLOBAL_CFLAGS = -Wall -Wno-unknown-pragmas -Wno-format
DEBUG_CFLAGS = -g -O0 -DDEBUG ${GLOBAL_CFLAGS}
RELEASE_CFLAGS = -O2 ${GLOBAL_CFLAGS}
P_OPTIONS = -pedantic
LIBS =
DEBUG_CXXFLAGS = ${DEBUG_CFLAGS}
RELEASE_CXXFLAGS = ${RELEASE_CFLAGS}
DEBUG_LDFLAGS = -g
RELEASE_LDFLAGS =
ifeq (YES, ${DEBUG})
CFLAGS = ${DEBUG_CFLAGS} ${INCS} ${P_OPTIONS}
CXXFLAGS = ${DEBUG_CXXFLAGS} ${INCS} ${P_OPTIONS}
LDFLAGS = ${DEBUG_LDFLAGS}
DEPENDFLAGS = ${DEBUG_CFLAGS} ${INCS}
else
CFLAGS = ${RELEASE_CFLAGS} ${INCS} ${P_OPTIONS}
CXXFLAGS = ${RELEASE_CXXFLAGS} ${INCS} ${P_OPTIONS}
LDFLAGS = ${RELEASE_LDFLAGS}
DEPENDFLAGS = ${RELEASE_CFLAGS} ${INCS}
endif
ifeq (YES, ${PROFILE})
CFLAGS := ${CFLAGS} -pg
CXXFLAGS := ${CXXFLAGS} -pg
LDFLAGS := ${LDFLAGS} -pg
endif
#****************************************************************************
# Preprocessor directives
#****************************************************************************
ifeq (YES, ${PROFILE})
DEFS =
else
DEFS =
endif
#****************************************************************************
# Include paths
#****************************************************************************
#INCS := -I/usr/include/g++-2 -I/usr/local/include
#INCS =
#****************************************************************************
# Makefile code common to all platforms
#****************************************************************************
CFLAGS := ${CFLAGS} ${DEFS}
CXXFLAGS := ${CXXFLAGS} ${DEFS}
#****************************************************************************
# General rules
#****************************************************************************
indent:
$(INDENT) --line-length 100 ${SRCS} ${SRCS_HEADERS}
$(DELETE) *.*~
indent80:
$(INDENT) --line-length 80 ${SRCS} ${SRCS_HEADERS}
$(DELETE) *.*~
clean:
rm -f core *.o *.so *.a *.exe
# what are the source dependencies
depend: $(SRCS)
$(DEPEND) $(DEPENDFLAGS) $(SRCS)

View File

@ -1,18 +1,18 @@
#!/bin/sh
# A small script that looks for duplicate EBML IDs in all of libmatroska's
# source files.
echo 'Duplicate IDs:'
grep -h '^EbmlId.*_TheId' ../../src/*cpp | \
sed -e 's/TheId/TheId /' | \
awk '{ print $3 }' | \
sed -e 's/(//' -e 's/,//' | \
sort | \
uniq -d | \
( while read id ; do
echo ''
echo ${id}:
grep -i $id ../../src/*cpp
done )
#!/bin/sh
# A small script that looks for duplicate EBML IDs in all of libmatroska's
# source files.
echo 'Duplicate IDs:'
grep -h '^EbmlId.*_TheId' ../../src/*cpp | \
sed -e 's/TheId/TheId /' | \
awk '{ print $3 }' | \
sed -e 's/(//' -e 's/,//' | \
sort | \
uniq -d | \
( while read id ; do
echo ''
echo ${id}:
grep -i $id ../../src/*cpp
done )

View File

@ -1,7 +1,7 @@
#!/usr/bin/sh
# you should have "doxygen" in your path
# http://www.doxygen.org/
echo make Documentation
doxygen Doxyfile > Doxygen.log.txt 2> Doxygen.err.txt
#!/usr/bin/sh
# you should have "doxygen" in your path
# http://www.doxygen.org/
echo make Documentation
doxygen Doxyfile > Doxygen.log.txt 2> Doxygen.err.txt

View File

@ -1,163 +1,163 @@
/****************************************************************************
** libmatroska : parse Matroska files, see http://www.matroska.org/
**
** <file/class description>
**
** Copyright (C) 2002-2010 Steve Lhomme. All rights reserved.
**
** This file is part of libmatroska.
**
** This library is free software; you can redistribute it and/or
** modify it under the terms of the GNU Lesser General Public
** License as published by the Free Software Foundation; either
** version 2.1 of the License, or (at your option) any later version.
**
** This library is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
** Lesser General Public License for more details.
**
** You should have received a copy of the GNU Lesser General Public
** License along with this library; if not, write to the Free Software
** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
**
** See http://www.matroska.org/license/lgpl/ for LGPL licensing information.**
** Contact license@matroska.org if any conditions of this licensing are
** not clear to you.
**
**********************************************************************/
/*!
\file
\version \$Id: FileKax.h,v 1.5 2004/04/14 23:26:17 robux4 Exp $
\author Steve Lhomme <robux4 @ users.sf.net>
*/
#ifndef LIBMATROSKA_FILE_H
#define LIBMATROSKA_FILE_H
//#include <vector>
#include "matroska/KaxTypes.h"
#include "ebml/IOCallback.h"
//#include "MainHeader.h"
//#include "TrackType.h"
//#include "StreamInfo.h"
//#include "Cluster.h"
//#include "CodecHeader.h"
using namespace LIBEBML_NAMESPACE;
START_LIBMATROSKA_NAMESPACE
//class Track;
//class Frame;
/*!
\class MATROSKA_DLL_API FileMatroska
\brief General container of all the parameters and data of an Matroska file
\todo Handle the filename and next filename
\todo Handle the IOCallback selection/type
*/
class MATROSKA_DLL_API FileMatroska {
public:
FileMatroska(IOCallback & output);
~FileMatroska();
#ifdef OLD
filepos_t RenderHead(const std::string & aEncoderApp);
uint32 ReadHead();
uint32 ReadTracks();
uint32 ReadCodec();
void Close(const uint32 aTimeLength);
inline void type_SetInfo(const std::string & aStr) {myMainHeader.type_SetInfo(aStr);}
inline void type_SetAds(const std::string & aStr) {myMainHeader.type_SetAds(aStr);}
inline void type_SetSize(const std::string & aStr) {myMainHeader.type_SetSize(aStr);}
inline void type_SetSize(uint64 aSize) {myMainHeader.type_SetSize(aSize);}
inline uint8 GetTrackNumber() const { return myTracks.size(); }
void track_SetName(Track * aTrack, const std::string & aName);
void track_SetLaced(Track * aTrack, bool bLaced = true);
Track * CreateTrack(const track_type aType);
inline Track * GetTrack(const uint8 aTrackNb) const
{
if (aTrackNb > myTracks.size())
return NULL;
else
return myTracks[aTrackNb-1];
}
void Track_GetInfo(const Track * aTrack, TrackInfo & aTrackInfo) const;
void Track_SetInfo_Audio(Track * aTrack, const TrackInfoAudio & aTrackInfo);
void Track_GetInfo_Audio(const Track * aTrack, TrackInfoAudio & aTrackInfo) const;
void Track_SetInfo_Video(Track * aTrack, const TrackInfoVideo & aTrackInfo);
void Track_GetInfo_Video(const Track * aTrack, TrackInfoVideo & aTrackInfo) const;
void SelectReadingTrack(Track * aTrack, bool select = true);
/*!
\return wether the frame has been added or not
*/
bool AddFrame(Track * aTrack, const uint32 aTimecode, const binary *aFrame, const uint32 aFrameSize,
bool aKeyFrame = true, bool aBFrame = false);
/*!
\return wether the frame has been read or not
*/
bool ReadFrame(Track * & aTrack, uint32 & aTimecode, const binary * & aFrame, uint32 & aFrameSize,
bool & aKeyFrame, bool & aBFrame);
/*
Render the pending cluster to file
*/
void Flush();
void SetMaxClusterSize(const uint32 value);
void SetMinClusterSize(const uint32 value) {myMinClusterSize = value;}
protected:
MainHeader myMainHeader;
std::vector<Track *> myTracks;
std::vector<uint8> mySelectedTracks;
// Track *findTrack(Track * aTrack) const;
Cluster myCurrWriteCluster; /// \todo merge with the write one ?
uint32 myReadBlockNumber;
Cluster myCurrReadCluster;
binary * myCurrReadBlock; ///< The buffer containing the current read block
uint32 myCurrReadBlockSize; ///< The size of the buffer containing the current read block
uint8 myCurrReadBlockTrack; ///< The track number of the current track to read
uint32 myMaxClusterSize;
uint32 myMinClusterSize;
StreamInfo myStreamInfo;
CodecHeader myCodecHeader;
inline bool IsMyTrack(const Track * aTrack) const;
inline bool IsReadingTrack(const uint8 aTrackNum) const;
#endif // OLD
IOCallback & myFile;
};
END_LIBMATROSKA_NAMESPACE
#ifdef __cplusplus
extern "C" {
#endif
MATROSKA_DLL_API void matroska_init();
MATROSKA_DLL_API void matroska_done();
#ifdef __cplusplus
}
#endif
#endif // FILE_KAX_HPP
/****************************************************************************
** libmatroska : parse Matroska files, see http://www.matroska.org/
**
** <file/class description>
**
** Copyright (C) 2002-2010 Steve Lhomme. All rights reserved.
**
** This file is part of libmatroska.
**
** This library is free software; you can redistribute it and/or
** modify it under the terms of the GNU Lesser General Public
** License as published by the Free Software Foundation; either
** version 2.1 of the License, or (at your option) any later version.
**
** This library is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
** Lesser General Public License for more details.
**
** You should have received a copy of the GNU Lesser General Public
** License along with this library; if not, write to the Free Software
** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
**
** See http://www.matroska.org/license/lgpl/ for LGPL licensing information.**
** Contact license@matroska.org if any conditions of this licensing are
** not clear to you.
**
**********************************************************************/
/*!
\file
\version \$Id: FileKax.h,v 1.5 2004/04/14 23:26:17 robux4 Exp $
\author Steve Lhomme <robux4 @ users.sf.net>
*/
#ifndef LIBMATROSKA_FILE_H
#define LIBMATROSKA_FILE_H
//#include <vector>
#include "matroska/KaxTypes.h"
#include "ebml/IOCallback.h"
//#include "MainHeader.h"
//#include "TrackType.h"
//#include "StreamInfo.h"
//#include "Cluster.h"
//#include "CodecHeader.h"
using namespace LIBEBML_NAMESPACE;
START_LIBMATROSKA_NAMESPACE
//class Track;
//class Frame;
/*!
\class MATROSKA_DLL_API FileMatroska
\brief General container of all the parameters and data of an Matroska file
\todo Handle the filename and next filename
\todo Handle the IOCallback selection/type
*/
class MATROSKA_DLL_API FileMatroska {
public:
FileMatroska(IOCallback & output);
~FileMatroska();
#ifdef OLD
filepos_t RenderHead(const std::string & aEncoderApp);
uint32 ReadHead();
uint32 ReadTracks();
uint32 ReadCodec();
void Close(const uint32 aTimeLength);
inline void type_SetInfo(const std::string & aStr) {myMainHeader.type_SetInfo(aStr);}
inline void type_SetAds(const std::string & aStr) {myMainHeader.type_SetAds(aStr);}
inline void type_SetSize(const std::string & aStr) {myMainHeader.type_SetSize(aStr);}
inline void type_SetSize(uint64 aSize) {myMainHeader.type_SetSize(aSize);}
inline uint8 GetTrackNumber() const { return myTracks.size(); }
void track_SetName(Track * aTrack, const std::string & aName);
void track_SetLaced(Track * aTrack, bool bLaced = true);
Track * CreateTrack(const track_type aType);
inline Track * GetTrack(const uint8 aTrackNb) const
{
if (aTrackNb > myTracks.size())
return NULL;
else
return myTracks[aTrackNb-1];
}
void Track_GetInfo(const Track * aTrack, TrackInfo & aTrackInfo) const;
void Track_SetInfo_Audio(Track * aTrack, const TrackInfoAudio & aTrackInfo);
void Track_GetInfo_Audio(const Track * aTrack, TrackInfoAudio & aTrackInfo) const;
void Track_SetInfo_Video(Track * aTrack, const TrackInfoVideo & aTrackInfo);
void Track_GetInfo_Video(const Track * aTrack, TrackInfoVideo & aTrackInfo) const;
void SelectReadingTrack(Track * aTrack, bool select = true);
/*!
\return wether the frame has been added or not
*/
bool AddFrame(Track * aTrack, const uint32 aTimecode, const binary *aFrame, const uint32 aFrameSize,
bool aKeyFrame = true, bool aBFrame = false);
/*!
\return wether the frame has been read or not
*/
bool ReadFrame(Track * & aTrack, uint32 & aTimecode, const binary * & aFrame, uint32 & aFrameSize,
bool & aKeyFrame, bool & aBFrame);
/*
Render the pending cluster to file
*/
void Flush();
void SetMaxClusterSize(const uint32 value);
void SetMinClusterSize(const uint32 value) {myMinClusterSize = value;}
protected:
MainHeader myMainHeader;
std::vector<Track *> myTracks;
std::vector<uint8> mySelectedTracks;
// Track *findTrack(Track * aTrack) const;
Cluster myCurrWriteCluster; /// \todo merge with the write one ?
uint32 myReadBlockNumber;
Cluster myCurrReadCluster;
binary * myCurrReadBlock; ///< The buffer containing the current read block
uint32 myCurrReadBlockSize; ///< The size of the buffer containing the current read block
uint8 myCurrReadBlockTrack; ///< The track number of the current track to read
uint32 myMaxClusterSize;
uint32 myMinClusterSize;
StreamInfo myStreamInfo;
CodecHeader myCodecHeader;
inline bool IsMyTrack(const Track * aTrack) const;
inline bool IsReadingTrack(const uint8 aTrackNum) const;
#endif // OLD
IOCallback & myFile;
};
END_LIBMATROSKA_NAMESPACE
#ifdef __cplusplus
extern "C" {
#endif
MATROSKA_DLL_API void matroska_init();
MATROSKA_DLL_API void matroska_done();
#ifdef __cplusplus
}
#endif
#endif // FILE_KAX_HPP

View File

@ -1,70 +1,70 @@
/****************************************************************************
** libmatroska : parse Matroska files, see http://www.matroska.org/
**
** <file/class description>
**
** Copyright (C) 2002-2010 Steve Lhomme. All rights reserved.
**
** This library is free software; you can redistribute it and/or
** modify it under the terms of the GNU Lesser General Public
** License as published by the Free Software Foundation; either
** version 2.1 of the License, or (at your option) any later version.
**
** This library is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
** Lesser General Public License for more details.
**
** You should have received a copy of the GNU Lesser General Public
** License along with this library; if not, write to the Free Software
** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
**
** See http://www.matroska.org/license/lgpl/ for LGPL licensing information.**
** Contact license@matroska.org if any conditions of this licensing are
** not clear to you.
**
**********************************************************************/
/*!
\file
\version \$Id: KaxConfig.h,v 1.7 2004/04/14 23:26:17 robux4 Exp $
\author Steve Lhomme <robux4 @ users.sf.net>
\author Moritz Bunkus <moritz @ bunkus.org>
*/
#ifndef LIBMATROSKA_CONFIG_H
#define LIBMATROSKA_CONFIG_H
#define LIBMATROSKA_NAMESPACE libmatroska
#if defined(NO_NAMESPACE) // for older GCC
# define START_LIBMATROSKA_NAMESPACE
# define END_LIBMATROSKA_NAMESPACE
#else // NO_NAMESPACE
# define START_LIBMATROSKA_NAMESPACE namespace LIBMATROSKA_NAMESPACE {
# define END_LIBMATROSKA_NAMESPACE };
#endif // NO_NAMESPACE
// There are special implementations for certain platforms. For example on Windows
// we use the Win32 file API. here we set the appropriate macros.
#if defined(_WIN32)||defined(WIN32)
# if defined(MATROSKA_DLL)
# if defined(MATROSKA_DLL_EXPORT)
# define MATROSKA_DLL_API __declspec(dllexport)
# else // MATROSKA_DLL_EXPORT
# define MATROSKA_DLL_API __declspec(dllimport)
# endif // MATROSKA_DLL_EXPORT
# else // MATROSKA_DLL
# define MATROSKA_DLL_API
# endif // MATROSKA_DLL
#else
# define MATROSKA_DLL_API
#endif
#if !defined(MATROSKA_VERSION)
#define MATROSKA_VERSION 2
#endif // MATROSKA_VERSION
#endif // LIBMATROSKA_CONFIG_H
/****************************************************************************
** libmatroska : parse Matroska files, see http://www.matroska.org/
**
** <file/class description>
**
** Copyright (C) 2002-2010 Steve Lhomme. All rights reserved.
**
** This library is free software; you can redistribute it and/or
** modify it under the terms of the GNU Lesser General Public
** License as published by the Free Software Foundation; either
** version 2.1 of the License, or (at your option) any later version.
**
** This library is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
** Lesser General Public License for more details.
**
** You should have received a copy of the GNU Lesser General Public
** License along with this library; if not, write to the Free Software
** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
**
** See http://www.matroska.org/license/lgpl/ for LGPL licensing information.**
** Contact license@matroska.org if any conditions of this licensing are
** not clear to you.
**
**********************************************************************/
/*!
\file
\version \$Id: KaxConfig.h,v 1.7 2004/04/14 23:26:17 robux4 Exp $
\author Steve Lhomme <robux4 @ users.sf.net>
\author Moritz Bunkus <moritz @ bunkus.org>
*/
#ifndef LIBMATROSKA_CONFIG_H
#define LIBMATROSKA_CONFIG_H
#define LIBMATROSKA_NAMESPACE libmatroska
#if defined(NO_NAMESPACE) // for older GCC
# define START_LIBMATROSKA_NAMESPACE
# define END_LIBMATROSKA_NAMESPACE
#else // NO_NAMESPACE
# define START_LIBMATROSKA_NAMESPACE namespace LIBMATROSKA_NAMESPACE {
# define END_LIBMATROSKA_NAMESPACE };
#endif // NO_NAMESPACE
// There are special implementations for certain platforms. For example on Windows
// we use the Win32 file API. here we set the appropriate macros.
#if defined(_WIN32)||defined(WIN32)
# if defined(MATROSKA_DLL)
# if defined(MATROSKA_DLL_EXPORT)
# define MATROSKA_DLL_API __declspec(dllexport)
# else // MATROSKA_DLL_EXPORT
# define MATROSKA_DLL_API __declspec(dllimport)
# endif // MATROSKA_DLL_EXPORT
# else // MATROSKA_DLL
# define MATROSKA_DLL_API
# endif // MATROSKA_DLL
#else
# define MATROSKA_DLL_API
#endif
#if !defined(MATROSKA_VERSION)
#define MATROSKA_VERSION 2
#endif // MATROSKA_VERSION
#endif // LIBMATROSKA_CONFIG_H

View File

@ -1,62 +1,62 @@
/****************************************************************************
** libmatroska : parse Matroska files, see http://www.matroska.org/
**
** <file/class MATROSKA_DLL_API description>
**
** Copyright (C) 2002-2010 Steve Lhomme. All rights reserved.
**
** This file is part of libmatroska.
**
** This library is free software; you can redistribute it and/or
** modify it under the terms of the GNU Lesser General Public
** License as published by the Free Software Foundation; either
** version 2.1 of the License, or (at your option) any later version.
**
** This library is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
** Lesser General Public License for more details.
**
** You should have received a copy of the GNU Lesser General Public
** License along with this library; if not, write to the Free Software
** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
**
** See http://www.matroska.org/license/lgpl/ for LGPL licensing information.**
** Contact license@matroska.org if any conditions of this licensing are
** not clear to you.
**
**********************************************************************/
/*!
\file
\version \$Id: KaxSegment.h,v 1.8 2004/04/14 23:26:17 robux4 Exp $
\author Steve Lhomme <robux4 @ users.sf.net>
*/
#ifndef LIBMATROSKA_SEGMENT_H
#define LIBMATROSKA_SEGMENT_H
#include "matroska/KaxTypes.h"
#include "ebml/EbmlMaster.h"
#include "matroska/KaxDefines.h"
using namespace LIBEBML_NAMESPACE;
START_LIBMATROSKA_NAMESPACE
DECLARE_MKX_MASTER_CONS(KaxSegment)
public:
/*!
\brief give the position of the element in the segment
*/
uint64 GetRelativePosition(const EbmlElement & Elt) const;
uint64 GetRelativePosition(uint64 aGlobalPosition) const;
/*!
\brief give the position of the element in the file
*/
uint64 GetGlobalPosition(uint64 aRelativePosition) const;
};
END_LIBMATROSKA_NAMESPACE
#endif // LIBMATROSKA_SEGMENT_H
/****************************************************************************
** libmatroska : parse Matroska files, see http://www.matroska.org/
**
** <file/class MATROSKA_DLL_API description>
**
** Copyright (C) 2002-2010 Steve Lhomme. All rights reserved.
**
** This file is part of libmatroska.
**
** This library is free software; you can redistribute it and/or
** modify it under the terms of the GNU Lesser General Public
** License as published by the Free Software Foundation; either
** version 2.1 of the License, or (at your option) any later version.
**
** This library is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
** Lesser General Public License for more details.
**
** You should have received a copy of the GNU Lesser General Public
** License along with this library; if not, write to the Free Software
** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
**
** See http://www.matroska.org/license/lgpl/ for LGPL licensing information.**
** Contact license@matroska.org if any conditions of this licensing are
** not clear to you.
**
**********************************************************************/
/*!
\file
\version \$Id: KaxSegment.h,v 1.8 2004/04/14 23:26:17 robux4 Exp $
\author Steve Lhomme <robux4 @ users.sf.net>
*/
#ifndef LIBMATROSKA_SEGMENT_H
#define LIBMATROSKA_SEGMENT_H
#include "matroska/KaxTypes.h"
#include "ebml/EbmlMaster.h"
#include "matroska/KaxDefines.h"
using namespace LIBEBML_NAMESPACE;
START_LIBMATROSKA_NAMESPACE
DECLARE_MKX_MASTER_CONS(KaxSegment)
public:
/*!
\brief give the position of the element in the segment
*/
uint64 GetRelativePosition(const EbmlElement & Elt) const;
uint64 GetRelativePosition(uint64 aGlobalPosition) const;
/*!
\brief give the position of the element in the file
*/
uint64 GetGlobalPosition(uint64 aRelativePosition) const;
};
END_LIBMATROSKA_NAMESPACE
#endif // LIBMATROSKA_SEGMENT_H

View File

@ -1,59 +1,59 @@
/****************************************************************************
** libmatroska : parse Matroska files, see http://www.matroska.org/
**
** <file/class description>
**
** Copyright (C) 2002-2010 Steve Lhomme. All rights reserved.
**
** This file is part of libmatroska.
**
** This library is free software; you can redistribute it and/or
** modify it under the terms of the GNU Lesser General Public
** License as published by the Free Software Foundation; either
** version 2.1 of the License, or (at your option) any later version.
**
** This library is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
** Lesser General Public License for more details.
**
** You should have received a copy of the GNU Lesser General Public
** License along with this library; if not, write to the Free Software
** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
**
** See http://www.matroska.org/license/lgpl/ for LGPL licensing information.**
** Contact license@matroska.org if any conditions of this licensing are
** not clear to you.
**
**********************************************************************/
/*!
\file
\version \$Id: KaxTypes.h,v 1.4 2004/04/14 23:26:17 robux4 Exp $
*/
#ifndef LIBMATROSKA_TYPES_H
#define LIBMATROSKA_TYPES_H
#include "matroska/KaxConfig.h"
#include "ebml/EbmlTypes.h"
#include "matroska/c/libmatroska_t.h"
START_LIBMATROSKA_NAMESPACE
enum LacingType {
LACING_NONE = 0,
LACING_XIPH,
LACING_FIXED,
LACING_EBML,
LACING_AUTO
};
enum BlockBlobType {
BLOCK_BLOB_NO_SIMPLE = 0,
BLOCK_BLOB_SIMPLE_AUTO,
BLOCK_BLOB_ALWAYS_SIMPLE,
};
END_LIBMATROSKA_NAMESPACE
#endif // LIBMATROSKA_TYPES_H
/****************************************************************************
** libmatroska : parse Matroska files, see http://www.matroska.org/
**
** <file/class description>
**
** Copyright (C) 2002-2010 Steve Lhomme. All rights reserved.
**
** This file is part of libmatroska.
**
** This library is free software; you can redistribute it and/or
** modify it under the terms of the GNU Lesser General Public
** License as published by the Free Software Foundation; either
** version 2.1 of the License, or (at your option) any later version.
**
** This library is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
** Lesser General Public License for more details.
**
** You should have received a copy of the GNU Lesser General Public
** License along with this library; if not, write to the Free Software
** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
**
** See http://www.matroska.org/license/lgpl/ for LGPL licensing information.**
** Contact license@matroska.org if any conditions of this licensing are
** not clear to you.
**
**********************************************************************/
/*!
\file
\version \$Id: KaxTypes.h,v 1.4 2004/04/14 23:26:17 robux4 Exp $
*/
#ifndef LIBMATROSKA_TYPES_H
#define LIBMATROSKA_TYPES_H
#include "matroska/KaxConfig.h"
#include "ebml/EbmlTypes.h"
#include "matroska/c/libmatroska_t.h"
START_LIBMATROSKA_NAMESPACE
enum LacingType {
LACING_NONE = 0,
LACING_XIPH,
LACING_FIXED,
LACING_EBML,
LACING_AUTO
};
enum BlockBlobType {
BLOCK_BLOB_NO_SIMPLE = 0,
BLOCK_BLOB_SIMPLE_AUTO,
BLOCK_BLOB_ALWAYS_SIMPLE,
};
END_LIBMATROSKA_NAMESPACE
#endif // LIBMATROSKA_TYPES_H

File diff suppressed because it is too large Load Diff

View File

@ -1,10 +1,10 @@
## libmatroska Makefile
## (c) 2002 Steve Lhomme
## This software is licensed under the LGPL, see LGPL.txt
all: endian
echo "Making endianess tests"
(cd endian; make)
clean:
echo "Cleaning all tests"
(cd endian; make $@)
## libmatroska Makefile
## (c) 2002 Steve Lhomme
## This software is licensed under the LGPL, see LGPL.txt
all: endian
echo "Making endianess tests"
(cd endian; make)
clean:
echo "Cleaning all tests"
(cd endian; make $@)

View File

@ -1,62 +1,62 @@
# libmatroska core Makefile (used in cygwin)
# $Id: Makefile 640 2004-07-09 21:05:36Z mosu $
# Options
EXTENSION=.cpp
CXXFLAGS=-g -DDEBUG -Wall -Wno-unknown-pragmas -DWIN32 -I../../src/
LDFLAGS=
SRC_DIR=../../src/
# Programs
CXX=g++ -c
LD=g++
DEP=$(CXX) -MM
DEPEND = makedepend
AR = ar rcvu
RANLIB = ranlib
# Librarires
INCLUDE=
LIBS=
# Names
PROGRAM=test00
# source-files
sources:=$(wildcard ${SRC_DIR}*$(EXTENSION))
# header files; replace .cxx extension with .h
headers:=$(patsubst %$(EXTENSION),%.hpp,$(sources))
# files holding dependency information; replace .cxx extension with .dep
dependencies:=$(patsubst %$(EXTENSION),%.dep,$(sources))
# object files; replace .cxx extension with .o
objects:=$(patsubst %$(EXTENSION),%.o,$(sources))
OBJ=$(objects) test00.o
DEPENDFLAGS = ${CXXFLAGS} ${INCLUDE}
# Build rules
%.o: %$(EXTENSION)
$(CXX) $(CXXFLAGS) $(INCLUDE) -o $@ $<
$(PROGRAM): $(OBJ)
# $(AR) $@ $(objects)
# $(RANLIB) $@
$(LD) $(LDFLAGS) -o $@ $^ $(LIBS)
${LD} -o $@ ${LDFLAGS} ${OBJ} ${LIBS} ${EXTRA_LIBS}
clean:
rm -f $(OBJ)
rm -f $(dependencies)
rm -f $(PROGRAM)
rm -f CORE
# what are the source dependencies
depend: $(sources)
$(DEPEND) $(DEPENDFLAGS) $(sources)
# DO NOT DELETE
# libmatroska core Makefile (used in cygwin)
# $Id: Makefile 640 2004-07-09 21:05:36Z mosu $
# Options
EXTENSION=.cpp
CXXFLAGS=-g -DDEBUG -Wall -Wno-unknown-pragmas -DWIN32 -I../../src/
LDFLAGS=
SRC_DIR=../../src/
# Programs
CXX=g++ -c
LD=g++
DEP=$(CXX) -MM
DEPEND = makedepend
AR = ar rcvu
RANLIB = ranlib
# Librarires
INCLUDE=
LIBS=
# Names
PROGRAM=test00
# source-files
sources:=$(wildcard ${SRC_DIR}*$(EXTENSION))
# header files; replace .cxx extension with .h
headers:=$(patsubst %$(EXTENSION),%.hpp,$(sources))
# files holding dependency information; replace .cxx extension with .dep
dependencies:=$(patsubst %$(EXTENSION),%.dep,$(sources))
# object files; replace .cxx extension with .o
objects:=$(patsubst %$(EXTENSION),%.o,$(sources))
OBJ=$(objects) test00.o
DEPENDFLAGS = ${CXXFLAGS} ${INCLUDE}
# Build rules
%.o: %$(EXTENSION)
$(CXX) $(CXXFLAGS) $(INCLUDE) -o $@ $<
$(PROGRAM): $(OBJ)
# $(AR) $@ $(objects)
# $(RANLIB) $@
$(LD) $(LDFLAGS) -o $@ $^ $(LIBS)
${LD} -o $@ ${LDFLAGS} ${OBJ} ${LIBS} ${EXTRA_LIBS}
clean:
rm -f $(OBJ)
rm -f $(dependencies)
rm -f $(PROGRAM)
rm -f CORE
# what are the source dependencies
depend: $(sources)
$(DEPEND) $(DEPENDFLAGS) $(sources)
# DO NOT DELETE