Split examiner parts off decoder.
[dcpomatic.git] / src / lib / wscript
1 import os
2 import i18n
3
4 sources = """
5           analyse_audio_job.cc
6           audio_analysis.cc
7           audio_buffers.cc
8           audio_content.cc
9           audio_decoder.cc
10           audio_mapping.cc
11           audio_source.cc
12           black_decoder.cc
13           config.cc
14           combiner.cc
15           content.cc
16           cross.cc
17           dci_metadata.cc
18           dcp_content_type.cc
19           dcp_video_frame.cc
20           decoder.cc
21           dolby_cp750.cc
22           encoder.cc
23           examine_content_job.cc
24           exceptions.cc
25           filter_graph.cc
26           ffmpeg.cc
27           ffmpeg_content.cc
28           ffmpeg_decoder.cc
29           ffmpeg_examiner.cc
30           film.cc
31           filter.cc
32           image.cc
33           imagemagick_content.cc
34           imagemagick_decoder.cc
35           imagemagick_examiner.cc
36           job.cc
37           job_manager.cc
38           log.cc
39           lut.cc
40           null_content.cc
41           player.cc
42           playlist.cc
43           ratio.cc
44           scp_dcp_job.cc
45           scaler.cc
46           server.cc
47           silence_decoder.cc
48           sndfile_content.cc
49           sndfile_decoder.cc
50           sound_processor.cc
51           subtitle.cc
52           timer.cc
53           transcode_job.cc
54           transcoder.cc
55           types.cc
56           ui_signaller.cc
57           util.cc
58           video_content.cc
59           video_decoder.cc
60           video_source.cc
61           writer.cc
62           """
63
64 def build(bld):
65     if bld.env.STATIC:
66         obj = bld(features = 'cxx cxxstlib')
67     else:
68         obj = bld(features = 'cxx cxxshlib')
69
70     obj.name = 'libdcpomatic'
71     obj.export_includes = ['.']
72     obj.uselib = """
73                  AVCODEC AVUTIL AVFORMAT AVFILTER SWSCALE SWRESAMPLE 
74                  BOOST_FILESYSTEM BOOST_THREAD BOOST_DATETIME BOOST_SIGNALS2 
75                  SNDFILE OPENJPEG POSTPROC TIFF MAGICK SSH DCP CXML GLIB LZMA
76                  """
77
78     obj.source = sources + ' version.cc'
79
80     if bld.env.TARGET_WINDOWS:
81         obj.uselib += ' WINSOCK2 BFD DBGHELP IBERTY'
82         obj.source += ' stack.cpp'
83     if bld.env.STATIC:
84         obj.uselib += ' XML++'
85     obj.source = sources + " version.cc"
86     obj.target = 'dcpomatic'
87
88     i18n.po_to_mo(os.path.join('src', 'lib'), 'libdcpomatic', bld)
89
90 def pot(bld):
91     i18n.pot(os.path.join('src', 'lib'), sources, 'libdcpomatic')
92
93 def pot_merge(bld):
94     i18n.pot_merge(os.path.join('src', 'lib'), 'libdcpomatic')