7 Import('env install_prefix final_prefix config_prefix libraries i18n version')
12 # this defines the version number of the GTK interface to ardour
17 gtkardour.Append(DOMAIN=domain, MAJOR=1,MINOR=0,MICRO=2)
18 gtkardour.Append(CXXFLAGS="-DPACKAGE=\\\"" + domain + "\\\"")
19 gtkardour.Append(CXXFLAGS="-DLIBSIGC_DISABLE_DEPRECATED")
20 gtkardour.Append(CXXFLAGS="-DFLOWCANVAS_AA")
21 gtkardour.Append(PACKAGE=domain)
22 gtkardour.Append(POTFILE=domain + '.pot')
26 libraries['gtkmm2ext'],
27 libraries['flowcanvas'],
32 libraries['libgnomecanvas2'],
33 libraries['libgnomecanvasmm'],
44 libraries['soundtouch'],
45 libraries['samplerate'],
47 libraries['libglademm']
51 gtkardour.Merge ([ libraries['fst']])
53 skipped_files=Split("""
57 gtkardour_files=Split("""
65 ardour_ui_dependents.cc
71 automation_gain_line.cc
73 automation_pan_line.cc
74 automation_time_axis.cc
90 editor_canvas_events.cc
93 editor_export_audio.cc
103 editor_region_list.cc
107 editor_selection_list.cc
108 editor_tempodisplay.cc
111 gain_automation_time_axis.cc
120 imageframe_socket_handler.cc
121 imageframe_time_axis.cc
122 imageframe_time_axis_group.cc
123 imageframe_time_axis_view.cc
132 marker_time_axis_view.cc
135 meter_bridge_strip.cc
138 new_session_dialog.cc
141 pan_automation_time_axis.cc
149 redirect_automation_line.cc
150 redirect_automation_time_axis.cc
157 route_redirect_selection.cc
165 time_axis_view_item.cc
173 glade_files=glob.glob('glade/*.glade')
175 intl_files = gtkardour_files + glade_files + glob.glob('*.h')
177 mtest_files=Split("""
181 itest_files=Split("""
186 vst_files = [ 'vst_pluginui.cc' ]
189 extra_sources += vst_files
191 intl_files += extra_sources
193 gtkardour.Append(CCFLAGS="-D_REENTRANT -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE")
194 gtkardour.Append(CXXFLAGS="-DDATA_DIR=\\\""+final_prefix+"/share\\\"")
195 gtkardour.Append(CXXFLAGS="-DLOCALEDIR=\\\""+final_prefix+"/share/locale\\\"")
196 gtkardour.Append(CXXFLAGS="-DGLADEPATH=\\\""+final_prefix+"/share/ardour/glade\\\"")
198 versionflag = '-DVERSIONSTRING=\\\"' + env['VERSION'] + '\\\"'
200 gtkardour.Append(CXXFLAGS=versionflag)
202 gtkardour.VersionBuild(['version.cc','version.h'], 'SConscript')
204 executable = 'ardour.bin'
206 ardour = gtkardour.Program(target = executable, source = gtkardour_files + extra_sources)
207 mtest = gtkardour.Program(target = 'mtest', source = mtest_files)
208 itest = gtkardour.Program(target = 'itest', source = itest_files)
213 Default (env.VersionedExecutable ('tagged_executable', ardour))
216 Export('gtkardour', 'intl_files')
217 SConscript ('po/SConscript')
222 env.Alias('install', env.InstallAs(os.path.join(install_prefix, 'bin')+'/ardour', ardour))
223 env.Alias('install', env.Install(os.path.join(config_prefix, 'ardour'), 'ardour_ui.rc'))
224 env.Alias('install', env.Install(os.path.join(install_prefix, 'share/ardour'), 'splash.ppm'))
225 env.Alias('install', env.Install(os.path.join(install_prefix, 'share/ardour/glade'), glade_files))
228 env.Alias ('tarball', env.Distribute (env['DISTTREE'],
230 'i18n.h', 'gettext.h',
231 'editor_xpms', 'misc_xpms', 'transport_xpms',
232 'ardour_ui.rc', 'splash.ppm'
234 gtkardour_files + vst_files + glade_files +
235 glob.glob('po/*.po') + glob.glob('*.h')))
237 # generate a prototype full-featured ardour_ui.rc file
239 env.Alias ('protorc', env.Command ('proto.rc', gtkardour_files, """
240 grep set_name $SOURCES | \
241 sed 's/.*("\([a-zA-Z_][a-zA-Z_]*\)").*/\\1/' | \
242 grep -v '\\.' | sort | uniq | \
243 awk '/\\./ {} { printf ("style \\"%s\\"\\n{\\n\
244 fg[NORMAL] = { 0, 0, 0 }\\n\
245 fg[ACTIVE] = { 0, 0, 0 }\\n\
246 fg[SELECTED] = { 0, 0, 0 }\\n\
247 bg[NORMAL] = { 0, 0, 0 }\\n\
248 bg[ACTIVE] = { 0, 0, 0 }\\n\
249 bg[SELECTED] = { 0, 0, 0 }\\n\
250 }\\nwidget \\"*%s\\" style \\"%s\\"\\nwidget \\"*%s*\\" style \\"%s\\"\\n\\n", \
251 $$0, $$0, $$0, $$0, $$0) }' > $TARGET && \
252 grep 'color_map\[[a-zA-Z_][a-zA-Z]*\]' $SOURCES | \
253 sed 's/.*\[\([a-zA-Z_][a-zA-Z_]*\)].*/\\1/'| \
255 awk '{ printf ("style \\"%s\\"\\n{\\n\
256 fg[NORMAL] = { 0, 0, 0 }\\n\
257 fg[ACTIVE] = { 0, 0, 0 }\\n\
258 }\\nwidget \\"*%s\\" style \\"%s\\"\\n \\n\\n", $$0, $$0, $$0) }' >> $TARGET ;