X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=gtk2_ardour%2Fwscript;h=80e54ef231f71c3ad66409126a02210fe69c7bf8;hb=035de2a367acd7ee27c3dbfba2f6c71f3c137eb8;hp=6a71c7718bb84a0b5b518cd03fe39c5b6dc69336;hpb=f85161c5d0ac5649bf33cf7d165213295a2a9d16;p=ardour.git diff --git a/gtk2_ardour/wscript b/gtk2_ardour/wscript index 6a71c7718b..80e54ef231 100644 --- a/gtk2_ardour/wscript +++ b/gtk2_ardour/wscript @@ -8,9 +8,9 @@ import TaskGen import re # Version of this package (even if built as a child) -MAJOR = '1' +MAJOR = '3' MINOR = '0' -MICRO = '2' +MICRO = '0' GTK2_ARDOUR_VERSION = "%s.%s.%s" % (MAJOR, MINOR, MICRO) # Variables for 'waf dist' @@ -116,15 +116,18 @@ gtk2_ardour_sources = [ 'group_tabs.cc', 'gtk-custom-hruler.c', 'gtk-custom-ruler.c', + 'interthread_progress_window.cc', 'io_selector.cc', 'keyboard.cc', 'keyeditor.cc', 'latency_gui.cc', + 'led.cc', 'level_meter.cc', 'lineset.cc', 'location_ui.cc', 'main.cc', 'marker.cc', + 'midi_automation_line.cc', 'midi_channel_selector.cc', 'midi_cut_buffer.cc', 'midi_list_editor.cc', @@ -162,6 +165,7 @@ gtk2_ardour_sources = [ 'public_editor.cc', 'quantize_dialog.cc', 'rc_option_editor.cc', + 'region_editor.cc', 'region_gain_line.cc', 'region_selection.cc', 'region_view.cc', @@ -234,13 +238,29 @@ def configure(conf): autowaf.check_header(conf, 'boost/shared_ptr.hpp') autowaf.check_header(conf, 'boost/weak_ptr.hpp') +# Add a waf `feature' to allow compilation of things using winegcc +from TaskGen import feature +@feature("wine") +def set_winegcc(self): + self.env.LINK_CXX = self.env.LINK_CC = 'wineg++' + self.env.CC = 'winegcc' + def build(bld): - # Program - obj = bld.new_task_gen(features = 'cxx cc cprogram') + # GTK front-end; if we're using VST we build this as a shared library, otherwise + # it's a normal executabale + if bld.env['VST_SUPPORT']: + obj = bld.new_task_gen(features = 'cxx cc cshlib') + else: + obj = bld.new_task_gen(features = 'cxx cc cprogram') + obj.includes = ['.'] obj.source = gtk2_ardour_sources obj.name = 'gtk2_ardour' - obj.target = 'ardour-3.0' + if bld.env['VST_SUPPORT']: + obj.target = 'gtk2_ardour' + obj.includes += ['../libs/fst'] + else: + obj.target = 'ardour-3.0' obj.install_path = os.path.join(bld.env['LIBDIR'], 'ardour3') obj.uselib = 'UUID FLAC GLIBMM GTHREAD GTK GNOMECANVAS OGG ALSA' obj.uselib += ' GTKMM GNOMECANVASMM OSX GTKOSX COREAUDIO' @@ -248,7 +268,7 @@ def build(bld): libgtkmm2ext libtaglib''' obj.cflags = ['-DPACKAGE="gtk2_ardour"'] obj.cxxflags = ['-DPACKAGE="gtk2_ardour"'] - obj.cxxflags += ['-DVERSIONSTRING="' + GTK2_ARDOUR_VERSION + '"'] + obj.cxxflags += ['-DVERSIONSTRING="' + bld.env['VERSION'] + '"'] obj.cxxflags += ['-DDATA_DIR="' + os.path.normpath(bld.env['DATADIR']) + '"'] obj.cxxflags += ['-DCONFIG_DIR="' + os.path.normpath(bld.env['CONFIGDIR']) + '"'] obj.cxxflags += ['-DMODULE_DIR="' + os.path.normpath(bld.env['LIBDIR']) + '"'] @@ -263,7 +283,7 @@ def build(bld): if bld.env['FREESOUND']: obj.source += [ 'sfdb_freesound_mootcher.cc' ] - if bld.env['VST']: + if bld.env['VST_SUPPORT']: obj.source += [ 'vst_pluginui.cc' ] obj.cxxflags += [ '-DVST_SUPPORT' ] @@ -278,6 +298,24 @@ def build(bld): else: obj.source += [ 'x11.cc' ] + if bld.env['VST_SUPPORT']: + # If we require VST support we build a stub main() and the FST library here using + # winegcc, and link it to the GTK front-end library + obj = bld.new_task_gen (features = 'cxx cc cprogram wine') + obj.source = ''' + ../libs/fst/fst.c + ../libs/fst/fstinfofile.c + ../libs/fst/vsti.c + ../libs/fst/vstwin.c + ../vst/winmain.c + ''' + obj.includes = '../libs/fst' + obj.target = 'ardour-3.0-vst' + obj.linkflags = ['-mwindows', '-Wl,--export-dynamic'] + obj.defines = ['_POSIX_SOURCE', 'USE_WS_PREFIX'] + obj.uselib = 'ALSA' + obj.uselib_local = '''libpbd libmidipp libtaglib libardour libardour_cp libgtkmm2ext libtaglib gtk2_ardour''' + # Wrappers wrapper_subst_dict = {