Rudimentary SSA parser.
[libsub.git] / src / wscript
1 from waflib import TaskGen
2
3 def build(bld):
4     if bld.env.STATIC:
5         obj = bld(features='cxx cxxstlib')
6     else:
7         obj = bld(features='cxx cxxshlib')
8
9     obj.name = 'libsub%s' % bld.env.API_VERSION
10     obj.target = 'sub%s' % bld.env.API_VERSION
11     obj.uselib = 'CXML DCP BOOST_FILESYSTEM BOOST_LOCALE BOOST_REGEX ASDCPLIB_CTH'
12     obj.use = 'libkumu-libsub%s libasdcp-libsub%s' % (bld.env.API_VERSION, bld.env.API_VERSION)
13     obj.export_includes = ['.']
14     obj.source = """
15                  colour.cc
16                  dcp_reader.cc
17                  effect.cc
18                  exceptions.cc
19                  font_size.cc
20                  interop_dcp_reader.cc
21                  iso6937.cc
22                  iso6937_tables.cc
23                  rational.cc
24                  raw_subtitle.cc
25                  reader.cc
26                  reader_factory.cc
27                  smpte_dcp_reader.cc
28                  ssa_reader.cc
29                  stl_binary_reader.cc
30                  stl_binary_tables.cc
31                  stl_binary_writer.cc
32                  stl_text_reader.cc
33                  stl_util.cc
34                  sub_time.cc
35                  subrip_reader.cc
36                  subtitle.cc
37                  util.cc
38                  vertical_reference.cc
39                  vertical_position.cc
40                  dcp/font.cc
41                  dcp/interop_load_font.cc
42                  dcp/smpte_load_font.cc
43                  dcp/subtitle.cc
44                  dcp/text.cc
45                  """
46
47     headers = """
48               collect.h
49               colour.h
50               dcp_reader.h
51               effect.h
52               font_size.h
53               interop_dcp_reader.h
54               rational.h
55               raw_subtitle.h
56               reader.h
57               smpte_dcp_reader.h
58               ssa_reader.h
59               stl_binary_tables.h
60               stl_binary_reader.h
61               stl_binary_writer.h
62               stl_text_reader.h
63               sub_time.h
64               subrip_reader.h
65               subtitle.h
66               vertical_position.h
67               vertical_reference.h
68               """
69
70     bld.install_files('${PREFIX}/include/libsub%s/sub' % bld.env.API_VERSION, headers)
71     if bld.env.STATIC:
72         bld.install_files('${PREFIX}/lib', 'libsub%s.a' % bld.env.API_VERSION)