2009-02-25 18:59:55 -05:00
|
|
|
#!/usr/bin/env python
|
2011-09-29 15:17:54 -04:00
|
|
|
from waflib.extras import autowaf as autowaf
|
2011-09-29 15:58:05 -04:00
|
|
|
from waflib import Options, TaskGen
|
2011-09-29 15:17:54 -04:00
|
|
|
import waflib.Logs as Logs, waflib.Utils as Utils
|
2009-02-25 18:59:55 -05:00
|
|
|
import os
|
2013-12-05 14:44:37 -05:00
|
|
|
import shutil
|
2009-08-08 18:36:32 -04:00
|
|
|
import sys
|
|
|
|
import re
|
2011-10-26 17:47:08 -04:00
|
|
|
import time
|
|
|
|
from waflib.Task import Task
|
2014-10-04 20:12:25 -04:00
|
|
|
from waflib.Tools import winres
|
2015-11-06 10:57:39 -05:00
|
|
|
import subprocess
|
|
|
|
import glob
|
2016-04-27 19:58:54 -04:00
|
|
|
import copy
|
2009-02-25 18:59:55 -05:00
|
|
|
|
|
|
|
# Mandatory variables
|
2011-09-29 15:17:54 -04:00
|
|
|
top = '.'
|
|
|
|
out = 'build'
|
2009-02-25 18:59:55 -05:00
|
|
|
|
2016-04-27 19:58:54 -04:00
|
|
|
from waflib import TaskGen
|
|
|
|
@TaskGen.extension('.m')
|
|
|
|
def m_hook(self, node):
|
|
|
|
"""Alias .m files to be compiled the same as .c files, gcc will do the right thing."""
|
|
|
|
return self.create_compiled_task('c', node)
|
|
|
|
|
2009-02-25 21:24:16 -05:00
|
|
|
path_prefix = 'gtk2_ardour/'
|
|
|
|
|
2009-07-22 09:51:16 -04:00
|
|
|
gtk2_ardour_sources = [
|
2011-03-16 12:32:56 -04:00
|
|
|
'about.cc',
|
|
|
|
'actions.cc',
|
|
|
|
'add_route_dialog.cc',
|
|
|
|
'ambiguous_file_dialog.cc',
|
|
|
|
'analysis_window.cc',
|
|
|
|
'ardour_dialog.cc',
|
2016-07-18 10:45:45 -04:00
|
|
|
'ardour_http.cc',
|
2019-12-14 17:26:25 -05:00
|
|
|
'ardour_message.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'ardour_ui.cc',
|
|
|
|
'ardour_ui2.cc',
|
2019-09-23 16:49:06 -04:00
|
|
|
'ardour_ui3.cc',
|
|
|
|
'ardour_ui_access_web.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'ardour_ui_dependents.cc',
|
|
|
|
'ardour_ui_dialogs.cc',
|
|
|
|
'ardour_ui_ed.cc',
|
2019-09-23 16:49:06 -04:00
|
|
|
'ardour_ui_engine.cc',
|
|
|
|
'ardour_ui_keys.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'ardour_ui_mixer.cc',
|
|
|
|
'ardour_ui_options.cc',
|
2019-09-23 16:49:06 -04:00
|
|
|
'ardour_ui_session.cc',
|
|
|
|
'ardour_ui_startup.cc',
|
|
|
|
'ardour_ui_video.cc',
|
2011-11-18 16:56:01 -05:00
|
|
|
'ardour_window.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'audio_clock.cc',
|
|
|
|
'audio_region_editor.cc',
|
|
|
|
'audio_region_view.cc',
|
|
|
|
'audio_streamview.cc',
|
|
|
|
'audio_time_axis.cc',
|
|
|
|
'automation_controller.cc',
|
|
|
|
'automation_line.cc',
|
|
|
|
'automation_region_view.cc',
|
|
|
|
'automation_streamview.cc',
|
|
|
|
'automation_time_axis.cc',
|
|
|
|
'axis_view.cc',
|
2013-05-04 22:02:05 -04:00
|
|
|
'big_clock_window.cc',
|
2017-12-22 14:21:27 -05:00
|
|
|
'big_transport_window.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'bundle_manager.cc',
|
2011-03-02 17:43:19 -05:00
|
|
|
'clock_group.cc',
|
2016-06-07 14:38:57 -04:00
|
|
|
'color_theme_manager.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'configinfo.cc',
|
|
|
|
'control_point.cc',
|
|
|
|
'control_point_dialog.cc',
|
2016-06-09 12:59:18 -04:00
|
|
|
'control_slave_ui.cc',
|
2014-12-20 01:11:28 -05:00
|
|
|
'cursor_context.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'curvetest.cc',
|
|
|
|
'debug.cc',
|
2015-11-14 10:29:50 -05:00
|
|
|
'duplicate_routes_dialog.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'edit_note_dialog.cc',
|
|
|
|
'editing.cc',
|
|
|
|
'editor.cc',
|
|
|
|
'editor_actions.cc',
|
|
|
|
'editor_audio_import.cc',
|
2015-07-31 23:41:26 -04:00
|
|
|
'editor_pt_import.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'editor_audiotrack.cc',
|
|
|
|
'editor_canvas.cc',
|
|
|
|
'editor_canvas_events.cc',
|
|
|
|
'editor_component.cc',
|
|
|
|
'editor_cursors.cc',
|
|
|
|
'editor_drag.cc',
|
|
|
|
'editor_route_groups.cc',
|
|
|
|
'editor_export_audio.cc',
|
|
|
|
'editor_group_tabs.cc',
|
|
|
|
'editor_keys.cc',
|
|
|
|
'editor_locations.cc',
|
|
|
|
'editor_markers.cc',
|
|
|
|
'editor_mixer.cc',
|
|
|
|
'editor_mouse.cc',
|
|
|
|
'editor_ops.cc',
|
|
|
|
'editor_regions.cc',
|
|
|
|
'editor_routes.cc',
|
|
|
|
'editor_rulers.cc',
|
|
|
|
'editor_selection.cc',
|
|
|
|
'editor_snapshots.cc',
|
2018-11-15 10:21:55 -05:00
|
|
|
'editor_sources.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'editor_summary.cc',
|
|
|
|
'editor_tempodisplay.cc',
|
|
|
|
'editor_timefx.cc',
|
|
|
|
'engine_dialog.cc',
|
|
|
|
'enums.cc',
|
|
|
|
'export_channel_selector.cc',
|
|
|
|
'export_dialog.cc',
|
|
|
|
'export_file_notebook.cc',
|
|
|
|
'export_filename_selector.cc',
|
|
|
|
'export_format_dialog.cc',
|
|
|
|
'export_format_selector.cc',
|
|
|
|
'export_preset_selector.cc',
|
2016-02-09 21:06:47 -05:00
|
|
|
'export_report.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'export_timespan_selector.cc',
|
|
|
|
'fft.cc',
|
|
|
|
'fft_graph.cc',
|
|
|
|
'fft_result.cc',
|
2014-10-31 12:26:57 -04:00
|
|
|
'floating_text_entry.cc',
|
2019-01-18 13:22:54 -05:00
|
|
|
'foldback_strip.cc',
|
2013-08-08 14:08:20 -04:00
|
|
|
'sfdb_freesound_mootcher.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'gain_meter.cc',
|
|
|
|
'generic_pluginui.cc',
|
|
|
|
'ghostregion.cc',
|
|
|
|
'global_port_matrix.cc',
|
|
|
|
'group_tabs.cc',
|
2011-07-06 20:37:13 -04:00
|
|
|
'gui_object.cc',
|
2017-03-15 06:34:05 -04:00
|
|
|
'idleometer.cc',
|
2020-12-06 16:05:09 -05:00
|
|
|
'input_port_monitor.cc',
|
2015-06-16 06:23:50 -04:00
|
|
|
'insert_remove_time_dialog.cc',
|
2014-12-24 18:39:15 -05:00
|
|
|
'instrument_selector.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'interthread_progress_window.cc',
|
2021-01-28 21:31:37 -05:00
|
|
|
'io_button.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'io_selector.cc',
|
2013-04-04 00:32:52 -04:00
|
|
|
'hit.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'keyboard.cc',
|
|
|
|
'keyeditor.cc',
|
|
|
|
'latency_gui.cc',
|
2010-05-05 16:29:46 -04:00
|
|
|
'led.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'level_meter.cc',
|
|
|
|
'location_ui.cc',
|
2020-07-19 18:29:56 -04:00
|
|
|
'loudness_dialog.cc',
|
2016-02-23 09:42:53 -05:00
|
|
|
'lua_script_manager.cc',
|
2017-04-24 16:12:09 -04:00
|
|
|
'luadialog.cc',
|
2016-02-21 16:08:36 -05:00
|
|
|
'luainstance.cc',
|
2016-02-23 09:42:13 -05:00
|
|
|
'luawindow.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'main.cc',
|
2012-05-31 19:14:03 -04:00
|
|
|
'main_clock.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'marker.cc',
|
|
|
|
'midi_automation_line.cc',
|
2011-06-13 10:48:48 -04:00
|
|
|
'midi_channel_dialog.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'midi_channel_selector.cc',
|
|
|
|
'midi_cut_buffer.cc',
|
2012-05-23 16:32:55 -04:00
|
|
|
'midi_export_dialog.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'midi_list_editor.cc',
|
|
|
|
'midi_region_view.cc',
|
|
|
|
'midi_scroomer.cc',
|
2011-12-12 14:03:46 -05:00
|
|
|
'midi_selection.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'midi_streamview.cc',
|
|
|
|
'midi_time_axis.cc',
|
|
|
|
'midi_tracer.cc',
|
2012-06-06 09:17:53 -04:00
|
|
|
'midi_velocity_dialog.cc',
|
2016-12-16 19:43:09 -05:00
|
|
|
'mini_timeline.cc',
|
2010-11-09 01:03:51 -05:00
|
|
|
'missing_file_dialog.cc',
|
2020-02-17 19:26:45 -05:00
|
|
|
'missing_filesource_dialog.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'missing_plugin_dialog.cc',
|
|
|
|
'mixer_group_tabs.cc',
|
|
|
|
'mixer_strip.cc',
|
|
|
|
'mixer_ui.cc',
|
2013-06-19 04:25:18 -04:00
|
|
|
'meterbridge.cc',
|
2013-06-23 10:05:52 -04:00
|
|
|
'meter_strip.cc',
|
2013-07-05 07:58:14 -04:00
|
|
|
'meter_patterns.cc',
|
2010-03-10 12:31:16 -05:00
|
|
|
'monitor_section.cc',
|
2015-04-21 09:18:10 -04:00
|
|
|
'monitor_selector.cc',
|
2011-01-07 12:36:01 -05:00
|
|
|
'mono_panner.cc',
|
2012-06-06 07:47:09 -04:00
|
|
|
'mono_panner_editor.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'mouse_cursors.cc',
|
|
|
|
'nag.cc',
|
|
|
|
'new_plugin_preset_dialog.cc',
|
2019-10-09 22:50:34 -04:00
|
|
|
'new_user_wizard.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'normalize_dialog.cc',
|
2013-04-04 00:32:52 -04:00
|
|
|
'note.cc',
|
2013-04-04 18:45:27 -04:00
|
|
|
'note_base.cc',
|
2010-09-15 14:54:04 -04:00
|
|
|
'note_player.cc',
|
2014-11-03 16:37:19 -05:00
|
|
|
'note_select_dialog.cc',
|
2013-03-21 16:16:48 -04:00
|
|
|
'nsm.cc',
|
|
|
|
'nsmclient.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'option_editor.cc',
|
|
|
|
'opts.cc',
|
|
|
|
'panner2d.cc',
|
2012-06-06 07:47:09 -04:00
|
|
|
'panner_editor.cc',
|
2011-12-26 09:05:19 -05:00
|
|
|
'panner_interface.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'panner_ui.cc',
|
2013-04-04 00:32:52 -04:00
|
|
|
'patch_change.cc',
|
2017-09-07 18:30:55 -04:00
|
|
|
'patch_change_widget.cc',
|
2020-04-07 12:38:33 -04:00
|
|
|
'pianokeyboard.cc',
|
|
|
|
'piano_key_bindings.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'piano_roll_header.cc',
|
2013-03-08 11:41:45 -05:00
|
|
|
'pingback.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'playlist_selector.cc',
|
2017-07-20 17:28:52 -04:00
|
|
|
'plugin_display.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'plugin_eq_gui.cc',
|
2016-03-27 15:35:42 -04:00
|
|
|
'plugin_pin_dialog.cc',
|
2018-12-20 10:56:34 -05:00
|
|
|
'plugin_presets_ui.cc',
|
2019-10-24 23:09:43 -04:00
|
|
|
'plugin_scan_dialog.cc',
|
2016-05-19 10:29:39 -04:00
|
|
|
'plugin_setup_dialog.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'plugin_selector.cc',
|
|
|
|
'plugin_ui.cc',
|
2018-09-24 17:20:15 -04:00
|
|
|
'plugin_dspload_ui.cc',
|
2018-09-24 18:12:42 -04:00
|
|
|
'plugin_dspload_window.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'port_group.cc',
|
2010-08-31 10:16:29 -04:00
|
|
|
'port_insert_ui.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'port_matrix.cc',
|
|
|
|
'port_matrix_body.cc',
|
|
|
|
'port_matrix_column_labels.cc',
|
|
|
|
'port_matrix_component.cc',
|
|
|
|
'port_matrix_grid.cc',
|
|
|
|
'port_matrix_labels.cc',
|
|
|
|
'port_matrix_row_labels.cc',
|
|
|
|
'processor_box.cc',
|
2017-05-05 07:31:49 -04:00
|
|
|
'processor_selection.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'patch_change_dialog.cc',
|
|
|
|
'progress_reporter.cc',
|
2018-10-10 05:09:24 -04:00
|
|
|
'pt_import_selector.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'public_editor.cc',
|
|
|
|
'quantize_dialog.cc',
|
|
|
|
'rc_option_editor.cc',
|
2021-02-15 18:08:02 -05:00
|
|
|
'rec_info_box.cc',
|
2020-12-06 16:05:09 -05:00
|
|
|
'recorder_group_tabs.cc',
|
2020-10-26 17:55:00 -04:00
|
|
|
'recorder_ui.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'region_editor.cc',
|
|
|
|
'region_gain_line.cc',
|
|
|
|
'region_layering_order_editor.cc',
|
2020-12-19 10:44:16 -05:00
|
|
|
'region_peak_cursor.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'region_selection.cc',
|
|
|
|
'region_view.cc',
|
|
|
|
'return_ui.cc',
|
|
|
|
'rhythm_ferret.cc',
|
|
|
|
'route_group_dialog.cc',
|
|
|
|
'route_group_menu.cc',
|
|
|
|
'route_params_ui.cc',
|
|
|
|
'route_processor_selection.cc',
|
|
|
|
'route_time_axis.cc',
|
|
|
|
'route_ui.cc',
|
2014-06-25 15:23:25 -04:00
|
|
|
'ruler_dialog.cc',
|
2015-07-05 08:50:02 -04:00
|
|
|
'save_as_dialog.cc',
|
2017-08-18 13:53:46 -04:00
|
|
|
'save_template_dialog.cc',
|
2010-11-09 01:03:51 -05:00
|
|
|
'search_path_option.cc',
|
2019-08-10 17:20:39 -04:00
|
|
|
'screensaver.cc',
|
2016-02-13 20:57:22 -05:00
|
|
|
'script_selector.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'selection.cc',
|
2014-12-14 08:13:38 -05:00
|
|
|
'selection_memento.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'send_ui.cc',
|
2016-09-20 13:46:49 -04:00
|
|
|
'session_archive_dialog.cc',
|
2013-09-23 14:41:52 -04:00
|
|
|
'session_dialog.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'session_import_dialog.cc',
|
|
|
|
'session_metadata_dialog.cc',
|
|
|
|
'session_option_editor.cc',
|
|
|
|
'sfdb_ui.cc',
|
2011-04-19 22:48:34 -04:00
|
|
|
'shuttle_control.cc',
|
2014-05-19 15:50:37 -04:00
|
|
|
'soundcloud_export_selector.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'splash.cc',
|
2011-02-16 23:45:49 -05:00
|
|
|
'speaker_dialog.cc',
|
2019-10-09 22:50:34 -04:00
|
|
|
'startup_fsm.cc',
|
2010-08-15 12:39:51 -04:00
|
|
|
'step_editor.cc',
|
2010-08-02 17:52:21 -04:00
|
|
|
'step_entry.cc',
|
2010-11-30 15:22:43 -05:00
|
|
|
'stereo_panner.cc',
|
2012-06-06 07:47:09 -04:00
|
|
|
'stereo_panner_editor.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'streamview.cc',
|
|
|
|
'strip_silence_dialog.cc',
|
2017-03-10 17:51:39 -05:00
|
|
|
'stripable_colorpicker.cc',
|
2017-06-09 08:48:33 -04:00
|
|
|
'stripable_time_axis.cc',
|
2013-04-04 00:32:52 -04:00
|
|
|
'sys_ex.cc',
|
2017-07-03 06:27:25 -04:00
|
|
|
'template_dialog.cc',
|
2016-05-07 13:03:12 -04:00
|
|
|
'tempo_curve.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'tempo_dialog.cc',
|
2018-02-09 10:59:39 -05:00
|
|
|
'grid_lines.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'time_axis_view.cc',
|
|
|
|
'time_axis_view_item.cc',
|
|
|
|
'time_fx_dialog.cc',
|
2011-06-03 18:18:47 -04:00
|
|
|
'time_info_box.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'time_selection.cc',
|
2014-12-25 10:02:00 -05:00
|
|
|
'timers.cc',
|
2020-12-06 16:05:09 -05:00
|
|
|
'track_record_axis.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'track_selection.cc',
|
|
|
|
'track_view_list.cc',
|
2014-12-28 15:50:57 -05:00
|
|
|
'transform_dialog.cc',
|
2017-12-22 14:20:59 -05:00
|
|
|
'transport_control.cc',
|
|
|
|
'transport_control_ui.cc',
|
2018-09-18 18:52:20 -04:00
|
|
|
'transport_masters_dialog.cc',
|
2011-04-05 22:04:37 -04:00
|
|
|
'transpose_dialog.cc',
|
2011-03-16 12:32:56 -04:00
|
|
|
'ui_config.cc',
|
|
|
|
'utils.cc',
|
2016-01-24 21:27:39 -05:00
|
|
|
'vca_master_strip.cc',
|
2011-05-02 09:38:16 -04:00
|
|
|
'verbose_cursor.cc',
|
2019-10-17 21:50:52 -04:00
|
|
|
'virtual_keyboard_window.cc',
|
2011-10-29 16:07:00 -04:00
|
|
|
'visibility_group.cc',
|
2013-05-04 22:02:05 -04:00
|
|
|
'window_manager.cc',
|
2013-04-11 13:49:29 -04:00
|
|
|
# video-timeline related sources:
|
|
|
|
'video_image_frame.cc',
|
|
|
|
'add_video_dialog.cc',
|
|
|
|
'editor_videotimeline.cc',
|
2016-05-21 12:44:41 -04:00
|
|
|
'vca_time_axis.cc',
|
2013-04-11 13:49:29 -04:00
|
|
|
'video_timeline.cc',
|
|
|
|
'video_monitor.cc',
|
|
|
|
'transcode_ffmpeg.cc',
|
|
|
|
'transcode_video_dialog.cc',
|
|
|
|
'video_server_dialog.cc',
|
|
|
|
'utils_videotl.cc',
|
|
|
|
'export_video_dialog.cc',
|
2018-11-18 21:20:11 -05:00
|
|
|
'export_video_infobox.cc'
|
2009-07-22 09:51:16 -04:00
|
|
|
]
|
|
|
|
|
2015-01-28 17:50:07 -05:00
|
|
|
def enoify (major, minor):
|
2015-11-29 11:48:21 -05:00
|
|
|
# Code names based on
|
|
|
|
# https://en.wikipedia.org/wiki/Brian_Eno_discography
|
|
|
|
#
|
|
|
|
# sort Studio albums + Collaborative albums + Compilation albums by Month/Year.
|
|
|
|
# (no Singles, no EPs, no Video Albums, no Production)
|
2015-01-28 17:50:07 -05:00
|
|
|
if major == 3:
|
|
|
|
return "\\n\\\"E-No\\\""
|
|
|
|
elif major == 4:
|
|
|
|
if minor == 0:
|
|
|
|
return "\\n\\\"No Pussyfooting\\\""
|
|
|
|
elif minor == 1:
|
|
|
|
return "\\n\\\"Here Come the Warm Jets\\\""
|
|
|
|
elif minor == 2:
|
|
|
|
return "\\n\\\"Taking Tiger Mountain\\\""
|
|
|
|
elif minor == 3:
|
|
|
|
return "\\n\\\"Lady June's Linguistic Leprosy\\\""
|
2015-08-05 18:50:54 -04:00
|
|
|
elif minor == 4:
|
|
|
|
return "\\n\\\"Discreet Music\\\""
|
|
|
|
elif minor == 5:
|
|
|
|
return "\\n\\\"Another Green World\\\""
|
|
|
|
elif minor == 6:
|
|
|
|
return "\\n\\\"Evening Star\\\""
|
2015-11-29 11:48:21 -05:00
|
|
|
elif minor == 7:
|
|
|
|
return "\\n\\\"Cluster and Eno\\\""
|
2016-05-30 15:01:16 -04:00
|
|
|
elif major == 5:
|
|
|
|
if minor == 0:
|
2015-11-29 11:48:21 -05:00
|
|
|
return "\\n\\\"Before and After Science\\\""
|
2016-05-30 15:01:16 -04:00
|
|
|
elif minor == 1:
|
|
|
|
return "\\n\\\"After the Heat\\\""
|
2016-08-17 11:03:06 -04:00
|
|
|
elif minor == 2:
|
|
|
|
return "\\n\\\"Music for Airports\\\""
|
|
|
|
elif minor == 3:
|
|
|
|
return "\\n\\\"Music for Films\\\""
|
|
|
|
elif minor == 4:
|
|
|
|
return "\\n\\\"In a Land of Clear Colours\\\""
|
2016-09-29 14:46:04 -04:00
|
|
|
elif minor == 5:
|
|
|
|
return "\\n\\\"The Plateaux of Mirror\\\""
|
|
|
|
elif minor == 6:
|
2017-02-26 09:35:40 -05:00
|
|
|
return "\\n\\\"Possible Musics\\\"" # 1980 Collaborative
|
2016-09-29 14:46:04 -04:00
|
|
|
elif minor == 7:
|
2017-02-26 09:35:40 -05:00
|
|
|
return "\\n\\\"My Life in the Bush of Ghosts\\\"" # 1981
|
|
|
|
elif minor == 8:
|
|
|
|
return "\\n\\\"Music for Airplay\\\"" # 1981 Compilation
|
|
|
|
elif minor == 9:
|
|
|
|
return "\\n\\\"On Land\\\"" # 1982
|
2020-01-24 15:15:57 -05:00
|
|
|
elif minor == 10:
|
2017-02-26 09:35:40 -05:00
|
|
|
return "\\n\\\"Atmospheres and Soundtracks\\\"" # 1983
|
|
|
|
elif minor == 11:
|
|
|
|
return "\\n\\\"More Music for Films\\\"" # 1983
|
|
|
|
elif minor == 12:
|
|
|
|
return "\\n\\\"Working Backwards\\\"" # 1984 Compilation
|
2017-09-18 13:38:54 -04:00
|
|
|
elif major == 6:
|
|
|
|
if minor == 0:
|
2017-02-26 09:35:40 -05:00
|
|
|
return "\\n\\\"The Pearl\\\"" # 1984 Collaborative
|
2017-09-18 13:38:54 -04:00
|
|
|
elif minor == 1:
|
2017-02-26 09:35:40 -05:00
|
|
|
return "\\n\\\"Begegnungen\\\"" # 1984 Compilation
|
2017-09-18 13:38:54 -04:00
|
|
|
elif minor == 2:
|
|
|
|
return "\\n\\\"Thursday Afternoon\\\"" # 1985
|
|
|
|
elif minor == 3:
|
2020-01-24 15:15:57 -05:00
|
|
|
return "\\n\\\"Hybrid\\\"" # 1985 Collaborative
|
2020-11-22 14:22:42 -05:00
|
|
|
elif minor == 4 or minor == 5: # (there was on 6.4 release)
|
2020-01-24 15:15:57 -05:00
|
|
|
return "\\n\\\"Old Land\\\"" # 1985 Compilation
|
2020-11-22 14:22:42 -05:00
|
|
|
elif minor == 6:
|
2020-11-18 16:33:00 -05:00
|
|
|
return "\\n\\\"Desert Island Selection\\\"" # 1986 Compilation
|
|
|
|
elif major == 7:
|
|
|
|
if minor == 0:
|
|
|
|
return "\\n\\\"More Blank Than Frank\\\"" # 1986 Compilation
|
|
|
|
if minor == 1:
|
|
|
|
return "\\n\\\"Music for Films III\\\"" # 1988 Collaborative
|
|
|
|
if minor == 2:
|
|
|
|
return "\\n\\\"Wrong Way Up\\\"" # 1990 Collaborative
|
|
|
|
if minor == 3:
|
|
|
|
return "\\n\\\"Nerve Net\\\"" # 1992
|
|
|
|
if minor == 4:
|
|
|
|
return "\\n\\\"The Shutov Assembly\\\"" # 1992
|
|
|
|
if minor == 5:
|
|
|
|
return "\\n\\\"Neroli\\\"" # 1993
|
2015-01-28 17:50:07 -05:00
|
|
|
return "\\\"\\\""
|
|
|
|
|
2011-09-29 15:17:54 -04:00
|
|
|
def options(opt):
|
2011-04-22 18:15:21 -04:00
|
|
|
autowaf.set_options(opt)
|
2009-02-25 18:59:55 -05:00
|
|
|
|
|
|
|
def configure(conf):
|
2011-09-29 15:17:54 -04:00
|
|
|
conf.load('misc')
|
2011-09-29 15:58:05 -04:00
|
|
|
conf.load('compiler_cxx')
|
2011-04-22 18:15:21 -04:00
|
|
|
autowaf.configure(conf)
|
|
|
|
|
2011-05-16 14:02:38 -04:00
|
|
|
# TODO: Insert a sanity check for on OS X to ensure CoreAudio is present
|
|
|
|
|
2013-10-26 10:22:05 -04:00
|
|
|
autowaf.check_pkg(conf, 'fftw3f', uselib_store='FFTW3F',
|
|
|
|
mandatory=True)
|
2011-05-16 14:02:38 -04:00
|
|
|
autowaf.check_pkg(conf, 'flac', uselib_store='FLAC',
|
|
|
|
atleast_version='1.2.1')
|
2011-09-29 15:58:05 -04:00
|
|
|
autowaf.check_pkg(conf, 'gthread-2.0', uselib_store='GTHREAD',
|
2011-05-16 14:02:38 -04:00
|
|
|
atleast_version='2.10.1')
|
|
|
|
autowaf.check_pkg(conf, 'gtk+-2.0', uselib_store='GTK',
|
|
|
|
atleast_version='2.18')
|
|
|
|
autowaf.check_pkg(conf, 'gtkmm-2.4', uselib_store='GTKMM',
|
|
|
|
atleast_version='2.18')
|
2011-04-22 18:15:21 -04:00
|
|
|
autowaf.check_pkg(conf, 'ogg', uselib_store='OGG', atleast_version='1.1.2')
|
2012-12-18 11:42:26 -05:00
|
|
|
autowaf.check_pkg(conf, 'x11', uselib_store='X11', atleast_version='1.1', mandatory=False)
|
2016-10-13 21:30:45 -04:00
|
|
|
autowaf.check_pkg(conf, 'pangoft2', uselib_store='PANGOFT2', atleast_version='1.36.8', mandatory=False)
|
2013-01-29 10:25:30 -05:00
|
|
|
autowaf.check_pkg(conf, 'fontconfig', uselib_store='FONTCONFIG')
|
2011-04-22 18:15:21 -04:00
|
|
|
|
2019-12-09 17:27:04 -05:00
|
|
|
if conf.env.CC_NAME == 'gcc' and Options.options.strict:
|
|
|
|
conf.define('GLIB_DISABLE_DEPRECATION_WARNINGS', 1)
|
|
|
|
for var in ['CFLAGS', 'CXXFLAGS']:
|
|
|
|
for lib in ['GTK', 'GTKMM']:
|
|
|
|
for d in conf.env['INCLUDES_' + lib]:
|
|
|
|
conf.env.append_value(var, ['-isystem', d])
|
2016-04-27 19:58:54 -04:00
|
|
|
|
|
|
|
if sys.platform == 'darwin':
|
2020-01-20 17:08:11 -05:00
|
|
|
conf.check(
|
|
|
|
msg ='Checking for Cocoa live resizing constants',
|
|
|
|
fragment = '#include <AppKit/NSWindow.h>\n int main(void) { (void) NSWindowWillStartLiveResizeNotification; return 0; }\n',
|
|
|
|
define_name = 'HAVE_COCOA_LIVE_RESIZING',
|
|
|
|
uselib_store = 'COCOA_LIVE_RESIZING',
|
|
|
|
compiler = 'cc',
|
|
|
|
compile_filename = 'test.m',
|
|
|
|
execute = True,
|
|
|
|
mandatory = False)
|
2016-04-27 19:58:54 -04:00
|
|
|
|
2011-09-29 15:17:54 -04:00
|
|
|
conf.write_config_header('gtk2ardour-config.h', remove=False)
|
2011-04-22 18:15:21 -04:00
|
|
|
|
2014-09-06 11:59:53 -04:00
|
|
|
bak = conf.env['define_key']
|
|
|
|
conf.define('VERSIONSTRING', str (conf.env['VERSION']))
|
2015-01-28 17:50:07 -05:00
|
|
|
conf.define('CODENAME', enoify(int(conf.env['MAJOR']), int(conf.env['MINOR'])))
|
|
|
|
conf.env['define_key'] = ['VERSIONSTRING', 'CODENAME' ]
|
2014-09-06 11:59:53 -04:00
|
|
|
conf.write_config_header('gtk2ardour-version.h')
|
|
|
|
conf.env['define_key'] = bak;
|
|
|
|
|
2011-04-22 18:15:21 -04:00
|
|
|
# Boost headers
|
2011-09-29 15:17:54 -04:00
|
|
|
autowaf.check_header(conf, 'cxx', 'boost/shared_ptr.hpp')
|
|
|
|
autowaf.check_header(conf, 'cxx', 'boost/weak_ptr.hpp')
|
2009-02-25 18:59:55 -05:00
|
|
|
|
2010-07-11 17:55:11 -04:00
|
|
|
# Add a waf `feature' to allow compilation of things using winegcc
|
2011-09-29 15:58:05 -04:00
|
|
|
from waflib.TaskGen import feature
|
2010-07-11 17:55:11 -04:00
|
|
|
@feature("wine")
|
|
|
|
def set_winegcc(self):
|
2011-04-22 18:15:21 -04:00
|
|
|
self.env.LINK_CXX = self.env.LINK_CC = 'wineg++'
|
|
|
|
self.env.CC = 'winegcc'
|
2010-07-11 17:55:11 -04:00
|
|
|
|
2011-10-26 17:47:08 -04:00
|
|
|
def _doPyp(infileName, deps = False):
|
2011-09-29 11:22:11 -04:00
|
|
|
outStr = ''
|
2011-10-26 17:47:08 -04:00
|
|
|
out = []
|
|
|
|
re_spaces = re.compile("\s+")
|
|
|
|
|
2011-09-29 11:22:11 -04:00
|
|
|
if infileName == '-':
|
|
|
|
fd = sys.stdin
|
|
|
|
else:
|
2011-09-29 18:50:08 -04:00
|
|
|
fd = open(infileName)
|
2011-09-29 11:22:11 -04:00
|
|
|
inLines = fd.readlines()
|
|
|
|
if fd != sys.stdin:
|
|
|
|
fd.close()
|
2015-11-29 11:52:42 -05:00
|
|
|
|
2011-09-29 17:36:31 -04:00
|
|
|
|
2011-09-29 11:22:11 -04:00
|
|
|
for line in inLines:
|
|
|
|
bits = re_spaces.split(line)
|
|
|
|
if bits[0] == '##include':
|
|
|
|
incName = bits[1]
|
2011-10-26 17:47:08 -04:00
|
|
|
if (deps):
|
|
|
|
out += [ incName ]
|
|
|
|
else:
|
|
|
|
# assume included file comes from same place as source file
|
|
|
|
incName = os.path.join (os.path.dirname (infileName), incName);
|
|
|
|
outStr += _doPyp(incName)
|
2011-09-29 11:22:11 -04:00
|
|
|
else:
|
2011-10-26 17:47:08 -04:00
|
|
|
if not deps:
|
|
|
|
outStr += line
|
2011-09-29 15:17:54 -04:00
|
|
|
|
2011-09-29 11:22:11 -04:00
|
|
|
# done
|
2011-10-26 17:47:08 -04:00
|
|
|
if deps:
|
|
|
|
return out
|
|
|
|
else:
|
|
|
|
return outStr
|
2011-09-29 17:36:31 -04:00
|
|
|
|
2011-09-29 11:22:11 -04:00
|
|
|
def include_processor(task):
|
2011-09-29 15:17:54 -04:00
|
|
|
infileName = task.inputs[0].srcpath()
|
|
|
|
outfileName = os.path.join(out, task.outputs[0].bldpath())
|
2011-09-29 18:50:08 -04:00
|
|
|
fdOut = open (outfileName, "w")
|
2011-09-29 11:22:11 -04:00
|
|
|
fdOut.write (_doPyp(infileName))
|
|
|
|
fdOut.close ()
|
|
|
|
|
|
|
|
|
2011-02-15 13:02:50 -05:00
|
|
|
def build_color_scheme(path, prefix):
|
2011-04-22 18:15:21 -04:00
|
|
|
f = open (path, 'r')
|
|
|
|
color_scheme = ''
|
|
|
|
for line in f:
|
|
|
|
if re.search ('^#@color', line):
|
|
|
|
line.strip() # remove newline
|
|
|
|
words = line.split()
|
|
|
|
if len(color_scheme):
|
|
|
|
color_scheme += ';'
|
|
|
|
color_scheme += prefix
|
|
|
|
color_scheme += '_'
|
|
|
|
color_scheme += words[1]
|
|
|
|
color_scheme += ':'
|
|
|
|
color_scheme += words[2]
|
|
|
|
f.close()
|
|
|
|
return color_scheme
|
|
|
|
|
2009-02-25 18:59:55 -05:00
|
|
|
def build(bld):
|
2011-04-22 18:15:21 -04:00
|
|
|
|
2013-06-11 11:37:52 -04:00
|
|
|
VERSION = "%s.%s" % (bld.env['MAJOR'], bld.env['MINOR'])
|
2015-04-11 10:35:28 -04:00
|
|
|
I18N_PACKAGE = 'gtk2_ardour' + bld.env['MAJOR']
|
2013-06-11 11:37:52 -04:00
|
|
|
|
2016-03-20 15:52:12 -04:00
|
|
|
# Tool to dump lua-bindings (of gtk2ardour + libs)
|
|
|
|
if re.search ("linux", sys.platform) != None and bld.env['LUABINDINGDOC']:
|
|
|
|
obj = bld (features = 'cxx c cxxprogram')
|
|
|
|
obj.install_path = None
|
|
|
|
obj.source = list(gtk2_ardour_sources)
|
|
|
|
obj.target = 'luadoc'
|
2019-11-02 23:11:27 -04:00
|
|
|
obj.includes = ['.', '../libs', '../libs/vst3']
|
2016-03-20 15:52:12 -04:00
|
|
|
obj.use = [
|
|
|
|
'libpbd',
|
|
|
|
'libardour',
|
|
|
|
'libardour_cp',
|
2017-09-24 12:03:54 -04:00
|
|
|
'libtemporal',
|
2016-03-20 15:52:12 -04:00
|
|
|
'libmidipp',
|
|
|
|
'libgtkmm2ext',
|
|
|
|
'libcanvas',
|
2017-07-17 14:12:33 -04:00
|
|
|
'libwaveview',
|
2017-07-15 11:38:28 -04:00
|
|
|
'libwidgets',
|
2016-03-20 15:52:12 -04:00
|
|
|
'libptformat',
|
|
|
|
]
|
|
|
|
obj.defines = [
|
|
|
|
'NOMAIN',
|
|
|
|
'PACKAGE="' + I18N_PACKAGE + '"',
|
|
|
|
'DATA_DIR="' + os.path.normpath(bld.env['DATADIR']) + '"',
|
|
|
|
'CONFIG_DIR="' + os.path.normpath(bld.env['SYSCONFDIR']) + '"',
|
|
|
|
'LOCALEDIR="' + os.path.normpath(bld.env['LOCALEDIR']) + '"',
|
|
|
|
]
|
|
|
|
obj.linkflags = ''
|
2020-03-01 15:26:43 -05:00
|
|
|
obj.uselib = 'UUID FLAC FONTCONFIG GLIBMM GTHREAD GTK OGG CURL DL GTKMM CANVAS FFTW3F LO TAGLIB XML LILV RUBBERBAND AUBIO LRDF ARCHIVE VAMPSDK VAMPHOSTSDK'
|
2016-03-20 15:52:12 -04:00
|
|
|
obj.source += [ 'luadoc.cc', 'bundle_env_linux.cc' ]
|
|
|
|
if bld.is_defined('HAVE_SUIL'):
|
|
|
|
obj.source += [ 'lv2_plugin_ui.cc' ]
|
|
|
|
obj.use += [ 'SUIL' ]
|
|
|
|
if bld.is_defined('LXVST_SUPPORT'):
|
|
|
|
obj.source += [ 'vst_plugin_ui.cc' ]
|
|
|
|
obj.source += [ 'linux_vst_gui_support.cc', 'lxvst_plugin_ui.cc' ]
|
|
|
|
obj.defines += [ 'LXVST_SUPPORT' ]
|
|
|
|
obj.use += [ 'X11' ]
|
|
|
|
|
2020-08-09 19:25:10 -04:00
|
|
|
if bld.is_defined('VST3_SUPPORT'):
|
|
|
|
obj.source += [ 'vst3_plugin_ui.cc' ]
|
|
|
|
if sys.platform == 'darwin':
|
|
|
|
obj.source += [ 'vst3_nsview_plugin_ui.mm' ]
|
|
|
|
elif bld.env['build_target'] == 'mingw':
|
|
|
|
obj.source += [ 'vst3_hwnd_plugin_ui.cc' ]
|
|
|
|
else:
|
|
|
|
obj.source += [ 'vst3_x11_plugin_ui.cc' ]
|
|
|
|
|
2017-07-15 11:38:28 -04:00
|
|
|
# # Tool to test libcanvas
|
|
|
|
# if re.search ("linux", sys.platform) != None and bld.env['CANVASTESTUI']:
|
|
|
|
# obj = bld (features = 'cxx c cxxprogram')
|
|
|
|
# obj.install_path = None
|
|
|
|
# obj.source = list(gtk2_ardour_sources)
|
|
|
|
# obj.source = [ 'ardour_button.cc', 'ui_config.cc', 'tooltips.cc' ]
|
|
|
|
# obj.target = 'canvas_test'
|
|
|
|
# obj.includes = ['.', '../libs']
|
|
|
|
# obj.use = [
|
|
|
|
# 'libpbd',
|
|
|
|
# 'libardour',
|
|
|
|
# 'libardour_cp',
|
2017-09-24 12:03:54 -04:00
|
|
|
# 'libtemporal',
|
2017-07-15 11:38:28 -04:00
|
|
|
# 'libmidipp',
|
|
|
|
# 'libgtkmm2ext',
|
|
|
|
# 'libcanvas',
|
|
|
|
# 'libptformat',
|
|
|
|
# ]
|
|
|
|
# obj.defines = [
|
|
|
|
# 'NOMAIN',
|
|
|
|
# 'PACKAGE="' + I18N_PACKAGE + '"',
|
|
|
|
# 'DATA_DIR="' + os.path.normpath(bld.env['DATADIR']) + '"',
|
|
|
|
# 'CONFIG_DIR="' + os.path.normpath(bld.env['SYSCONFDIR']) + '"',
|
|
|
|
# 'LOCALEDIR="' + os.path.normpath(bld.env['LOCALEDIR']) + '"',
|
|
|
|
# ]
|
|
|
|
# obj.linkflags = ''
|
|
|
|
# obj.uselib = 'UUID FLAC FONTCONFIG GLIBMM GTHREAD GTK OGG CURL DL GTKMM CANVAS FFTW3F LO TAGLIB XML '
|
|
|
|
# # obj.source += [ 'canvas_test.cc', ]
|
|
|
|
# obj.source += [ 'toolbar_test.cc', 'enums.cc']
|
2016-12-11 09:45:42 -05:00
|
|
|
|
2016-03-20 15:52:12 -04:00
|
|
|
|
2014-02-21 21:06:33 -05:00
|
|
|
if bld.is_defined('WINDOWS_VST_SUPPORT') and bld.env['build_target'] != 'mingw':
|
|
|
|
# Windows VST support w/wine
|
2012-02-29 15:16:06 -05:00
|
|
|
# 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
|
2013-12-22 13:39:57 -05:00
|
|
|
obj = bld (features = 'cxx c cxxprogram wine')
|
2015-01-17 15:09:37 -05:00
|
|
|
obj.source = ( '../libs/fst/vstwin.c', '../vst/winmain.c' )
|
2013-12-22 13:39:57 -05:00
|
|
|
#
|
|
|
|
# XXX do we really need to explicitly link to all of these for the wine executable?
|
|
|
|
#
|
2012-02-29 15:16:06 -05:00
|
|
|
obj.use = [ 'libpbd',
|
|
|
|
'libmidipp',
|
|
|
|
'libardour',
|
|
|
|
'libardour_cp',
|
2017-09-24 12:03:54 -04:00
|
|
|
'libtemporal',
|
2013-11-29 22:24:37 -05:00
|
|
|
'libmidipp',
|
2012-03-02 15:51:01 -05:00
|
|
|
'libgtk2_ardour',
|
2012-02-29 15:16:06 -05:00
|
|
|
'libgtkmm2ext',
|
2015-01-17 12:19:25 -05:00
|
|
|
'libcanvas',
|
2017-07-17 14:12:33 -04:00
|
|
|
'libwaveview',
|
2017-07-15 11:38:28 -04:00
|
|
|
'libwidgets',
|
2015-07-31 23:41:26 -04:00
|
|
|
'libptformat',
|
2013-04-04 00:32:52 -04:00
|
|
|
]
|
2014-07-13 08:36:11 -04:00
|
|
|
obj.target = 'ardour-' + str (bld.env['VERSION']) + '-vst.exe.so'
|
2012-03-01 19:51:13 -05:00
|
|
|
obj.includes = [ '../libs/fst', '.' ]
|
2014-02-21 21:23:36 -05:00
|
|
|
obj.linkflags = ['-mwindows', '-Wl,--export-dynamic']
|
2014-12-28 09:18:39 -05:00
|
|
|
obj.linkflags += bld.env['LDFLAGS']
|
2012-02-29 15:16:06 -05:00
|
|
|
obj.defines = ['_POSIX_SOURCE', 'USE_WS_PREFIX']
|
2020-03-18 14:57:59 -04:00
|
|
|
obj.uselib = 'GLIB'
|
2014-04-10 10:23:16 -04:00
|
|
|
obj.install_path = bld.env['DLLDIR']
|
2012-02-29 15:16:06 -05:00
|
|
|
# end of the wine executable
|
|
|
|
|
|
|
|
# now the shared library containing the GTK GUI for ardour
|
|
|
|
obj = bld (features = 'cxx c cxxshlib')
|
2015-11-23 07:52:14 -05:00
|
|
|
# operate on copy to avoid adding sources twice
|
|
|
|
obj.source = list(gtk2_ardour_sources)
|
2012-03-01 18:17:46 -05:00
|
|
|
obj.includes = [ '../libs/fst', '.' ]
|
2012-03-02 17:41:29 -05:00
|
|
|
obj.name = 'libgtk2_ardour'
|
2012-02-29 15:16:06 -05:00
|
|
|
obj.target = 'gtk2_ardour'
|
2020-01-13 18:52:01 -05:00
|
|
|
obj.cflags = [ bld.env['compiler_flags_dict']['pic'] ]
|
2015-07-31 23:41:26 -04:00
|
|
|
|
2011-04-22 18:15:21 -04:00
|
|
|
else:
|
2012-02-29 15:16:06 -05:00
|
|
|
# just the normal executable version of the GTK GUI
|
2014-10-04 20:12:25 -04:00
|
|
|
if bld.env['build_target'] == 'mingw':
|
|
|
|
obj = bld (features = 'cxx c cxxprogram winres')
|
|
|
|
else:
|
|
|
|
obj = bld (features = 'cxx c cxxprogram')
|
2015-11-23 07:52:14 -05:00
|
|
|
# operate on copy to avoid adding sources twice
|
|
|
|
obj.source = list(gtk2_ardour_sources)
|
2020-01-20 17:08:11 -05:00
|
|
|
obj.target = 'ardour-' + str (bld.env['VERSION'])
|
|
|
|
obj.includes = ['.']
|
2013-12-22 13:39:57 -05:00
|
|
|
|
2014-02-21 21:06:33 -05:00
|
|
|
if bld.is_defined('WINDOWS_VST_SUPPORT'):
|
|
|
|
# Windows VST support mingw
|
|
|
|
obj.includes += [ '../libs/fst' ]
|
|
|
|
|
2013-12-22 13:39:57 -05:00
|
|
|
# at this point, "obj" refers to either the normal native executable
|
|
|
|
# OR the shared library built for use with wine on linux.
|
|
|
|
|
|
|
|
obj.use = [ 'libpbd',
|
|
|
|
'libardour',
|
|
|
|
'libardour_cp',
|
2017-09-24 12:03:54 -04:00
|
|
|
'libtemporal',
|
2013-12-22 13:39:57 -05:00
|
|
|
'libmidipp',
|
|
|
|
'libgtkmm2ext',
|
2013-12-23 15:35:49 -05:00
|
|
|
'libcanvas',
|
2017-07-17 14:12:33 -04:00
|
|
|
'libwaveview',
|
2017-07-15 11:38:28 -04:00
|
|
|
'libwidgets',
|
2015-07-31 23:41:26 -04:00
|
|
|
'libptformat',
|
2013-12-22 13:39:57 -05:00
|
|
|
]
|
2012-02-29 15:16:06 -05:00
|
|
|
|
2013-12-27 14:29:06 -05:00
|
|
|
obj.defines = [
|
2011-11-21 17:24:56 -05:00
|
|
|
'PACKAGE="' + I18N_PACKAGE + '"',
|
2011-05-16 14:02:38 -04:00
|
|
|
'DATA_DIR="' + os.path.normpath(bld.env['DATADIR']) + '"',
|
2011-09-29 15:17:54 -04:00
|
|
|
'CONFIG_DIR="' + os.path.normpath(bld.env['SYSCONFDIR']) + '"',
|
2014-12-09 08:19:11 -05:00
|
|
|
'LOCALEDIR="' + os.path.normpath(bld.env['LOCALEDIR']) + '"',
|
2011-05-16 14:02:38 -04:00
|
|
|
]
|
2014-04-29 16:06:32 -04:00
|
|
|
obj.install_path = bld.env['DLLDIR']
|
2015-10-18 08:22:55 -04:00
|
|
|
obj.linkflags = ''
|
2020-02-13 18:20:45 -05:00
|
|
|
obj.uselib = 'UUID FLAC FONTCONFIG GLIBMM GTHREAD GTK OGG CURL DL GTKMM CANVAS FFTW3F LO TAGLIB XML LILV RUBBERBAND AUBIO LRDF ARCHIVE VAMPSDK VAMPHOSTSDK'
|
2013-11-29 22:31:29 -05:00
|
|
|
|
2011-04-22 18:15:21 -04:00
|
|
|
if sys.platform == 'darwin':
|
2015-10-27 13:43:31 -04:00
|
|
|
obj.uselib += ' AUDIOUNITS OSX '
|
2013-04-04 00:32:52 -04:00
|
|
|
obj.use += ' libappleutility'
|
2014-03-02 11:30:51 -05:00
|
|
|
obj.source += [ 'cocoacarbon.mm', 'bundle_env_cocoa.cc' ]
|
2014-05-06 13:14:18 -04:00
|
|
|
elif bld.env['build_target'] == 'mingw':
|
2014-03-02 11:30:51 -05:00
|
|
|
obj.source += [ 'bundle_env_mingw.cc' ]
|
2014-10-04 20:12:25 -04:00
|
|
|
obj.source += [ 'windows_icon.rc' ]
|
2014-03-02 11:30:51 -05:00
|
|
|
else:
|
|
|
|
obj.source += [ 'bundle_env_linux.cc' ]
|
|
|
|
|
2011-05-16 14:02:38 -04:00
|
|
|
obj.includes += ['../libs']
|
2019-11-02 23:11:27 -04:00
|
|
|
obj.includes += ['../libs/vst3']
|
2011-04-22 18:15:21 -04:00
|
|
|
|
2015-07-31 23:41:26 -04:00
|
|
|
obj.use += 'libptformat'
|
|
|
|
|
2014-01-10 16:07:57 -05:00
|
|
|
if bld.env['build_target'] == 'mingw':
|
2015-10-18 08:31:04 -04:00
|
|
|
obj.linkflags += ' -mwindows'
|
2016-10-13 21:30:45 -04:00
|
|
|
obj.use += [ 'PANGOFT2' ]
|
2014-01-10 16:07:57 -05:00
|
|
|
|
2011-09-29 16:29:06 -04:00
|
|
|
if bld.is_defined('HAVE_SUIL'):
|
2011-05-15 19:10:13 -04:00
|
|
|
obj.source += [ 'lv2_plugin_ui.cc' ]
|
2012-10-04 18:21:59 -04:00
|
|
|
obj.use += [ 'SUIL' ]
|
2011-04-22 18:15:21 -04:00
|
|
|
|
2015-10-17 20:44:26 -04:00
|
|
|
if bld.is_defined('HAVE_FFTW35F') and bld.env['build_target'] != 'mingw':
|
2016-01-09 13:03:43 -05:00
|
|
|
bld.env['LIB_FFTW3F'] += ['fftw3f_threads']
|
2015-10-17 13:23:39 -04:00
|
|
|
|
2012-10-04 18:21:59 -04:00
|
|
|
if bld.is_defined('NEED_INTL'):
|
2015-10-18 08:22:55 -04:00
|
|
|
obj.linkflags += ' -lintl'
|
2012-10-04 18:21:59 -04:00
|
|
|
|
2011-11-21 12:42:29 -05:00
|
|
|
if bld.is_defined('WINDOWS_VST_SUPPORT'):
|
|
|
|
obj.source += [ 'windows_vst_plugin_ui.cc' ]
|
|
|
|
obj.defines += [ 'WINDOWS_VST_SUPPORT' ]
|
2014-03-04 09:25:58 -05:00
|
|
|
if bld.env['build_target'] != 'mingw':
|
|
|
|
obj.use += [ 'X11' ]
|
2015-11-29 11:52:42 -05:00
|
|
|
|
2011-09-30 12:22:04 -04:00
|
|
|
if bld.is_defined('LXVST_SUPPORT'):
|
2011-11-23 14:31:04 -05:00
|
|
|
obj.source += [ 'linux_vst_gui_support.cc', 'lxvst_plugin_ui.cc' ]
|
2011-09-20 16:29:47 -04:00
|
|
|
obj.defines += [ 'LXVST_SUPPORT' ]
|
2012-10-04 18:21:59 -04:00
|
|
|
obj.use += [ 'X11' ]
|
2011-11-22 19:55:25 -05:00
|
|
|
|
2016-11-13 10:32:30 -05:00
|
|
|
if bld.is_defined('MACVST_SUPPORT'):
|
|
|
|
obj.source += [ 'mac_vst_plugin_ui.mm' ]
|
|
|
|
obj.defines += [ 'MACVST_SUPPORT' ]
|
|
|
|
|
|
|
|
if bld.is_defined('WINDOWS_VST_SUPPORT') or bld.is_defined('LXVST_SUPPORT') or bld.is_defined ('MACVST_SUPPORT'):
|
2011-11-22 19:55:25 -05:00
|
|
|
obj.source += [ 'vst_plugin_ui.cc' ]
|
2015-11-29 11:52:42 -05:00
|
|
|
|
2011-09-30 12:22:04 -04:00
|
|
|
if bld.is_defined('PHONE_HOME'):
|
2011-05-16 14:02:38 -04:00
|
|
|
obj.defines += [ 'PHONE_HOME' ]
|
2011-04-22 18:15:21 -04:00
|
|
|
|
2011-10-18 11:08:42 -04:00
|
|
|
if bld.is_defined('HAVE_COREAUDIO'):
|
2011-04-22 18:15:21 -04:00
|
|
|
TaskGen.task_gen.mappings['.mm'] = TaskGen.task_gen.mappings['.cc']
|
2011-09-29 15:17:54 -04:00
|
|
|
obj.use += ' libappleutility '
|
2011-04-22 18:15:21 -04:00
|
|
|
|
2011-12-02 15:03:03 -05:00
|
|
|
if bld.is_defined('AUDIOUNIT_SUPPORT'):
|
|
|
|
obj.source += [ 'au_pluginui.mm' ]
|
|
|
|
|
2020-08-09 19:25:10 -04:00
|
|
|
if bld.is_defined('VST3_SUPPORT'):
|
|
|
|
obj.source += [ 'vst3_plugin_ui.cc' ]
|
|
|
|
if sys.platform == 'darwin':
|
|
|
|
obj.source += [ 'vst3_nsview_plugin_ui.mm' ]
|
|
|
|
elif bld.env['build_target'] == 'mingw':
|
|
|
|
obj.source += [ 'vst3_hwnd_plugin_ui.cc' ]
|
|
|
|
else:
|
|
|
|
obj.source += [ 'vst3_x11_plugin_ui.cc' ]
|
|
|
|
|
2011-04-22 18:15:21 -04:00
|
|
|
# Wrappers
|
|
|
|
|
|
|
|
wrapper_subst_dict = {
|
|
|
|
'INSTALL_PREFIX' : bld.env['PREFIX'],
|
2014-04-10 10:23:16 -04:00
|
|
|
'LIBDIR' : os.path.normpath(bld.env['DLLDIR']),
|
2012-05-18 13:24:06 -04:00
|
|
|
'DATADIR' : os.path.normpath(bld.env['DATADIR']),
|
2014-06-03 08:27:36 -04:00
|
|
|
'CONFDIR' : os.path.normpath(bld.env['CONFDIR']),
|
2011-09-29 15:17:54 -04:00
|
|
|
'LIBS' : 'build/libs',
|
2015-07-05 08:43:26 -04:00
|
|
|
'VERSION' : str (bld.env['VERSION']),
|
2014-07-13 08:36:11 -04:00
|
|
|
'EXECUTABLE' : 'build/gtk2_ardour/ardour-' + str (bld.env['VERSION'])
|
2011-04-22 18:15:21 -04:00
|
|
|
}
|
|
|
|
|
2011-09-29 15:17:54 -04:00
|
|
|
def set_subst_dict(obj, dict):
|
|
|
|
for i in dict:
|
|
|
|
setattr(obj, i, dict[i])
|
|
|
|
|
2014-12-28 04:20:25 -05:00
|
|
|
obj = bld(features = 'subst')
|
2011-04-22 18:15:21 -04:00
|
|
|
obj.source = 'ardev_common.sh.in'
|
|
|
|
obj.target = 'ardev_common_waf.sh'
|
2011-09-29 15:17:54 -04:00
|
|
|
obj.chmod = Utils.O755
|
2011-04-22 18:15:21 -04:00
|
|
|
obj.dict = wrapper_subst_dict
|
2011-09-29 15:17:54 -04:00
|
|
|
set_subst_dict(obj, wrapper_subst_dict)
|
2011-04-22 18:15:21 -04:00
|
|
|
|
2011-09-29 15:17:54 -04:00
|
|
|
obj = bld(features = 'subst')
|
2011-04-22 18:15:21 -04:00
|
|
|
obj.source = 'ardour.sh.in'
|
2015-04-04 13:10:39 -04:00
|
|
|
obj.target = 'ardour' + str (bld.env['MAJOR'])
|
2011-09-29 15:17:54 -04:00
|
|
|
obj.chmod = Utils.O755
|
2011-04-22 18:15:21 -04:00
|
|
|
obj.dict = wrapper_subst_dict
|
|
|
|
obj.install_path = bld.env['BINDIR']
|
2011-09-29 15:17:54 -04:00
|
|
|
set_subst_dict(obj, wrapper_subst_dict)
|
2011-04-22 18:15:21 -04:00
|
|
|
|
2012-02-29 14:11:42 -05:00
|
|
|
if bld.is_defined('WINDOWS_VST_SUPPORT'):
|
|
|
|
obj = bld(features = 'subst')
|
|
|
|
obj.source = '../vst/ardourvst.in'
|
2015-04-04 13:10:39 -04:00
|
|
|
obj.target = 'ardourvst' + str (bld.env['MAJOR'])
|
2012-02-29 14:11:42 -05:00
|
|
|
obj.chmod = Utils.O755
|
|
|
|
obj.dict = wrapper_subst_dict
|
|
|
|
obj.install_path = bld.env['BINDIR']
|
|
|
|
set_subst_dict(obj, wrapper_subst_dict)
|
|
|
|
|
2011-04-22 18:15:21 -04:00
|
|
|
# Font configuration
|
|
|
|
|
2014-12-08 11:00:00 -05:00
|
|
|
font_subst_dict = {}
|
2011-04-22 18:15:21 -04:00
|
|
|
font_sizes = {}
|
|
|
|
base_font = ""
|
|
|
|
|
|
|
|
# Set up font sizes
|
2015-10-27 13:43:31 -04:00
|
|
|
if sys.platform == 'darwin':
|
2012-01-09 11:13:16 -05:00
|
|
|
basefont = ""
|
2011-04-22 18:15:21 -04:00
|
|
|
font_sizes = {
|
|
|
|
'SMALLER' : '9',
|
|
|
|
'SMALL' : '10',
|
|
|
|
'NORMAL' : '11',
|
2013-08-09 00:50:41 -04:00
|
|
|
'BIG' : '13',
|
2013-03-05 08:51:14 -05:00
|
|
|
'BIGGER' : '17',
|
2011-04-22 18:15:21 -04:00
|
|
|
'LARGE' : '18',
|
|
|
|
'LARGER' : '28',
|
|
|
|
'HUGER' : '36',
|
2012-12-10 20:43:25 -05:00
|
|
|
'MASSIVE' : '60',
|
2012-12-12 09:50:10 -05:00
|
|
|
}
|
2017-08-05 18:01:23 -04:00
|
|
|
if bld.env['build_target'] in ['panther', 'tiger', 'leopard'] or (Options.options.ppc and bld.env['build_target'] == 'snowleopard'):
|
2017-08-05 16:32:13 -04:00
|
|
|
# CTFontManagerRegisterFontsForURL for ArdourMono is 10.6 or newer
|
|
|
|
# "Lucida Grande" is not mono-spaced, but works for most cases, except big-clock-window
|
|
|
|
font_names = {
|
|
|
|
'MONOSPACE' : 'Monaco',
|
|
|
|
'CLOCKFONT' : 'Lucida Grande',
|
|
|
|
}
|
|
|
|
else:
|
|
|
|
font_names = {
|
|
|
|
'MONOSPACE' : 'Monaco',
|
|
|
|
'CLOCKFONT' : 'ArdourMono',
|
|
|
|
}
|
|
|
|
else: # Linux/X11 & Windows fonts
|
2011-04-22 18:15:21 -04:00
|
|
|
basefont = '' # unspecified - use system defaults
|
|
|
|
font_sizes = {
|
2014-12-21 11:55:03 -05:00
|
|
|
'SMALLER' : '6',
|
|
|
|
'SMALL' : '7',
|
|
|
|
'NORMAL' : '8',
|
|
|
|
'BIG' : '11',
|
|
|
|
'BIGGER' : '13.5',
|
|
|
|
'LARGE' : '14.5',
|
|
|
|
'LARGER' : '19',
|
|
|
|
'HUGER' : '27',
|
|
|
|
'MASSIVE' : '48',
|
2012-12-12 09:50:10 -05:00
|
|
|
}
|
|
|
|
font_names = {
|
2013-01-30 08:13:57 -05:00
|
|
|
'MONOSPACE' : 'ArdourMono',
|
2015-04-06 15:01:59 -04:00
|
|
|
'CLOCKFONT' : 'ArdourMono',
|
2012-12-12 09:50:10 -05:00
|
|
|
}
|
2011-03-16 12:32:56 -04:00
|
|
|
|
2011-06-07 12:42:48 -04:00
|
|
|
# Set up font substitution dictionary
|
|
|
|
# @FONT_XXXX@
|
2011-04-22 18:15:21 -04:00
|
|
|
for style in ['', 'BOLD', 'ITALIC']:
|
|
|
|
for sizename,points in iter(font_sizes.items()):
|
|
|
|
if (len (style)):
|
|
|
|
key = "_".join (['FONT',style,sizename])
|
|
|
|
fontstyle = " ".join ([basefont,style.lower(),points])
|
|
|
|
else:
|
|
|
|
key = "_".join (['FONT',sizename])
|
|
|
|
fontstyle = " ".join ([basefont,points])
|
2015-11-29 11:52:42 -05:00
|
|
|
|
2014-12-08 11:00:00 -05:00
|
|
|
font_subst_dict[key] = fontstyle
|
2015-11-29 11:52:42 -05:00
|
|
|
|
2011-06-07 12:42:48 -04:00
|
|
|
# @FONT_SIZE_XXXX@
|
|
|
|
for sizename,points in iter(font_sizes.items()):
|
|
|
|
key = "_".join (['FONT_SIZE',sizename])
|
2014-12-08 11:00:00 -05:00
|
|
|
font_subst_dict[key] = points
|
2011-06-07 12:42:48 -04:00
|
|
|
|
2012-12-12 09:50:10 -05:00
|
|
|
# various font names, eg @BOLD_MONOSPACE@
|
|
|
|
for font_sym,text in iter(font_names.items()):
|
|
|
|
key = font_sym
|
2014-12-08 11:00:00 -05:00
|
|
|
font_subst_dict[key] = text
|
2011-04-22 18:15:21 -04:00
|
|
|
|
2019-12-04 16:59:51 -05:00
|
|
|
font_subst_dict['FONTFAMILY'] = ''
|
2014-12-08 11:00:00 -05:00
|
|
|
# RC file
|
2011-04-22 18:15:21 -04:00
|
|
|
|
2011-09-29 15:17:54 -04:00
|
|
|
obj = bld(features = 'subst')
|
2014-12-08 11:00:00 -05:00
|
|
|
obj.source = [ 'clearlooks.rc.in' ]
|
|
|
|
obj.target = 'clearlooks.rc'
|
2014-04-10 10:23:16 -04:00
|
|
|
obj.install_path = bld.env['CONFDIR']
|
2014-12-08 11:00:00 -05:00
|
|
|
set_subst_dict(obj, font_subst_dict)
|
2011-06-09 11:44:09 -04:00
|
|
|
|
2019-12-04 16:59:51 -05:00
|
|
|
font_subst_dict['FONTFAMILY'] = 'ArdourSans'
|
|
|
|
|
|
|
|
obj = bld(features = 'subst')
|
|
|
|
obj.source = [ 'clearlooks.rc.in' ]
|
|
|
|
obj.target = 'clearlooks.ardoursans.rc'
|
|
|
|
obj.install_path = bld.env['CONFDIR']
|
|
|
|
set_subst_dict(obj, font_subst_dict)
|
|
|
|
|
2014-06-13 12:20:33 -04:00
|
|
|
obj = bld(features = 'subst')
|
2014-09-07 10:48:09 -04:00
|
|
|
obj.source = [ 'default_ui_config.in' ]
|
|
|
|
obj.target = 'default_ui_config'
|
2014-12-08 11:00:00 -05:00
|
|
|
obj.install_path = bld.env['CONFDIR']
|
|
|
|
set_subst_dict(obj, font_subst_dict)
|
2014-06-13 12:20:33 -04:00
|
|
|
|
2011-04-22 18:15:21 -04:00
|
|
|
# Menus
|
|
|
|
menus_argv = []
|
2015-10-27 14:35:55 -04:00
|
|
|
if sys.platform == 'darwin':
|
|
|
|
menus_argv = [ '-E', '-P', '-D__APPLE__', '-' ]
|
2011-04-22 18:15:21 -04:00
|
|
|
else:
|
|
|
|
menus_argv = [ '-E', '-P' ]
|
2013-03-12 17:00:09 -04:00
|
|
|
|
2019-04-09 07:17:15 -04:00
|
|
|
if bld.is_defined('MIXBUS'):
|
|
|
|
menus_argv += [ '-DMIXBUS' ]
|
|
|
|
|
2015-07-31 23:41:26 -04:00
|
|
|
if bld.is_defined('PTFORMAT'):
|
|
|
|
menus_argv += [ '-DPTFORMAT' ]
|
|
|
|
|
2014-04-10 07:31:26 -04:00
|
|
|
# always build all versions of the menu definitions
|
|
|
|
# so that we can try them out with different program builds.
|
|
|
|
for program in [ 'ardour', 'trx' ]:
|
|
|
|
obj = bld(features = 'command-output')
|
|
|
|
obj.command = 'cpp'
|
|
|
|
obj.command_is_external = True
|
|
|
|
obj.no_inputs = True
|
|
|
|
obj.argv = menus_argv
|
2019-04-09 07:17:15 -04:00
|
|
|
obj.dep_vars = ['PTFORMAT', 'MIXBUS', 'WINDOWS']
|
2014-04-10 07:31:26 -04:00
|
|
|
obj.stdin = program + '.menus.in'
|
|
|
|
obj.stdout = program + '.menus'
|
2014-04-10 10:23:16 -04:00
|
|
|
bld.install_files (bld.env['CONFDIR'], program + '.menus')
|
2011-04-22 18:15:21 -04:00
|
|
|
|
2015-10-22 11:21:01 -04:00
|
|
|
# Freedesktop
|
2015-10-22 12:07:55 -04:00
|
|
|
freedesktop_subst_dict = {
|
2015-10-22 13:03:16 -04:00
|
|
|
'ARDOUR_EXEC' : str (bld.env['lwrcase_dirname']),
|
2015-11-06 10:59:46 -05:00
|
|
|
'ARDOUR_ICON' : str (bld.env['lwrcase_dirname']),
|
|
|
|
'VERSION': str (bld.env['VERSION']),
|
2016-08-13 08:38:28 -04:00
|
|
|
'DATE': str (bld.env['DATE']),
|
2015-10-22 12:07:55 -04:00
|
|
|
}
|
|
|
|
|
2015-10-22 11:21:01 -04:00
|
|
|
if bld.env['FREEDESKTOP']:
|
|
|
|
obj = bld(features = 'subst')
|
|
|
|
obj.source = 'ardour.desktop.in'
|
2015-10-22 13:03:16 -04:00
|
|
|
obj.target = str (bld.env['lwrcase_dirname']) + '.desktop'
|
2015-10-22 11:21:01 -04:00
|
|
|
obj.chmod = Utils.O644
|
2015-10-22 12:07:55 -04:00
|
|
|
obj.dict = freedesktop_subst_dict
|
|
|
|
set_subst_dict(obj, freedesktop_subst_dict)
|
2015-10-22 11:21:01 -04:00
|
|
|
|
|
|
|
obj = bld(features = 'subst')
|
|
|
|
obj.source = 'ardour-mime-info.xml'
|
2015-10-22 15:05:20 -04:00
|
|
|
obj.target = 'ardour.xml'
|
2015-10-22 11:21:01 -04:00
|
|
|
obj.chmod = Utils.O644
|
|
|
|
|
2015-11-06 10:57:39 -05:00
|
|
|
# build appdata with translations
|
|
|
|
appdata_i18n_mo(bld)
|
|
|
|
appdata_i18n_xmlin(bld)
|
2015-10-26 06:04:06 -04:00
|
|
|
obj = bld(features = 'subst')
|
|
|
|
obj.source = 'ardour.appdata.xml.in'
|
2015-11-06 10:57:39 -05:00
|
|
|
obj.target = str (bld.env['lwrcase_dirname']) + '.appdata.xml'
|
2015-10-26 06:04:06 -04:00
|
|
|
obj.chmod = Utils.O644
|
|
|
|
obj.dict = freedesktop_subst_dict
|
|
|
|
set_subst_dict(obj, freedesktop_subst_dict)
|
|
|
|
|
2011-04-22 18:15:21 -04:00
|
|
|
# Keybindings
|
|
|
|
|
2015-08-01 22:39:53 -04:00
|
|
|
# NATIVE ARDOUR BINDING FILES
|
2013-12-05 14:44:37 -05:00
|
|
|
# explicitly state the use of perl here so that it works on windows too
|
2017-07-03 06:27:25 -04:00
|
|
|
#
|
2020-01-25 16:11:56 -05:00
|
|
|
a_rule = 'perl %s/tools/fmt-bindings --platform="%s" --winkey="%s" --accelmap ${SRC[0].abspath()} >${TGT}' % (bld.top_dir, sys.platform, bld.env['WINDOWS_KEY'] )
|
2015-10-26 13:35:45 -04:00
|
|
|
for b in [ 'ardour' ] :
|
2011-09-29 15:17:54 -04:00
|
|
|
obj = bld(
|
2015-10-26 13:35:45 -04:00
|
|
|
target = b + '.keys',
|
2016-03-15 21:24:39 -04:00
|
|
|
source = [ b + '.keys.in', 'mixer.bindings', 'processor_box.bindings', 'step_editing.bindings', 'monitor.bindings' ],
|
2013-12-05 14:44:37 -05:00
|
|
|
rule = a_rule
|
2011-05-16 14:02:38 -04:00
|
|
|
)
|
2014-04-29 16:06:32 -04:00
|
|
|
obj.install_path = bld.env['CONFDIR']
|
2017-07-03 06:27:25 -04:00
|
|
|
|
2011-04-22 18:15:21 -04:00
|
|
|
# Icons/Images
|
2014-04-10 10:23:16 -04:00
|
|
|
bld.install_files(os.path.join (bld.env['DATADIR'], 'icons'), bld.path.ant_glob('icons/*.png'))
|
|
|
|
bld.install_files(bld.env['DATADIR'], 'ArdourMono.ttf')
|
2019-12-05 17:33:27 -05:00
|
|
|
bld.install_files(bld.env['DATADIR'], 'ArdourSans.ttf')
|
2009-02-25 18:59:55 -05:00
|
|
|
|
2016-05-17 07:12:05 -04:00
|
|
|
# Application/Product specific resources (icon, splash)
|
2017-01-03 11:34:36 -05:00
|
|
|
pgmname = bld.env['PROGRAM_NAME']
|
2016-05-17 07:12:05 -04:00
|
|
|
bld.install_files(os.path.join(bld.env['DATADIR'], 'resources'), bld.path.ant_glob('resources/' + pgmname + '*'))
|
2016-05-16 12:47:00 -04:00
|
|
|
|
2015-08-17 07:37:06 -04:00
|
|
|
if bld.env['build_target'] == 'mingw':
|
|
|
|
# These icons need to overwrite the files already installed in the icons
|
|
|
|
# directory above. Do this in the external packaging scripts for now.
|
|
|
|
#bld.install_files(os.path.join (bld.env['DATADIR'], 'icons'), bld.path.ant_glob('icons/cursor_square/*.png'))
|
|
|
|
bld.install_files(os.path.join (bld.env['DATADIR'], 'icons'), 'icons/cursor_square/hotspots')
|
|
|
|
|
2011-04-22 18:15:21 -04:00
|
|
|
# Default UI configuration
|
2014-09-30 18:12:29 -04:00
|
|
|
bld.install_files(bld.env['CONFDIR'], 'default_ui_config')
|
2016-07-18 11:50:21 -04:00
|
|
|
# Color Themes. Find each color file for this program only
|
|
|
|
# and install
|
2017-01-03 11:34:36 -05:00
|
|
|
bld.install_files (os.path.join(bld.env['DATADIR'], 'themes'), bld.path.ant_glob ('themes/*-' + pgmname.lower() + '.colors'));
|
2011-09-29 17:36:31 -04:00
|
|
|
|
2011-04-22 18:15:21 -04:00
|
|
|
# Default export stuff
|
2015-03-11 21:36:33 -04:00
|
|
|
bld.install_files(os.path.join(bld.env['CONFDIR'], 'export'), bld.path.ant_glob('export/*.format'))
|
2011-04-22 18:15:21 -04:00
|
|
|
|
|
|
|
# i18n
|
2011-09-30 12:22:04 -04:00
|
|
|
if bld.is_defined('ENABLE_NLS'):
|
2011-11-05 12:35:24 -04:00
|
|
|
mo_files = bld.path.ant_glob('po/*.mo')
|
2011-04-22 18:15:21 -04:00
|
|
|
for mo in mo_files:
|
2011-11-05 12:35:24 -04:00
|
|
|
lang = os.path.basename(mo.srcpath()).replace('.mo', '')
|
2014-12-09 08:19:11 -05:00
|
|
|
bld.install_as (os.path.join(os.path.normpath(bld.env['LOCALEDIR']), lang, 'LC_MESSAGES', I18N_PACKAGE + '.mo'),
|
|
|
|
mo)
|
2011-04-22 18:15:21 -04:00
|
|
|
|
|
|
|
def i18n(bld):
|
2015-07-05 08:50:02 -04:00
|
|
|
I18N_PACKAGE = 'gtk2_ardour' + bld.env['MAJOR']
|
|
|
|
autowaf.build_i18n(bld, top, 'gtk2_ardour', I18N_PACKAGE, gtk2_ardour_sources,
|
|
|
|
'Paul Davis')
|
2015-11-06 10:57:39 -05:00
|
|
|
appdata_i18n_pot(bld)
|
|
|
|
appdata_i18n_po(bld)
|
2015-11-29 11:52:42 -05:00
|
|
|
|
2011-11-21 16:27:30 -05:00
|
|
|
def i18n_pot(bld):
|
2015-07-05 08:50:02 -04:00
|
|
|
I18N_PACKAGE = 'gtk2_ardour' + bld.env['MAJOR']
|
|
|
|
autowaf.build_i18n_pot(bld, top, 'gtk2_ardour', I18N_PACKAGE, gtk2_ardour_sources,
|
|
|
|
'Paul Davis')
|
2015-11-06 10:57:39 -05:00
|
|
|
appdata_i18n_pot(bld)
|
2011-11-21 16:27:30 -05:00
|
|
|
|
|
|
|
def i18n_po(bld):
|
2015-07-05 08:50:02 -04:00
|
|
|
I18N_PACKAGE = 'gtk2_ardour' + bld.env['MAJOR']
|
|
|
|
autowaf.build_i18n_po(bld, top, 'gtk2_ardour', I18N_PACKAGE, gtk2_ardour_sources,
|
|
|
|
'Paul Davis')
|
2015-11-06 10:57:39 -05:00
|
|
|
appdata_i18n_po(bld)
|
2015-11-29 11:52:42 -05:00
|
|
|
|
2011-11-21 16:27:30 -05:00
|
|
|
def i18n_mo(bld):
|
2015-07-05 08:50:02 -04:00
|
|
|
I18N_PACKAGE = 'gtk2_ardour' + bld.env['MAJOR']
|
|
|
|
autowaf.build_i18n_mo(bld, top, 'gtk2_ardour', I18N_PACKAGE, gtk2_ardour_sources,
|
|
|
|
'Paul Davis')
|
2015-11-06 10:57:39 -05:00
|
|
|
|
|
|
|
def appdata_i18n_pot(bld):
|
|
|
|
potfile = os.path.join(bld.top_dir, 'gtk2_ardour', 'appdata',
|
|
|
|
'ardour.appdata.pot')
|
2016-06-08 07:15:21 -04:00
|
|
|
if bld.cmd == 'i18n_pot':
|
2015-11-23 07:49:41 -05:00
|
|
|
Logs.info('Generating pot file from Ardour appdata')
|
|
|
|
itsfile = os.path.join(bld.top_dir, 'tools', 'as-metainfo.its')
|
|
|
|
adsource = os.path.join(bld.top_dir, 'gtk2_ardour',
|
|
|
|
'ardour.appdata.xml.in.in')
|
|
|
|
Logs.info('Updating ' + potfile)
|
2016-08-08 13:51:20 -04:00
|
|
|
try:
|
|
|
|
subprocess.call(('itstool', '-i', itsfile, '-o', potfile, adsource))
|
|
|
|
except:
|
|
|
|
print ('Error processing appdata pot file - ignored')
|
2015-11-23 07:49:41 -05:00
|
|
|
elif bld.cmd == 'clean' and os.path.exists(potfile):
|
|
|
|
Logs.info('Removing Ardour appdata pot file')
|
|
|
|
os.remove(potfile)
|
2015-11-06 10:57:39 -05:00
|
|
|
|
|
|
|
def appdata_i18n_po(bld):
|
|
|
|
autowaf.build_i18n_po(bld, bld.top_dir, os.path.join(
|
|
|
|
'gtk2_ardour', 'appdata'), 'ardour.appdata', 'dummy', 'dummy')
|
|
|
|
|
|
|
|
def appdata_i18n_mo(bld):
|
|
|
|
autowaf.build_i18n_mo(bld, bld.top_dir, os.path.join(
|
|
|
|
'gtk2_ardour', 'appdata'), 'ardour.appdata', 'dummy', 'dummy')
|
|
|
|
|
|
|
|
def appdata_i18n_xmlin(bld):
|
|
|
|
adxmlinfile = os.path.join(bld.top_dir, 'gtk2_ardour',
|
|
|
|
'ardour.appdata.xml.in')
|
2015-11-23 07:49:41 -05:00
|
|
|
if bld.cmd == 'build':
|
|
|
|
itsfile = os.path.join(bld.top_dir, 'tools', 'as-metainfo.its')
|
|
|
|
adxmlininfile = os.path.join(bld.top_dir, 'gtk2_ardour',
|
|
|
|
'ardour.appdata.xml.in.in')
|
|
|
|
mo_glob = os.path.join(bld.top_dir, 'gtk2_ardour', 'appdata', 'po', '*.mo')
|
|
|
|
mo_files = glob.glob(mo_glob)
|
|
|
|
Logs.info('Generating ' + adxmlinfile)
|
|
|
|
subprocess.call(['itstool', '-i', itsfile, '-o', adxmlinfile,
|
|
|
|
'-j', adxmlininfile] + mo_files)
|
|
|
|
elif bld.cmd == 'clean' and os.path.exists(adxmlinfile):
|
|
|
|
Logs.info('Removing ' + adxmlinfile)
|
|
|
|
os.remove(adxmlinfile)
|